summaryrefslogtreecommitdiff
path: root/test
diff options
context:
space:
mode:
authorRalf Habacker <ralf.habacker@freenet.de>2020-09-23 16:32:54 +0200
committerRalf Habacker <ralf.habacker@freenet.de>2020-09-23 17:21:40 +0200
commit5b1870a5bd89934307aa730511c7da187ae4dc06 (patch)
treede77d6c5e8fb545a18ae6905d894f91af4d53acc /test
parent82942171a827349f083ef3401d8456d2647a9a4b (diff)
downloaddbus-5b1870a5bd89934307aa730511c7da187ae4dc06.tar.gz
cmake: make support for traditional activation optional
Traditional activation is enabled/disabled with the cmake configure parameter -DENABLE_TRADITIONAL_ACTIVATION, which is enabled by default. This was added to the Autotools build system as part of dbus/dbus!107 but until now was not possible to disable when building with CMake.
Diffstat (limited to 'test')
-rw-r--r--test/CMakeLists.txt12
-rw-r--r--test/name-test/CMakeLists.txt8
2 files changed, 13 insertions, 7 deletions
diff --git a/test/CMakeLists.txt b/test/CMakeLists.txt
index 00042000..20e75d85 100644
--- a/test/CMakeLists.txt
+++ b/test/CMakeLists.txt
@@ -81,10 +81,12 @@ add_test_executable(test-shell ${test-shell_SOURCES} ${DBUS_INTERNAL_LIBRARIES})
add_test_executable(test-printf internals/printf.c dbus-testutils)
add_helper_executable(test-privserver test-privserver.c dbus-testutils)
add_helper_executable(test-shell-service ${test-shell-service_SOURCES} dbus-testutils)
-add_helper_executable(test-spawn ${test-spawn_SOURCES} ${DBUS_INTERNAL_LIBRARIES})
-if(NOT WINCE)
+if(NOT WINCE AND ENABLE_TRADITIONAL_ACTIVATION)
add_test_executable(test-spawn-oom internals/spawn-oom.c dbus-testutils)
endif()
+if(ENABLE_TRADITIONAL_ACTIVATION)
+ add_helper_executable(test-spawn ${test-spawn_SOURCES} ${DBUS_INTERNAL_LIBRARIES})
+endif()
add_helper_executable(test-exit ${test-exit_SOURCES} ${DBUS_INTERNAL_LIBRARIES})
# the second argument of add_helper_executable() is a whitespace-separated
# list of source files and the third and subsequent arguments are libraries
@@ -156,8 +158,10 @@ if(DBUS_ENABLE_EMBEDDED_TESTS)
if(NOT WIN32)
add_test_executable(test-bus-system bus/system.c launch-helper-internal dbus-testutils)
- add_test_executable(test-bus-launch-helper-oom bus/launch-helper-oom.c launch-helper-internal dbus-testutils)
- add_helper_executable(dbus-daemon-launch-helper-for-tests bus/launch-helper-for-tests.c launch-helper-internal)
+ if(ENABLE_TRADITIONAL_ACTIVATION)
+ add_test_executable(test-bus-launch-helper-oom bus/launch-helper-oom.c launch-helper-internal dbus-testutils)
+ add_helper_executable(dbus-daemon-launch-helper-for-tests bus/launch-helper-for-tests.c launch-helper-internal)
+ endif()
endif()
endif()
diff --git a/test/name-test/CMakeLists.txt b/test/name-test/CMakeLists.txt
index 7058d696..e7c62587 100644
--- a/test/name-test/CMakeLists.txt
+++ b/test/name-test/CMakeLists.txt
@@ -1,14 +1,16 @@
add_definitions(${DBUS_INTERNAL_CLIENT_DEFINITIONS})
add_helper_executable(test-autolaunch test-autolaunch.c dbus-testutils)
-add_helper_executable(test-privserver-client test-privserver-client.c dbus-testutils)
add_session_test_executable(test-ids test-ids.c ${DBUS_INTERNAL_LIBRARIES})
-if (ENABLE_TRADITIONAL_ACTIVATION)
+add_session_test_executable(test-pending-call-disconnected test-pending-call-disconnected.c ${DBUS_INTERNAL_LIBRARIES})
+
+if(ENABLE_TRADITIONAL_ACTIVATION)
add_session_test_executable(test-pending-call-dispatch test-pending-call-dispatch.c ${DBUS_INTERNAL_LIBRARIES})
add_session_test_executable(test-pending-call-timeout test-pending-call-timeout.c ${DBUS_INTERNAL_LIBRARIES})
endif()
add_session_test_executable(test-shutdown test-shutdown.c dbus-testutils)
if (ENABLE_TRADITIONAL_ACTIVATION)
- add_session_test_executable(test-thread-init test-threads-init.c ${DBUS_INTERNAL_LIBRARIES})
+ add_session_test_executable(test-privserver-client test-privserver-client.c dbus-testutils)
+ add_session_test_executable(test-thread-init test-threads-init.c ${DBUS_INTERNAL_LIBRARIES})
endif()