diff options
-rw-r--r-- | CMakeLists.txt | 4 | ||||
-rw-r--r-- | common/CMakeLists.txt | 8 |
2 files changed, 9 insertions, 3 deletions
diff --git a/CMakeLists.txt b/CMakeLists.txt index bb13ef96..4c349865 100644 --- a/CMakeLists.txt +++ b/CMakeLists.txt | |||
@@ -61,9 +61,9 @@ find_package(PAM) | |||
61 | 61 | ||
62 | find_package(Backtrace) | 62 | find_package(Backtrace) |
63 | if(Backtrace_FOUND) | 63 | if(Backtrace_FOUND) |
64 | include_directories(${Backtrace_INCLUDE_DIRS}) | 64 | include_directories("${Backtrace_INCLUDE_DIRS}") |
65 | target_link_libraries(${Backtrace_LIBRARIES}) | ||
66 | add_definitions(-DSWAY_Backtrace_FOUND=1) | 65 | add_definitions(-DSWAY_Backtrace_FOUND=1) |
66 | set(LINK_LIBRARIES, "${LINK_LIBRARIES} ${Backtrace_LIBRARIES}") | ||
67 | set(SWAY_Backtrace_HEADER "${Backtrace_HEADER}") | 67 | set(SWAY_Backtrace_HEADER "${Backtrace_HEADER}") |
68 | endif() | 68 | endif() |
69 | 69 | ||
diff --git a/common/CMakeLists.txt b/common/CMakeLists.txt index 95617e15..38767249 100644 --- a/common/CMakeLists.txt +++ b/common/CMakeLists.txt | |||
@@ -1,5 +1,4 @@ | |||
1 | add_library(sway-common | 1 | add_library(sway-common |
2 | ${SWAY_Backtrace_HEADER} | ||
3 | ipc-client.c | 2 | ipc-client.c |
4 | list.c | 3 | list.c |
5 | log.c | 4 | log.c |
@@ -7,3 +6,10 @@ add_library(sway-common | |||
7 | readline.c | 6 | readline.c |
8 | stringop.c | 7 | stringop.c |
9 | ) | 8 | ) |
9 | |||
10 | if(Backtrace_FOUND) | ||
11 | set_target_properties(sway-common | ||
12 | PROPERTIES | ||
13 | COMPILE_FLAGS "-include ${Backtrace_HEADER}" | ||
14 | ) | ||
15 | endif() | ||