[CMAKE] Fix setting CMake build type so we can use other types too (like Release).
authorAmine Khaldi <amine.khaldi@reactos.org>
Sat, 23 May 2015 10:31:52 +0000 (10:31 +0000)
committerAmine Khaldi <amine.khaldi@reactos.org>
Sat, 23 May 2015 10:31:52 +0000 (10:31 +0000)
svn path=/trunk/; revision=67859

reactos/CMakeLists.txt

index eea5cb4..86b006a 100644 (file)
@@ -47,8 +47,10 @@ endif()
 string(TOLOWER ${ARCH} ARCH)
 
 # Default to Debug for the build type
-set(CMAKE_BUILD_TYPE "Debug" CACHE STRING
-    "Choose the type of build, options are: None(CMAKE_CXX_FLAGS or CMAKE_C_FLAGS used) Debug Release RelWithDebInfo MinSizeRel." FORCE)
+if(NOT CMAKE_BUILD_TYPE)
+    set(CMAKE_BUILD_TYPE "Debug" CACHE STRING
+        "Choose the type of build, options are: None(CMAKE_CXX_FLAGS or CMAKE_C_FLAGS used) Debug Release RelWithDebInfo MinSizeRel.")
+endif()
 
 # Compile options
 if(ARCH STREQUAL "i386")