Fix assert macro on Apple/clang when using default cmake build
This commit is contained in:
@@ -96,7 +96,10 @@ macro(compile_flags)
|
|||||||
|
|
||||||
if(NOT CMAKE_BUILD_TYPE)
|
if(NOT CMAKE_BUILD_TYPE)
|
||||||
# Sensible default if no build type specified
|
# Sensible default if no build type specified
|
||||||
add_compile_options(-O2 -DNDEBUG)
|
add_compile_options(-O2)
|
||||||
|
if(NOT CMAKE_CXX_COMPILER_ID STREQUAL "AppleClang")
|
||||||
|
add_compile_options(-DNDEBUG)
|
||||||
|
endif()
|
||||||
endif(NOT CMAKE_BUILD_TYPE)
|
endif(NOT CMAKE_BUILD_TYPE)
|
||||||
|
|
||||||
# When we are a stable release (Release build + USE_ASSERTS not set),
|
# When we are a stable release (Release build + USE_ASSERTS not set),
|
||||||
|
Reference in New Issue
Block a user