mirror of
https://github.com/swaywm/sway.git
synced 2024-12-27 15:36:29 +01:00
fix backtrace detection in CMake
works on arch (glibc) and void linux (tested with musl libc) now
This commit is contained in:
parent
03c041dd30
commit
470e59b291
2 changed files with 9 additions and 3 deletions
|
@ -61,9 +61,9 @@ find_package(PAM)
|
||||||
|
|
||||||
find_package(Backtrace)
|
find_package(Backtrace)
|
||||||
if(Backtrace_FOUND)
|
if(Backtrace_FOUND)
|
||||||
include_directories(${Backtrace_INCLUDE_DIRS})
|
include_directories("${Backtrace_INCLUDE_DIRS}")
|
||||||
target_link_libraries(${Backtrace_LIBRARIES})
|
|
||||||
add_definitions(-DSWAY_Backtrace_FOUND=1)
|
add_definitions(-DSWAY_Backtrace_FOUND=1)
|
||||||
|
set(LINK_LIBRARIES, "${LINK_LIBRARIES} ${Backtrace_LIBRARIES}")
|
||||||
set(SWAY_Backtrace_HEADER "${Backtrace_HEADER}")
|
set(SWAY_Backtrace_HEADER "${Backtrace_HEADER}")
|
||||||
endif()
|
endif()
|
||||||
|
|
||||||
|
|
|
@ -1,5 +1,4 @@
|
||||||
add_library(sway-common
|
add_library(sway-common
|
||||||
${SWAY_Backtrace_HEADER}
|
|
||||||
ipc-client.c
|
ipc-client.c
|
||||||
list.c
|
list.c
|
||||||
log.c
|
log.c
|
||||||
|
@ -7,3 +6,10 @@ add_library(sway-common
|
||||||
readline.c
|
readline.c
|
||||||
stringop.c
|
stringop.c
|
||||||
)
|
)
|
||||||
|
|
||||||
|
if(Backtrace_FOUND)
|
||||||
|
set_target_properties(sway-common
|
||||||
|
PROPERTIES
|
||||||
|
COMPILE_FLAGS "-include ${Backtrace_HEADER}"
|
||||||
|
)
|
||||||
|
endif()
|
||||||
|
|
Loading…
Reference in a new issue