add optional flag for disabling compiler optimization (debug only)
authorFelix Fietkau <nbd@openwrt.org>
Thu, 6 Sep 2012 14:54:16 +0000 (16:54 +0200)
committerFelix Fietkau <nbd@openwrt.org>
Thu, 6 Sep 2012 14:54:38 +0000 (16:54 +0200)
CMakeLists.txt

index 4ef4dfaa75045db305c79aeb56dcb615a7bc609f..74cb080582a1c496c50b0b96677a634313875f8b 100644 (file)
@@ -35,6 +35,9 @@ ENDIF()
 
 IF(DEBUG)
   ADD_DEFINITIONS(-DDEBUG -g3)
+  IF(NO_OPTIMIZE)
+    ADD_DEFINITIONS(-O0)
+  ENDIF()
 ENDIF()