X-Git-Url: https://git.quassel-irc.org/?p=quassel.git;a=blobdiff_plain;f=CMakeLists.txt;h=ba4dab88748f3d632d3b4e451dc80ba00918060a;hp=0b1f39bdf437cacb103758ab1b094f3d63de9eea;hb=ff0eb87665d476b39f2f3b192b8db31627e44adb;hpb=d9db3175f4d977a4c809b2981a5a60ee00bb69b4 diff --git a/CMakeLists.txt b/CMakeLists.txt index 0b1f39bd..ba4dab88 100644 --- a/CMakeLists.txt +++ b/CMakeLists.txt @@ -7,6 +7,7 @@ # -DWITH_DBUS=OFF : Disable D-Bus support (dbus notifications) # -DWITH_WEBKIT=OFF : Disable WebKit support (link previews) # -DWITH_PHONON=OFF : Disable Phonon support (audio notifications) +# -DWITH_LIBINDICATE=OFF : Disable libindicate support (Ayatana notifications) # -DWITH_KDE=ON : Enable KDE4 support # -DWITH_OXYGEN=(ON|OFF) : Whether to install Oxygen icons (default: yes, unless KDE > 4.3.0 is present and enabled) # @@ -40,6 +41,7 @@ option(WITH_OPENSSL "Enable OpenSSL support if present on the system" ON) option(WITH_DBUS "Enable D-Bus support if present on the system" ON) option(WITH_WEBKIT "Enable WebKit support (for link previews)" ON) option(WITH_PHONON "Enable Phonon support (for audio notifications)" ON) +option(WITH_LIBINDICATE "Enable Ayatana notification support" ON) option(WITH_KDE "Enable KDE4 integration" OFF) # We use icon paths from KDE 4.3.x, which are partially invalid on older and possibly @@ -231,6 +233,17 @@ if(NOT HAVE_KDE) endif(WITH_PHONON) endif(NOT HAVE_KDE) +# Setup libindicate-qt support +if(WITH_LIBINDICATE) + find_package(PkgConfig QUIET) + if(PKG_CONFIG_FOUND) + pkg_check_modules(INDICATEQT indicate-qt) + if(INDICATEQT_FOUND) + add_definitions(-DHAVE_INDICATEQT) + endif(INDICATEQT_FOUND) + endif(PKG_CONFIG_FOUND) +endif(WITH_LIBINDICATE) + # Now set up install locations; those are set by KDE if integration is enabled if(NOT HAVE_KDE) if(WIN32) @@ -276,6 +289,16 @@ if(WIN32) endif(HAVE_SSL) endif(WIN32) +if(INDICATEQT_FOUND) + if(WANT_QTCLIENT) + set(DESKTOP_FILE ${XDG_APPS_INSTALL_DIR}/quasselclient.desktop) + endif(WANT_QTCLIENT) + if(WANT_MONO) + set(DESKTOP_FILE ${XDG_APPS_INSTALL_DIR}/quassel.desktop) + endif(WANT_MONO) + add_definitions(-DDESKTOP_FILE="\\"${DESKTOP_FILE}\\"") +endif(INDICATEQT_FOUND) + # We need to create a version.gen # For this, we create our genversion binary and make sure it is run every time. add_executable(genversion ${CMAKE_SOURCE_DIR}/src/common/genversion.cpp)