aboutsummaryrefslogtreecommitdiff
path: root/CMakeLists.txt
diff options
context:
space:
mode:
authorRobert Tari <robert@tari.in>2023-11-02 14:41:30 +0100
committerRobert Tari <robert@tari.in>2023-11-02 14:41:30 +0100
commit4a9824a84f44529254388cec9f08d80488f3c938 (patch)
treefc083a25efdf7f3d948172a2e2609fcb301ac190 /CMakeLists.txt
parent9e19aaef2031739d8ddba99aafc8f9f2d5d740fd (diff)
parenteca237d3b0ba0cccbe8855db1fda53e70e4ee8ec (diff)
downloadayatana-indicator-session-4a9824a84f44529254388cec9f08d80488f3c938.tar.gz
ayatana-indicator-session-4a9824a84f44529254388cec9f08d80488f3c938.tar.bz2
ayatana-indicator-session-4a9824a84f44529254388cec9f08d80488f3c938.zip
Merge branch 'sunweaver-pr/rda-optional'
Attributes GH PR #91: https://github.com/AyatanaIndicators/ayatana-indicator-session/pull/91
Diffstat (limited to 'CMakeLists.txt')
-rw-r--r--CMakeLists.txt18
1 files changed, 13 insertions, 5 deletions
diff --git a/CMakeLists.txt b/CMakeLists.txt
index c14ca59..848a1df 100644
--- a/CMakeLists.txt
+++ b/CMakeLists.txt
@@ -14,6 +14,7 @@ set (GETTEXT_PACKAGE "ayatana-indicator-session")
option(ENABLE_TESTS "Enable all tests and checks" OFF)
option(ENABLE_COVERAGE "Enable coverage reports (includes enabling all tests and checks)" OFF)
option(ENABLE_WERROR "Treat all build warnings as errors" OFF)
+option(ENABLE_RDA "Enable RDA (remote desktop awareness)" ON)
if(ENABLE_COVERAGE)
set(ENABLE_TESTS ON)
@@ -45,11 +46,18 @@ include (GNUInstallDirs)
##
find_package (PkgConfig REQUIRED)
include (FindPkgConfig)
-pkg_check_modules (SERVICE REQUIRED
- libayatana-common>=0.9.2
- glib-2.0>=2.36
- gio-unix-2.0>=2.36
- rda)
+set (SERVICE REQUIRED
+ libayatana-common>=0.9.2
+ glib-2.0>=2.36
+ gio-unix-2.0>=2.36)
+
+if (ENABLE_RDA)
+ list (APPEND SERVICE rda)
+ add_definitions (-DRDA_ENABLED)
+endif ()
+
+pkg_check_modules (SERVICE REQUIRED ${SERVICE})
+
include_directories (${SERVICE_INCLUDE_DIRS})
set (ARCHIVE_NAME ${CMAKE_PROJECT_NAME}-${PROJECT_VERSION})