Browse Source

CMAKE_BUILD_TYPE was being overridden on GNU

lagkey
Trevor Irons 6 years ago
parent
commit
68e6e52d05
1 changed files with 5 additions and 6 deletions
  1. 5
    6
      CMakeLists.txt

+ 5
- 6
CMakeLists.txt View File

22
 ########################################
22
 ########################################
23
 
23
 
24
 ## Options--what do you want to do
24
 ## Options--what do you want to do
25
-
26
 option ( BUILD_SHARED_LIBS      "Shared or static libraries"  OFF )
25
 option ( BUILD_SHARED_LIBS      "Shared or static libraries"  OFF )
27
-set(CMAKE_BUILD_TYPE "Release" STRING
28
-       "Choose the type of build, options are: Debug Release RelWithDebInfo MinSizeRel."
29
-       FORCE cache)
30
-set_property(CACHE CMAKE_BUILD_TYPE PROPERTY STRINGS Debug Release RelWithDebInfo MinSizeRel )
31
- 
26
+
27
+IF( NOT CMAKE_BUILD_TYPE )
28
+   SET( CMAKE_BUILD_TYPE Release ... FORCE )
29
+ENDIF()
30
+
32
 option ( LEMMA_ENABLE_TESTING       "Turn on unit testing" OFF )
31
 option ( LEMMA_ENABLE_TESTING       "Turn on unit testing" OFF )
33
 option ( LEMMA_BUILD_EXAMPLES       "Compile example Lemma applications" OFF )
32
 option ( LEMMA_BUILD_EXAMPLES       "Compile example Lemma applications" OFF )
34
 option ( LEMMA_USE_OPENMP           "Use OpenMP in Lemma" OFF )
33
 option ( LEMMA_USE_OPENMP           "Use OpenMP in Lemma" OFF )

Loading…
Cancel
Save