diff options
author | Brad King <brad.king@kitware.com> | 2004-06-01 18:08:04 (GMT) |
---|---|---|
committer | Brad King <brad.king@kitware.com> | 2004-06-01 18:08:04 (GMT) |
commit | 830e1ac1d9044790751370b985c80c9ec3be4b1c (patch) | |
tree | 115227c2a65f54d835b5e95ebdd4dcdaa57554ae /Modules/Platform/gcc.cmake | |
parent | 5bbfbd56f584a43b13f3b2409f168bcfd6e02411 (diff) | |
download | CMake-830e1ac1d9044790751370b985c80c9ec3be4b1c.zip CMake-830e1ac1d9044790751370b985c80c9ec3be4b1c.tar.gz CMake-830e1ac1d9044790751370b985c80c9ec3be4b1c.tar.bz2 |
BUG#895: Adding -DNDEBUG to C and C++ flags for release builds.
Diffstat (limited to 'Modules/Platform/gcc.cmake')
-rw-r--r-- | Modules/Platform/gcc.cmake | 8 |
1 files changed, 4 insertions, 4 deletions
diff --git a/Modules/Platform/gcc.cmake b/Modules/Platform/gcc.cmake index 9d289d1..6543f5c 100644 --- a/Modules/Platform/gcc.cmake +++ b/Modules/Platform/gcc.cmake @@ -1,16 +1,16 @@ IF(CMAKE_COMPILER_IS_GNUCC) SET (CMAKE_C_FLAGS_INIT "") SET (CMAKE_C_FLAGS_DEBUG_INIT "-g") - SET (CMAKE_C_FLAGS_MINSIZEREL_INIT "-Os") - SET (CMAKE_C_FLAGS_RELEASE_INIT "-O3") + SET (CMAKE_C_FLAGS_MINSIZEREL_INIT "-Os -DNDEBUG") + SET (CMAKE_C_FLAGS_RELEASE_INIT "-O3 -DNDEBUG") SET (CMAKE_C_FLAGS_RELWITHDEBINFO_INIT "-O2 -g") ENDIF(CMAKE_COMPILER_IS_GNUCC) IF(CMAKE_COMPILER_IS_GNUCXX) SET (CMAKE_CXX_FLAGS_INIT "") SET (CMAKE_CXX_FLAGS_DEBUG_INIT "-g") - SET (CMAKE_CXX_FLAGS_MINSIZEREL_INIT "-Os") - SET (CMAKE_CXX_FLAGS_RELEASE_INIT "-O3") + SET (CMAKE_CXX_FLAGS_MINSIZEREL_INIT "-Os -DNDEBUG") + SET (CMAKE_CXX_FLAGS_RELEASE_INIT "-O3 -DNDEBUG") SET (CMAKE_CXX_FLAGS_RELWITHDEBINFO_INIT "-O2 -g") ENDIF(CMAKE_COMPILER_IS_GNUCXX) |