Parcourir la source

Test fix of CMake for MacOS

add-code-of-conduct-1
Trevor Irons il y a 6 ans
Parent
révision
3a6f89bc3c
2 fichiers modifiés avec 20 ajouts et 1 suppressions
  1. 20
    0
      CMakeLists.txt
  2. 0
    1
      Modules/FDEM1D/src/FastSinTransformAnderson.cpp

+ 20
- 0
CMakeLists.txt Voir le fichier

@@ -305,6 +305,26 @@ endif()
305 305
 SET(CMAKE_INSTALL_RPATH_USE_LINK_PATH TRUE)
306 306
 
307 307
 if (LEMMA_USE_OPENMP)
308
+
309
+    if(APPLE)
310
+        if(CMAKE_C_COMPILER_ID MATCHES "Clang")
311
+            set(OpenMP_C "${CMAKE_C_COMPILER}")
312
+            set(OpenMP_C_FLAGS "-fopenmp=libomp -Wno-unused-command-line-argument")
313
+            set(OpenMP_C_LIB_NAMES "libomp" "libgomp" "libiomp5")
314
+            set(OpenMP_libomp_LIBRARY ${OpenMP_C_LIB_NAMES})
315
+            set(OpenMP_libgomp_LIBRARY ${OpenMP_C_LIB_NAMES})
316
+            set(OpenMP_libiomp5_LIBRARY ${OpenMP_C_LIB_NAMES})
317
+        endif()
318
+        if(CMAKE_CXX_COMPILER_ID MATCHES "Clang")
319
+            set(OpenMP_CXX "${CMAKE_CXX_COMPILER}")
320
+            set(OpenMP_CXX_FLAGS "-fopenmp=libomp -Wno-unused-command-line-argument")
321
+            set(OpenMP_CXX_LIB_NAMES "libomp" "libgomp" "libiomp5")
322
+            set(OpenMP_libomp_LIBRARY ${OpenMP_CXX_LIB_NAMES})
323
+            set(OpenMP_libgomp_LIBRARY ${OpenMP_CXX_LIB_NAMES})
324
+            set(OpenMP_libiomp5_LIBRARY ${OpenMP_CXX_LIB_NAMES})
325
+        endif()
326
+    endif()
327
+
308 328
     if (CMAKE_CROSSCOMPILING)
309 329
         set (CMAKE_C_FLAGS "${CMAKE_C_FLAGS} -fopenmp")
310 330
         set (CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} -fopenmp")

+ 0
- 1
Modules/FDEM1D/src/FastSinTransformAnderson.cpp Voir le fichier

@@ -9,7 +9,6 @@
9 9
   @author   M. Andy Kass and Trevor P. Irons
10 10
   @date     02/16/2011
11 11
             15 Dec 2018
12
-  @version  $Id: digitalfiltersintrans.cpp 87 2013-09-05 22:44:05Z tirons $
13 12
  **/
14 13
 #include "FastSinTransformAnderson.h"
15 14
 

Chargement…
Annuler
Enregistrer