From 1233027bb14899ce6ffe6923d3c4b3fa3eeb1c0e Mon Sep 17 00:00:00 2001 From: maier Date: Fri, 18 Jan 2013 15:37:17 +0000 Subject: [PATCH] Reorganize and cleanup the configure checks git-svn-id: https://svn.dealii.org/branches/branch_cmake@28129 0785d39b-7218-0410-832d-ea1e28bc413d --- deal.II/CMakeLists.txt | 1 + ...cmake => check_01_compiler_features.cmake} | 67 +++- .../cmake/checks/check_01_cpu_features.cmake | 126 +++++++ ...ures.cmake => check_01_cxx_features.cmake} | 12 +- .../checks/check_01_system_features.cmake | 111 ++++++ ...ugs.cmake => check_02_compiler_bugs.cmake} | 15 +- .../checks/check_for_system_features.cmake | 218 ------------ deal.II/include/deal.II/base/config.h.in | 329 +++++++++--------- 8 files changed, 473 insertions(+), 406 deletions(-) rename deal.II/cmake/checks/{check_for_compiler_features.cmake => check_01_compiler_features.cmake} (84%) create mode 100644 deal.II/cmake/checks/check_01_cpu_features.cmake rename deal.II/cmake/checks/{check_for_cxx_features.cmake => check_01_cxx_features.cmake} (96%) create mode 100644 deal.II/cmake/checks/check_01_system_features.cmake rename deal.II/cmake/checks/{check_for_compiler_bugs.cmake => check_02_compiler_bugs.cmake} (94%) delete mode 100644 deal.II/cmake/checks/check_for_system_features.cmake diff --git a/deal.II/CMakeLists.txt b/deal.II/CMakeLists.txt index 0bc0358352..319173bf18 100644 --- a/deal.II/CMakeLists.txt +++ b/deal.II/CMakeLists.txt @@ -86,6 +86,7 @@ ENDIF() # Run all system checks: # FILE(GLOB _check_files "cmake/checks/*.cmake") +LIST(SORT _check_files) FOREACH(_file ${_check_files}) MESSAGE(STATUS "") MESSAGE(STATUS "Include ${_file}") diff --git a/deal.II/cmake/checks/check_for_compiler_features.cmake b/deal.II/cmake/checks/check_01_compiler_features.cmake similarity index 84% rename from deal.II/cmake/checks/check_for_compiler_features.cmake rename to deal.II/cmake/checks/check_01_compiler_features.cmake index 5742fe0942..ce0a4e40d3 100644 --- a/deal.II/cmake/checks/check_for_compiler_features.cmake +++ b/deal.II/cmake/checks/check_01_compiler_features.cmake @@ -1,6 +1,6 @@ ##### ## -## Copyright (C) 2012 by the deal.II authors +## Copyright (C) 2012, 2013 by the deal.II authors ## ## This file is part of the deal.II library. ## @@ -10,9 +10,55 @@ ## ##### +########################################################################### +# # +# Check for various compiler features: # +# # +########################################################################### + +# +# This file sets up: +# +# DEAL_II_COMPILER_USE_VECTOR_ARITHMETICS +# DEAL_II_VECTOR_ITERATOR_IS_POINTER +# HAVE_BUILTIN_EXPECT +# HAVE_VERBOSE_TERMINATE +# HAVE_GLIBC_STACKTRACE +# HAVE_LIBSTDCXX_DEMANGLER +# DEAL_II_COMPILER_HAS_ATTRIBUTE_PRETTY_FUNCTION +# DEAL_II_MIN_VECTOR_CAPACITY +# DEAL_II_MIN_BOOL_VECTOR_CAPACITY +# DEAL_II_COMPILER_HAS_ATTRIBUTE_DEPRECATED +# DEAL_II_DEPRECATED # -# Check for various compiler features. + + # +# Check whether the compiler allows to use arithmetic operations +# +-*/ on vectorized data types or whether we need to use +# _mm_add_pd for addition and so on. +-*/ is preferred because +# it allows the compiler to choose other optimizations like +# fused multiply add, whereas _mm_add_pd explicitly enforces the +# assembler command. +# +# - Matthias Maier, rewritten 2012 +# +CHECK_CXX_SOURCE_COMPILES( + " + #include + int main() + { + __m128d a, b; + a = _mm_set_sd (1.0); + b = _mm_set1_pd (2.1); + __m128d c = a + b; + __m128d d = b - c; + __m128d e = c * a + d; + __m128d f = e/a; + (void)f; + } + " + DEAL_II_COMPILER_USE_VECTOR_ARITHMETICS) # @@ -107,16 +153,13 @@ CHECK_CXX_SOURCE_COMPILES( # # On Mac OS X, -rdynamic is accepted by the compiler (i.e. # it doesn't produce an error) but we always get a warning -# that it isn't supported. That's pretty stupid because -# we can't test for it. Consequently, only run the test -# if not on OS X. +# that it isn't supported. So, only enable -rdynamic on non-Darwin +# platforms. # # - Matthias Maier, rewritten 2012 # IF(HAVE_GLIBC_STACKTRACE AND NOT CMAKE_SYSTEM_NAME MATCHES "Darwin") - ENABLE_IF_SUPPORTED(CMAKE_SHARED_LINKER_FLAGS "-rdynamic") - ENDIF() @@ -234,11 +277,6 @@ GET_CXX_SOURCE_RETURN_VALUE( DEAL_II_MIN_VECTOR_CAPACITY_RETURN_VALUE) IF(NOT DEAL_II_MIN_VECTOR_CAPACITY) - # We have a problem... - MESSAGE(WARNING - "Could not determine DEAL_II_MIN_VECTOR_CAPACITY, " - "source might not compile..." - ) SET(DEAL_II_MIN_VECTOR_CAPACITY 1) ELSE() SET(DEAL_II_MIN_VECTOR_CAPACITY @@ -267,11 +305,6 @@ GET_CXX_SOURCE_RETURN_VALUE( DEAL_II_MIN_BOOL_VECTOR_CAPACITY_RETURN_VALUE) IF(NOT DEAL_II_MIN_BOOL_VECTOR_CAPACITY) - # We have a problem... - MESSAGE(WARNING - "Could not determine DEAL_II_MIN_VECTOR_CAPACITY, " - "source might not compile..." - ) SET(DEAL_II_MIN_VECTOR_CAPACITY 1) ELSE() SET(DEAL_II_MIN_BOOL_VECTOR_CAPACITY diff --git a/deal.II/cmake/checks/check_01_cpu_features.cmake b/deal.II/cmake/checks/check_01_cpu_features.cmake new file mode 100644 index 0000000000..056758c64e --- /dev/null +++ b/deal.II/cmake/checks/check_01_cpu_features.cmake @@ -0,0 +1,126 @@ +##### +## +## Copyright (C) 2012, 2013 by the deal.II authors +## +## This file is part of the deal.II library. +## +## +## This file is dual licensed under QPL 1.0 and LGPL 2.1 or any later +## version of the LGPL license. +## +## Author: Matthias Maier +## +##### + + +########################################################################### +# # +# Platform and CPU specific tests: # +# # +########################################################################### + +# +# This file sets up +# +# DEAL_II_WORDS_BIGENDIAN +# DEAL_II_HAVE_SSE2 *) +# DEAL_II_HAVE_AVX *) +# DEAL_II_COMPILER_VECTORIZATION_LEVEL +# +# Note: It is possible to disable the platform introspection tests (e.g. +# for cross compiling or for packaging) by defining the variables (*) in +# the cache prior to configure +# + + +# +# Determine the Endianess of the platform: +# +INCLUDE(TestBigEndian) +TEST_BIG_ENDIAN(DEAL_II_WORDS_BIGENDIAN) + + +# +# Check whether the compiler allows for vectorization and that +# vectorization actually works on the given CPU. For this test, we use +# compiler intrinsics similar to what is used in the deal.II library and +# check whether the arithmetic operations are correctly performed on +# examples where all numbers are exactly represented as floating point +# numbers. +# +# - Matthias Maier, rewritten 2012 +# +CHECK_CXX_SOURCE_RUNS( + " + #include + #include + int main() + { + __m128d a, b; + const unsigned int vector_bytes = sizeof(__m128d); + const int n_vectors = vector_bytes/sizeof(double); + __m128d * data = + reinterpret_cast<__m128d*>(_mm_malloc (2*vector_bytes, vector_bytes)); + double * ptr = reinterpret_cast(&a); + ptr[0] = (volatile double)(1.0); + for (int i=1; i(&data[1]); + unsigned int return_value = 0; + if (ptr[0] != 7.3125) + return_value = 1; + for (int i=1; i + #include + int main() + { + __m256d a, b; + const unsigned int vector_bytes = sizeof(__m256d); + const int n_vectors = vector_bytes/sizeof(double); + __m256d * data = + reinterpret_cast<__m256d*>(_mm_malloc (2*vector_bytes, vector_bytes)); + double * ptr = reinterpret_cast(&a); + ptr[0] = (volatile double)(1.0); + for (int i=1; i(&data[1]); + unsigned int return_value = 0; + if (ptr[0] != 7.3125) + return_value = 1; + for (int i=1; i +## This file is dual licensed under QPL 1.0 and LGPL 2.1 or any later +## version of the LGPL license. +## +## Author: Matthias Maier +## +##### + +# +# This file sets up: +# +# HAVE_SYS_RESOURCE_H +# HAVE_SYS_TIME_H +# HAVE_SYS_TIMES_H +# HAVE_SYS_TYPES_H +# HAVE_UNISTD_H +# HAVE_GETHOSTNAME +# HAVE_GETPID +# HAVE_RAND_R +# HAVE_TIMES +# HAVE_JN +# DEAL_II_MSVC +# + + +########################################################################### +# # +# POSIX and Linux specific tests: # +# # +########################################################################### + +CHECK_INCLUDE_FILE("sys/resource.h" HAVE_SYS_RESOURCE_H) +CHECK_INCLUDE_FILE("sys/time.h" HAVE_SYS_TIME_H) +CHECK_INCLUDE_FILE("sys/times.h" HAVE_SYS_TIMES_H) +CHECK_INCLUDE_FILE("sys/types.h" HAVE_SYS_TYPES_H) + + +# +# Check for various posix specific functions. On a posix system they should +# be all defined in unistd.h. On other platforms, most notably +# Windows/MinGW unistd.h is available but not all posix functions. So test +# for each funtion as well. +# +CHECK_INCLUDE_FILE("unistd.h" HAVE_UNISTD_H) +CHECK_FUNCTION_EXISTS(gethostname HAVE_GETHOSTNAME) +CHECK_FUNCTION_EXISTS(getpid HAVE_GETPID) +CHECK_FUNCTION_EXISTS(rand_r HAVE_RAND_R) +CHECK_FUNCTION_EXISTS(times HAVE_TIMES) + + +# +# Do we have the Bessel function jn? +# +FIND_LIBRARY(m_lib NAMES m) +MARK_AS_ADVANCED(m_lib) + +IF(NOT m_lib MATCHES "-NOTFOUND") + SET(CMAKE_REQUIRED_LIBRARIES ${m_lib}) + CHECK_FUNCTION_EXISTS(jn HAVE_JN) + SET(CMAKE_REQUIRED_LIBRARIES) + IF(HAVE_JN) + LIST(APPEND DEAL_II_EXTERNAL_LIBRARIES ${m_lib}) + ENDIF() +ENDIF() + + +########################################################################### +# # +# Windows and CYGWIN specific setup: # +# # +########################################################################### + +IF(CMAKE_SYSTEM_NAME MATCHES "Windows") + # + # Export DEAL_II_MSVC if we are on a Windows platform: + # + SET(DEAL_II_MSVC TRUE) + + # + # Disable -ggdb and -g on Windows/MinGW targets for the moment until the + # compilation issues with too big files are resolved + # + # - Matthias Maier, 2012 + # + STRIP_FLAG(DEAL_II_CXX_FLAGS_DEBUG "-ggdb") + STRIP_FLAG(DEAL_II_SHARED_LINKER_FLAGS_DEBUG "-ggdb") + STRIP_FLAG(DEAL_II_CXX_FLAGS_DEBUG "-g") + STRIP_FLAG(DEAL_II_SHARED_LINKER_FLAGS_DEBUG "-g") +ENDIF() + + +# +# Disable shared libraries on CYGWIN and Windows targets for the moment. +# Our support for shared libraries on Windows is a bit buggy atm.. +# +# - Matthias Maier, 2012 +# +IF( CMAKE_SYSTEM_NAME MATCHES "CYGWIN" OR + CMAKE_SYSTEM_NAME MATCHES "Windows" ) + MESSAGE(WARNING "\n" + "BUILD_SHARED_LIBS forced to OFF\n\n" + ) + SET(BUILD_SHARED_LIBS OFF CACHE BOOL "" FORCE) +ENDIF() + diff --git a/deal.II/cmake/checks/check_for_compiler_bugs.cmake b/deal.II/cmake/checks/check_02_compiler_bugs.cmake similarity index 94% rename from deal.II/cmake/checks/check_for_compiler_bugs.cmake rename to deal.II/cmake/checks/check_02_compiler_bugs.cmake index 568cefed59..767af79679 100644 --- a/deal.II/cmake/checks/check_for_compiler_bugs.cmake +++ b/deal.II/cmake/checks/check_02_compiler_bugs.cmake @@ -1,6 +1,6 @@ ##### ## -## Copyright (C) 2012 by the deal.II authors +## Copyright (C) 2012, 2013 by the deal.II authors ## ## This file is part of the deal.II library. ## @@ -10,9 +10,11 @@ ## ##### -# -# Check for various compiler bugs: -# +########################################################################### +# # +# Check for various compiler bugs: # +# # +########################################################################### # @@ -316,8 +318,8 @@ CHECK_CXX_COMPILER_BUG( template class ConstIterator; int main(){return 0;} " - DEAL_II_TYPE_QUALIFIER_BUG - ) + DEAL_II_TYPE_QUALIFIER_BUG) + IF(DEAL_II_TYPE_QUALIFIER_BUG) ENABLE_IF_SUPPORTED(CMAKE_CXX_FLAGS -Wno-ignored-qualifiers) ENABLE_IF_SUPPORTED(CMAKE_C_FLAGS -Wno-ignored-qualifiers) @@ -355,3 +357,4 @@ IF(DEAL_II_HAVE_BUNDLED_DIRECTORY) ) ENDIF() + diff --git a/deal.II/cmake/checks/check_for_system_features.cmake b/deal.II/cmake/checks/check_for_system_features.cmake deleted file mode 100644 index d7dce0e039..0000000000 --- a/deal.II/cmake/checks/check_for_system_features.cmake +++ /dev/null @@ -1,218 +0,0 @@ -##### -## -## Copyright (C) 2012 by the deal.II authors -## -## This file is part of the deal.II library. -## -## -## This file is dual licensed under QPL 1.0 and LGPL 2.1 or any later -## version of the LGPL license. -## -## Author: Matthias Maier -## -##### - - -########################################################################### -# # -# Platform and CPU specific tests: # -# # -########################################################################### - -# -# Determine the Endianess of the platform: -# -INCLUDE(TestBigEndian) -TEST_BIG_ENDIAN(DEAL_II_WORDS_BIGENDIAN) - - -# -# Check whether the compiler allows for vectorization and that -# vectorization actually works on the given CPU. For this test, we use -# compiler intrinsics similar to what is used in the deal.II library and -# check whether the arithmetic operations are correctly performed on -# examples where all numbers are exactly represented as floating point -# numbers. -# -# - Matthias Maier, rewritten 2012 -# -CHECK_CXX_SOURCE_RUNS( - " - #include - #include - int main() - { - __m128d a, b; - const unsigned int vector_bytes = sizeof(__m128d); - const int n_vectors = vector_bytes/sizeof(double); - __m128d * data = - reinterpret_cast<__m128d*>(_mm_malloc (2*vector_bytes, vector_bytes)); - double * ptr = reinterpret_cast(&a); - ptr[0] = (volatile double)(1.0); - for (int i=1; i(&data[1]); - unsigned int return_value = 0; - if (ptr[0] != 7.3125) - return_value = 1; - for (int i=1; i - #include - int main() - { - __m256d a, b; - const unsigned int vector_bytes = sizeof(__m256d); - const int n_vectors = vector_bytes/sizeof(double); - __m256d * data = - reinterpret_cast<__m256d*>(_mm_malloc (2*vector_bytes, vector_bytes)); - double * ptr = reinterpret_cast(&a); - ptr[0] = (volatile double)(1.0); - for (int i=1; i(&data[1]); - unsigned int return_value = 0; - if (ptr[0] != 7.3125) - return_value = 1; - for (int i=1; i - int main() - { - __m128d a, b; - a = _mm_set_sd (1.0); - b = _mm_set1_pd (2.1); - __m128d c = a + b; - __m128d d = b - c; - __m128d e = c * a + d; - __m128d f = e/a; - (void)f; - } - " - DEAL_II_COMPILER_USE_VECTOR_ARITHMETICS) - - -########################################################################### -# # -# POSIX and Linux specific tests: # -# # -########################################################################### - -CHECK_INCLUDE_FILE("sys/resource.h" HAVE_SYS_RESOURCE_H) -CHECK_INCLUDE_FILE("sys/time.h" HAVE_SYS_TIME_H) -CHECK_INCLUDE_FILE("sys/times.h" HAVE_SYS_TIMES_H) -CHECK_INCLUDE_FILE("sys/types.h" HAVE_SYS_TYPES_H) - - -# -# Check for various posix specific functions. On a posix system they should -# be all defined in unistd.h. On other platforms, most notably -# Windows/MinGW unistd.h is available but not all posix functions. So test -# for each funtion as well. -# -CHECK_INCLUDE_FILE("unistd.h" HAVE_UNISTD_H) -CHECK_FUNCTION_EXISTS(gethostname HAVE_GETHOSTNAME) -CHECK_FUNCTION_EXISTS(getpid HAVE_GETPID) -CHECK_FUNCTION_EXISTS(rand_r HAVE_RAND_R) -CHECK_FUNCTION_EXISTS(times HAVE_TIMES) - - -# -# Do we have the Bessel function jn? -# -FIND_LIBRARY(m_lib NAMES m) -MARK_AS_ADVANCED(m_lib) - -IF(NOT m_lib MATCHES "-NOTFOUND") - SET(CMAKE_REQUIRED_LIBRARIES ${m_lib}) - CHECK_FUNCTION_EXISTS(jn HAVE_JN) - SET(CMAKE_REQUIRED_LIBRARIES) - IF(HAVE_JN) - LIST(APPEND DEAL_II_EXTERNAL_LIBRARIES ${m_lib}) - ENDIF() -ENDIF() - - -########################################################################### -# # -# Windos and CYGWIN specific setup: # -# # -########################################################################### - -IF(CMAKE_SYSTEM_NAME MATCHES "Windows") - # - # Export DEAL_II_MSVC if we are on a Windows platform: - # - SET(DEAL_II_MSVC TRUE) - - # - # Disable -ggdb and -g on Windows/MinGW targets for the moment until the - # compilation issues with too big files is resolved - # - # - Matthias Maier, 2012 - # - STRIP_FLAG(DEAL_II_CXX_FLAGS_DEBUG "-ggdb") - STRIP_FLAG(DEAL_II_SHARED_LINKER_FLAGS_DEBUG "-ggdb") - STRIP_FLAG(DEAL_II_CXX_FLAGS_DEBUG "-g") - STRIP_FLAG(DEAL_II_SHARED_LINKER_FLAGS_DEBUG "-g") -ENDIF() - - -# -# Disable shared libraries on CYGWIN and Windows targets for the moment. -# Our support for shared libraries on Windows is a bit buggy atm.. -# -# - Matthias Maier, 2012 -# -IF( CMAKE_SYSTEM_NAME MATCHES "CYGWIN" OR - CMAKE_SYSTEM_NAME MATCHES "Windows" ) - MESSAGE(WARNING "\n" - "BUILD_SHARED_LIBS forced to OFF\n\n" - ) - SET(BUILD_SHARED_LIBS OFF CACHE BOOL "" FORCE) -ENDIF() - diff --git a/deal.II/include/deal.II/base/config.h.in b/deal.II/include/deal.II/base/config.h.in index 2b6516607f..01f220b53a 100644 --- a/deal.II/include/deal.II/base/config.h.in +++ b/deal.II/include/deal.II/base/config.h.in @@ -39,6 +39,171 @@ #define DEAL_II_VERSION_MINOR @DEAL_II_VERSION_MINOR@ +/******************************************** + * Configured in check_1_compiler_features: * + ********************************************/ + +/* Defined if the compiler can use arithmetic operations on vectorized data types */ +#cmakedefine DEAL_II_COMPILER_USE_VECTOR_ARITHMETICS + +/* Defined if vector iterators are just plain pointers */ +#cmakedefine DEAL_II_VECTOR_ITERATOR_IS_POINTER + +/* Define if the compiler provides __builtin_expect */ +#cmakedefine HAVE_BUILTIN_EXPECT + +/* Define if the compiler provides __verbose_terminate_handler */ +#cmakedefine HAVE_VERBOSE_TERMINATE + +/* Define if deal.II is linked against a libc that provides stacktrace + * debug information that can be printed out in the exception class + * */ +#cmakedefine HAVE_GLIBC_STACKTRACE + +/* Defined if the std c++ library provides a demangler conforming to the + * GCC libstdc++ interface. + */ +#cmakedefine HAVE_LIBSTDCXX_DEMANGLER + +/* If already available, do not define at all. Otherwise, define to + * __func__ if that is available. In all other cases, indicate that no + * information about the present function is available for this compiler. + */ +#cmakedefine __PRETTY_FUNCTION__ @__PRETTY_FUNCTION__@ + +/* Set to the minimal number of elements a std::vector can always hold, + * i.e. its minimal capacity. + */ +#define DEAL_II_MIN_VECTOR_CAPACITY @DEAL_II_MIN_VECTOR_CAPACITY@ + +/* Set to the minimal number of elements a std::vector can always + * hold, i.e. its minimal capacity. + */ +#define DEAL_II_MIN_BOOL_VECTOR_CAPACITY @DEAL_II_MIN_BOOL_VECTOR_CAPACITY@ + +/* If the compiler supports it, then this variable is defined to a string + * that when written after a function name makes the compiler emit a warning + * whenever this function is used somewhere that its use is deprecated. + */ +#cmakedefine DEAL_II_DEPRECATED @DEAL_II_DEPRECATED@ + + +/*************************************** + * Configured in check_1_cpu_features: * + ***************************************/ + +/* Defined if the system stores words with the most significant byte first */ +#cmakedefine DEAL_II_WORDS_BIGENDIAN + +/* Equal to 0 in the generic case, equal to 1 if CPU compiled for supports + * SSE2, equal to 2 if CPU compiled for supports AVX + */ +#define DEAL_II_COMPILER_VECTORIZATION_LEVEL @DEAL_II_COMPILER_VECTORIZATION_LEVEL@ + + +/*************************************** + * Configured in check_1_cxx_features: * + ***************************************/ + +/* Defined if the compiler we use supports the C++2011 standard well enough + * to allow using the standard library classes instead of the corresponding + * BOOST classes. + */ +#cmakedefine DEAL_II_CAN_USE_CXX1X + +/* Defined if isnan is available */ +#cmakedefine HAVE_ISNAN + +/* Defined if _isnan is available */ +#cmakedefine HAVE_UNDERSCORE_ISNAN + +/* Defined if std::isfinite is available */ +#cmakedefine DEAL_II_HAVE_ISFINITE + + +/****************************************** + * Configured in check_1_system_features: * + ******************************************/ + +/* Defined if you have the header file */ +#cmakedefine HAVE_SYS_RESOURCE_H + +/* Defined if you have the header file. */ +#cmakedefine HAVE_SYS_TIME_H + +/* Defined if you have the header file. */ +#cmakedefine HAVE_SYS_TIMES_H + +/* Defined if you have the header file. */ +#cmakedefine HAVE_SYS_TYPES_H + +/* Defined if you have the header file. */ +#cmakedefine HAVE_UNISTD_H + +/* Defined if you have the "gethostname" function. */ +#cmakedefine HAVE_GETHOSTNAME + +/* Defined if you have the "getpid' function. */ +#cmakedefine HAVE_GETPID + +/* Defined if you have the "rand_r" function */ +#cmakedefine HAVE_RAND_R + +/* Defined if you have the "times" function. */ +#cmakedefine HAVE_TIMES + +/* Defined if you have the "jn" function. */ +#cmakedefine HAVE_JN + +/* Defined if deal.II was configured on a native Windows platform. */ +#cmakedefine DEAL_II_MSVC + + +/**************************************** + * Configured in check_2_compiler_bugs: * + ****************************************/ + +/* Defined if we have to work around a bug where the compiler doesn't accept + * an explicit destructor call. See the aclocal.m4 file in the top-level + * directory for a description of this bug. + */ +#cmakedefine DEAL_II_EXPLICIT_DESTRUCTOR_BUG + +/* Defined if we have to work around a bug with some compilers that will not + * allow us to specify a fully specialized class of a template as a friend. + * See the aclocal.m4 file in the top-level directory for a description of + * this bug. + * */ +#cmakedefine DEAL_II_TEMPL_SPEC_FRIEND_BUG + +/* Defined if the compiler refuses to allow the explicit specialization of + * static member arrays. For the exact failure mode, look at aclocal.m4 in the + * top-level directory. + */ +#cmakedefine DEAL_II_MEMBER_ARRAY_SPECIALIZATION_BUG + +/* Defined if the compiler refuses to allow the explicit specialization of + * static member variables. + */ +#cmakedefine DEAL_II_MEMBER_VAR_SPECIALIZATION_BUG + +/* Defined if the compiler does not honor the explicit keyword on template + * constructors. + */ +#cmakedefine DEAL_II_EXPLICIT_CONSTRUCTOR_BUG + +/* Defined if the compiler has a bug in deducing the type of pointers to const + * member functions. + */ +#cmakedefine DEAL_II_CONST_MEMBER_DEDUCTION_BUG + +/* Defined if the compiler gets an internal error compiling some code that + * involves boost::bind + */ +#cmakedefine DEAL_II_BOOST_BIND_COMPILER_BUG + + + /***************************************** * Configured in configure_arpack.cmake: * *****************************************/ @@ -335,169 +500,6 @@ #cmakedefine HAVE_LIBZ -/********************************************** - * Configured in check_for_compiler_features: * - **********************************************/ - -/* Defined if vector iterators are just plain pointers */ -#cmakedefine DEAL_II_VECTOR_ITERATOR_IS_POINTER - -/* Define if the compiler provides __builtin_expect */ -#cmakedefine HAVE_BUILTIN_EXPECT - -/* Define if the compiler provides __verbose_terminate_handler */ -#cmakedefine HAVE_VERBOSE_TERMINATE - -/* Define if deal.II is linked against a libc that provides stacktrace - * debug information that can be printed out in the exception class - * */ -#cmakedefine HAVE_GLIBC_STACKTRACE - -/* Defined if the std c++ library provides a demangler conforming to the - * GCC libstdc++ interface. - */ -#cmakedefine HAVE_LIBSTDCXX_DEMANGLER - -/* If already available, do not define at all. Otherwise, define to - * __func__ if that is available. In all other cases, indicate that no - * information about the present function is available for this compiler. - */ -#cmakedefine __PRETTY_FUNCTION__ @__PRETTY_FUNCTION__@ - -/* Set to the minimal number of elements a std::vector can always hold, - * i.e. its minimal capacity. - */ -#define DEAL_II_MIN_VECTOR_CAPACITY @DEAL_II_MIN_VECTOR_CAPACITY@ - -/* Set to the minimal number of elements a std::vector can always - * hold, i.e. its minimal capacity. - */ -#define DEAL_II_MIN_BOOL_VECTOR_CAPACITY @DEAL_II_MIN_BOOL_VECTOR_CAPACITY@ - -/* If the compiler supports it, then this variable is defined to a string - * that when written after a function name makes the compiler emit a warning - * whenever this function is used somewhere that its use is deprecated. - */ -#cmakedefine DEAL_II_DEPRECATED @DEAL_II_DEPRECATED@ - - - -/****************************************** - * Configured in check_for_compiler_bugs: * - ******************************************/ - -/* Defined if we have to work around a bug where the compiler doesn't accept - * an explicit destructor call. See the aclocal.m4 file in the top-level - * directory for a description of this bug. - */ -#cmakedefine DEAL_II_EXPLICIT_DESTRUCTOR_BUG - -/* Defined if we have to work around a bug with some compilers that will not - * allow us to specify a fully specialized class of a template as a friend. - * See the aclocal.m4 file in the top-level directory for a description of - * this bug. - * */ -#cmakedefine DEAL_II_TEMPL_SPEC_FRIEND_BUG - -/* Defined if the compiler refuses to allow the explicit specialization of - * static member arrays. For the exact failure mode, look at aclocal.m4 in the - * top-level directory. - */ -#cmakedefine DEAL_II_MEMBER_ARRAY_SPECIALIZATION_BUG - -/* Defined if the compiler refuses to allow the explicit specialization of - * static member variables. - */ -#cmakedefine DEAL_II_MEMBER_VAR_SPECIALIZATION_BUG - -/* Defined if the compiler does not honor the explicit keyword on template - * constructors. - */ -#cmakedefine DEAL_II_EXPLICIT_CONSTRUCTOR_BUG - -/* Defined if the compiler has a bug in deducing the type of pointers to const - * member functions. - */ -#cmakedefine DEAL_II_CONST_MEMBER_DEDUCTION_BUG - -/* Defined if the compiler gets an internal error compiling some code that - * involves boost::bind - */ -#cmakedefine DEAL_II_BOOST_BIND_COMPILER_BUG - - - -/***************************************** - * Configured in check_for_cxx_features: * - *****************************************/ - -/* Defined if the compiler we use supports the C++2011 standard well enough - * to allow using the standard library classes instead of the corresponding - * BOOST classes. - */ -#cmakedefine DEAL_II_CAN_USE_CXX1X - -/* Defined if isnan is available */ -#cmakedefine HAVE_ISNAN - -/* Defined if _isnan is available */ -#cmakedefine HAVE_UNDERSCORE_ISNAN - -/* Defined if std::isfinite is available */ -#cmakedefine DEAL_II_HAVE_ISFINITE - - -/******************************************** - * Configured in check_for_system_features: * - ********************************************/ - -/* Defined if the system stores words with the most significant byte first */ -#cmakedefine DEAL_II_WORDS_BIGENDIAN - -/* Equal to 0 in the generic case, equal to 1 if CPU compiled for supports - * SSE2, equal to 2 if CPU compiled for supports AVX - */ -#define DEAL_II_COMPILER_VECTORIZATION_LEVEL @DEAL_II_COMPILER_VECTORIZATION_LEVEL@ - -/* Defined if the compiler can use arithmetic operations on vectorized data - * types - */ -#cmakedefine DEAL_II_COMPILER_USE_VECTOR_ARITHMETICS - - -/* Defined if you have the header file */ -#cmakedefine HAVE_SYS_RESOURCE_H - -/* Defined if you have the header file. */ -#cmakedefine HAVE_SYS_TIME_H - -/* Defined if you have the header file. */ -#cmakedefine HAVE_SYS_TIMES_H - -/* Defined if you have the header file. */ -#cmakedefine HAVE_SYS_TYPES_H - -/* Defined if you have the header file. */ -#cmakedefine HAVE_UNISTD_H - -/* Defined if you have the "gethostname" function. */ -#cmakedefine HAVE_GETHOSTNAME - -/* Defined if you have the "getpid' function. */ -#cmakedefine HAVE_GETPID - -/* Defined if you have the "rand_r" function */ -#cmakedefine HAVE_RAND_R - -/* Defined if you have the "times" function. */ -#cmakedefine HAVE_TIMES - -/* Defined if you have the "jn" function. */ -#cmakedefine HAVE_JN - - -/* Defined if deal.II was configured on a native Windows platform. */ -#cmakedefine DEAL_II_MSVC /* Disable a bunch of warnings for Microsoft Visual C++. */ //#ifdef DEAL_II_MSVC @@ -515,7 +517,6 @@ //# pragma warning( disable : 4808 ) /* case 'value' is not a valid value for switch condition of type 'bool */ //#endif // DEAL_II_MSVC - #include #include -- 2.39.5