aboutsummaryrefslogtreecommitdiff
path: root/CMakeLists.txt
diff options
context:
space:
mode:
authorArisotura <thetotalworm@gmail.com>2020-05-10 23:47:09 +0200
committerGitHub <noreply@github.com>2020-05-10 23:47:09 +0200
commitc823b4bfcee01a886a9ddaddc63b3cab4373a6e4 (patch)
tree0d21d13526fe3707d1bd7fee62dfc2a4d44f1692 /CMakeLists.txt
parenta7a286371a31f832234a8a241c216180b3fd6e3d (diff)
parentb341514a221c49b0b444b6185947e4a4c00e9aeb (diff)
Merge pull request #623 from nadiaholmquist/feature/debug-og
Use -Og for debug builds
Diffstat (limited to 'CMakeLists.txt')
-rw-r--r--CMakeLists.txt4
1 files changed, 4 insertions, 0 deletions
diff --git a/CMakeLists.txt b/CMakeLists.txt
index aa33d4b..0aa558d 100644
--- a/CMakeLists.txt
+++ b/CMakeLists.txt
@@ -20,6 +20,10 @@ else()
option(ENABLE_LTO "Enable link-time optimization" OFF)
endif()
+if (CMAKE_BUILD_TYPE STREQUAL Debug)
+ add_compile_options(-Og)
+endif()
+
if(ENABLE_LTO)
add_compile_options(-O3 -flto)
add_link_options(-flto)