]> https://gitweb.dealii.org/ - dealii.git/commitdiff
Require TBB 4.2.0 or newer. 6793/head
authorDavid Wells <wellsd2@rpi.edu>
Tue, 19 Jun 2018 18:02:18 +0000 (14:02 -0400)
committerDavid Wells <wellsd2@rpi.edu>
Wed, 4 Jul 2018 12:01:55 +0000 (08:01 -0400)
TBB 4.1 is not compatible with newer versions of GCC due to some missing
std::atomic::load calls, so lets blacklist all older versions.

cmake/configure/configure_1_threads.cmake

index bfae7589fdf552557736399414146bf02666e745..7cfe00dd43af97c9309d1077fcec82b310c0af69 100644 (file)
@@ -138,6 +138,25 @@ MACRO(FEATURE_THREADS_FIND_EXTERNAL var)
   IF(TBB_FOUND)
     SET(${var} TRUE)
   ENDIF()
+
+  #
+  # TBB versions before 4.2 are missing some explicit calls to std::atomic::load
+  # in ternary expressions; these cause compilation errors in some compilers
+  # (such as GCC 8.1 and newer). To fix this we simply blacklist all older
+  # versions:
+  #
+  IF(TBB_VERSION VERSION_LESS "4.2")
+    MESSAGE(STATUS
+      "The externally provided TBB library is older than version 4.2.0, which "
+      "cannot be used with deal.II."
+      )
+    SET(THREADS_ADDITIONAL_ERROR_STRING
+      "The externally provided TBB library is older than version\n"
+      "4.2.0, which is the oldest version compatible with deal.II and its\n"
+      "supported compilers."
+      )
+    SET(${var} FALSE)
+  ENDIF()
 ENDMACRO()
 
 

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


Typeset in Trocchi and Trocchi Bold Sans Serif.