diff options
author | Eric Haszlakiewicz <erh+git@nimenees.com> | 2020-03-03 07:54:21 -0600 |
---|---|---|
committer | GitHub <noreply@github.com> | 2020-03-03 07:54:21 -0600 |
commit | a8c9284f06895de483a809add8b9030d7878027e (patch) | |
tree | d5387caea05fdc65871aba90e14f4935f7fa5b18 /CMakeLists.txt | |
parent | b3296e778fc0beb9855282c84a290fb4c4e155bb (diff) | |
parent | 0030e905b4bf2250a9e2f5e18079f3b4fc49b22d (diff) | |
download | json-c-a8c9284f06895de483a809add8b9030d7878027e.tar.gz |
Merge pull request #547 from dota17/assert_test
modify json-c default build type, and fix up the assert() errors in t…
Diffstat (limited to 'CMakeLists.txt')
-rw-r--r-- | CMakeLists.txt | 7 |
1 files changed, 7 insertions, 0 deletions
diff --git a/CMakeLists.txt b/CMakeLists.txt index a086e85..661cd91 100644 --- a/CMakeLists.txt +++ b/CMakeLists.txt @@ -19,6 +19,13 @@ if(POLICY CMP0054) cmake_policy(SET CMP0054 NEW) endif() +# set default build type if not specified by user +if(NOT CMAKE_BUILD_TYPE) + set(CMAKE_BUILD_TYPE debug) +endif() + +set(CMAKE_C_FLAGS_RELEASE "${CMAKE_C_FLAGS_RELEASE} -O2") + # Include file check macros honor CMAKE_REQUIRED_LIBRARIES # i.e. the check_include_file() calls will include -lm when checking. if(POLICY CMP0075) |