Browse Source

Merge pull request #952 from gjasny/optional-debug

CMake: Add option to disable Debug tools
bel2125 4 năm trước cách đây
mục cha
commit
7634665f64
1 tập tin đã thay đổi với 4 bổ sung1 xóa
  1. 4 1
      CMakeLists.txt

+ 4 - 1
CMakeLists.txt

@@ -476,8 +476,11 @@ endif()
 
 
 # Set up the definitions
+option(CIVETWEB_ENABLE_DEBUG_TOOLS "For Debug builds enable verbose logging and assertions" ON)
 if (${CMAKE_BUILD_TYPE} MATCHES "[Dd]ebug")
-  add_definitions(-DDEBUG)
+  if(CIVETWEB_ENABLE_DEBUG_TOOLS)
+    add_definitions(-DDEBUG)
+  endif()
   add_definitions(-O0)
   add_definitions(-g)
 endif()