]> https://gitweb.dealii.org/ - dealii-svn.git/commitdiff
CMake: Bugfix: Switch keywords "debug" and "optimized" to "general" if only on type...
authormaier <maier@0785d39b-7218-0410-832d-ea1e28bc413d>
Sun, 10 Mar 2013 09:11:30 +0000 (09:11 +0000)
committermaier <maier@0785d39b-7218-0410-832d-ea1e28bc413d>
Sun, 10 Mar 2013 09:11:30 +0000 (09:11 +0000)
git-svn-id: https://svn.dealii.org/trunk@28845 0785d39b-7218-0410-832d-ea1e28bc413d

deal.II/cmake/config/CMakeLists.txt

index a7b65eaa7d0887d8d6414e355d6e80f71445362f..b427bd153ba1128be662020ee48eff7a5f2a1e42 100644 (file)
@@ -55,10 +55,15 @@ STRIP_FLAG(CMAKE_CXX_FLAGS "-Wno-deprecated-declarations")
 #
 
 FOREACH(_build ${DEAL_II_BUILD_TYPES})
-  IF(_build MATCHES DEBUG)
-    SET(_keyword "debug")
+
+  IF(NOT "${CMAKE_BUILD_TYPE}" STREQUAL "DebugRelease")
+    SET(_keyword "general")
   ELSE()
-    SET(_keyword "optimized")
+    IF(_build MATCHES DEBUG)
+      SET(_keyword "debug")
+    ELSE()
+      SET(_keyword "optimized")
+    ENDIF()
   ENDIF()
 
   SET(CONFIG_LIBRARIES_${_build}
@@ -66,18 +71,14 @@ FOREACH(_build ${DEAL_II_BUILD_TYPES})
     ${DEAL_II_EXTERNAL_LIBRARIES}
     ${DEAL_II_EXTERNAL_LIBRARIES_${_build}}
     )
-
-  IF(NOT "${CONFIG_LIBRARIES_${_build}}" STREQUAL "")
-    LIST(APPEND CONFIG_LIBRARIES
-      ${_keyword}
-      ${CONFIG_LIBRARIES_${_build}}
-      )
-  ENDIF()
+  LIST(APPEND CONFIG_LIBRARIES
+    ${_keyword}
+    ${CONFIG_LIBRARIES_${_build}}
+    )
 
   SET(CONFIG_TARGET_${_build}
     ${DEAL_II_BASE_NAME}${DEAL_II_${_build}_SUFFIX}
     )
-
   LIST(APPEND CONFIG_TARGET
     ${_keyword}
     ${DEAL_II_BASE_NAME}${DEAL_II_${_build}_SUFFIX}

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.