diff options
| author | Drew DeVault <sir@cmpwn.com> | 2017-06-14 18:53:40 -0400 |
|---|---|---|
| committer | GitHub <noreply@github.com> | 2017-06-14 18:53:40 -0400 |
| commit | 298f56353ef155f6a2ccc977c96b2ff5d971e65e (patch) | |
| tree | dcb3b74f1dde93bce8657b7509662ffd7db667d0 /CMakeLists.txt | |
| parent | a5c07dde6aba87584ddb6c6a2769472a6003623a (diff) | |
| parent | eb6e38c86d2deb37cc6f378f8644c4a530fd7448 (diff) | |
Merge branch 'master' into server-decoration
Diffstat (limited to 'CMakeLists.txt')
| -rw-r--r-- | CMakeLists.txt | 18 |
1 files changed, 17 insertions, 1 deletions
diff --git a/CMakeLists.txt b/CMakeLists.txt index 9ed45830..c80f6361 100644 --- a/CMakeLists.txt +++ b/CMakeLists.txt @@ -47,6 +47,7 @@ option(enable-swaybar "Enables the swaybar utility" YES) option(enable-swaygrab "Enables the swaygrab utility" YES) option(enable-swaymsg "Enables the swaymsg utility" YES) option(enable-gdk-pixbuf "Use Pixbuf to support more image formats" YES) +option(enable-tray "Enables the swaybar tray" YES) option(zsh-completions "Zsh shell completions" NO) option(default-wallpaper "Installs the default wallpaper" YES) option(LD_LIBRARY_PATH "Configure sway's default LD_LIBRARY_PATH") @@ -64,9 +65,13 @@ find_package(Cairo REQUIRED) find_package(Pango REQUIRED) find_package(GdkPixbuf) find_package(PAM) +find_package(DBus) find_package(LibInput REQUIRED) -find_package(Libcap REQUIRED) + +if (CMAKE_SYSTEM_NAME STREQUAL Linux) + find_package(Libcap REQUIRED) +endif (CMAKE_SYSTEM_NAME STREQUAL Linux) if (CMAKE_SYSTEM_NAME STREQUAL FreeBSD) find_package(EpollShim REQUIRED) @@ -87,6 +92,17 @@ else() message(STATUS "Building without gdk-pixbuf, only png images supported.") endif() +if (enable-tray) + if (DBUS_FOUND) + set(ENABLE_TRAY) + add_definitions(-DENABLE_TRAY) + else() + message(WARNING "Tray required but DBus was not found. Tray will not be included") + endif() +else() + message(STATUS "Building without the tray.") +endif() + include_directories(include) add_subdirectory(protocols) |
