X-Git-Url: https://git.quassel-irc.org/?p=quassel.git;a=blobdiff_plain;f=CMakeLists.txt;h=ea108c4083715bdbb89a37f9a2c25c82291a569a;hp=2a7d0fc258836bf5fca526b67522c7eae872772b;hb=3c2914faeb01f3bc32e29f40179ae88040fbcf59;hpb=603f1fd2e9501d84a320554f068df26861ebde71 diff --git a/CMakeLists.txt b/CMakeLists.txt index 2a7d0fc2..ea108c40 100644 --- a/CMakeLists.txt +++ b/CMakeLists.txt @@ -6,6 +6,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_KDE=ON : Enable KDE4 support # -DOXYGEN_ICONS=(Builtin|External) : If "Builtin" (the default), compile our Oxygen Icon Theme subset into the binary # : If "External", we assume Oxygen is already installed on the system # -DQUASSEL_ICONS=(Builtin|External) : If "Builtin" (the default), put our own icons into the binary @@ -37,6 +38,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_KDE "Enable KDE4 integration" OFF) option(STATIC "Enable static building (might not be portable)" OFF) option(DEPLOY "Mac OS X only! Adds required libs to bundle resources and create a dmg. Note: requires Qt to be built with 10.4u SDK" OFF) @@ -52,6 +54,7 @@ if(STATIC) set(CMAKE_BUILD_TYPE Release) set(OXYGEN_ICONS "Builtin") set(QUASSEL_ICONS "Builtin") + set(WITH_KDE OFF) endif(STATIC) # RPATH needs to be set correctly @@ -167,6 +170,25 @@ else(WITH_PHONON) message(STATUS "Disabling Phonon support") endif(WITH_PHONON) +# Setup KDE4 support +if(WITH_KDE) + find_package(KDE4) + if(KDE4_FOUND) + message(STATUS "Enabling KDE4 integration") + include_directories(${KDE4_INCLUDES}) + add_definitions(-DHAVE_KDE ${KDE4_DEFINITIONS}) + set(HAVE_KDE 1) + set(MOC_DEFINES ${MOC_DEFINES} -DHAVE_KDE) + set(QUASSEL_KDE_LIBRARIES ${KDE4_KDECORE_LIBS} ${KDE4_KDEUI_LIBRARY} knotifyconfig) + set(OXYGEN_ICONS "External") + set(QUASSEL_ICONS "External") + else(KDE4_FOUND) + message(STATUS "KDE4 not found, disabling KDE integration") + endif(KDE4_FOUND) +else(WITH_KDE) + message(STATUS "Disabling KDE4 integration") +endif(WITH_KDE) + # Set global buildflags # This is very much non-portable, so don't use -DSTATIC until you know what # you do.