summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorJiri Popek <jiri.popek@gmail.com>2019-02-07 12:02:51 +0100
committerChristoph Lipka <clipka@users.noreply.github.com>2019-02-07 12:02:51 +0100
commit4c4cc967ad46abae60f2f9bf5e47b65e8bcbb4b1 (patch)
tree39eb9ead91a54d2eeccbf225a090a19c7c292c0c
parent18321f3551098d6313c0f3f3620bc74b53b84472 (diff)
downloadDLT-daemon-4c4cc967ad46abae60f2f9bf5e47b65e8bcbb4b1.tar.gz
Fix linking problem with tests when systemd enabled (#103)
Change-Id: Ide7c91a9f3a182c4bc2f91613874b0ef3feca648
-rw-r--r--tests/CMakeLists.txt10
1 files changed, 5 insertions, 5 deletions
diff --git a/tests/CMakeLists.txt b/tests/CMakeLists.txt
index 56a21b7..c56bb22 100644
--- a/tests/CMakeLists.txt
+++ b/tests/CMakeLists.txt
@@ -20,8 +20,8 @@ endif()
set(DLT_LIBRARIES ${LIBRARIES} dlt)
set(DLT_DAEMON_LIBRARIES ${LIBRARIES} dlt_daemon)
-if(WITH_SYSTEMD OR WITH_SYSTEMD_WATCHDOG)
- set(DLT_DAEMON_LIBRARIES ${DLT_DAEMON_LIBRARIES} systemd)
+if(WITH_SYSTEMD OR WITH_SYSTEMD_WATCHDOG OR WITH_SYSTEMD_JOURNAL)
+ add_definitions( -DSD_EXPORT_SYMBOLS )
endif()
add_executable(gtest_dlt_common gtest_dlt_common.cpp)
@@ -30,9 +30,9 @@ add_executable(gtest_dlt_daemon_common gtest_dlt_daemon_common.cpp ../src/daemon
add_executable(dlt_test_receiver dlt_test_receiver.c)
add_executable(dlt_env_ll_unit_test dlt_env_ll_unit_test.cpp)
add_executable(dlt-test-preregister-context dlt-test-preregister-context.c)
-add_executable(gtest_dlt_daemon_gateway gtest_dlt_daemon_gateway.cpp)
-add_executable(gtest_dlt_daemon_event_handler gtest_dlt_daemon_event_handler.cpp)
-add_executable(gtest_dlt_daemon_offline_log gtest_dlt_daemon_offline_log.cpp)
+add_executable(gtest_dlt_daemon_gateway gtest_dlt_daemon_gateway.cpp ${systemd_SRCS})
+add_executable(gtest_dlt_daemon_event_handler gtest_dlt_daemon_event_handler.cpp ${systemd_SRCS})
+add_executable(gtest_dlt_daemon_offline_log gtest_dlt_daemon_offline_log.cpp ${systemd_SRCS})
target_link_libraries(gtest_dlt_common ${DLT_LIBRARIES})
target_link_libraries(gtest_dlt_user ${DLT_LIBRARIES})
target_link_libraries(gtest_dlt_daemon_common ${DLT_LIBRARIES})