contrib: cmake: set the Debug/Release target depending on the bootstrap flags
authorSteve Lhomme <robUx4@videolabs.io>
Wed, 14 Jun 2017 12:01:52 +0000 (14:01 +0200)
committerHugo Beauzée-Luyssen <hugo@beauzee.fr>
Wed, 14 Jun 2017 14:46:33 +0000 (16:46 +0200)
Signed-off-by: Hugo Beauzée-Luyssen <hugo@beauzee.fr>
contrib/src/main.mak

index 9f49f26..be37866 100644 (file)
@@ -463,6 +463,11 @@ else
        echo "set(CMAKE_SYSTEM_NAME Windows)" >> $@
 endif
 endif
+ifndef WITH_OPTIMIZATION
+       echo "set(CMAKE_BUILD_TYPE Debug)" >> $@
+else
+       echo "set(CMAKE_BUILD_TYPE Release)" >> $@
+endif
        echo "set(CMAKE_RC_COMPILER $(HOST)-windres)" >> $@
 endif
 ifdef HAVE_DARWIN_OS