From: Matthias Maier Date: Sat, 23 May 2020 05:04:58 +0000 (-0500) Subject: CMake: Remove obsolete posix thread barrier detection X-Git-Tag: v9.3.0-rc1~1579^2 X-Git-Url: https://gitweb.dealii.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=refs%2Fpull%2F10324%2Fhead;p=dealii.git CMake: Remove obsolete posix thread barrier detection --- diff --git a/cmake/configure/configure_1_threads.cmake b/cmake/configure/configure_1_threads.cmake index 85d0b3da9b..520f7ceaee 100644 --- a/cmake/configure/configure_1_threads.cmake +++ b/cmake/configure/configure_1_threads.cmake @@ -90,51 +90,6 @@ MACRO(SETUP_THREADING) ENDIF() ADD_FLAGS(THREADS_LINKER_FLAGS "${CMAKE_THREAD_LIBS_INIT}") - - # - # Set up some posix thread specific configuration toggles: - # - IF(NOT CMAKE_SYSTEM_NAME MATCHES "Windows") - - IF(NOT CMAKE_USE_PTHREADS_INIT) - MESSAGE(FATAL_ERROR - "\nInternal configuration error: Not on Windows but posix thread support unavailable\n\n" - ) - ENDIF() - - SET(DEAL_II_USE_MT_POSIX TRUE) - - # - # Check whether posix thread barriers are available: - # - ADD_FLAGS(CMAKE_REQUIRED_FLAGS "${CMAKE_THREAD_LIBS_INIT}") - CHECK_CXX_SOURCE_COMPILES( - " - #include - int main() - { - pthread_barrier_t pb; - pthread_barrier_init (&pb, 0, 1); - pthread_barrier_wait (&pb); - pthread_barrier_destroy (&pb); - return 0; - } - " - DEAL_II_HAVE_MT_POSIX_BARRIERS) - RESET_CMAKE_REQUIRED() - IF(NOT DEAL_II_HAVE_MT_POSIX_BARRIERS) - SET(DEAL_II_USE_MT_POSIX_NO_BARRIERS TRUE) - ENDIF() - - ELSE() - - # - # Poor Windows: - # - SET(DEAL_II_USE_MT_POSIX FALSE) - SET(DEAL_II_USE_MT_POSIX_NO_BARRIERS TRUE) - ENDIF() - ENDMACRO()