diff options
author | Robert Tari <robert@tari.in> | 2022-11-08 00:15:36 +0100 |
---|---|---|
committer | Mike Gabriel <mike.gabriel@das-netzwerkteam.de> | 2022-11-10 11:49:50 +0100 |
commit | 214a5114e324700e2c854cff675e0a86f74e42f1 (patch) | |
tree | 670a3dda4b633fc426b71572e72ce84f8e4b6cc3 | |
parent | 2b1112598123c4c3a8bec2d44330871ea6010200 (diff) | |
download | ayatana-indicator-display-214a5114e324700e2c854cff675e0a86f74e42f1.tar.gz ayatana-indicator-display-214a5114e324700e2c854cff675e0a86f74e42f1.tar.bz2 ayatana-indicator-display-214a5114e324700e2c854cff675e0a86f74e42f1.zip |
CMakeLists.txt: Skip test dependencies when testing is off
-rw-r--r-- | CMakeLists.txt | 15 |
1 files changed, 8 insertions, 7 deletions
diff --git a/CMakeLists.txt b/CMakeLists.txt index 9605ff1..34fda26 100644 --- a/CMakeLists.txt +++ b/CMakeLists.txt @@ -65,13 +65,14 @@ find_package(PkgConfig REQUIRED) # glib... set(GLIB_MINIMUM 2.36) -pkg_check_modules(SERVICE_DEPS REQUIRED - libayatana-common>=0.9.3 - gio-unix-2.0>=${GLIB_MINIMUM} - glib-2.0>=${GLIB_MINIMUM} - gudev-1.0 - properties-cpp>=0.0.1 -) +set (SERVICE_DEPS libayatana-common>=0.9.3 gio-unix-2.0>=${GLIB_MINIMUM} glib-2.0>=${GLIB_MINIMUM} gudev-1.0) + +if (ENABLE_TESTS) + list (APPEND SERVICE_DEPS properties-cpp>=0.0.1) +endif () + +pkg_check_modules (SERVICE_DEPS REQUIRED ${SERVICE_DEPS}) + include_directories (SYSTEM ${SERVICE_DEPS_INCLUDE_DIRS} ) |