aboutsummaryrefslogtreecommitdiffhomepage
path: root/CMakeLists.txt
diff options
context:
space:
mode:
authorvaxerski <[email protected]>2023-03-16 15:40:50 +0000
committervaxerski <[email protected]>2023-03-16 15:40:50 +0000
commite8adae65feb26a16693490a3a1bc10d953e031d8 (patch)
tree385f6e3f02d209f34187631340919755d06e2bfe /CMakeLists.txt
parent96718d8b090cc5013171adeb6f9e41516c8b7503 (diff)
downloadHyprland-e8adae65feb26a16693490a3a1bc10d953e031d8.tar.gz
Hyprland-e8adae65feb26a16693490a3a1bc10d953e031d8.zip
debug: unbreak debug builds
Diffstat (limited to 'CMakeLists.txt')
-rw-r--r--CMakeLists.txt18
1 files changed, 9 insertions, 9 deletions
diff --git a/CMakeLists.txt b/CMakeLists.txt
index 0a262433..a9c972d2 100644
--- a/CMakeLists.txt
+++ b/CMakeLists.txt
@@ -72,6 +72,15 @@ file(GLOB_RECURSE SRCFILES CONFIGURE_DEPENDS "src/*.cpp")
add_executable(Hyprland ${SRCFILES})
+if(CMAKE_BUILD_TYPE MATCHES Debug OR CMAKE_BUILD_TYPE MATCHES DEBUG)
+ message(STATUS "Setting debug flags")
+
+ target_link_libraries(Hyprland asan)
+
+ add_compile_options(-pg -no-pie -fno-builtin -fsanitize=address)
+ add_link_options(-pg -no-pie -fno-builtin)
+endif()
+
include(CheckLibraryExists)
check_library_exists(execinfo backtrace "" HAVE_LIBEXECINFO)
if(HAVE_LIBEXECINFO)
@@ -123,15 +132,6 @@ message(STATUS "Setting link libraries")
target_link_libraries(Hyprland PkgConfig::deps)
-if(CMAKE_BUILD_TYPE MATCHES Debug OR CMAKE_BUILD_TYPE MATCHES DEBUG)
- message(STATUS "Setting debug flags")
-
- target_link_libraries(Hyprland asan)
-
- add_compile_options(-pg -no-pie -fno-builtin -fsanitize=address)
- add_link_options(-pg -no-pie -fno-builtin)
-endif()
-
target_link_libraries(Hyprland
${CMAKE_SOURCE_DIR}/subprojects/wlroots/build/libwlroots.so.12032 # wlroots is provided by us
pixman-1