[Kst] branches/work/kst/portto4/kst/cmake

Peter Kümmel syntheticpp at gmx.net
Sat Jun 1 14:24:07 UTC 2013


SVN commit 1356715 by kuemmel:

add support of Clang's runtime checks

 M  +8 -0      CMakeLists.txt  
 A             modules/Clang-sanitize.cmake  


--- branches/work/kst/portto4/kst/cmake/CMakeLists.txt #1356714:1356715
@@ -45,6 +45,7 @@
 kst_option(bool   ON  all qt5base_only      "Only use Qt5 features available in qtbase")
 kst_option(bool   ON  all opengl            "Use OpenGL")
 kst_option(bool   OFF all clang             "Use Clang compiler")
+kst_option(bool   OFF all sanitize          "Use Clang's sanitizers")
 
 message(STATUS)
 
@@ -63,6 +64,13 @@
 endif()
 
 
+if(kst_sanitize)
+    include(Clang-sanitize)
+    set(clang_flags "${clang_flags}")
+    set(CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} ${clang_flags}")
+endif()
+
+
 set(kst_version_major 2)
 if(kst_version_string)
 	set(kst_version ${kst_version_string})


More information about the Kst mailing list