Hook up the ResourceMerger and ResourceWatcher for new resource notifications
[plasma-active-clones:kde-runtime.git] / CMakeLists.txt
1 project(KDEBASE_RUNTIME)
2
3 # where to look first for cmake modules, before ${CMAKE_ROOT}/Modules/ is checked
4 set(CMAKE_MODULE_PATH ${CMAKE_CURRENT_SOURCE_DIR}/cmake/modules ${CMAKE_MODULE_PATH})
5
6 if(WINCE)
7     #Needs to be set because otherwise he wouldn't find kde parts
8     set(KDE4_DATA_DIR "${CMAKE_PREFIX_PATH}/share/apps")
9     add_definitions(-DKDELIBS_STATIC_LIBS)
10 endif(WINCE)
11
12 #search packages used by KDE
13 set(KDE_MIN_VERSION "4.6.80")  # for the < 4.2 macro
14 find_package(KDE4 4.6.80 REQUIRED)
15 if (WIN32)
16     find_package(Strigi)
17 else ()
18     find_package(Strigi REQUIRED)
19 endif ()
20
21 include(KDE4Defaults)
22 include(MacroLibrary)
23 include(CheckFunctionExists)
24 include(CheckIncludeFiles)
25
26 set(SOPRANO_MIN_VERSION "2.6.50")
27 set(SDO_MIN_VERSION "0.6.50")
28 macro_optional_find_package(SharedDesktopOntologies ${SDO_MIN_VERSION})
29 macro_optional_find_package(Nepomuk)
30 macro_log_feature(SHAREDDESKTOPONTOLOGIES_FOUND "Shared desktop ontologies" "Desktop ontologies" "http://oscaf.sourceforge.net" FALSE ${SDO_MIN_VERSION} "Ontologies necessary for the Nepomuk semantic desktop.")
31 macro_log_feature(Nepomuk_FOUND "Nepomuk" "Nepomuk Libraries" "kdelibs" FALSE "" "Required to build Nepomuk.")
32 macro_log_feature(SOPRANO_PLUGIN_VIRTUOSOBACKEND_FOUND "Soprano Virtuoso Backend" "Virtuoso storage backend for Soprano" "http://soprano.sourceforge.net" FALSE "" "The Soprano Virtuoso backend is required to run the Nepomuk semantic desktop system.")
33 macro_log_feature(SOPRANO_PLUGIN_RAPTORPARSER_FOUND "Soprano Raptor Parser" "RDF parser plugin for Soprano" "http://soprano.sourceforge.net" FALSE "" "The Soprano raptor parser plugin is required to build the Nepomuk semantic desktop system.")
34 macro_log_feature(SOPRANO_PLUGIN_REDLANDBACKEND_FOUND "Soprano Redland Backend" "Redland storage backend for Soprano" "http://soprano.sourceforge.net" FALSE "" "The Soprano redland backend is required to build the Nepomuk semantic desktop system.")
35
36 macro_optional_find_package(SLP)
37 macro_log_feature( SLP_FOUND
38   "OpenSLP" "SLP (Service Location Protocol) implementation" "http://www.openslp.org/" FALSE
39   "" "Provides SLP support in the network:/ kioslave."
40 )
41
42 set(LIBATTICA_MIN_VERSION "0.1.4")
43 find_package(LibAttica)
44 macro_log_feature(LIBATTICA_FOUND "libattica" "A library to access Open Collaboration Service providers" "http://websvn.kde.org/trunk/kdesupport/attica/" TRUE "" "Required for Get Hot New Stuff."
45 )
46
47 check_include_files(sys/wait.h HAVE_SYS_WAIT_H)
48 check_include_files(sys/time.h HAVE_SYS_TIME_H)
49
50 configure_file (config-runtime.h.cmake ${CMAKE_CURRENT_BINARY_DIR}/config-runtime.h )
51
52 add_definitions (${QT_DEFINITIONS} ${KDE4_DEFINITIONS})
53 add_definitions(-DQT_USE_FAST_CONCATENATION -DQT_USE_FAST_OPERATOR_PLUS)
54
55 include_directories (${CMAKE_SOURCE_DIR} ${CMAKE_CURRENT_BINARY_DIR} ${KDE4_INCLUDES})
56
57 # Build infrastructure
58 add_subdirectory(cmake)
59
60 add_definitions(-DDISABLE_NEPOMUK_LEGACY)
61
62 # Background processes
63 add_subdirectory(kpasswdserver)
64 add_subdirectory(kdontchangethehostname)
65 add_subdirectory(kglobalaccel)
66 add_subdirectory(knotify)
67 add_subdirectory(ktimezoned)
68 if(NOT WINCE)
69 add_subdirectory(kuiserver)
70 endif(NOT WINCE)
71 add_subdirectory(kwalletd)
72 add_subdirectory(activitymanager)
73 if ( UNIX )
74    add_subdirectory(soliduiserver)
75    add_subdirectory(solidautoeject)
76    add_subdirectory(solid-device-automounter)
77    add_subdirectory(solid-networkstatus)
78 endif ( UNIX )
79 if(NOT WIN32 AND SHAREDDESKTOPONTOLOGIES_FOUND AND Nepomuk_FOUND AND STRIGI_STRIGIQTDBUSCLIENT_LIBRARY AND SOPRANO_PLUGIN_REDLANDBACKEND_FOUND AND SOPRANO_PLUGIN_VIRTUOSOBACKEND_FOUND AND SOPRANO_PLUGIN_RAPTORPARSER_FOUND)
80   macro_optional_add_subdirectory(nepomuk)
81 endif(NOT WIN32 AND SHAREDDESKTOPONTOLOGIES_FOUND AND Nepomuk_FOUND AND STRIGI_STRIGIQTDBUSCLIENT_LIBRARY AND SOPRANO_PLUGIN_REDLANDBACKEND_FOUND AND SOPRANO_PLUGIN_VIRTUOSOBACKEND_FOUND AND SOPRANO_PLUGIN_RAPTORPARSER_FOUND)
82
83 # Plugins/components required for basic utility
84 if ( NOT WINCE )
85     add_subdirectory(kcontrol)
86 endif ( NOT WINCE )
87 add_subdirectory(kioslave)
88 add_subdirectory(kurifilter-plugins)
89 add_subdirectory(phonon)
90 macro_optional_add_subdirectory(renamedlgplugins)
91
92 # UI Helper applications
93 add_subdirectory(drkonqi)
94 add_subdirectory(kcmshell)
95 add_subdirectory(kdebugdialog)
96 if ( ${QT_QT3SUPPORT_FOUND} )
97    add_subdirectory(khelpcenter)
98 endif ( ${QT_QT3SUPPORT_FOUND} )
99 add_subdirectory(knetattach)
100 add_subdirectory(knewstuff)
101 macro_optional_add_subdirectory(keditfiletype)
102 if ( UNIX )
103    add_subdirectory(kdesu)
104 endif ( UNIX )
105
106 # Command-line tools (e.g. for shell scripts)
107 if ( UNIX )
108    add_subdirectory(kdeeject)
109 endif ( UNIX )
110 add_subdirectory(kfile)
111 add_subdirectory(kiconfinder)
112 add_subdirectory(kioclient)
113 add_subdirectory(kioexec)
114 add_subdirectory(ktraderclient)
115 add_subdirectory(kreadconfig)
116 add_subdirectory(kmimetypefinder)
117 if (Q_WS_X11)
118   add_subdirectory(kstart)
119 endif (Q_WS_X11)
120 add_subdirectory(kquitapp)
121 add_subdirectory(menu)
122 if ( NOT WINCE )
123     add_subdirectory(plasma)
124 endif ( NOT WINCE )
125 add_subdirectory(solid-hardware)
126
127 # Platform-specific integration
128 add_subdirectory(platforms)
129
130 # Default settings, content and config
131 add_subdirectory(l10n)
132 add_subdirectory(localization)
133 if(NOT WINCE)
134   add_subdirectory(kde-menu)
135 macro_optional_add_subdirectory(doc)
136 endif(NOT WINCE)
137
138 # Artwork
139 add_subdirectory(desktoptheme)
140 if ( NOT WINCE )
141   add_subdirectory(pics)
142 endif ( NOT WINCE )
143
144 # KDE integration for attica
145 if(LIBATTICA_FOUND)
146   macro_optional_add_subdirectory(attica)
147 endif(LIBATTICA_FOUND)
148
149 if(CMAKE_SOURCE_DIR STREQUAL "${CMAKE_CURRENT_SOURCE_DIR}")
150   macro_display_feature_log()
151 endif(CMAKE_SOURCE_DIR STREQUAL "${CMAKE_CURRENT_SOURCE_DIR}")
152
153 ########### install files ###############
154 install(PROGRAMS ${CMAKE_CURRENT_SOURCE_DIR}/kde4 DESTINATION ${BIN_INSTALL_DIR})