This way people can switch off the whole mechanism if the want.
"
_HAVE_FP_EXCEPTIONS)
-IF(_HAVE_FP_EXCEPTIONS)
- MESSAGE(STATUS "Checking for Floating Point Exception macros -- Success")
- SET(DEAL_II_HAVE_FP_EXCEPTIONS 1)
-ELSE()
- MESSAGE(STATUS "Checking for Floating Point Exception macros -- Failed")
+
+SET(DEAL_II_HAVE_FP_EXCEPTIONS ON CACHE BOOL "If ON, floating point exception are raised in debug mode when running the testsuite.")
+
+IF (DEAL_II_HAVE_FP_EXCEPTIONS)
+ IF(_HAVE_FP_EXCEPTIONS)
+ MESSAGE(STATUS "Checking for Floating Point Exception macros -- Success")
+ # nothing to set here -- DEAL_II_HAVE_FP_EXCEPTIONS is already ON
+ ELSE()
+ MESSAGE(STATUS "Checking for Floating Point Exception macros -- Failed")
+ SET(DEAL_II_HAVE_FP_EXCEPTIONS OFF CACHE BOOL "" FORCE)
+ ENDIF()
ENDIF()
In the beginning the Universe was created. This has made a lot of
people very angry and has been widely regarded as a bad move.
Douglas Adams