~jgonzalezdr/cairo-dock-plug-ins/suspend-workaround-applet_3.3

1546.1.2 by fabounet
added the files for cimpiling with cmake
1
########### requirements ###############
2
3
cmake_minimum_required (VERSION 2.6)
4
find_package (PkgConfig)
5
include (CheckLibraryExists)
6
include (CheckIncludeFiles)
7
include (CheckFunctionExists)
8
include (CheckSymbolExists)
2196 by Matthieu Baerts
CMakeLists.txt:
9
include ("${CMAKE_CURRENT_SOURCE_DIR}/cmake_modules/GNUInstallDirs.cmake")
1546.1.2 by fabounet
added the files for cimpiling with cmake
10
11
########### project ###############
12
1557 by matttbe
Updated 'make dist' function with Cmake
13
project ("cairo-dock-plugins")
2984 by Matthieu Baerts
3.3.1: new bug-fix release!
14
set (VERSION "3.3.1")
1663 by matttbe
CMakeLists:
15
2894 by Matthieu Baerts
CMakeLists.txt: definitions (gcc args): added -Werror-implicit-function-declaration
16
add_definitions (-std=c99 -Wall -Werror-implicit-function-declaration) # -Wextra -Wwrite-strings -Wuninitialized -Werror-implicit-function-declaration -Wstrict-prototypes -Wreturn-type -Wparentheses -Warray-bounds)
2802 by Matthieu Baerts
CMakeLists.txt: fixed a typo with CMAKE_BUILD_TYPE
17
if (NOT DEFINED CMAKE_BUILD_TYPE)
1546.1.2 by fabounet
added the files for cimpiling with cmake
18
	add_definitions (-O3)
19
endif()
20
add_definitions (-DGL_GLEXT_PROTOTYPES="1")
1663 by matttbe
CMakeLists:
21
22
############ sources tarball #############
23
24
set (CPACK_SOURCE_GENERATOR "TGZ")
25
set (CPACK_SOURCE_PACKAGE_FILE_NAME "${CMAKE_PROJECT_NAME}-${VERSION}")
2054 by Matthieu Baerts
CMakeLists.txt:
26
set (CPACK_SOURCE_IGNORE_FILES
1817 by matttbe
po: Updated Translations: thanks to all translators ;)
27
	"/build/;/.bzr/;bzrignore$;/misc/;~$;${CPACK_SOURCE_IGNORE_FILES}")
1663 by matttbe
CMakeLists:
28
include (CPack)
29
1968 by matttbe
CMakeLists.txt: a 'with_status_notifier' was missing. Ok right, this is really a tiny tiny tiny detail :P
30
add_custom_target(dist
1663 by matttbe
CMakeLists:
31
	COMMAND ${CMAKE_MAKE_PROGRAM} package_source)
32
add_custom_target(dist-bzr
33
	COMMAND bzr export ${CMAKE_PROJECT_NAME}-${VERSION}.tar.gz
34
	WORKING_DIRECTORY ${CMAKE_SOURCE_DIR})
35
36
############ uninstall #############
37
38
configure_file (${CMAKE_CURRENT_SOURCE_DIR}/cmake_uninstall.cmake.in ${CMAKE_CURRENT_BINARY_DIR}/cmake_uninstall.cmake IMMEDIATE @ONLY)
39
add_custom_target (uninstall "${CMAKE_COMMAND}" -P "${CMAKE_CURRENT_BINARY_DIR}/cmake_uninstall.cmake")
1546.1.2 by fabounet
added the files for cimpiling with cmake
40
41
########### global variables ###############
42
1663 by matttbe
CMakeLists:
43
if( WIN32 )
44
	message(FATAL_ERROR "Cairo-Dock requires an air-conditioned room. Please close Windows!")
45
endif( WIN32 )
46
1546.1.2 by fabounet
added the files for cimpiling with cmake
47
set (PACKAGE ${CMAKE_PROJECT_NAME})
48
set (GETTEXT_PACKAGE ${PACKAGE})
1811.1.4 by Fabrice Rey
added the vala interface
49
2823 by Matthieu Baerts
CMakeLists.txt: if Gldi is not found, display a error message and then stop
50
if ("${PACKAGEMENT}" STREQUAL "") ## do not check if we're using the same version when packaging the application (e.g. if we just want to generate a tarball of a previous version)
2809 by Matthieu Baerts
CMakeLists: used pkg_check_modules to check if we're using the same version of gldi
51
	# we need GLDI which contains most global var: check it now to avoid many errors with regex
52
	pkg_check_modules (GLDI REQUIRED gldi=${VERSION})
2823 by Matthieu Baerts
CMakeLists.txt: if Gldi is not found, display a error message and then stop
53
	if (NOT GLDI_FOUND)
54
		execute_process(
55
			COMMAND pkg-config --modversion gldi  # 2.2.0-3
56
			OUTPUT_VARIABLE dock_version)
57
		if (NOT "${PACKAGEMENT}" STREQUAL "")
58
			STRING (REGEX REPLACE "\n" "" dock_version ${dock_version})
59
		endif ()
60
		MESSAGE (FATAL_ERROR "Error: version mismatch with the core: ${VERSION} <> ${dock_version}")
61
	endif ()
2809 by Matthieu Baerts
CMakeLists: used pkg_check_modules to check if we're using the same version of gldi
62
endif ()
2805 by Matthieu Baerts
CMakeLists.txt: check if gldi.pc is available before using 'pkg-config gldi (..)' commands
63
2831 by Matthieu Baerts
CMakeLists.txt: set the dock version even if PACKAGEMENT flag is set (e.g. if we want to compile it and this flag is set)
64
set (dock_version ${VERSION}) # should be the same except if PACKAGEMENT is set
65
1811.1.4 by Fabrice Rey
added the vala interface
66
# get plug-ins install dir
1546.1.2 by fabounet
added the files for cimpiling with cmake
67
execute_process(
2196 by Matthieu Baerts
CMakeLists.txt:
68
    COMMAND pkg-config gldi --variable=pluginsdir  # /usr/lib/cairo-dock # or /usr/lib/x86_64-linux-gnu/cairo-dock
1546.1.2 by fabounet
added the files for cimpiling with cmake
69
    OUTPUT_VARIABLE pluginsdir)
2187 by Fabrice Rey
port to GTK3 - final part - removed all calls to any deprecated functions
70
STRING (REGEX REPLACE "\n" "" pluginsdir ${pluginsdir})  # remove the \n
1811.1.4 by Fabrice Rey
added the vala interface
71
# get plug-ins data dir
1546.1.2 by fabounet
added the files for cimpiling with cmake
72
execute_process(
2187 by Fabrice Rey
port to GTK3 - final part - removed all calls to any deprecated functions
73
    COMMAND pkg-config gldi --variable=pluginsdatadir  # /usr/share/cairo-dock/plug-ins
1546.1.2 by fabounet
added the files for cimpiling with cmake
74
    OUTPUT_VARIABLE pluginsdatadir)
75
STRING (REGEX REPLACE "\n" "" pluginsdatadir ${pluginsdatadir})
2196 by Matthieu Baerts
CMakeLists.txt:
76
# get prefix dir
77
execute_process(
78
    COMMAND pkg-config gldi --variable=prefix  # /usr/share/cairo-dock/plug-ins
79
    OUTPUT_VARIABLE prefix)
80
STRING (REGEX REPLACE "\n" "" prefix ${prefix})
2187 by Fabrice Rey
port to GTK3 - final part - removed all calls to any deprecated functions
81
# get GTK version (must be the same as the core, as GTK2 and GTK3 can't coexist at runtime)
82
execute_process(
83
    COMMAND pkg-config gldi --variable=gtkversion  # 2 or 3
84
    OUTPUT_VARIABLE gtkversion)
85
STRING (REGEX REPLACE "\n" "" gtkversion ${gtkversion})
1811.1.4 by Fabrice Rey
added the vala interface
86
87
# check that installation dir matches with the core
2196 by Matthieu Baerts
CMakeLists.txt:
88
GET_FILENAME_COMPONENT(libdir "${pluginsdir}/.." ABSOLUTE)  # /usr/lib # or /usr/lib/x86_64-linux-gnu
89
GET_FILENAME_COMPONENT(datadir "${pluginsdatadir}/../.." ABSOLUTE)  # /usr/share
90
if (NOT "${CMAKE_INSTALL_PREFIX}" STREQUAL "${prefix}"
91
		OR NOT "${CMAKE_INSTALL_PREFIX}/${CMAKE_INSTALL_LIBDIR}" STREQUAL "${libdir}"
92
		OR NOT "${CMAKE_INSTALL_PREFIX}/${CMAKE_INSTALL_DATAROOTDIR}" STREQUAL "${datadir}")
93
	message (STATUS "It seems that the current CMAKE_INSTALL_{PREFIX,LIBDIR,DATAROOTDIR} flags are not the same that you have used with the core.")
2047 by matttbe
CMakeLists.txt: Added some warnings if a module or a program is missing + added some messages (+ fixed a few typos)
94
	message (STATUS " It will be replaced by this value: ${prefix}")
95
	message (WARNING "Plug-ins should be installed in the same directory as the core, that is to say in ${pluginsdir}")
1811.1.4 by Fabrice Rey
added the vala interface
96
	set (CMAKE_INSTALL_PREFIX "${prefix}")
97
	#set (libdir "${CMAKE_INSTALL_PREFIX}/${libname}/cairo-dock")
98
endif()
99
100
# set internationalisation
1546.1.2 by fabounet
added the files for cimpiling with cmake
101
set (GETTEXT_PLUGINS "cairo-dock-plugins")
2293 by Matthieu Baerts
CMakeLists.txt: fixed a bug with the translations (wrong locale folder)
102
set (localedir "${prefix}/${CMAKE_INSTALL_LOCALEDIR}")
103
set (gaugesdir "${datadir}/cairo-dock/gauges")
1600 by fabounet
fixed possible division by 0 in Switcher, in the case the number of desktops would be nul
104
1771 by Fabrice Rey
weather: remove workaround for double-click since the dock handles it nicely + CMakeList: fixed the plug-in dir test + System-monitor: added data from sensors (work in progress)
105
set(CMAKE_MODULE_PATH "${CMAKE_SOURCE_DIR}/cmake_modules/")  # additionnal FindPackage files
1546.1.4 by fabounet
cmake compilation is operational
106
2047 by matttbe
CMakeLists.txt: Added some warnings if a module or a program is missing + added some messages (+ fixed a few typos)
107
set (MODULES_MISSING "")
108
set (MODULES_INTEGRATION_MISSING "")
109
set (PROGRAMS_MISSING "")
110
2648 by Matthieu Baerts
CMakeLists.txt: big changes! We are now using booleans for CMake flags
111
112
###########     Misc     ###############
113
macro (enable_if_not_defined MODULE1)
2676 by Fabrice Rey
CMakeLists: fixed 2 bugs in the makefile
114
	if (NOT DEFINED ${MODULE1}) # true if not defined
2648 by Matthieu Baerts
CMakeLists.txt: big changes! We are now using booleans for CMake flags
115
		set (${MODULE1} TRUE)
116
	endif ()
117
endmacro (enable_if_not_defined)
118
119
120
##########     Config    ###############
121
122
enable_if_not_defined (force-icon-in-menus)
123
if (force-icon-in-menus)  # we believe that not showing icons in the menus by default is a terrible idea; unfortunately, it's not easily undoable for an end-user; so until this is fixed by a big player (Gnome, Ubuntu or other), we'll force the display, unless "-Dforce-icon-in-menus=yes" is provided in the cmake command.
124
	add_definitions (-DCAIRO_DOCK_FORCE_ICON_IN_MENUS=1)
125
else()
126
	add_definitions (-DCAIRO_DOCK_FORCE_ICON_IN_MENUS=0)
127
endif()
128
129
1811.1.2 by Fabrice Rey
updated to libgldi 2.2.1
130
########### dependancies ###############
131
1820 by matttbe
DBus Interfaces: added the prefix (needed to build packages) + used complet path for python and ruby executable
132
message ("")
1811.1.2 by Fabrice Rey
updated to libgldi 2.2.1
133
message (STATUS "=====================")
2265 by Matthieu Baerts
Network Monitor: fixed a possible crash ( LP: #916609 )
134
message (STATUS "Check dependencies...")
1811.1.2 by Fabrice Rey
updated to libgldi 2.2.1
135
message (STATUS "=====================")
1820 by matttbe
DBus Interfaces: added the prefix (needed to build packages) + used complet path for python and ruby executable
136
message ("")
1546.1.2 by fabounet
added the files for cimpiling with cmake
137
2555 by Fabrice Rey
fixed a few warnings and bumped version: first release candidate
138
pkg_check_modules ("PACKAGE" REQUIRED "gldi")  # we check first the common libs that most plug-ins would need: basically, all the libs used by the core.
139
STRING (REGEX REPLACE "gldi;" "" PACKAGE_LIBRARIES "${PACKAGE_LIBRARIES}")  # but we don't want to link to gldi, since we are dl-opened by it.
1546.1.2 by fabounet
added the files for cimpiling with cmake
140
2912 by Matthieu Baerts
CMakeLists.txt: GTK: Removed GTK_DISABLE_DEPRECATED flag
141
# add_definitions (-DGTK_DISABLE_DEPRECATED="1")
2187 by Fabrice Rey
port to GTK3 - final part - removed all calls to any deprecated functions
142
1892 by matttbe
CMakeLists.txt: Vala interface: check GLib version because 2.26 is required
143
#############    GLIB    #################
144
pkg_check_modules (GLIB glib-2.0)
145
	STRING (REGEX REPLACE "\\..*" "" GLIB_MAJOR "${GLIB_VERSION}") # 2.28.3 => 2
146
	STRING (REGEX REPLACE "[0-9]*\\.([^ ]+)" "\\1" GLIB_MINOR "${GLIB_VERSION}")  # 2.28.3 => 2.28
147
	STRING (REGEX REPLACE "\\.[0-9]*" "" GLIB_MINOR "${GLIB_MINOR}") # 2.28 => 28
148
	STRING (REGEX REPLACE ".*\\." "" GLIB_NANO "${GLIB_VERSION}") # 2.28.3 => 3
149
	STRING (REGEX REPLACE "-.*" "" GLIB_NANO "${GLIB_NANO}")
150
2463 by Fabrice Rey
config files : removed unnecessary tooltips => 3.0.2
151
############# SHARED-FILES #################
152
set (shared_filesdatadir "${pluginsdatadir}/shared-files")
153
add_subdirectory (shared-files)
154
2511 by Matthieu Baerts
CMakeLists.txt: Checked gio-2.0 for 'gvfs-integration' even if GMenu is not compiled
155
############# STATIC LIBRARIES ################
2513 by Matthieu Baerts
CMakeLists.txt: linked each plugin to all libs used by gldi except gldi
156
message (STATUS "> Static Libraries:")
157
2511 by Matthieu Baerts
CMakeLists.txt: Checked gio-2.0 for 'gvfs-integration' even if GMenu is not compiled
158
############# GVFS-INTEGRATION ################
159
message (STATUS "> GVFS-Integration:")
2648 by Matthieu Baerts
CMakeLists.txt: big changes! We are now using booleans for CMake flags
160
pkg_check_modules ("LIBGIO" "gio-2.0") ## GIO is used by a few applets: do not offer the possibility to not disable it
161
add_subdirectory (gvfs-integration)
2511 by Matthieu Baerts
CMakeLists.txt: Checked gio-2.0 for 'gvfs-integration' even if GMenu is not compiled
162
2254 by Fabrice Rey
Sound-Control: merged with Sound-Menu
163
############# INDICATOR-APPLET #################
164
message (STATUS "> Indicator-Applet:")
2648 by Matthieu Baerts
CMakeLists.txt: big changes! We are now using booleans for CMake flags
165
enable_if_not_defined (enable-dbusmenu-support)
166
if (enable-dbusmenu-support)
167
	# Note: the names of dbusmenu-glib, dbusmenu-gtk and indicator have changed...
168
	## DBusMenu Glib
169
	set (DBUSMENU_MODULE dbusmenu-glib-0.4)
2254 by Fabrice Rey
Sound-Control: merged with Sound-Menu
170
	pkg_check_modules (DBUSMENU ${DBUSMENU_MODULE})
2648 by Matthieu Baerts
CMakeLists.txt: big changes! We are now using booleans for CMake flags
171
	if (NOT DBUSMENU_FOUND)
172
		set (DBUSMENU_MODULE dbusmenu-glib)
173
		pkg_check_modules (DBUSMENU ${DBUSMENU_MODULE})
174
		set (INDICATOR_APPLICATIONADDED_HAS_HINT 0) # doesn't have 'hint' with old version
175
	else ()
176
		set (INDICATOR_APPLICATIONADDED_HAS_HINT 1) # now the ApplicationAdded signal (Status-Notifier) has a new parameter (hint) => https://code.launchpad.net/~ted/indicator-application/name-hints/+merge/67213
177
	endif()
2254 by Fabrice Rey
Sound-Control: merged with Sound-Menu
178
2648 by Matthieu Baerts
CMakeLists.txt: big changes! We are now using booleans for CMake flags
179
	## DBusMenu Gtk
180
	if (gtkversion EQUAL 2)
181
		set (DBUSMENU_GTK_MODULE dbusmenu-gtk-0.4)
2254 by Fabrice Rey
Sound-Control: merged with Sound-Menu
182
	else()
2648 by Matthieu Baerts
CMakeLists.txt: big changes! We are now using booleans for CMake flags
183
		set (DBUSMENU_GTK_MODULE dbusmenu-gtk3-0.4)
2254 by Fabrice Rey
Sound-Control: merged with Sound-Menu
184
	endif()
185
	pkg_check_modules (DBUSMENU_GTK ${DBUSMENU_GTK_MODULE})
2648 by Matthieu Baerts
CMakeLists.txt: big changes! We are now using booleans for CMake flags
186
	if (NOT DBUSMENU_GTK_FOUND)
187
		if (gtkversion EQUAL 2)
188
			set (DBUSMENU_GTK_MODULE dbusmenu-gtk)
189
		else()
190
			set (DBUSMENU_GTK_MODULE dbusmenu-gtk3)
191
		endif()
192
		pkg_check_modules (DBUSMENU_GTK ${DBUSMENU_GTK_MODULE})
193
	endif()
2254 by Fabrice Rey
Sound-Control: merged with Sound-Menu
194
endif()
195
2621 by Matthieu Baerts
CMakeLists.txt: DBusMenu GLib and GTK are needed for Indicator-Applet
196
## Indicator
2648 by Matthieu Baerts
CMakeLists.txt: big changes! We are now using booleans for CMake flags
197
enable_if_not_defined (enable-indicator-support)
198
if (enable-indicator-support)
199
	if (gtkversion EQUAL 2)
200
		set (INDICATOR_APPLET_MODULE indicator-0.4)
2254 by Fabrice Rey
Sound-Control: merged with Sound-Menu
201
	else()
2648 by Matthieu Baerts
CMakeLists.txt: big changes! We are now using booleans for CMake flags
202
		set (INDICATOR_APPLET_MODULE indicator3-0.4)
2254 by Fabrice Rey
Sound-Control: merged with Sound-Menu
203
	endif()
204
	pkg_check_modules (INDICATOR_APPLET ${INDICATOR_APPLET_MODULE})
2648 by Matthieu Baerts
CMakeLists.txt: big changes! We are now using booleans for CMake flags
205
	if (INDICATOR_APPLET_FOUND)
206
		set (INDICATOR_NEW_VERSION TRUE)  # oneiric and newer
207
	else()
208
		if (gtkversion EQUAL 2)
209
			set (INDICATOR_APPLET_MODULE indicator)
210
		else()
211
			set (INDICATOR_APPLET_MODULE indicator3)
212
		endif()
213
		pkg_check_modules (INDICATOR_APPLET ${INDICATOR_APPLET_MODULE})
214
	endif()
2254 by Fabrice Rey
Sound-Control: merged with Sound-Menu
215
endif()
216
2621 by Matthieu Baerts
CMakeLists.txt: DBusMenu GLib and GTK are needed for Indicator-Applet
217
## libido
2648 by Matthieu Baerts
CMakeLists.txt: big changes! We are now using booleans for CMake flags
218
enable_if_not_defined (enable-libido-support)
219
if (enable-libido-support)
220
	if (gtkversion EQUAL 2)
221
		set (IDO_MODULE libido-0.1)
222
	else()
223
		set (IDO_MODULE libido3-0.1)
224
	endif()
225
	pkg_check_modules (IDO ${IDO_MODULE})
2873 by Matthieu Baerts
Indicator-applet3: added support of Indicator Services (Indicator-NG)
226
	if (IDO_FOUND)
227
		STRING (REGEX REPLACE "\\..*" "" IDO_MAJOR "${IDO_VERSION}")
228
		STRING (REGEX REPLACE "[0-9]*\\.([^ ]+)" "\\1" IDO_MINOR "${IDO_VERSION}")  # 0.1.7 => 1.7
229
		STRING (REGEX REPLACE "\\.[0-9]*" "" IDO_MINOR "${IDO_MINOR}")
230
		if (${IDO_MAJOR} GREATER 13
231
		    OR ${IDO_MAJOR} EQUAL 13 AND ${IDO_MINOR} GREATER 9)
232
			set (INDICATOR_NG 1)
233
		endif()
234
	endif()
2254 by Fabrice Rey
Sound-Control: merged with Sound-Menu
235
endif()
236
2621 by Matthieu Baerts
CMakeLists.txt: DBusMenu GLib and GTK are needed for Indicator-Applet
237
## Extract versions of DBusMenu
2648 by Matthieu Baerts
CMakeLists.txt: big changes! We are now using booleans for CMake flags
238
if (DBUSMENU_FOUND AND DBUSMENU_GTK_FOUND)
2254 by Fabrice Rey
Sound-Control: merged with Sound-Menu
239
	STRING (REGEX REPLACE "\\..*" "" DBUSMENU_MAJOR "${DBUSMENU_VERSION}")
240
	STRING (REGEX REPLACE "[0-9]*\\.([^ ]+)" "\\1" DBUSMENU_MINOR "${DBUSMENU_VERSION}")  # 0.1.7 => 1.7
241
	STRING (REGEX REPLACE "\\.[0-9]*" "" DBUSMENU_MINOR "${DBUSMENU_MINOR}")
242
	STRING (REGEX REPLACE ".*\\." "" DBUSMENU_NANO "${DBUSMENU_VERSION}")
243
	STRING (REGEX REPLACE "-.*" "" DBUSMENU_NANO "${DBUSMENU_NANO}")
2285 by Matthieu Baerts
CMakeLists.txt: the include dir of dbusmenu-gtk3 has changed with the latest version (0.5.90)
244
245
	STRING (REGEX REPLACE "\\..*" "" DBUSMENU_GTK_MAJOR "${DBUSMENU_GTK_VERSION}")
246
	STRING (REGEX REPLACE "[0-9]*\\.([^ ]+)" "\\1" DBUSMENU_GTK_MINOR "${DBUSMENU_GTK_VERSION}")  # 0.1.7 => 1.7
247
	STRING (REGEX REPLACE "\\.[0-9]*" "" DBUSMENU_GTK_MINOR "${DBUSMENU_GTK_MINOR}")
248
	STRING (REGEX REPLACE ".*\\." "" DBUSMENU_GTK_NANO "${DBUSMENU_GTK_VERSION}")
249
	STRING (REGEX REPLACE "-.*" "" DBUSMENU_GTK_NANO "${DBUSMENU_GTK_NANO}")
2335 by Fabrice Rey
fixed an error when compiling without libindicator
250
	
251
	if (${DBUSMENU_GTK_MAJOR} GREATER 0 OR ${DBUSMENU_GTK_MINOR} GREATER 5
252
	    OR (${DBUSMENU_GTK_MINOR} EQUAL 5 AND ${DBUSMENU_GTK_NANO} GREATER 89))
253
		set (DBUSMENU_GTK3_NEW 1)
254
		set (INDICATOR_APPLICATIONADDED_HAS_TITLE 1) # Status-Notifier: new parameter "Title" in the "added" signal since Precise
255
	else()
256
		set (INDICATOR_APPLICATIONADDED_HAS_TITLE 0)
257
	endif()
258
endif()
2254 by Fabrice Rey
Sound-Control: merged with Sound-Menu
259
2621 by Matthieu Baerts
CMakeLists.txt: DBusMenu GLib and GTK are needed for Indicator-Applet
260
## Extract version of indicator
2648 by Matthieu Baerts
CMakeLists.txt: big changes! We are now using booleans for CMake flags
261
if (INDICATOR_APPLET_FOUND)
2254 by Fabrice Rey
Sound-Control: merged with Sound-Menu
262
	STRING (REGEX REPLACE "\\..*" "" INDICATOR_MAJOR "${INDICATOR_APPLET_VERSION}")
263
	STRING (REGEX REPLACE "[0-9]*\\.([^ ]+)" "\\1" INDICATOR_MINOR "${INDICATOR_APPLET_VERSION}")  # 0.1.7 => 1.7
264
	STRING (REGEX REPLACE "\\.[0-9]*" "" INDICATOR_MINOR "${INDICATOR_MINOR}")
265
	STRING (REGEX REPLACE ".*\\." "" INDICATOR_NANO "${INDICATOR_APPLET_VERSION}")
266
	STRING (REGEX REPLACE "-.*" "" INDICATOR_NANO "${INDICATOR_NANO}")
2335 by Fabrice Rey
fixed an error when compiling without libindicator
267
	
2316 by Matthieu Baerts
CMakeLists.txt: indicator-sound: used the new DBus address if the version of libindicator is newer than 0.4.89 instead of looking at the version of the distribution
268
	if (${INDICATOR_MAJOR} GREATER 0 OR ${INDICATOR_MINOR} GREATER 4
269
	    OR (${INDICATOR_MINOR} EQUAL 4 AND ${INDICATOR_NANO} GREATER 89))
270
		set (SOUND_SERVICE_VERSION 1) # Sound-Menu: new DBus path
2355 by Matthieu Baerts
Messaging-Menu: renamed INDICATOR_VERSION_5 by INDICATOR_MESSAGES_HAS_LOZENGE
271
		set (INDICATOR_MESSAGES_HAS_LOZENGE 1)   # Messaging Menu has 'right-is-lozenge'
2316 by Matthieu Baerts
CMakeLists.txt: indicator-sound: used the new DBus address if the version of libindicator is newer than 0.4.89 instead of looking at the version of the distribution
272
	else() # older than Precise.
273
		set (SOUND_SERVICE_VERSION 0)
2355 by Matthieu Baerts
Messaging-Menu: renamed INDICATOR_VERSION_5 by INDICATOR_MESSAGES_HAS_LOZENGE
274
		set (INDICATOR_MESSAGES_HAS_LOZENGE 0)
2307 by Matthieu Baerts
Status-Notifier: indicator 0.4.90 (and newer) has a new variable (Title) -> added this variable
275
	endif()
276
2648 by Matthieu Baerts
CMakeLists.txt: big changes! We are now using booleans for CMake flags
277
	if (INDICATOR_NEW_VERSION)  # oneiric and newer
278
		if (gtkversion EQUAL 2)
2254 by Fabrice Rey
Sound-Control: merged with Sound-Menu
279
			execute_process(
280
				COMMAND pkg-config --variable=iconsdir indicator-0.4
281
				OUTPUT_VARIABLE INDICATORICONSDIR)
282
		else()
283
			execute_process(
284
				COMMAND pkg-config --variable=iconsdir indicator3-0.4
285
				OUTPUT_VARIABLE INDICATORICONSDIR)
2520 by Matthieu Baerts
Added support of the new Indicator (3-0.4) to easily create Indicator applets
286
			execute_process(
287
				COMMAND pkg-config --variable=indicatordir indicator3-0.4
288
				OUTPUT_VARIABLE INDICATORDIR)
289
			STRING (REGEX REPLACE "\n" "" INDICATORDIR ${INDICATORDIR})
2668 by Fabrice Rey
All applets: use the new icon rendering API
290
			set (with_indicator3 yes)
2520 by Matthieu Baerts
Added support of the new Indicator (3-0.4) to easily create Indicator applets
291
			message (STATUS "  Indicators: with Indicator3 support")
2254 by Fabrice Rey
Sound-Control: merged with Sound-Menu
292
		endif()
293
	else()
2648 by Matthieu Baerts
CMakeLists.txt: big changes! We are now using booleans for CMake flags
294
		if (gtkversion EQUAL 2)
2254 by Fabrice Rey
Sound-Control: merged with Sound-Menu
295
			execute_process(
296
				COMMAND pkg-config --variable=iconsdir indicator
297
				OUTPUT_VARIABLE INDICATORICONSDIR)
298
		else()
299
			execute_process(
300
				COMMAND pkg-config --variable=iconsdir indicator3
301
				OUTPUT_VARIABLE INDICATORICONSDIR)
302
		endif()
303
	endif()
2648 by Matthieu Baerts
CMakeLists.txt: big changes! We are now using booleans for CMake flags
304
	STRING (REGEX REPLACE "\n" "" INDICATORICONSDIR "${INDICATORICONSDIR}")  # la commande rajoute un retour chariot ...
305
	if (with_indicator3)
2520 by Matthieu Baerts
Added support of the new Indicator (3-0.4) to easily create Indicator applets
306
		add_subdirectory (Indicator-applet3)
307
	endif()
2621 by Matthieu Baerts
CMakeLists.txt: DBusMenu GLib and GTK are needed for Indicator-Applet
308
	## DBusMenu is needed for Indicator-applet
2648 by Matthieu Baerts
CMakeLists.txt: big changes! We are now using booleans for CMake flags
309
	if (DBUSMENU_FOUND AND DBUSMENU_GTK_FOUND)
2621 by Matthieu Baerts
CMakeLists.txt: DBusMenu GLib and GTK are needed for Indicator-Applet
310
		add_subdirectory (Indicator-applet)
311
		set (with_indicator "yes")
312
	endif()
2335 by Fabrice Rey
fixed an error when compiling without libindicator
313
endif()
314
2648 by Matthieu Baerts
CMakeLists.txt: big changes! We are now using booleans for CMake flags
315
if (NOT DBUSMENU_FOUND OR NOT DBUSMENU_GTK_FOUND OR NOT INDICATOR_APPLET_FOUND)
2254 by Fabrice Rey
Sound-Control: merged with Sound-Menu
316
	message (WARNING "These modules are required to compile Indicators applet (MeMenu, Messaging-Menu, Sound-Control, Status-Notifier and Global-Menu): ${INDICATOR_APPLET_MODULE}(-0.4), ${IDO_MODULE}, ${DBUSMENU_MODULE}(-0.4), ${DBUSMENU_GTK_MODULE}(-0.4)")
317
	set (MODULES_MISSING "${MODULES_MISSING} ${INDICATOR_APPLET_MODULE}(-0.4) (${IDO_MODULE}) ${DBUSMENU_MODULE}(-0.4) ${DBUSMENU_GTK_MODULE}(-0.4)")
318
endif()
319
320
############# INDICATOR-NAME #################
321
message (STATUS "> Indicator Names:")
322
set (INDICATOR_OLD_NAMES 0)
2648 by Matthieu Baerts
CMakeLists.txt: big changes! We are now using booleans for CMake flags
323
if (force_old_indicator_names)
2254 by Fabrice Rey
Sound-Control: merged with Sound-Menu
324
	set (INDICATOR_OLD_NAMES 1)
325
	message (STATUS "  Indicators: use old Ayatana Dbus names (forced)")
326
#~ elseif ("${DISTRO_ID}" STREQUAL "Ubuntu")
327
	#~ STRING (REGEX REPLACE "\\..*" "" DISTRO_RELEASE_MAJOR ${DISTRO_RELEASE})
328
	#~ # message (STATUS "DISTRO_RELEASE_MAJOR: ${DISTRO_RELEASE_MAJOR}")
329
	#~ if (${DISTRO_RELEASE_MAJOR} LESS 11)  # from 11.04, new names are used.
330
		#~ set (INDICATOR_OLD_NAMES 1)
331
		#~ message (STATUS "  Indicators: use old Ayatana Dbus names")
332
	#~ endif()
2648 by Matthieu Baerts
CMakeLists.txt: big changes! We are now using booleans for CMake flags
333
elseif (INDICATOR_APPLET_FOUND)
2374 by Matthieu Baerts
CMakeLists.txt: fixed a CMake warning (or error?)
334
	if (NOT (${INDICATOR_MAJOR} GREATER 0 OR ${INDICATOR_MINOR} GREATER 3 OR (${INDICATOR_MINOR} EQUAL 3 AND ${INDICATOR_NANO} GREATER 20)))
335
		set (INDICATOR_OLD_NAMES 1)  # maverick or older
336
		message (STATUS "  Indicators: use old Ayatana Dbus names")
337
	endif()
2254 by Fabrice Rey
Sound-Control: merged with Sound-Menu
338
endif()
339
2315 by Fabrice Rey
Sound control applet: updated the Dbus names to match with Ubuntu 12.04
340
############# DISTRIBUTION #################
341
message (STATUS "> Distribution:")
342
# We try to detect if the user is on Ubuntu to know which bus we have to use...
343
execute_process(
344
	COMMAND lsb_release -i
345
	OUTPUT_VARIABLE DISTRO_ID)  # -> "Distributor ID:	Ubuntu"
346
if (NOT "${DISTRO_ID}" STREQUAL "") # this tool isn't available on all distributions
347
	STRING (REGEX REPLACE "\n" "" DISTRO_ID ${DISTRO_ID})  # retour chariot
348
	STRING (REGEX REPLACE ".*: *\t*" "" DISTRO_ID ${DISTRO_ID})
349
350
	execute_process(
351
		COMMAND lsb_release -r
352
		OUTPUT_VARIABLE DISTRO_RELEASE)  # -> "Release:	10.10"
353
	STRING (REGEX REPLACE "\n" "" DISTRO_RELEASE ${DISTRO_RELEASE})  # retour chariot
354
	STRING (REGEX REPLACE ".*: *\t*" "" DISTRO_RELEASE ${DISTRO_RELEASE})
355
else()
356
	# on Ubuntu deb builders, lsb_release isn't available but we can have a look to /etc/issue.net
357
	get_filename_component(ISSUE_NET "/etc/issue.net" ABSOLUTE)
358
	if (EXISTS ${ISSUE_NET}) # to not have an error with cat
359
		execute_process(
360
			COMMAND cat ${ISSUE_NET}
361
			OUTPUT_VARIABLE DISTRO_RELEASE)  # -> Ubuntu 10.10 || Ubuntu natty (development branch)
362
		if (NOT "${DISTRO_RELEASE}" STREQUAL "")
363
			STRING (REGEX REPLACE "\n" "" DISTRO_RELEASE ${DISTRO_RELEASE})  # retour chariot
364
			STRING (REGEX REPLACE " (.+)" "" DISTRO_ID ${DISTRO_RELEASE})
365
			if ("${DISTRO_ID}" STREQUAL "Ubuntu")
366
				STRING (REGEX REPLACE ".[(]development branch[)]" "" DISTRO_RELEASE ${DISTRO_RELEASE})
367
				STRING (REGEX REPLACE ".LTS" "" DISTRO_RELEASE ${DISTRO_RELEASE}) # Ubuntu 10.04.1 LTS
368
				STRING (REGEX REPLACE "(.+) " "" DISTRO_RELEASE ${DISTRO_RELEASE})
369
				if ("${DISTRO_RELEASE}" STREQUAL "natty")
370
					set (DISTRO_RELEASE "11.04")
371
				elseif ("${DISTRO_RELEASE}" STREQUAL "oneiric")
372
					set (DISTRO_RELEASE "11.10")
373
				elseif ("${DISTRO_RELEASE}" STREQUAL "precise")
374
					set (DISTRO_RELEASE "12.04")
375
				endif()
376
			endif()
377
		endif()
378
	endif()
379
endif()
380
381
if (NOT "${DISTRO_ID}" STREQUAL "")
382
	message (STATUS "  DISTRO_ID: ${DISTRO_ID}, DISTRO_RELEASE: ${DISTRO_RELEASE}")
383
endif()
384
2511 by Matthieu Baerts
CMakeLists.txt: Checked gio-2.0 for 'gvfs-integration' even if GMenu is not compiled
385
############# SHARED LIBRARIES ###########
2513 by Matthieu Baerts
CMakeLists.txt: linked each plugin to all libs used by gldi except gldi
386
message (STATUS "> Shared Libraries:")
387
1546.1.2 by fabounet
added the files for cimpiling with cmake
388
############# ALSA_MIXER #################
1981 by matttbe
CMakeLists.txt: Fixed a compilation error in Composite Manager + added a few messages in order to have a better debugging and removed a few blank messages in KDE
389
message (STATUS "> AlsaMixer:")
2668 by Fabrice Rey
All applets: use the new icon rendering API
390
set (with_alsa no)
391
set (with_soundmenu no)
2648 by Matthieu Baerts
CMakeLists.txt: big changes! We are now using booleans for CMake flags
392
enable_if_not_defined (enable-alsa-mixer)
393
if (enable-alsa-mixer)
1546.1.2 by fabounet
added the files for cimpiling with cmake
394
	pkg_check_modules (ALSA_MIXER_PACKAGE alsa)
2648 by Matthieu Baerts
CMakeLists.txt: big changes! We are now using booleans for CMake flags
395
	if (NOT ALSA_MIXER_PACKAGE_FOUND)
1546.1.2 by fabounet
added the files for cimpiling with cmake
396
		message (STATUS "Could not find alsa; Cairo-Dock won't be built with AlsaMixer applet.")
2047 by matttbe
CMakeLists.txt: Added some warnings if a module or a program is missing + added some messages (+ fixed a few typos)
397
		message (WARNING "This module is required to compile AlsaMixer applet: alsa")
398
		set (MODULES_MISSING "${MODULES_MISSING} alsa")
1546.1.2 by fabounet
added the files for cimpiling with cmake
399
	else()
400
		set (GETTEXT_ALSA_MIXER ${GETTEXT_PLUGINS})
2721 by Matthieu Baerts
alsaMixer: SoundMenu: Load the menu from libsoundmenu.so directly if indicator3 is available
401
		set (VERSION_ALSA_MIXER "2.1.4")
1546.1.2 by fabounet
added the files for cimpiling with cmake
402
		set (PACKAGE_ALSA_MIXER "cd-AlsaMixer")
2668 by Fabrice Rey
All applets: use the new icon rendering API
403
		set (with_alsa yes)
1546.1.4 by fabounet
cmake compilation is operational
404
		set (alsa_mixerdatadir "${pluginsdatadir}/AlsaMixer")
1663 by matttbe
CMakeLists:
405
		configure_file (${CMAKE_CURRENT_SOURCE_DIR}/alsaMixer/data/AlsaMixer.conf.in ${CMAKE_CURRENT_BINARY_DIR}/alsaMixer/data/AlsaMixer.conf)
2721 by Matthieu Baerts
alsaMixer: SoundMenu: Load the menu from libsoundmenu.so directly if indicator3 is available
406
		if (with_indicator3)
407
			set (INDICATOR_SOUNDMENU_WITH_IND3 TRUE) # If it's supported, it's maybe better to use it
408
			set (with_soundmenu yes)
409
		elseif (with_indicator AND IDO_FOUND
2263 by Matthieu Baerts
Sound-Menu: removed support of old versions of dbusmenu, indicator and ido (mostly for Maverick which will no longer be supported after April 2012)
410
			AND "${INDICATOR_OLD_NAMES}" STREQUAL "0")
2668 by Fabrice Rey
All applets: use the new icon rendering API
411
			set (with_soundmenu yes)
2255 by Matthieu Baerts
CMakeLists.txt: Sound-Control with Sound-Menu support: Checked if IDO is available and not with an old version
412
		endif()
1546.1.2 by fabounet
added the files for cimpiling with cmake
413
		add_subdirectory ("alsaMixer")
414
	endif()
415
endif()
416
417
############# ANIMATED ICONS #################
1981 by matttbe
CMakeLists.txt: Fixed a compilation error in Composite Manager + added a few messages in order to have a better debugging and removed a few blank messages in KDE
418
message (STATUS "> Animated Icons:")
1546.1.2 by fabounet
added the files for cimpiling with cmake
419
set (GETTEXT_ANIMATED_ICONS ${GETTEXT_PLUGINS})
2585 by Matthieu Baerts
CMakeLists.txt: bumped the version of all applets (just to be sure :) )
420
set (VERSION_ANIMATED_ICONS "1.0.12")
1546.1.2 by fabounet
added the files for cimpiling with cmake
421
set (PACKAGE_ANIMATED_ICONS "cd-Animated-icons")
1546.1.4 by fabounet
cmake compilation is operational
422
set (animated_iconsdatadir "${pluginsdatadir}/Animated-icons")
1663 by matttbe
CMakeLists:
423
configure_file (${CMAKE_CURRENT_SOURCE_DIR}/Animated-icons/data/Animated-icons.conf.in ${CMAKE_CURRENT_BINARY_DIR}/Animated-icons/data/Animated-icons.conf)
1546.1.2 by fabounet
added the files for cimpiling with cmake
424
add_subdirectory (Animated-icons)
425
426
############# CAIRO_PENGUIN #################
1981 by matttbe
CMakeLists.txt: Fixed a compilation error in Composite Manager + added a few messages in order to have a better debugging and removed a few blank messages in KDE
427
message (STATUS "> Cairo Penguin:")
1546.1.2 by fabounet
added the files for cimpiling with cmake
428
set (GETTEXT_CAIRO_PENGUIN ${GETTEXT_PLUGINS})
2585 by Matthieu Baerts
CMakeLists.txt: bumped the version of all applets (just to be sure :) )
429
set (VERSION_CAIRO_PENGUIN "1.1.12")
1546.1.2 by fabounet
added the files for cimpiling with cmake
430
set (PACKAGE_CAIRO_PENGUIN "cd-Cairo-Penguin")
431
set (cairo_penguinuserdirname "Cairo-Penguin")
1546.1.4 by fabounet
cmake compilation is operational
432
set (cairo_penguindatadir "${pluginsdatadir}/Cairo-Penguin")
1663 by matttbe
CMakeLists:
433
configure_file (${CMAKE_CURRENT_SOURCE_DIR}/Cairo-Penguin/data/Cairo-Penguin.conf.in ${CMAKE_CURRENT_BINARY_DIR}/Cairo-Penguin/data/Cairo-Penguin.conf)
1546.1.2 by fabounet
added the files for cimpiling with cmake
434
add_subdirectory (Cairo-Penguin)
435
436
############# CLIPPER #################
1981 by matttbe
CMakeLists.txt: Fixed a compilation error in Composite Manager + added a few messages in order to have a better debugging and removed a few blank messages in KDE
437
message (STATUS "> Clipper:")
1546.1.2 by fabounet
added the files for cimpiling with cmake
438
set (GETTEXT_CLIPPER ${GETTEXT_PLUGINS})
2585 by Matthieu Baerts
CMakeLists.txt: bumped the version of all applets (just to be sure :) )
439
set (VERSION_CLIPPER "1.1.8")
1546.1.2 by fabounet
added the files for cimpiling with cmake
440
set (PACKAGE_CLIPPER "cd-Clipper")
1546.1.4 by fabounet
cmake compilation is operational
441
set (Clipperdatadir "${pluginsdatadir}/Clipper")
1663 by matttbe
CMakeLists:
442
configure_file (${CMAKE_CURRENT_SOURCE_DIR}/Clipper/data/Clipper.conf.in ${CMAKE_CURRENT_BINARY_DIR}/Clipper/data/Clipper.conf)
1546.1.2 by fabounet
added the files for cimpiling with cmake
443
add_subdirectory (Clipper)
444
445
############# CLOCK #################
1981 by matttbe
CMakeLists.txt: Fixed a compilation error in Composite Manager + added a few messages in order to have a better debugging and removed a few blank messages in KDE
446
message (STATUS "> Clock:")
2648 by Matthieu Baerts
CMakeLists.txt: big changes! We are now using booleans for CMake flags
447
enable_if_not_defined (enable-ical-support)
2747 by Fabrice Rey
Clock: fixed a few bugs with ICS file support
448
set (with_ical no)
2648 by Matthieu Baerts
CMakeLists.txt: big changes! We are now using booleans for CMake flags
449
if (enable-ical-support)
450
	pkg_check_modules ("LIBICAL_PACKAGE" "libical")
451
	if (NOT LIBICAL_PACKAGE_FOUND)
452
		message (STATUS "Could not find libical; Clock plugin won't be built with iCal support.")
453
		message (WARNING "This module is required to compile Clock applet with iCal support: libical")
454
		set (MODULES_MISSING "${MODULES_MISSING} libical")
455
	else ()
2668 by Fabrice Rey
All applets: use the new icon rendering API
456
		set (with_ical yes)
2648 by Matthieu Baerts
CMakeLists.txt: big changes! We are now using booleans for CMake flags
457
	endif()
1602 by Tofe
Clock now manages iCal; some fixes also
458
endif()
1546.1.2 by fabounet
added the files for cimpiling with cmake
459
set (GETTEXT_CLOCK ${GETTEXT_PLUGINS})
2585 by Matthieu Baerts
CMakeLists.txt: bumped the version of all applets (just to be sure :) )
460
set (VERSION_CLOCK "2.2.2")
1546.1.2 by fabounet
added the files for cimpiling with cmake
461
set (PACKAGE_CLOCK "cd-clock")
462
set (clockuserdirname "clock")
1546.1.4 by fabounet
cmake compilation is operational
463
set (clockdatadir "${pluginsdatadir}/clock")
1663 by matttbe
CMakeLists:
464
configure_file (${CMAKE_CURRENT_SOURCE_DIR}/clock/data/clock.conf.in ${CMAKE_CURRENT_BINARY_DIR}/clock/data/clock.conf)
1546.1.2 by fabounet
added the files for cimpiling with cmake
465
add_subdirectory (clock)
466
1980 by Fabrice Rey
changed the .conf 'Icon' group layout + updated translations => beta1
467
############# COMPOSITE_MANAGER #################
2073 by Matthieu Baerts
CMakeLists.txt: Impulse is now considered as stable
468
message (STATUS "> Composite Manager:")
1980 by Fabrice Rey
changed the .conf 'Icon' group layout + updated translations => beta1
469
set (GETTEXT_COMPOSITE_MANAGER ${GETTEXT_PLUGINS})
2585 by Matthieu Baerts
CMakeLists.txt: bumped the version of all applets (just to be sure :) )
470
set (VERSION_COMPOSITE_MANAGER "1.0.3")
1980 by Fabrice Rey
changed the .conf 'Icon' group layout + updated translations => beta1
471
set (PACKAGE_COMPOSITE_MANAGER "cd-Composite-Manager")
472
set (composite_managerdatadir "${pluginsdatadir}/Composite-Manager")
1981 by matttbe
CMakeLists.txt: Fixed a compilation error in Composite Manager + added a few messages in order to have a better debugging and removed a few blank messages in KDE
473
configure_file (${CMAKE_CURRENT_SOURCE_DIR}/Composite-Manager/data/Composite-Manager.conf.in ${CMAKE_CURRENT_BINARY_DIR}/Composite-Manager/data/Composite-Manager.conf)
1980 by Fabrice Rey
changed the .conf 'Icon' group layout + updated translations => beta1
474
add_subdirectory (Composite-Manager)
1546.1.2 by fabounet
added the files for cimpiling with cmake
475
476
############# DBUS #################
1981 by matttbe
CMakeLists.txt: Fixed a compilation error in Composite Manager + added a few messages in order to have a better debugging and removed a few blank messages in KDE
477
message (STATUS "> DBus:")
2872 by Matthieu Baerts
CMakeLists.txt: DBus: Python: support DESTDIR env var
478
set (with_python no)
479
set (with_python2 no)
480
set (with_python3 no)
2648 by Matthieu Baerts
CMakeLists.txt: big changes! We are now using booleans for CMake flags
481
enable_if_not_defined (enable-python-interface)
482
if (enable-python-interface)
483
	message (STATUS " * Python:")
2778 by Fabrice Rey
Dbus interfaces: install python interfaces for both python2 and 3
484
	# find python executables
485
	find_program (PYTHON2_EXECUTABLE python2)  # if both python2&3 are installed, usually we will have 'python2' and 'python3' available (one of them being a link to 'python')
486
	if (PYTHON2_EXECUTABLE AND EXISTS ${PYTHON2_EXECUTABLE})
487
		set (PYTHON2_FOUND TRUE)
2872 by Matthieu Baerts
CMakeLists.txt: DBus: Python: support DESTDIR env var
488
		set (with_python2 yes)
2778 by Fabrice Rey
Dbus interfaces: install python interfaces for both python2 and 3
489
	endif()
490
	find_program (PYTHON3_EXECUTABLE python3)
491
	if (PYTHON3_EXECUTABLE AND EXISTS ${PYTHON3_EXECUTABLE})
492
		set (PYTHON3_FOUND TRUE)
2872 by Matthieu Baerts
CMakeLists.txt: DBus: Python: support DESTDIR env var
493
		set (with_python3 yes)
2778 by Fabrice Rey
Dbus interfaces: install python interfaces for both python2 and 3
494
	endif()
2780 by Matthieu Baerts
CMakeLists: check the version of 'python' if we doesn't find 'python2' OR 'python3'
495
	if (NOT PYTHON2_FOUND OR NOT PYTHON3_FOUND)  # if we didn't find one of them, 
2648 by Matthieu Baerts
CMakeLists.txt: big changes! We are now using booleans for CMake flags
496
		find_program (PYTHON_EXECUTABLE python)
2872 by Matthieu Baerts
CMakeLists.txt: DBus: Python: support DESTDIR env var
497
		if (PYTHON_EXECUTABLE AND EXISTS ${PYTHON_EXECUTABLE})
498
			EXECUTE_PROCESS(COMMAND ${PYTHON_EXECUTABLE} -c
499
				"from __future__ import print_function; import sys; print(sys.version)"
500
				OUTPUT_VARIABLE PYTHON_VERSION)
501
			STRING (REGEX REPLACE "\\..*" "" PYTHON_VERSION ${PYTHON_VERSION})
502
			message (STATUS "   Python Version: ${PYTHON_VERSION}")
503
			if ("${PYTHON_VERSION}" STREQUAL "2")
504
				set (PYTHON2_EXECUTABLE ${PYTHON_EXECUTABLE})
505
				set (PYTHON2_FOUND TRUE)
506
				set (with_python2 yes)
507
			elseif ("${PYTHON_VERSION}" STREQUAL "3")
508
				set (PYTHON3_EXECUTABLE ${PYTHON_EXECUTABLE})
509
				set (PYTHON3_FOUND TRUE)
510
				set (with_python3 yes)
511
			endif()
2778 by Fabrice Rey
Dbus interfaces: install python interfaces for both python2 and 3
512
		endif()
2648 by Matthieu Baerts
CMakeLists.txt: big changes! We are now using booleans for CMake flags
513
	endif()
2778 by Fabrice Rey
Dbus interfaces: install python interfaces for both python2 and 3
514
	
515
	# see if we found anything
516
	if (NOT PYTHON2_FOUND AND NOT PYTHON3_FOUND)
2648 by Matthieu Baerts
CMakeLists.txt: big changes! We are now using booleans for CMake flags
517
		message (STATUS "Could not find Python, won't install Python interface.")
518
		message (WARNING "This program is required to compile DBus applet with Python interface: python (version 2)")
519
		set (PROGRAMS_MISSING "${PROGRAMS_MISSING} python")
520
	else()
2778 by Fabrice Rey
Dbus interfaces: install python interfaces for both python2 and 3
521
		message (STATUS "   Python executable program(s): ${PYTHON2_EXECUTABLE} ; ${PYTHON3_EXECUTABLE}")
2648 by Matthieu Baerts
CMakeLists.txt: big changes! We are now using booleans for CMake flags
522
		GET_FILENAME_COMPONENT(DEBIAN_VERSION /etc/debian_version ABSOLUTE)
523
		if (EXISTS ${DEBIAN_VERSION})
524
			message (STATUS "   will use '--install-layout deb' with 'python setup.py install'")
525
			set (DEBIAN_INSTALL_LAYOUT "--install-layout deb")
526
		endif()
2668 by Fabrice Rey
All applets: use the new icon rendering API
527
		set (with_python yes)
2648 by Matthieu Baerts
CMakeLists.txt: big changes! We are now using booleans for CMake flags
528
	endif()
529
endif()
530
531
enable_if_not_defined (enable-ruby-interface)
532
if (enable-ruby-interface)
533
	message (STATUS " * Ruby:")
534
	# find_package(Ruby) found libs of ruby-dev but we only need a directory where we can install ruby libs.
535
	find_program (RUBY_EXECUTABLE ruby)
536
	EXECUTE_PROCESS(COMMAND ${RUBY_EXECUTABLE} -r rbconfig -e "print RbConfig::CONFIG['rubylibdir']"
537
		OUTPUT_VARIABLE RUBY_LIB_DIR)
538
	message (STATUS "   Ruby library dir: ${RUBY_LIB_DIR}")
539
	if ("${RUBY_LIB_DIR}" STREQUAL "" OR "${RUBY_LIB_DIR}" STREQUAL "nil")
540
		message (STATUS "Could not find ruby libs, won't install Ruby interface.")
541
		message (WARNING "This program is required to compile DBus applet with Ruby interface: ruby")
542
		set (PROGRAMS_MISSING "${PROGRAMS_MISSING} ruby")
2668 by Fabrice Rey
All applets: use the new icon rendering API
543
		set (with_ruby no)
2648 by Matthieu Baerts
CMakeLists.txt: big changes! We are now using booleans for CMake flags
544
	else()
545
		# /usr/lib/ruby/1.8 or /usr/lib/ruby/1.9.1
546
		string (REGEX REPLACE "lib/ruby/[0-9].[0-9]?.+" "" RUBY_LIB_DIR_INSTALL "${RUBY_LIB_DIR}")
547
		string (REGEX REPLACE "${RUBY_LIB_DIR_INSTALL}" "" RUBY_LIB_DIR_INSTALL "${RUBY_LIB_DIR}")
548
		set (RUBY_LIB_DIR "${CMAKE_INSTALL_PREFIX}/${RUBY_LIB_DIR_INSTALL}")
549
		message (STATUS "   will be installed in: ${RUBY_LIB_DIR}")
550
		set (RUBY_FOUND "TRUE")
2668 by Fabrice Rey
All applets: use the new icon rendering API
551
		set (with_ruby yes)
2648 by Matthieu Baerts
CMakeLists.txt: big changes! We are now using booleans for CMake flags
552
	endif()
553
endif()
554
2872 by Matthieu Baerts
CMakeLists.txt: DBus: Python: support DESTDIR env var
555
set (with_mono no)
2648 by Matthieu Baerts
CMakeLists.txt: big changes! We are now using booleans for CMake flags
556
enable_if_not_defined (enable-mono-interface)
557
if (enable-mono-interface)
558
	message (STATUS " * Mono:")
559
	#find_package (Mono)
560
	find_program (GMCS_EXECUTABLE gmcs)
561
	if (NOT GMCS_EXECUTABLE OR NOT EXISTS ${GMCS_EXECUTABLE})
562
		message (STATUS "Could not find Mono compiler gmcs, won't build Mono interface.")
563
	else()
564
		pkg_check_modules (MONO_PACKAGE glib-sharp-2.0 ndesk-dbus-1.0 ndesk-dbus-glib-1.0)
565
		if (NOT MONO_PACKAGE_FOUND)
566
			message (STATUS "Could not find glib-sharp-2.0, ndesk-dbus-1.0 or ndesk-dbus-glib-1.0; won't be built Mono interface.")
567
			message (WARNING "These modules are required to compile DBus applet with Mono interface: glib-sharp-2.0, ndesk-dbus-1.0 and ndesk-dbus-glib-1.0")
568
			set (MODULES_MISSING "${MODULES_MISSING} glib-sharp-2.0 ndesk-dbus-1.0 ndesk-dbus-glib-1.0")
569
		else()
570
			set (MONO_FOUND TRUE)
2668 by Fabrice Rey
All applets: use the new icon rendering API
571
			set (with_mono yes)
2648 by Matthieu Baerts
CMakeLists.txt: big changes! We are now using booleans for CMake flags
572
		endif()
573
	endif()
574
endif()
575
2872 by Matthieu Baerts
CMakeLists.txt: DBus: Python: support DESTDIR env var
576
set (with_vala no)
577
set (with_valac no)
2648 by Matthieu Baerts
CMakeLists.txt: big changes! We are now using booleans for CMake flags
578
enable_if_not_defined (enable-vala-interface)
579
if (enable-vala-interface)
580
	message (STATUS " * Vala:")
581
	# Valac is only required to convert vala files to C files.
582
	#  So we can directly use produced files (c, h, vapi) without using valac.
2668 by Fabrice Rey
All applets: use the new icon rendering API
583
	set (with_vala yes)
584
	set (with_valac no)
2648 by Matthieu Baerts
CMakeLists.txt: big changes! We are now using booleans for CMake flags
585
	find_program (VALAC_EXE valac)
586
	message (STATUS "   Path to valac: ${VALAC_EXE}")
587
588
	enable_if_not_defined (enable-vala-support)
589
	if (NOT enable-vala-support)
2668 by Fabrice Rey
All applets: use the new icon rendering API
590
		set (with_vala no)
2648 by Matthieu Baerts
CMakeLists.txt: big changes! We are now using booleans for CMake flags
591
	# Glib < 2.26
592
	elseif (${GLIB_MAJOR} LESS 3 AND ${GLIB_MINOR} LESS 26)
2668 by Fabrice Rey
All applets: use the new icon rendering API
593
		set (with_vala no)
2648 by Matthieu Baerts
CMakeLists.txt: big changes! We are now using booleans for CMake flags
594
	elseif (VALAC_EXE AND EXISTS ${VALAC_EXE}) # now it works with 0.10 and 0.11 (= next 0.12) # $VALAC_EXE may be the correct path, even if valac is not installed !
595
		execute_process(COMMAND ${VALAC_EXE} "--version"
596
			OUTPUT_VARIABLE "VALA_VERSION")
597
		string(REPLACE "Vala" "" "VALA_VERSION" ${VALA_VERSION})
598
		string(STRIP ${VALA_VERSION} "VALA_VERSION")
599
		message (STATUS "   Vala version: ${VALA_VERSION}")
600
601
		STRING (REGEX REPLACE "\\..*" "" VALA_MAJOR "${VALA_VERSION}")
602
		# message (STATUS "VALA_MAJOR : ${VALA_MAJOR}")
603
604
		STRING (REGEX REPLACE "[0-9]*\\.([^ ]+)" "\\1" VALA_MINOR "${VALA_VERSION}")  # 0.1.7 => 1.7
605
		STRING (REGEX REPLACE "\\.[0-9]*" "" VALA_MINOR "${VALA_MINOR}")
606
		# message (STATUS "VALA_MINOR : ${VALA_MINOR}")
607
608
		STRING (REGEX REPLACE ".*\\." "" VALA_NANO "${VALA_VERSION}")
609
		STRING (REGEX REPLACE "-.*" "" VALA_NANO "${VALA_NANO}")
610
		# message (STATUS "VALA_NANO  : ${VALA_NANO}")
611
612
		if (${VALA_MAJOR} GREATER 0 OR ${VALA_MINOR} GREATER 9) # vala >= 0.10 
613
			# AND (${VALA_MAJOR} LESS 1 AND ${VALA_MINOR} LESS 13)) # and <= 0.12
614
			message (STATUS "   Vala compiler OK (>= 0.10).")# and <= 0.12).")
615
			set (VALAC_FOUND TRUE)
2668 by Fabrice Rey
All applets: use the new icon rendering API
616
			set (with_valac yes)
2648 by Matthieu Baerts
CMakeLists.txt: big changes! We are now using booleans for CMake flags
617
		else()
618
			message (STATUS "   Vala compiler is too old (0.10 required) or too new (> 0.12), won't build Vala interface.")
619
		endif()
620
	else()
621
		message (STATUS "Could not find ValaC, won't build Vala interface with the version of your distribution.")
622
		message (WARNING "This program is required to compile DBus applet with Vala interface: valac (version > 0.10)")
623
		set (PROGRAMS_MISSING "${PROGRAMS_MISSING} valac")
624
	endif()
1811.1.4 by Fabrice Rey
added the vala interface
625
endif()
626
627
1546.1.2 by fabounet
added the files for cimpiling with cmake
628
set (GETTEXT_DBUS ${GETTEXT_PLUGINS})
2585 by Matthieu Baerts
CMakeLists.txt: bumped the version of all applets (just to be sure :) )
629
set (VERSION_DBUS "1.2.2")
1546.1.2 by fabounet
added the files for cimpiling with cmake
630
set (PACKAGE_DBUS "cd-Dbus")
1546.1.4 by fabounet
cmake compilation is operational
631
set (dbusdatadir "${pluginsdatadir}/Dbus")
1663 by matttbe
CMakeLists:
632
configure_file (${CMAKE_CURRENT_SOURCE_DIR}/Dbus/data/Dbus.conf.in ${CMAKE_CURRENT_BINARY_DIR}/Dbus/data/Dbus.conf)
1546.1.2 by fabounet
added the files for cimpiling with cmake
633
add_subdirectory (Dbus)
634
635
############# DESKLET_RENDERING #################
1981 by matttbe
CMakeLists.txt: Fixed a compilation error in Composite Manager + added a few messages in order to have a better debugging and removed a few blank messages in KDE
636
message (STATUS "> Desklet Rendering:")
1546.1.2 by fabounet
added the files for cimpiling with cmake
637
set (GETTEXT_DESKLET_RENDERING ${GETTEXT_PLUGINS})
2585 by Matthieu Baerts
CMakeLists.txt: bumped the version of all applets (just to be sure :) )
638
set (VERSION_DESKLET_RENDERING "1.5.7")
1546.1.2 by fabounet
added the files for cimpiling with cmake
639
set (PACKAGE_DESKLET_RENDERING "cd-desklet-rendering")
1546.1.4 by fabounet
cmake compilation is operational
640
set (desklet_renderingdatadir "${pluginsdatadir}/desklet-rendering")
1663 by matttbe
CMakeLists:
641
configure_file (${CMAKE_CURRENT_SOURCE_DIR}/desklet-rendering/data/desklet-rendering.conf.in ${CMAKE_CURRENT_BINARY_DIR}/desklet-rendering/data/desklet-rendering.conf)
1546.1.2 by fabounet
added the files for cimpiling with cmake
642
add_subdirectory (desklet-rendering)
643
644
############# DIALOG_RENDERING #################
1981 by matttbe
CMakeLists.txt: Fixed a compilation error in Composite Manager + added a few messages in order to have a better debugging and removed a few blank messages in KDE
645
message (STATUS "> Dialog Rendering:")
1546.1.2 by fabounet
added the files for cimpiling with cmake
646
set (GETTEXT_DIALOG_RENDERING ${GETTEXT_PLUGINS})
2585 by Matthieu Baerts
CMakeLists.txt: bumped the version of all applets (just to be sure :) )
647
set (VERSION_DIALOG_RENDERING "0.5.2")
1546.1.2 by fabounet
added the files for cimpiling with cmake
648
set (PACKAGE_DIALOG_RENDERING "cd-dialog-rendering")
1546.1.4 by fabounet
cmake compilation is operational
649
set (dialog_renderingdatadir "${pluginsdatadir}/dialog-rendering")
1663 by matttbe
CMakeLists:
650
configure_file (${CMAKE_CURRENT_SOURCE_DIR}/dialog-rendering/data/dialog-rendering.conf.in ${CMAKE_CURRENT_BINARY_DIR}/dialog-rendering/data/dialog-rendering.conf)
1546.1.2 by fabounet
added the files for cimpiling with cmake
651
add_subdirectory (dialog-rendering)
652
1762.1.8 by sqp
Disks : Update CMakeLists
653
############# DISKS #################
2668 by Fabrice Rey
All applets: use the new icon rendering API
654
set (with_disks no) # unstable
2648 by Matthieu Baerts
CMakeLists.txt: big changes! We are now using booleans for CMake flags
655
if (enable-disks)
1981 by matttbe
CMakeLists.txt: Fixed a compilation error in Composite Manager + added a few messages in order to have a better debugging and removed a few blank messages in KDE
656
	message (STATUS "> Disks:")
1790 by matttbe
Disks: compiled from root directory with this flag --enable-disks=yes
657
	set (GETTEXT_DISKS ${GETTEXT_PLUGINS})
2585 by Matthieu Baerts
CMakeLists.txt: bumped the version of all applets (just to be sure :) )
658
	set (VERSION_DISKS "0.0.6")
1790 by matttbe
Disks: compiled from root directory with this flag --enable-disks=yes
659
	set (PACKAGE_DISKS "cd-disks")
2668 by Fabrice Rey
All applets: use the new icon rendering API
660
	set (with_disks yes)
1790 by matttbe
Disks: compiled from root directory with this flag --enable-disks=yes
661
	set (disksdatadir "${pluginsdatadir}/Disks")
662
	configure_file (${CMAKE_CURRENT_SOURCE_DIR}/Disks/data/Disks.conf.in ${CMAKE_CURRENT_BINARY_DIR}/Disks/data/Disks.conf)
663
	add_subdirectory ("Disks")
664
endif()
1762.1.8 by sqp
Disks : Update CMakeLists
665
1546.1.2 by fabounet
added the files for cimpiling with cmake
666
############# DND2SHARE #################
1981 by matttbe
CMakeLists.txt: Fixed a compilation error in Composite Manager + added a few messages in order to have a better debugging and removed a few blank messages in KDE
667
message (STATUS "> DND2Share:")
1546.1.2 by fabounet
added the files for cimpiling with cmake
668
set (GETTEXT_DND2SHARE ${GETTEXT_PLUGINS})
2585 by Matthieu Baerts
CMakeLists.txt: bumped the version of all applets (just to be sure :) )
669
set (VERSION_DND2SHARE "1.0.10")
1546.1.2 by fabounet
added the files for cimpiling with cmake
670
set (PACKAGE_DND2SHARE "cd-dnd2share")
1546.1.4 by fabounet
cmake compilation is operational
671
set (dnd2sharedatadir "${pluginsdatadir}/dnd2share")
1663 by matttbe
CMakeLists:
672
configure_file (${CMAKE_CURRENT_SOURCE_DIR}/dnd2share/data/dnd2share.conf.in ${CMAKE_CURRENT_BINARY_DIR}/dnd2share/data/dnd2share.conf)
1546.1.2 by fabounet
added the files for cimpiling with cmake
673
add_subdirectory (dnd2share)
674
675
############# DOCK RENDERING #################
1981 by matttbe
CMakeLists.txt: Fixed a compilation error in Composite Manager + added a few messages in order to have a better debugging and removed a few blank messages in KDE
676
message (STATUS "> Dock Rendering:")
1546.1.2 by fabounet
added the files for cimpiling with cmake
677
set (GETTEXT_RENDERING ${GETTEXT_PLUGINS})
2585 by Matthieu Baerts
CMakeLists.txt: bumped the version of all applets (just to be sure :) )
678
set (VERSION_RENDERING "1.5.10")
1546.1.2 by fabounet
added the files for cimpiling with cmake
679
set (PACKAGE_RENDERING "cd-rendering")
1546.1.4 by fabounet
cmake compilation is operational
680
set (renderingdatadir "${pluginsdatadir}/rendering")
1663 by matttbe
CMakeLists:
681
configure_file (${CMAKE_CURRENT_SOURCE_DIR}/dock-rendering/data/rendering.conf.in ${CMAKE_CURRENT_BINARY_DIR}/dock-rendering/data/rendering.conf)
1546.1.2 by fabounet
added the files for cimpiling with cmake
682
add_subdirectory (dock-rendering)
683
684
############# DONCKY #################
2668 by Fabrice Rey
All applets: use the new icon rendering API
685
set (with_doncky no) # unstable
2648 by Matthieu Baerts
CMakeLists.txt: big changes! We are now using booleans for CMake flags
686
if (enable-doncky)
1981 by matttbe
CMakeLists.txt: Fixed a compilation error in Composite Manager + added a few messages in order to have a better debugging and removed a few blank messages in KDE
687
	message (STATUS "> Doncky:")
1546.1.4 by fabounet
cmake compilation is operational
688
	set (GETTEXT_DONCKY ${GETTEXT_PLUGINS})
2585 by Matthieu Baerts
CMakeLists.txt: bumped the version of all applets (just to be sure :) )
689
	set (VERSION_DONCKY "0.0.8")
1546.1.4 by fabounet
cmake compilation is operational
690
	set (PACKAGE_DONCKY "cd-doncky")
2668 by Fabrice Rey
All applets: use the new icon rendering API
691
	set (with_doncky yes)
1546.1.4 by fabounet
cmake compilation is operational
692
	set (donckydatadir "${pluginsdatadir}/Doncky")
1663 by matttbe
CMakeLists:
693
	configure_file (${CMAKE_CURRENT_SOURCE_DIR}/Doncky/data/Doncky.conf.in ${CMAKE_CURRENT_BINARY_DIR}/Doncky/data/Doncky.conf)
1546.1.4 by fabounet
cmake compilation is operational
694
	add_subdirectory (Doncky)
695
endif()
1546.1.2 by fabounet
added the files for cimpiling with cmake
696
697
############# DROP INDICATOR #################
1981 by matttbe
CMakeLists.txt: Fixed a compilation error in Composite Manager + added a few messages in order to have a better debugging and removed a few blank messages in KDE
698
message (STATUS "> Drop Indicator:")
1546.1.2 by fabounet
added the files for cimpiling with cmake
699
set (GETTEXT_DROP_INDICATOR ${GETTEXT_PLUGINS})
2585 by Matthieu Baerts
CMakeLists.txt: bumped the version of all applets (just to be sure :) )
700
set (VERSION_DROP_INDICATOR "1.1.6")
1546.1.2 by fabounet
added the files for cimpiling with cmake
701
set (PACKAGE_DROP_INDICATOR "cd-drop_indicator")
1546.1.4 by fabounet
cmake compilation is operational
702
set (drop_indicatordatadir "${pluginsdatadir}/drop-indicator")
1663 by matttbe
CMakeLists:
703
configure_file (${CMAKE_CURRENT_SOURCE_DIR}/drop-indicator/data/drop_indicator.conf.in ${CMAKE_CURRENT_BINARY_DIR}/drop-indicator/data/drop_indicator.conf)
1546.1.2 by fabounet
added the files for cimpiling with cmake
704
add_subdirectory (drop-indicator)
705
706
############# DUSTBIN #################
1981 by matttbe
CMakeLists.txt: Fixed a compilation error in Composite Manager + added a few messages in order to have a better debugging and removed a few blank messages in KDE
707
message (STATUS "> Dustbin:")
1546.1.2 by fabounet
added the files for cimpiling with cmake
708
set (GETTEXT_DUSTBIN ${GETTEXT_PLUGINS})
2585 by Matthieu Baerts
CMakeLists.txt: bumped the version of all applets (just to be sure :) )
709
set (VERSION_DUSTBIN "2.3.5")
1546.1.2 by fabounet
added the files for cimpiling with cmake
710
set (PACKAGE_DUSTBIN "cd-dustbin")
711
set (dustbinuserdirname "dustbin")
1546.1.4 by fabounet
cmake compilation is operational
712
set (dustbindatadir "${pluginsdatadir}/dustbin")
1663 by matttbe
CMakeLists:
713
configure_file (${CMAKE_CURRENT_SOURCE_DIR}/dustbin/data/dustbin.conf.in ${CMAKE_CURRENT_BINARY_DIR}/dustbin/data/dustbin.conf)
1546.1.2 by fabounet
added the files for cimpiling with cmake
714
add_subdirectory (dustbin)
715
1718 by Fabrice Rey
Slide : scrolling (in progress) + dialogs : updated tooltip (in progress)
716
############# FOLDERS #################
1981 by matttbe
CMakeLists.txt: Fixed a compilation error in Composite Manager + added a few messages in order to have a better debugging and removed a few blank messages in KDE
717
message (STATUS "> Folders:")
1718 by Fabrice Rey
Slide : scrolling (in progress) + dialogs : updated tooltip (in progress)
718
set (GETTEXT_FOLDERS ${GETTEXT_PLUGINS})
2585 by Matthieu Baerts
CMakeLists.txt: bumped the version of all applets (just to be sure :) )
719
set (VERSION_FOLDERS "0.2.5")
1718 by Fabrice Rey
Slide : scrolling (in progress) + dialogs : updated tooltip (in progress)
720
set (PACKAGE_FOLDERS "cd-Folders")
721
set (foldersdatadir "${pluginsdatadir}/Folders")
722
configure_file (${CMAKE_CURRENT_SOURCE_DIR}/Folders/data/Folders.conf.in ${CMAKE_CURRENT_BINARY_DIR}/Folders/data/Folders.conf)
723
add_subdirectory (Folders)
724
2489 by Matthieu Baerts
.conf.in files: removed '#F[Applet's Handbook]' which is no longer needed due to the changes in the widget API
725
############# GLOBAL-MENU #################
2668 by Fabrice Rey
All applets: use the new icon rendering API
726
set (with_global_menu no) # unstable
2648 by Matthieu Baerts
CMakeLists.txt: big changes! We are now using booleans for CMake flags
727
if (enable-global-menu AND "${INDICATOR_OLD_NAMES}" STREQUAL "0" AND DBUSMENU_FOUND AND DBUSMENU_GTK_FOUND)  # currently only supported with new name of the indicator module and with newer version of dbusmenu
2489 by Matthieu Baerts
.conf.in files: removed '#F[Applet's Handbook]' which is no longer needed due to the changes in the widget API
728
	message (STATUS "> Global-Menu:")
729
	set (GETTEXT_GLOBAL_MENU ${GETTEXT_PLUGINS})
2585 by Matthieu Baerts
CMakeLists.txt: bumped the version of all applets (just to be sure :) )
730
	set (VERSION_GLOBAL_MENU "0.1.2")
2489 by Matthieu Baerts
.conf.in files: removed '#F[Applet's Handbook]' which is no longer needed due to the changes in the widget API
731
	set (PACKAGE_GLOBAL_MENU "cd-Global-Menu")
2668 by Fabrice Rey
All applets: use the new icon rendering API
732
	set (with_global_menu yes)
2489 by Matthieu Baerts
.conf.in files: removed '#F[Applet's Handbook]' which is no longer needed due to the changes in the widget API
733
	set (global_menudatadir "${pluginsdatadir}/Global-Menu")
734
	configure_file (${CMAKE_CURRENT_SOURCE_DIR}/Global-Menu/data/Global-Menu.conf.in ${CMAKE_CURRENT_BINARY_DIR}/Global-Menu/data/Global-Menu.conf)
735
	add_subdirectory (Global-Menu)
736
endif()
737
1629 by fabounet
added the Messaging-Menu applet and a framework for Indicator-Applets
738
############# GMENU #################
1981 by matttbe
CMakeLists.txt: Fixed a compilation error in Composite Manager + added a few messages in order to have a better debugging and removed a few blank messages in KDE
739
message (STATUS "> GMenu:")
2668 by Fabrice Rey
All applets: use the new icon rendering API
740
set (with_gmenu no)
2648 by Matthieu Baerts
CMakeLists.txt: big changes! We are now using booleans for CMake flags
741
enable_if_not_defined (enable-gmenu)
742
if (enable-gmenu)
2766 by Fabrice Rey
GMenu: rewrote the applet ... seriously, in RC ? yes ! and here is why: 1) the code was such a mess, a blob of old code from gnome-panel patched a hundred times to fix it 2) it was using gnome-menu2, which is deprecated for years now, and not even available in some distros, which means the applet is also N/A 3) the code is so much more clean and simple now, I wouldn't want to maintain the old code for one more release
743
	set (GMENU_MODULE "libgnome-menu-3.0")
744
	set (GMENU_MODULE_OLD "libgnome-menu")
2227 by Matthieu Baerts
CMakeLists.txt: GTK3: compiled 'terminal' and 'weblets' (+TODO: GMenu) applets with GTK3 libs + improved messages if a module is not found.
745
	pkg_check_modules (GMENU_PACKAGE ${GMENU_MODULE})
2648 by Matthieu Baerts
CMakeLists.txt: big changes! We are now using booleans for CMake flags
746
	if (NOT GMENU_PACKAGE_FOUND)
2766 by Fabrice Rey
GMenu: rewrote the applet ... seriously, in RC ? yes ! and here is why: 1) the code was such a mess, a blob of old code from gnome-panel patched a hundred times to fix it 2) it was using gnome-menu2, which is deprecated for years now, and not even available in some distros, which means the applet is also N/A 3) the code is so much more clean and simple now, I wouldn't want to maintain the old code for one more release
747
		message (STATUS "Could not find ${GMENU_MODULE}; trying with an old version...")
748
		pkg_check_modules (GMENU_PACKAGE ${GMENU_MODULE_OLD})
749
		set(GMENU_OLD 1)
750
	endif()
751
	if (NOT GMENU_PACKAGE_FOUND)
752
		message (STATUS "Could not find ${GMENU_MODULE} nor ${GMENU_MODULE_OLD}; Cairo-Dock won't be built with GMenu applet.")
753
		message (WARNING "This module is required to compile GMenu applet: ${GMENU_MODULE} (or ${GMENU_MODULE_OLD})")
2227 by Matthieu Baerts
CMakeLists.txt: GTK3: compiled 'terminal' and 'weblets' (+TODO: GMenu) applets with GTK3 libs + improved messages if a module is not found.
754
		set (MODULES_MISSING "${MODULES_MISSING} ${GMENU_MODULE}")
1629 by fabounet
added the Messaging-Menu applet and a framework for Indicator-Applets
755
	else()
756
		set (GETTEXT_GMENU ${GETTEXT_PLUGINS})
2766 by Fabrice Rey
GMenu: rewrote the applet ... seriously, in RC ? yes ! and here is why: 1) the code was such a mess, a blob of old code from gnome-panel patched a hundred times to fix it 2) it was using gnome-menu2, which is deprecated for years now, and not even available in some distros, which means the applet is also N/A 3) the code is so much more clean and simple now, I wouldn't want to maintain the old code for one more release
757
		if (GMENU_OLD)
758
			set (VERSION_GMENU "1.1.11")
759
			set(GMENU_SRC "GMenu-old")
760
			set (with_gmenu "yes (old version)")
761
		else()
762
			set (VERSION_GMENU "2.0.0")
763
			set(GMENU_SRC "GMenu")
764
			set (with_gmenu "yes (new version)")
765
		endif()
1629 by fabounet
added the Messaging-Menu applet and a framework for Indicator-Applets
766
		set (PACKAGE_GMENU "cd-GMenu")
767
		set (gmenudatadir "${pluginsdatadir}/GMenu")
2766 by Fabrice Rey
GMenu: rewrote the applet ... seriously, in RC ? yes ! and here is why: 1) the code was such a mess, a blob of old code from gnome-panel patched a hundred times to fix it 2) it was using gnome-menu2, which is deprecated for years now, and not even available in some distros, which means the applet is also N/A 3) the code is so much more clean and simple now, I wouldn't want to maintain the old code for one more release
768
		configure_file (${CMAKE_CURRENT_SOURCE_DIR}/${GMENU_SRC}/data/GMenu.conf.in ${CMAKE_CURRENT_BINARY_DIR}/${GMENU_SRC}/data/GMenu.conf)
769
		add_subdirectory (${GMENU_SRC})
1629 by fabounet
added the Messaging-Menu applet and a framework for Indicator-Applets
770
	endif()
771
endif()
772
1546.1.2 by fabounet
added the files for cimpiling with cmake
773
############# GNOME-INTEGRATION #################
1981 by matttbe
CMakeLists.txt: Fixed a compilation error in Composite Manager + added a few messages in order to have a better debugging and removed a few blank messages in KDE
774
message (STATUS "> Gnome-Integration:")
2668 by Fabrice Rey
All applets: use the new icon rendering API
775
set (with_gnome_integration no)
2648 by Matthieu Baerts
CMakeLists.txt: big changes! We are now using booleans for CMake flags
776
enable_if_not_defined (enable-gnome-integration)
777
if (enable-gnome-integration)
1546.1.2 by fabounet
added the files for cimpiling with cmake
778
	pkg_check_modules (GNOME_INTEGRATION gio-2.0)
2648 by Matthieu Baerts
CMakeLists.txt: big changes! We are now using booleans for CMake flags
779
	if (NOT GNOME_INTEGRATION_FOUND)
1546.1.2 by fabounet
added the files for cimpiling with cmake
780
		message (STATUS "Could not find gio; Cairo-Dock won't be built with Gnome>=2.22 support.")
2047 by matttbe
CMakeLists.txt: Added some warnings if a module or a program is missing + added some messages (+ fixed a few typos)
781
		message (STATUS "This module is required to compile Gnome-Integration applet: gio-2.0")
782
		set (MODULES_INTEGRATION_MISSING "${MODULES_INTEGRATION_MISSING} gio-2.0")
1546.1.2 by fabounet
added the files for cimpiling with cmake
783
	else()
2523 by Matthieu Baerts
Integration plugins: Even if there is no translatable strings in these plugins, use the right gettext domain (if we want to add translatable strings in the future)
784
		set (GETTEXT_GNOME_INTEGRATION ${GETTEXT_PLUGINS})
2585 by Matthieu Baerts
CMakeLists.txt: bumped the version of all applets (just to be sure :) )
785
		set (VERSION_GNOME_INTEGRATION "1.0.4")
1546.1.2 by fabounet
added the files for cimpiling with cmake
786
		set (PACKAGE_GNOME_INTEGRATION "cd_gnome-integration")
2668 by Fabrice Rey
All applets: use the new icon rendering API
787
		set (with_gnome_integration yes)
1546.1.4 by fabounet
cmake compilation is operational
788
		set (gnome_integrationdatadir "${pluginsdatadir}/gnome-integration")
1546.1.2 by fabounet
added the files for cimpiling with cmake
789
		add_subdirectory ("gnome-integration")
790
	endif()
791
endif()
792
793
############# GNOME-INTEGRATION-OLD #################
2668 by Fabrice Rey
All applets: use the new icon rendering API
794
set (with_gnome_integration_old no) # deprecated
2648 by Matthieu Baerts
CMakeLists.txt: big changes! We are now using booleans for CMake flags
795
if (enable-old-gnome-integration)
1981 by matttbe
CMakeLists.txt: Fixed a compilation error in Composite Manager + added a few messages in order to have a better debugging and removed a few blank messages in KDE
796
	message (STATUS "> Gnome-Integration:")
2047 by matttbe
CMakeLists.txt: Added some warnings if a module or a program is missing + added some messages (+ fixed a few typos)
797
	message (WARNING "This applet is deprecated")
1546.1.2 by fabounet
added the files for cimpiling with cmake
798
	pkg_check_modules (OLD_GNOME_INTEGRATION gnome-vfs-2.0 libgnomeui-2.0)
2648 by Matthieu Baerts
CMakeLists.txt: big changes! We are now using booleans for CMake flags
799
	if (NOT OLD_GNOME_INTEGRATION_FOUND)
1546.1.2 by fabounet
added the files for cimpiling with cmake
800
		message (STATUS "Could not find gnome-vfs and/or gnomeui; Cairo-Dock won't be built with Gnome<2.22 support.")
2047 by matttbe
CMakeLists.txt: Added some warnings if a module or a program is missing + added some messages (+ fixed a few typos)
801
		message (STATUS "These modules are required to compile Gnome-Integration-Old applet: gnome-vfs-2.0 libgnomeui-2.0")
802
		set (MODULES_INTEGRATION_MISSING "${MODULES_INTEGRATION_MISSING} gnome-vfs-2.0 libgnomeui-2.0")
1546.1.2 by fabounet
added the files for cimpiling with cmake
803
	else()
2523 by Matthieu Baerts
Integration plugins: Even if there is no translatable strings in these plugins, use the right gettext domain (if we want to add translatable strings in the future)
804
		set (GETTEXT_GNOME_INTEGRATION_OLD ${GETTEXT_PLUGINS})
2585 by Matthieu Baerts
CMakeLists.txt: bumped the version of all applets (just to be sure :) )
805
		set (VERSION_GNOME_INTEGRATION_OLD "1.0.5")
1546.1.2 by fabounet
added the files for cimpiling with cmake
806
		set (PACKAGE_GNOME_INTEGRATION_OLD "cd_gnome-integration-old")
2668 by Fabrice Rey
All applets: use the new icon rendering API
807
		set (with_gnome_integration_old yes)
1546.1.4 by fabounet
cmake compilation is operational
808
		set (gnome_integration_olddatadir "${pluginsdatadir}/gnome-integration-old")
1546.1.2 by fabounet
added the files for cimpiling with cmake
809
		add_subdirectory ("gnome-integration-old")
810
	endif()
811
endif()
812
1981 by matttbe
CMakeLists.txt: Fixed a compilation error in Composite Manager + added a few messages in order to have a better debugging and removed a few blank messages in KDE
813
############# ICON EFFECTS #################
814
message (STATUS "> Icon Effects:")
1546.1.2 by fabounet
added the files for cimpiling with cmake
815
set (GETTEXT_ICON_EFFECTS ${GETTEXT_PLUGINS})
2585 by Matthieu Baerts
CMakeLists.txt: bumped the version of all applets (just to be sure :) )
816
set (VERSION_ICON_EFFECTS "1.2.5")
1546.1.2 by fabounet
added the files for cimpiling with cmake
817
set (PACKAGE_ICON_EFFECTS "cd-icon-effect")
1546.1.4 by fabounet
cmake compilation is operational
818
set (icon_effectsdatadir "${pluginsdatadir}/icon-effect")
1663 by matttbe
CMakeLists:
819
configure_file (${CMAKE_CURRENT_SOURCE_DIR}/icon-effect/data/icon-effect.conf.in ${CMAKE_CURRENT_BINARY_DIR}/icon-effect/data/icon-effect.conf)
1546.1.2 by fabounet
added the files for cimpiling with cmake
820
add_subdirectory (icon-effect)
821
2000 by matttbe
Added a new applet: Impulse
822
############# IMPULSE #################
2668 by Fabrice Rey
All applets: use the new icon rendering API
823
set (with_impulse no)
2073 by Matthieu Baerts
CMakeLists.txt: Impulse is now considered as stable
824
message (STATUS "> Impulse:")
2648 by Matthieu Baerts
CMakeLists.txt: big changes! We are now using booleans for CMake flags
825
enable_if_not_defined (enable-impulse)
826
if (enable-impulse)
827
	pkg_check_modules (LIBPULSE libpulse)
828
	pkg_check_modules (FFTW3 fftw3)  # optional, not advised for distributions packages (it's not a small dependence...)
829
	if (NOT LIBPULSE_FOUND)
830
		message (STATUS "Could not find libpulse; Cairo-Dock won't be built with Impulse applet.")
831
		message (WARNING "These modules are required to compile Impulse applet: libpulse (and fftw3 - optional)")
832
		set (MODULES_MISSING "${MODULES_MISSING} libpulse")
833
	else()
834
		set (GETTEXT_IMPULSE ${GETTEXT_PLUGINS})
835
		set (VERSION_IMPULSE "0.0.6")
836
		set (PACKAGE_IMPULSE "cd-Impulse")
2668 by Fabrice Rey
All applets: use the new icon rendering API
837
		set (with_impulse yes)
2648 by Matthieu Baerts
CMakeLists.txt: big changes! We are now using booleans for CMake flags
838
		set (impulsedatadir "${pluginsdatadir}/Impulse")
839
		configure_file (${CMAKE_CURRENT_SOURCE_DIR}/Impulse/data/Impulse.conf.in ${CMAKE_CURRENT_BINARY_DIR}/Impulse/data/Impulse.conf)
840
		add_subdirectory (Impulse)
841
	endif()
2000 by matttbe
Added a new applet: Impulse
842
endif()
843
2730 by Matthieu Baerts
Indicator-Generic: new applet! A plugin to hold all your 'indicators' applets.
844
############# INDICATOR_GENERIC #################
845
set (with_indicator_generic no)
846
if (with_indicator3)
847
	message (STATUS "> Indicator-Generic:")
848
	set (GETTEXT_INDICATOR_GENERIC ${GETTEXT_PLUGINS})
849
	set (VERSION_INDICATOR_GENERIC "0.0.1")
850
	set (PACKAGE_INDICATOR_GENERIC "cd-Indicator-Generic")
851
	set (with_indicator_generic yes)
852
	set (indicator_genericdatadir "${pluginsdatadir}/Indicator-Generic")
853
	configure_file (${CMAKE_CURRENT_SOURCE_DIR}/Indicator-Generic/data/Indicator-Generic.conf.in ${CMAKE_CURRENT_BINARY_DIR}/Indicator-Generic/data/Indicator-Generic.conf)
854
	add_subdirectory (Indicator-Generic)
855
endif()
856
1546.1.2 by fabounet
added the files for cimpiling with cmake
857
############# ILLUSION #################
1981 by matttbe
CMakeLists.txt: Fixed a compilation error in Composite Manager + added a few messages in order to have a better debugging and removed a few blank messages in KDE
858
message (STATUS "> Illusion:")
1546.1.2 by fabounet
added the files for cimpiling with cmake
859
set (GETTEXT_ILLUSION ${GETTEXT_PLUGINS})
2585 by Matthieu Baerts
CMakeLists.txt: bumped the version of all applets (just to be sure :) )
860
set (VERSION_ILLUSION "1.0.8")
1546.1.2 by fabounet
added the files for cimpiling with cmake
861
set (PACKAGE_ILLUSION "cd-illusion")
1546.1.4 by fabounet
cmake compilation is operational
862
set (illusiondatadir "${pluginsdatadir}/illusion")
1663 by matttbe
CMakeLists:
863
configure_file (${CMAKE_CURRENT_SOURCE_DIR}/illusion/data/illusion.conf.in ${CMAKE_CURRENT_BINARY_DIR}/illusion/data/illusion.conf)
1546.1.2 by fabounet
added the files for cimpiling with cmake
864
add_subdirectory (illusion)
865
866
############# KDE-INTEGRATION #################
1981 by matttbe
CMakeLists.txt: Fixed a compilation error in Composite Manager + added a few messages in order to have a better debugging and removed a few blank messages in KDE
867
message (STATUS "> KDE-Integration:")
2668 by Fabrice Rey
All applets: use the new icon rendering API
868
set (with_kde_integration no)
2648 by Matthieu Baerts
CMakeLists.txt: big changes! We are now using booleans for CMake flags
869
enable_if_not_defined (enable-kde-integration)
2668 by Fabrice Rey
All applets: use the new icon rendering API
870
set (with_kde_integration2 no) # highly unstable
2648 by Matthieu Baerts
CMakeLists.txt: big changes! We are now using booleans for CMake flags
871
if (enable-kde-integration2)
1980 by Fabrice Rey
changed the .conf 'Icon' group layout + updated translations => beta1
872
	#find_package(KDE4)
873
	find_package(Qt4)
1983 by Fabrice Rey
added icons for WM actions shared by several applets
874
	if (QT4_FOUND)
1981 by matttbe
CMakeLists.txt: Fixed a compilation error in Composite Manager + added a few messages in order to have a better debugging and removed a few blank messages in KDE
875
		message (STATUS " * Qt Includes: ${QT_INCLUDES}")
876
		message (STATUS " * Qt Definitions: ${QT_DEFINITIONS}")
877
		message (STATUS " * QtCore Library: ${QT_QTCORE_LIBRARY} / ${PACKAGE_LIBRARIES}")
878
	else()
879
		message (STATUS " * Qt unavailable")
880
	endif()
2054 by Matthieu Baerts
CMakeLists.txt:
881
1980 by Fabrice Rey
changed the .conf 'Icon' group layout + updated translations => beta1
882
	find_path(KDECORE_INCLUDE_DIR "kdecore_export.h")
883
	find_library(KDECORE_LIBRARY NAMES "kdecore")
2054 by Matthieu Baerts
CMakeLists.txt:
884
	GET_FILENAME_COMPONENT(KDECORE_LIBRARY ${KDECORE_LIBRARY} PATH)
885
1980 by Fabrice Rey
changed the .conf 'Icon' group layout + updated translations => beta1
886
	find_path(KIO_INCLUDE_DIR "kio_export.h" PATH_SUFFIXES "kio")
887
	find_library(KIO_LIBRARY NAMES "kio")
2054 by Matthieu Baerts
CMakeLists.txt:
888
	GET_FILENAME_COMPONENT(KIO_LIBRARY ${KIO_LIBRARY} PATH)
889
1980 by Fabrice Rey
changed the .conf 'Icon' group layout + updated translations => beta1
890
	find_path(KDE_INCLUDE_DIR "KDirWatch" PATH_SUFFIXES "KDE")
2054 by Matthieu Baerts
CMakeLists.txt:
891
2648 by Matthieu Baerts
CMakeLists.txt: big changes! We are now using booleans for CMake flags
892
	if (NOT KDECORE_LIBRARY)
1981 by matttbe
CMakeLists.txt: Fixed a compilation error in Composite Manager + added a few messages in order to have a better debugging and removed a few blank messages in KDE
893
		message (STATUS " * KDECORE Dir: ${KDECORE_INCLUDE_DIR}")
894
		message (STATUS " * KDECORE Library: ${KDECORE_LIBRARY}")
895
	else()
896
		message (STATUS " * KDECORE unavailable")
897
	endif()
2648 by Matthieu Baerts
CMakeLists.txt: big changes! We are now using booleans for CMake flags
898
	if (NOT KIO_LIBRARY)
1981 by matttbe
CMakeLists.txt: Fixed a compilation error in Composite Manager + added a few messages in order to have a better debugging and removed a few blank messages in KDE
899
		message (STATUS " * KIO Dir: ${KIO_INCLUDE_DIR}")
900
		message (STATUS " * KIO Library: ${KIO_LIBRARY}")
901
	else()
902
		message (STATUS " * KIO unavailable")
903
	endif()
2648 by Matthieu Baerts
CMakeLists.txt: big changes! We are now using booleans for CMake flags
904
	if (NOT KDE_LIBRARY) ## always empty?
1981 by matttbe
CMakeLists.txt: Fixed a compilation error in Composite Manager + added a few messages in order to have a better debugging and removed a few blank messages in KDE
905
		message (STATUS " * KDE4 Dir: ${KDE_INCLUDE_DIR}")
906
		message (STATUS " * KDE4 Library: ${KDE_LIBRARY}")
907
	else()
908
		message (STATUS " * KDE4 unavailable")
909
	endif()
2054 by Matthieu Baerts
CMakeLists.txt:
910
1983 by Fabrice Rey
added icons for WM actions shared by several applets
911
	if (QT4_FOUND
912
		 AND KDECORE_INCLUDE_DIR
1981 by matttbe
CMakeLists.txt: Fixed a compilation error in Composite Manager + added a few messages in order to have a better debugging and removed a few blank messages in KDE
913
		 AND KDECORE_LIBRARY
914
		 AND KIO_INCLUDE_DIR
915
		 AND KIO_LIBRARY
916
		 AND KDE_INCLUDE_DIR)
2073 by Matthieu Baerts
CMakeLists.txt: Impulse is now considered as stable
917
		message (STATUS "  KDE: OK")
2585 by Matthieu Baerts
CMakeLists.txt: bumped the version of all applets (just to be sure :) )
918
		set (VERSION_KDE_INTEGRATION "0.0.4")
1546.1.2 by fabounet
added the files for cimpiling with cmake
919
		set (PACKAGE_KDE_INTEGRATION "cd_kde-integration")
2668 by Fabrice Rey
All applets: use the new icon rendering API
920
		set (with_kde_integration2 yes)
2012 by Fabrice Rey
Composite-Manager: added an option to quickly reload the Window Manager
921
		set (kde_integrationdatadir "${pluginsdatadir}/kde-integration2")
922
		add_subdirectory ("kde-integration2")
923
	else()
924
		message (STATUS "Could not find kde libs; Cairo-Dock won't be built with KDE support.")
2047 by matttbe
CMakeLists.txt: Added some warnings if a module or a program is missing + added some messages (+ fixed a few typos)
925
		message (STATUS "These libraries are required to compile KDE experimental applet: kdecore, kio, kde4")
926
		set (MODULES_INTEGRATION_MISSING "${MODULES_INTEGRATION_MISSING} kdecore, kio, kde4")
2012 by Fabrice Rey
Composite-Manager: added an option to quickly reload the Window Manager
927
	endif()
2648 by Matthieu Baerts
CMakeLists.txt: big changes! We are now using booleans for CMake flags
928
elseif (enable-kde-integration)
2012 by Fabrice Rey
Composite-Manager: added an option to quickly reload the Window Manager
929
	pkg_check_modules (KDE_INTEGRATION gio-2.0)
2073 by Matthieu Baerts
CMakeLists.txt: Impulse is now considered as stable
930
	message (STATUS "  KDE_INTEGRATION_FOUND: ${KDE_INTEGRATION_FOUND}")
2012 by Fabrice Rey
Composite-Manager: added an option to quickly reload the Window Manager
931
	if (NOT KDE_INTEGRATION_FOUND)
2047 by matttbe
CMakeLists.txt: Added some warnings if a module or a program is missing + added some messages (+ fixed a few typos)
932
		message (STATUS "Could not find gio; Cairo-Dock won't be built with KDE support.")
933
		message (STATUS "This module is required to compile KDE-Integration applet: gio-2.0")
934
		set (MODULES_INTEGRATION_MISSING "${MODULES_INTEGRATION_MISSING} gio-2.0")
2012 by Fabrice Rey
Composite-Manager: added an option to quickly reload the Window Manager
935
	else()
2523 by Matthieu Baerts
Integration plugins: Even if there is no translatable strings in these plugins, use the right gettext domain (if we want to add translatable strings in the future)
936
		set (GETTEXT_KDE_INTEGRATION ${GETTEXT_PLUGINS})
2585 by Matthieu Baerts
CMakeLists.txt: bumped the version of all applets (just to be sure :) )
937
		set (VERSION_KDE_INTEGRATION "1.0.4")
2012 by Fabrice Rey
Composite-Manager: added an option to quickly reload the Window Manager
938
		set (PACKAGE_KDE_INTEGRATION "cd_kde-integration")
2668 by Fabrice Rey
All applets: use the new icon rendering API
939
		set (with_kde_integration yes)
1546.1.4 by fabounet
cmake compilation is operational
940
		set (kde_integrationdatadir "${pluginsdatadir}/kde-integration")
1546.1.2 by fabounet
added the files for cimpiling with cmake
941
		add_subdirectory ("kde-integration")
942
	endif()
943
endif()
944
945
############# KEYBOARD_INDICATOR #################
1981 by matttbe
CMakeLists.txt: Fixed a compilation error in Composite Manager + added a few messages in order to have a better debugging and removed a few blank messages in KDE
946
message (STATUS "> Keyboard-Indicator:")
2668 by Fabrice Rey
All applets: use the new icon rendering API
947
set (with_keyboard_indicator no)
2648 by Matthieu Baerts
CMakeLists.txt: big changes! We are now using booleans for CMake flags
948
enable_if_not_defined (enable-keyboard-indicator)
949
if (enable-keyboard-indicator)
950
	pkg_check_modules (KEYBOARD_INDICATOR_PACKAGE libxklavier)
951
	if (NOT KEYBOARD_INDICATOR_PACKAGE_FOUND)
952
		message (STATUS "Could not find libxklavier; Cairo-Dock won't be built with keyboard-indicator applet.")
953
		message (WARNING "This module is required to compile Keyboard-Indicator applet: libxklavier")
954
		set (MODULES_MISSING "${MODULES_MISSING} libxklavier")
955
	else()
956
		set (GETTEXT_KEYBOARD_INDICATOR ${GETTEXT_PLUGINS})
957
		set (VERSION_KEYBOARD_INDICATOR "1.1.9")
958
		set (PACKAGE_KEYBOARD_INDICATOR "cd-keyboard-indicator")
2668 by Fabrice Rey
All applets: use the new icon rendering API
959
		set (with_keyboard_indicator yes)
2648 by Matthieu Baerts
CMakeLists.txt: big changes! We are now using booleans for CMake flags
960
		set (keyboard_indicatordatadir "${pluginsdatadir}/keyboard-indicator")
961
		configure_file (${CMAKE_CURRENT_SOURCE_DIR}/keyboard-indicator/data/keyboard-indicator.conf.in ${CMAKE_CURRENT_BINARY_DIR}/keyboard-indicator/data/keyboard-indicator.conf)
962
		add_subdirectory ("keyboard-indicator")
963
	endif()
1546.1.2 by fabounet
added the files for cimpiling with cmake
964
endif()
965
966
############# LOGOUT #################
2648 by Matthieu Baerts
CMakeLists.txt: big changes! We are now using booleans for CMake flags
967
message (STATUS "> Logout:")
968
enable_if_not_defined (enable-upower-support)
969
if (enable-upower-support)
970
	pkg_check_modules (UPOWER upower-glib)  # useful for Powermanager too.
971
endif()
972
if (UPOWER_FOUND)
2668 by Fabrice Rey
All applets: use the new icon rendering API
973
	set (with_upower_support yes)
2019 by Fabrice Rey
Logout: now works when no session-manager is present + updated translations
974
else()
2668 by Fabrice Rey
All applets: use the new icon rendering API
975
	set (with_upower_support no)
2648 by Matthieu Baerts
CMakeLists.txt: big changes! We are now using booleans for CMake flags
976
	message (STATUS "Could not find upower-glib; Logout and PowerManager plugin won't be built with UPower support.")
2047 by matttbe
CMakeLists.txt: Added some warnings if a module or a program is missing + added some messages (+ fixed a few typos)
977
	message (WARNING "This module is required to compile LogOut and PowerManager applet with UPower support: upower-glib")
978
	set (MODULES_MISSING "${MODULES_MISSING} upower-glib")
2019 by Fabrice Rey
Logout: now works when no session-manager is present + updated translations
979
endif()
1546.1.2 by fabounet
added the files for cimpiling with cmake
980
set (GETTEXT_LOGOUT ${GETTEXT_PLUGINS})
2585 by Matthieu Baerts
CMakeLists.txt: bumped the version of all applets (just to be sure :) )
981
set (VERSION_LOGOUT "2.0.3")
1546.1.2 by fabounet
added the files for cimpiling with cmake
982
set (PACKAGE_LOGOUT "cd-logout")
1546.1.4 by fabounet
cmake compilation is operational
983
set (logoutdatadir "${pluginsdatadir}/logout")
1663 by matttbe
CMakeLists:
984
configure_file (${CMAKE_CURRENT_SOURCE_DIR}/logout/data/logout.conf.in ${CMAKE_CURRENT_BINARY_DIR}/logout/data/logout.conf)
1546.1.2 by fabounet
added the files for cimpiling with cmake
985
add_subdirectory (logout)
986
987
############# MAIL #################
1981 by matttbe
CMakeLists.txt: Fixed a compilation error in Composite Manager + added a few messages in order to have a better debugging and removed a few blank messages in KDE
988
message (STATUS "> Mail:")
2668 by Fabrice Rey
All applets: use the new icon rendering API
989
set (with_mail no)
1602 by Tofe
Clock now manages iCal; some fixes also
990
# find the compilation flags
2648 by Matthieu Baerts
CMakeLists.txt: big changes! We are now using booleans for CMake flags
991
enable_if_not_defined (enable-mail)
992
if (enable-mail)
993
	find_program (LIBETPAN_CONFIG_EXECUTABLE libetpan-config)
994
	execute_process(
995
		COMMAND ${LIBETPAN_CONFIG_EXECUTABLE} --cflags
996
		OUTPUT_VARIABLE MAIL_PACKAGE_CFLAGS)
997
	if (NOT "${MAIL_PACKAGE_CFLAGS}" STREQUAL "" AND NOT "${MAIL_PACKAGE_CFLAGS}" STREQUAL "\n") # if there is a problem with the previous, we don't want to have a lot of errors
998
		STRING (REGEX REPLACE "\n" "" TMP_VARIABLE "${MAIL_PACKAGE_CFLAGS}") # to not skip the last option
999
		STRING (REGEX MATCHALL "(^| )-I[^ ]+( |$)" TMP_VARIABLE "${TMP_VARIABLE}") # first extract the "-I" options
1000
		STRING (REGEX REPLACE ";" "" TMP_VARIABLE "${TMP_VARIABLE}")
1001
		STRING (REGEX REPLACE " $" "" TMP_VARIABLE "${TMP_VARIABLE}")
1002
		STRING (REGEX REPLACE "^ " "" TMP_VARIABLE "${TMP_VARIABLE}")
1003
		STRING (REGEX REPLACE "  " " " TMP_VARIABLE "${TMP_VARIABLE}")
1004
		STRING (REGEX REPLACE "-I([^ ]+)" "\\1" MAIL_PACKAGE_INCLUDE_DIRS "${TMP_VARIABLE}")  # then remove the "-I" string
1005
	endif()
1006
	# find the link flags
1007
	execute_process(
1008
		COMMAND ${LIBETPAN_CONFIG_EXECUTABLE} --libs
1009
		OUTPUT_VARIABLE MAIL_PACKAGE_LIBS)
1010
	if (NOT "${MAIL_PACKAGE_LIBS}" STREQUAL "")
1011
		STRING (REGEX REPLACE "\n" "" MAIL_PACKAGE_LIBS "${MAIL_PACKAGE_LIBS}")
1012
		#   find the link libraries
1013
		STRING (REGEX MATCHALL "(^| )-l[^ ]+( |$)" TMP_VARIABLE "${MAIL_PACKAGE_LIBS}") # extract the "-l" options (only if it's separated by two blank spaces or the end/beginning of the line => -L/usr/lib/x86_64-linux-gnu)
1014
		STRING (REGEX REPLACE ";" "" TMP_VARIABLE "${TMP_VARIABLE}")
1015
		STRING (REGEX REPLACE "^ " "" TMP_VARIABLE "${TMP_VARIABLE}")
1016
		STRING (REGEX REPLACE "  " " " TMP_VARIABLE "${TMP_VARIABLE}")
1017
		STRING (REGEX REPLACE " $" "" MAIL_PACKAGE_LIBRARIES "${TMP_VARIABLE}")
1018
		#   find the link directories
1019
		STRING (REGEX MATCHALL "(^| )-L[^ ]+( |$)" TMP_VARIABLE "${MAIL_PACKAGE_LIBS}") # extract the "-L" options
1020
		STRING (REGEX REPLACE ";" "" TMP_VARIABLE "${TMP_VARIABLE}")
1021
		STRING (REGEX REPLACE " $" "" TMP_VARIABLE "${TMP_VARIABLE}")
1022
		STRING (REGEX REPLACE "^ " "" TMP_VARIABLE "${TMP_VARIABLE}")
1023
		STRING (REGEX REPLACE "  " " " TMP_VARIABLE "${TMP_VARIABLE}")
1024
		STRING (REGEX REPLACE "-L([^ ]+)" "\\1" MAIL_PACKAGE_LIBRARY_DIRS "${TMP_VARIABLE}")  # then remove the "-L" string
1025
	endif()
1026
	if ("${MAIL_PACKAGE_LIBS}" STREQUAL "")
1027
		message (STATUS "warning : Could not find libetpan; Cairo-Dock won't be built with Mail applet.")
1028
		message (WARNING "This module is required to compile Mail applet: libetpan")
1029
		set (PROGRAMS_MISSING "${PROGRAMS_MISSING} libetpan-config")
1030
	else()
1031
		message (STATUS "  libetpan found. Using the following options:")
1032
		message (STATUS "   Include directories: ${MAIL_PACKAGE_INCLUDE_DIRS}")
1033
		message (STATUS "   Link directories: ${MAIL_PACKAGE_LIBRARY_DIRS}")
1034
		message (STATUS "   Link libraries: ${MAIL_PACKAGE_LIBRARIES}")
1035
		set (GETTEXT_MAIL ${GETTEXT_PLUGINS})
1036
		set (VERSION_MAIL "1.0.13")
1037
		set (PACKAGE_MAIL "cd-mail")
1038
		set (maildatadir "${pluginsdatadir}/mail")
2668 by Fabrice Rey
All applets: use the new icon rendering API
1039
		set (with_mail yes)
2648 by Matthieu Baerts
CMakeLists.txt: big changes! We are now using booleans for CMake flags
1040
		configure_file (${CMAKE_CURRENT_SOURCE_DIR}/mail/data/mail.conf.in ${CMAKE_CURRENT_BINARY_DIR}/mail/data/mail.conf)
1041
		add_subdirectory ("mail")
1042
	endif()
1546.1.2 by fabounet
added the files for cimpiling with cmake
1043
endif()
1044
2047 by matttbe
CMakeLists.txt: Added some warnings if a module or a program is missing + added some messages (+ fixed a few typos)
1045
############# MEMENU #################
2668 by Fabrice Rey
All applets: use the new icon rendering API
1046
set (with_me_menu no)
2648 by Matthieu Baerts
CMakeLists.txt: big changes! We are now using booleans for CMake flags
1047
if (INDICATOR_NEW_VERSION AND NOT enable-memenu)
2225 by Matthieu Baerts
CMakeLists.txt:
1048
	message (STATUS "> MeMenu: this applet has been automatically merged with Messaging-Menu")  # oneiric or newer
2648 by Matthieu Baerts
CMakeLists.txt: big changes! We are now using booleans for CMake flags
1049
elseif (with_indicator AND IDO_FOUND)
2047 by matttbe
CMakeLists.txt: Added some warnings if a module or a program is missing + added some messages (+ fixed a few typos)
1050
	message (STATUS "> MeMenu:")
1623 by fabounet
added a new view : 'Panel'
1051
	set (GETTEXT_MEMENU ${GETTEXT_PLUGINS})
2585 by Matthieu Baerts
CMakeLists.txt: bumped the version of all applets (just to be sure :) )
1052
	set (VERSION_MEMENU "1.0.5")
1623 by fabounet
added a new view : 'Panel'
1053
	set (PACKAGE_MEMENU "cd-MeMenu")
1054
	set (memenudatadir "${pluginsdatadir}/MeMenu")
2668 by Fabrice Rey
All applets: use the new icon rendering API
1055
	set (with_me_menu yes)
1663 by matttbe
CMakeLists:
1056
	configure_file (${CMAKE_CURRENT_SOURCE_DIR}/MeMenu/data/MeMenu.conf.in ${CMAKE_CURRENT_BINARY_DIR}/MeMenu/data/MeMenu.conf)
1631 by fabounet
added the Indicator-applet framework
1057
	add_subdirectory (MeMenu)
1619 by fabounet
added the MeMenu applet
1058
endif()
1059
1629 by fabounet
added the Messaging-Menu applet and a framework for Indicator-Applets
1060
############# MESSAGING_MENU #################
2668 by Fabrice Rey
All applets: use the new icon rendering API
1061
set (with_messaging_menu no)
2648 by Matthieu Baerts
CMakeLists.txt: big changes! We are now using booleans for CMake flags
1062
if (with_indicator)
2047 by matttbe
CMakeLists.txt: Added some warnings if a module or a program is missing + added some messages (+ fixed a few typos)
1063
	message (STATUS "> Messaging-Menu:")
2661 by Matthieu Baerts
Messaging Menu: used Indicator3 if it's available (not only on Ubuntu 12.10)
1064
	if (with_indicator3)
1065
		set (INDICATOR_MESSAGES_WITH_IND3 TRUE) # If it's supported, it's maybe better to use it
2520 by Matthieu Baerts
Added support of the new Indicator (3-0.4) to easily create Indicator applets
1066
	endif()
1629 by fabounet
added the Messaging-Menu applet and a framework for Indicator-Applets
1067
	set (GETTEXT_MESSAGING_MENU ${GETTEXT_PLUGINS})
2585 by Matthieu Baerts
CMakeLists.txt: bumped the version of all applets (just to be sure :) )
1068
	set (VERSION_MESSAGING_MENU "1.0.6")
1629 by fabounet
added the Messaging-Menu applet and a framework for Indicator-Applets
1069
	set (PACKAGE_MESSAGING_MENU "cd-Messaging-Menu")
2668 by Fabrice Rey
All applets: use the new icon rendering API
1070
	set (with_messaging_menu yes)
1629 by fabounet
added the Messaging-Menu applet and a framework for Indicator-Applets
1071
	set (messaging_menudatadir "${pluginsdatadir}/Messaging-Menu")
1663 by matttbe
CMakeLists:
1072
	configure_file (${CMAKE_CURRENT_SOURCE_DIR}/Messaging-Menu/data/Messaging-Menu.conf.in ${CMAKE_CURRENT_BINARY_DIR}/Messaging-Menu/data/Messaging-Menu.conf)
1631 by fabounet
added the Indicator-applet framework
1073
	add_subdirectory (Messaging-Menu)
1629 by fabounet
added the Messaging-Menu applet and a framework for Indicator-Applets
1074
endif()
1075
1546.1.2 by fabounet
added the files for cimpiling with cmake
1076
############# MOTION BLUR #################
1981 by matttbe
CMakeLists.txt: Fixed a compilation error in Composite Manager + added a few messages in order to have a better debugging and removed a few blank messages in KDE
1077
message (STATUS "> Motion Blur:")
1546.1.2 by fabounet
added the files for cimpiling with cmake
1078
set (GETTEXT_MOTION_BLUR ${GETTEXT_PLUGINS})
2585 by Matthieu Baerts
CMakeLists.txt: bumped the version of all applets (just to be sure :) )
1079
set (VERSION_MOTION_BLUR "1.0.5")
1546.1.2 by fabounet
added the files for cimpiling with cmake
1080
set (PACKAGE_MOTION_BLUR "cd-motion_blur")
1546.1.4 by fabounet
cmake compilation is operational
1081
set (motion_blurdatadir "${pluginsdatadir}/motion-blur")
1663 by matttbe
CMakeLists:
1082
configure_file (${CMAKE_CURRENT_SOURCE_DIR}/motion-blur/data/motion_blur.conf.in ${CMAKE_CURRENT_BINARY_DIR}/motion-blur/data/motion_blur.conf)
1546.1.2 by fabounet
added the files for cimpiling with cmake
1083
add_subdirectory (motion-blur)
1084
1085
############# MUSICPLAYER #################
1981 by matttbe
CMakeLists.txt: Fixed a compilation error in Composite Manager + added a few messages in order to have a better debugging and removed a few blank messages in KDE
1086
message (STATUS "> MusicPlayer:")
1546.1.2 by fabounet
added the files for cimpiling with cmake
1087
set (GETTEXT_MUSICPLAYER ${GETTEXT_PLUGINS})
2585 by Matthieu Baerts
CMakeLists.txt: bumped the version of all applets (just to be sure :) )
1088
set (VERSION_MUSICPLAYER "2.0.3")
1546.1.2 by fabounet
added the files for cimpiling with cmake
1089
set (PACKAGE_MUSICPLAYER "cd-musicPlayer")
1546.1.4 by fabounet
cmake compilation is operational
1090
set (musicplayerdatadir "${pluginsdatadir}/musicPlayer")
1663 by matttbe
CMakeLists:
1091
configure_file (${CMAKE_CURRENT_SOURCE_DIR}/musicPlayer/data/musicPlayer.conf.in ${CMAKE_CURRENT_BINARY_DIR}/musicPlayer/data/musicPlayer.conf)
1546.1.2 by fabounet
added the files for cimpiling with cmake
1092
add_subdirectory (musicPlayer)
1093
1094
############# NETSPEED #################
1981 by matttbe
CMakeLists.txt: Fixed a compilation error in Composite Manager + added a few messages in order to have a better debugging and removed a few blank messages in KDE
1095
message (STATUS "> NetSpeed:")
1546.1.2 by fabounet
added the files for cimpiling with cmake
1096
set (GETTEXT_NETSPEED ${GETTEXT_PLUGINS})
2585 by Matthieu Baerts
CMakeLists.txt: bumped the version of all applets (just to be sure :) )
1097
set (VERSION_NETSPEED "1.2.11")
1546.1.2 by fabounet
added the files for cimpiling with cmake
1098
set (PACKAGE_NETSPEED "cd-netspeed")
1546.1.4 by fabounet
cmake compilation is operational
1099
set (netspeeddatadir "${pluginsdatadir}/netspeed")
1663 by matttbe
CMakeLists:
1100
configure_file (${CMAKE_CURRENT_SOURCE_DIR}/netspeed/data/netspeed.conf.in ${CMAKE_CURRENT_BINARY_DIR}/netspeed/data/netspeed.conf)
1546.1.2 by fabounet
added the files for cimpiling with cmake
1101
add_subdirectory (netspeed)
1102
1103
############# NETWORK_MONITOR #################
2668 by Fabrice Rey
All applets: use the new icon rendering API
1104
set (with_network_monitor no) # unstable
2648 by Matthieu Baerts
CMakeLists.txt: big changes! We are now using booleans for CMake flags
1105
if (enable-network-monitor)
1981 by matttbe
CMakeLists.txt: Fixed a compilation error in Composite Manager + added a few messages in order to have a better debugging and removed a few blank messages in KDE
1106
	message (STATUS "> Network Monitor:")
1546.1.4 by fabounet
cmake compilation is operational
1107
	set (GETTEXT_NETWORK_MONITOR ${GETTEXT_PLUGINS})
2585 by Matthieu Baerts
CMakeLists.txt: bumped the version of all applets (just to be sure :) )
1108
	set (VERSION_NETWORK_MONITOR "0.2.9")
1546.1.4 by fabounet
cmake compilation is operational
1109
	set (PACKAGE_NETWORK_MONITOR "cd-network-monitor")
2668 by Fabrice Rey
All applets: use the new icon rendering API
1110
	set (with_network_monitor yes)
1546.1.4 by fabounet
cmake compilation is operational
1111
	set (network_monitordatadir "${pluginsdatadir}/Network-Monitor")
1663 by matttbe
CMakeLists:
1112
	configure_file (${CMAKE_CURRENT_SOURCE_DIR}/Network-Monitor/data/Network-Monitor.conf.in ${CMAKE_CURRENT_BINARY_DIR}/Network-Monitor/data/Network-Monitor.conf)
1546.1.4 by fabounet
cmake compilation is operational
1113
	add_subdirectory (Network-Monitor)
1114
endif()
1546.1.2 by fabounet
added the files for cimpiling with cmake
1115
1116
############# POWERMANAGER #################
1981 by matttbe
CMakeLists.txt: Fixed a compilation error in Composite Manager + added a few messages in order to have a better debugging and removed a few blank messages in KDE
1117
message (STATUS "> PowerManager:")
1546.1.2 by fabounet
added the files for cimpiling with cmake
1118
set (GETTEXT_POWERMANAGER ${GETTEXT_PLUGINS})
2585 by Matthieu Baerts
CMakeLists.txt: bumped the version of all applets (just to be sure :) )
1119
set (VERSION_POWERMANAGER "1.3.11")
1546.1.2 by fabounet
added the files for cimpiling with cmake
1120
set (PACKAGE_POWERMANAGER "cd-powermanager")
1546.1.4 by fabounet
cmake compilation is operational
1121
set (powermanagerdatadir "${pluginsdatadir}/powermanager")
1663 by matttbe
CMakeLists:
1122
configure_file (${CMAKE_CURRENT_SOURCE_DIR}/powermanager/data/powermanager.conf.in ${CMAKE_CURRENT_BINARY_DIR}/powermanager/data/powermanager.conf)
1546.1.2 by fabounet
added the files for cimpiling with cmake
1123
add_subdirectory (powermanager)
1124
1125
############# QUICK BROWSER #################
1981 by matttbe
CMakeLists.txt: Fixed a compilation error in Composite Manager + added a few messages in order to have a better debugging and removed a few blank messages in KDE
1126
message (STATUS "> Quick Browser:")
1546.1.2 by fabounet
added the files for cimpiling with cmake
1127
set (GETTEXT_QUICK_BROWSER ${GETTEXT_PLUGINS})
2585 by Matthieu Baerts
CMakeLists.txt: bumped the version of all applets (just to be sure :) )
1128
set (VERSION_QUICK_BROWSER "1.0.12")
1546.1.2 by fabounet
added the files for cimpiling with cmake
1129
set (PACKAGE_QUICK_BROWSER "cd-quick-browser")
1546.1.4 by fabounet
cmake compilation is operational
1130
set (quick_browserdatadir "${pluginsdatadir}/quick_browser")
1663 by matttbe
CMakeLists:
1131
configure_file (${CMAKE_CURRENT_SOURCE_DIR}/quick-browser/data/quick-browser.conf.in ${CMAKE_CURRENT_BINARY_DIR}/quick-browser/data/quick-browser.conf)
1546.1.2 by fabounet
added the files for cimpiling with cmake
1132
add_subdirectory (quick-browser)
1133
1811.1.9 by Fabrice Rey
added Recent Events applet (currently support recent files related to a launcher or an appli on right click)
1134
############# RECENT-EVENTS #################
1981 by matttbe
CMakeLists.txt: Fixed a compilation error in Composite Manager + added a few messages in order to have a better debugging and removed a few blank messages in KDE
1135
message (STATUS "> Recent-Events:")
2668 by Fabrice Rey
All applets: use the new icon rendering API
1136
set (with_recent_events no)
2648 by Matthieu Baerts
CMakeLists.txt: big changes! We are now using booleans for CMake flags
1137
enable_if_not_defined (enable-recent-events)
1138
if (enable-recent-events)
2876 by Matthieu Baerts
Recent-event: Support both Zeitgeist-1.0 and Zeitgeist-2.0
1139
	pkg_check_modules (RECENT_EVENTS zeitgeist-2.0)
1140
	if (NOT RECENT_EVENTS_FOUND)
1141
		message (STATUS "Could not find 'zeitgeist-2.0'; trying with an old version 'zeitgeist-1.0'...")
1142
		pkg_check_modules (RECENT_EVENTS zeitgeist-1.0)
2896 by Fabrice Rey
Recent events: ZEITGEIST_OLD -> ZEITGEIST_1_0 + simplified a #ifdef condition
1143
		set (ZEITGEIST_1_0 1)
2876 by Matthieu Baerts
Recent-event: Support both Zeitgeist-1.0 and Zeitgeist-2.0
1144
	endif()
2648 by Matthieu Baerts
CMakeLists.txt: big changes! We are now using booleans for CMake flags
1145
	if (NOT RECENT_EVENTS_FOUND)
1146
		message (STATUS "Could not find libzeitgeist; Cairo-Dock won't be built with Zeitgeist support.")
2876 by Matthieu Baerts
Recent-event: Support both Zeitgeist-1.0 and Zeitgeist-2.0
1147
		message (WARNING "This module is required to compile Recent-Events applet: zeitgeist-x.0")
1148
		set (MODULES_MISSING "${MODULES_MISSING} zeitgeist-x.0")
2648 by Matthieu Baerts
CMakeLists.txt: big changes! We are now using booleans for CMake flags
1149
	else()
1150
		set (GETTEXT_RECENT_EVENTS ${GETTEXT_PLUGINS})
1151
		set (VERSION_RECENT_EVENTS "1.0.3")
1152
		set (PACKAGE_RECENT_EVENTS "cd-Recent-Events")
2896 by Fabrice Rey
Recent events: ZEITGEIST_OLD -> ZEITGEIST_1_0 + simplified a #ifdef condition
1153
		if (ZEITGEIST_1_0)
1154
			set (with_recent_events "yes (zeitgeist 1.0)")
1155
		else()
1156
			set (with_recent_events "yes (zeitgeist 2.0)")
1157
		endif()
2648 by Matthieu Baerts
CMakeLists.txt: big changes! We are now using booleans for CMake flags
1158
		set (recent_eventsdatadir "${pluginsdatadir}/Recent-Events")
1159
		configure_file (${CMAKE_CURRENT_SOURCE_DIR}/Recent-Events/data/Recent-Events.conf.in ${CMAKE_CURRENT_BINARY_DIR}/Recent-Events/data/Recent-Events.conf)
1160
		add_subdirectory ("Recent-Events")
1161
	endif()
1811.1.9 by Fabrice Rey
added Recent Events applet (currently support recent files related to a launcher or an appli on right click)
1162
endif()
1163
1774 by Fabrice Rey
Sys-monitor: work on cpu temp and fan speed + Xgamma : inverted mouse scroll
1164
############# REMOTE_CONTROL #################
1981 by matttbe
CMakeLists.txt: Fixed a compilation error in Composite Manager + added a few messages in order to have a better debugging and removed a few blank messages in KDE
1165
message (STATUS "> Remote Control:")
1774 by Fabrice Rey
Sys-monitor: work on cpu temp and fan speed + Xgamma : inverted mouse scroll
1166
set (GETTEXT_REMOTE_CONTROL ${GETTEXT_PLUGINS})
2585 by Matthieu Baerts
CMakeLists.txt: bumped the version of all applets (just to be sure :) )
1167
set (VERSION_REMOTE_CONTROL "1.0.2")
1774 by Fabrice Rey
Sys-monitor: work on cpu temp and fan speed + Xgamma : inverted mouse scroll
1168
set (PACKAGE_REMOTE_CONTROL "cd-Remote-Control")
1169
set (remote_controldatadir "${pluginsdatadir}/Remote-Control")
1170
configure_file (${CMAKE_CURRENT_SOURCE_DIR}/Remote-Control/data/Remote-Control.conf.in ${CMAKE_CURRENT_BINARY_DIR}/Remote-Control/data/Remote-Control.conf)
1171
add_subdirectory (Remote-Control)
1172
1546.1.2 by fabounet
added the files for cimpiling with cmake
1173
############# RSSREADER #################
1981 by matttbe
CMakeLists.txt: Fixed a compilation error in Composite Manager + added a few messages in order to have a better debugging and removed a few blank messages in KDE
1174
message (STATUS "> RSSreader:")
1546.1.2 by fabounet
added the files for cimpiling with cmake
1175
set (GETTEXT_RSS_READER ${GETTEXT_PLUGINS})
2585 by Matthieu Baerts
CMakeLists.txt: bumped the version of all applets (just to be sure :) )
1176
set (VERSION_RSS_READER "1.0.7")
1546.1.2 by fabounet
added the files for cimpiling with cmake
1177
set (PACKAGE_RSS_READER "cd-rssreader")
1546.1.4 by fabounet
cmake compilation is operational
1178
set (rss_readerdatadir "${pluginsdatadir}/RSSreader")
1663 by matttbe
CMakeLists:
1179
configure_file (${CMAKE_CURRENT_SOURCE_DIR}/RSSreader/data/RSSreader.conf.in ${CMAKE_CURRENT_BINARY_DIR}/RSSreader/data/RSSreader.conf)
1546.1.2 by fabounet
added the files for cimpiling with cmake
1180
add_subdirectory (RSSreader)
1181
1182
############# SCOOBY_DO #################
2668 by Fabrice Rey
All applets: use the new icon rendering API
1183
set (with_scooby_do no) # unstable
2648 by Matthieu Baerts
CMakeLists.txt: big changes! We are now using booleans for CMake flags
1184
if (enable-scooby-do)
1981 by matttbe
CMakeLists.txt: Fixed a compilation error in Composite Manager + added a few messages in order to have a better debugging and removed a few blank messages in KDE
1185
	message (STATUS "> Scooby-Do:")
1546.1.4 by fabounet
cmake compilation is operational
1186
	set (GETTEXT_SCOOBY_DO ${GETTEXT_PLUGINS})
2585 by Matthieu Baerts
CMakeLists.txt: bumped the version of all applets (just to be sure :) )
1187
	set (VERSION_SCOOBY_DO "0.1.3")
1546.1.4 by fabounet
cmake compilation is operational
1188
	set (PACKAGE_SCOOBY_DO "cd-scooby-do")
2668 by Fabrice Rey
All applets: use the new icon rendering API
1189
	set (with_scooby_do yes)
1546.1.4 by fabounet
cmake compilation is operational
1190
	set (scooby_dodatadir "${pluginsdatadir}/Scooby-Do")
1663 by matttbe
CMakeLists:
1191
	configure_file (${CMAKE_CURRENT_SOURCE_DIR}/Scooby-Do/data/Scooby-Do.conf.in ${CMAKE_CURRENT_BINARY_DIR}/Scooby-Do/data/Scooby-Do.conf)
1546.1.4 by fabounet
cmake compilation is operational
1192
	add_subdirectory (Scooby-Do)
1193
endif()
1546.1.2 by fabounet
added the files for cimpiling with cmake
1194
2677 by Fabrice Rey
New applet: Screenshot (fast, clean, and with no useless effect or sound...)
1195
############# SCREENSHOT #################
1196
message (STATUS "> Screenshot:")
1197
set (GETTEXT_SCREENSHOT ${GETTEXT_PLUGINS})
1198
set (VERSION_SCREENSHOT "0.0.1")
1199
set (PACKAGE_SCREENSHOT "cd-Screenshot")
1200
set (screenshotdatadir "${pluginsdatadir}/Screenshot")
1201
configure_file (${CMAKE_CURRENT_SOURCE_DIR}/Screenshot/data/Screenshot.conf.in ${CMAKE_CURRENT_BINARY_DIR}/Screenshot/data/Screenshot.conf)
1202
add_subdirectory (Screenshot)
1203
1546.1.2 by fabounet
added the files for cimpiling with cmake
1204
############# SHORTCUTS #################
1981 by matttbe
CMakeLists.txt: Fixed a compilation error in Composite Manager + added a few messages in order to have a better debugging and removed a few blank messages in KDE
1205
message (STATUS "> Shortcuts:")
1546.1.2 by fabounet
added the files for cimpiling with cmake
1206
set (GETTEXT_SHORTCUTS ${GETTEXT_PLUGINS})
2585 by Matthieu Baerts
CMakeLists.txt: bumped the version of all applets (just to be sure :) )
1207
set (VERSION_SHORTCUTS "1.3.5")
1546.1.2 by fabounet
added the files for cimpiling with cmake
1208
set (PACKAGE_SHORTCUTS "cd-shortcuts")
1546.1.4 by fabounet
cmake compilation is operational
1209
set (shortcutsdatadir "${pluginsdatadir}/shortcuts")
1663 by matttbe
CMakeLists:
1210
configure_file (${CMAKE_CURRENT_SOURCE_DIR}/shortcuts/data/shortcuts.conf.in ${CMAKE_CURRENT_BINARY_DIR}/shortcuts/data/shortcuts.conf)
1546.1.2 by fabounet
added the files for cimpiling with cmake
1211
add_subdirectory (shortcuts)
1212
1213
############# SHOW DESKTOP #################
1981 by matttbe
CMakeLists.txt: Fixed a compilation error in Composite Manager + added a few messages in order to have a better debugging and removed a few blank messages in KDE
1214
message (STATUS "> ShowDesktop:")
2648 by Matthieu Baerts
CMakeLists.txt: big changes! We are now using booleans for CMake flags
1215
enable_if_not_defined (enable-xrandr-support)
1216
if (enable-xrandr-support)
1217
	pkg_check_modules (SHOW_DESKTOP_XRANDR xrandr)
1218
	if (NOT SHOW_DESKTOP_XRANDR_FOUND)
1219
		message (STATUS "Could not find xrandr; ShowDesktop won't be built with screen resolution abilities.")
1220
		message (WARNING "This module is required to compile ShowDesktop applet with xRandr support: xrandr")
1221
		set (MODULES_MISSING "${MODULES_MISSING} xrandr")
2668 by Fabrice Rey
All applets: use the new icon rendering API
1222
		set (with_xrandr no)
2648 by Matthieu Baerts
CMakeLists.txt: big changes! We are now using booleans for CMake flags
1223
	else ()
2668 by Fabrice Rey
All applets: use the new icon rendering API
1224
		set (with_xrandr yes)
2648 by Matthieu Baerts
CMakeLists.txt: big changes! We are now using booleans for CMake flags
1225
	endif()
1546.1.2 by fabounet
added the files for cimpiling with cmake
1226
endif()
1227
set (GETTEXT_SHOW_DESKTOP ${GETTEXT_PLUGINS})
2585 by Matthieu Baerts
CMakeLists.txt: bumped the version of all applets (just to be sure :) )
1228
set (VERSION_SHOW_DESKTOP "1.2.8")
1546.1.2 by fabounet
added the files for cimpiling with cmake
1229
set (PACKAGE_SHOW_DESKTOP "cd-showDesktop")
1546.1.4 by fabounet
cmake compilation is operational
1230
set (show_desktopdatadir "${pluginsdatadir}/showDesktop")
1663 by matttbe
CMakeLists:
1231
configure_file (${CMAKE_CURRENT_SOURCE_DIR}/showDesktop/data/showDesktop.conf.in ${CMAKE_CURRENT_BINARY_DIR}/showDesktop/data/showDesktop.conf)
1546.1.2 by fabounet
added the files for cimpiling with cmake
1232
add_subdirectory (showDesktop)
1233
1234
############# SHOW MOUSE #################
1981 by matttbe
CMakeLists.txt: Fixed a compilation error in Composite Manager + added a few messages in order to have a better debugging and removed a few blank messages in KDE
1235
message (STATUS "> Show Mouse:")
1546.1.2 by fabounet
added the files for cimpiling with cmake
1236
set (GETTEXT_SHOW_MOUSE ${GETTEXT_PLUGINS})
2585 by Matthieu Baerts
CMakeLists.txt: bumped the version of all applets (just to be sure :) )
1237
set (VERSION_SHOW_MOUSE "1.0.5")
1546.1.2 by fabounet
added the files for cimpiling with cmake
1238
set (PACKAGE_SHOW_MOUSE "cd-show_mouse")
1546.1.4 by fabounet
cmake compilation is operational
1239
set (show_mousedatadir "${pluginsdatadir}/show_mouse")
1663 by matttbe
CMakeLists:
1240
configure_file (${CMAKE_CURRENT_SOURCE_DIR}/show-mouse/data/show_mouse.conf.in ${CMAKE_CURRENT_BINARY_DIR}/show-mouse/data/show_mouse.conf)
1546.1.2 by fabounet
added the files for cimpiling with cmake
1241
add_subdirectory (show-mouse)
1242
1243
############# SLIDER #################
1981 by matttbe
CMakeLists.txt: Fixed a compilation error in Composite Manager + added a few messages in order to have a better debugging and removed a few blank messages in KDE
1244
message (STATUS "> Slider:")
2676 by Fabrice Rey
CMakeLists: fixed 2 bugs in the makefile
1245
set (with_exif no)
2648 by Matthieu Baerts
CMakeLists.txt: big changes! We are now using booleans for CMake flags
1246
enable_if_not_defined (enable-exif-support)
1247
if (enable-exif-support)
1248
	pkg_check_modules (EXIF libexif)
1249
	if (NOT EXIF_FOUND)
1250
		message (STATUS "Could not find libexif; Slider won't be able to rotate the images accordingly to their exif data.")
1251
		message (WARNING "This module is required to compile Slider applet with Exif support: libexif")
1252
		set (MODULES_MISSING "${MODULES_MISSING} libexif")
1253
	else ()
2668 by Fabrice Rey
All applets: use the new icon rendering API
1254
		set (with_exif yes)
2648 by Matthieu Baerts
CMakeLists.txt: big changes! We are now using booleans for CMake flags
1255
	endif()
1546.1.2 by fabounet
added the files for cimpiling with cmake
1256
endif()
1257
set (GETTEXT_SLIDER ${GETTEXT_PLUGINS})
2585 by Matthieu Baerts
CMakeLists.txt: bumped the version of all applets (just to be sure :) )
1258
set (VERSION_SLIDER "2.0.14")
1546.1.2 by fabounet
added the files for cimpiling with cmake
1259
set (PACKAGE_SLIDER "cd-slider")
1546.1.4 by fabounet
cmake compilation is operational
1260
set (sliderdatadir "${pluginsdatadir}/slider")
1663 by matttbe
CMakeLists:
1261
configure_file (${CMAKE_CURRENT_SOURCE_DIR}/slider/data/slider.conf.in ${CMAKE_CURRENT_BINARY_DIR}/slider/data/slider.conf)
1546.1.2 by fabounet
added the files for cimpiling with cmake
1262
add_subdirectory (slider)
1263
2645 by Fabrice Rey
New plug-in: Sound-effects: add sounds to various events in the dock
1264
############# SOUND_EFFECTS #################
2668 by Fabrice Rey
All applets: use the new icon rendering API
1265
set (with_sound_effects no)
2648 by Matthieu Baerts
CMakeLists.txt: big changes! We are now using booleans for CMake flags
1266
enable_if_not_defined (enable-sound-effects)
1267
if (enable-sound-effects)
2645 by Fabrice Rey
New plug-in: Sound-effects: add sounds to various events in the dock
1268
	pkg_check_modules (ALSA_PACKAGE alsa)
2648 by Matthieu Baerts
CMakeLists.txt: big changes! We are now using booleans for CMake flags
1269
	if (NOT ALSA_PACKAGE_FOUND)
2645 by Fabrice Rey
New plug-in: Sound-effects: add sounds to various events in the dock
1270
		message (STATUS "Could not find alsa; Cairo-Dock won't be built with Sound-Effect applet.")
1271
		message (WARNING "This module is required to compile Sound-Effect applet: alsa")
1272
		set (MODULES_MISSING "${MODULES_MISSING} alsa")
1273
	else()
1274
		message (STATUS "> Sound-Effects:")
1275
		set (GETTEXT_SOUND_EFFECTS ${GETTEXT_PLUGINS})
1276
		set (VERSION_SOUND_EFFECTS "0.0.1")
1277
		set (PACKAGE_SOUND_EFFECTS "cd-Sound-Effects")
2668 by Fabrice Rey
All applets: use the new icon rendering API
1278
		set (with_sound_effects yes)
2645 by Fabrice Rey
New plug-in: Sound-effects: add sounds to various events in the dock
1279
		set (sound_effectsdatadir "${pluginsdatadir}/Sound-Effects")
1280
		configure_file (${CMAKE_CURRENT_SOURCE_DIR}/Sound-Effects/data/Sound-Effects.conf.in ${CMAKE_CURRENT_BINARY_DIR}/Sound-Effects/data/Sound-Effects.conf)
1281
		add_subdirectory (Sound-Effects)
1282
	endif()
1283
endif()
1284
1546.1.2 by fabounet
added the files for cimpiling with cmake
1285
############# STACK #################
1981 by matttbe
CMakeLists.txt: Fixed a compilation error in Composite Manager + added a few messages in order to have a better debugging and removed a few blank messages in KDE
1286
message (STATUS "> Stack:")
1546.1.2 by fabounet
added the files for cimpiling with cmake
1287
set (GETTEXT_STACK ${GETTEXT_PLUGINS})
2585 by Matthieu Baerts
CMakeLists.txt: bumped the version of all applets (just to be sure :) )
1288
set (VERSION_STACK "0.3.5")
1546.1.2 by fabounet
added the files for cimpiling with cmake
1289
set (PACKAGE_STACK "cd-stack")
1546.1.4 by fabounet
cmake compilation is operational
1290
set (stackdatadir "${pluginsdatadir}/stack")
1663 by matttbe
CMakeLists:
1291
configure_file (${CMAKE_CURRENT_SOURCE_DIR}/stack/data/stack.conf.in ${CMAKE_CURRENT_BINARY_DIR}/stack/data/stack.conf)
1546.1.2 by fabounet
added the files for cimpiling with cmake
1292
add_subdirectory (stack)
1293
1608 by fabounet
Systray 2.0 : version alpha \!
1294
############# STATUS NOTIFIER #################
1981 by matttbe
CMakeLists.txt: Fixed a compilation error in Composite Manager + added a few messages in order to have a better debugging and removed a few blank messages in KDE
1295
message (STATUS "> Status Notifier:")
2648 by Matthieu Baerts
CMakeLists.txt: big changes! We are now using booleans for CMake flags
1296
if (NOT DBUSMENU_GTK_FOUND)
1919 by Fabrice Rey
Status-Notifier: added the option in config to switch from compact to sub-dock mode
1297
	message (STATUS "Could not find Status-Notifier libs; Cairo-Dock won't be built with Status-Notifier support.")
2227 by Matthieu Baerts
CMakeLists.txt: GTK3: compiled 'terminal' and 'weblets' (+TODO: GMenu) applets with GTK3 libs + improved messages if a module is not found.
1298
	message (WARNING "This module is required to compile Status Notifier applet: ${DBUSMENU_GTK_MODULE}(-0.4)")
2047 by matttbe
CMakeLists.txt: Added some warnings if a module or a program is missing + added some messages (+ fixed a few typos)
1299
	# set (MODULES_MISSING "${MODULES_MISSING} dbusmenu-gtk(-0.4)") # it should already be in the list.
2668 by Fabrice Rey
All applets: use the new icon rendering API
1300
	set (with_status_notifier no)
1919 by Fabrice Rey
Status-Notifier: added the option in config to switch from compact to sub-dock mode
1301
else()
2648 by Matthieu Baerts
CMakeLists.txt: big changes! We are now using booleans for CMake flags
1302
	if (force_indicator_applicationadded_have_hint)
2072 by Matthieu Baerts
Status-Notifier: On Ubuntu Oneiric (with indicator-0.4), the ApplicationAdded signal has changed and it has now a new parameter (Hint, with the name of the applet... strange :) )
1303
		set (INDICATOR_APPLICATIONADDED_HAS_HINT 1)
2648 by Matthieu Baerts
CMakeLists.txt: big changes! We are now using booleans for CMake flags
1304
	elseif (DEFINED force_indicator_applicationadded_have_hint)
2072 by Matthieu Baerts
Status-Notifier: On Ubuntu Oneiric (with indicator-0.4), the ApplicationAdded signal has changed and it has now a new parameter (Hint, with the name of the applet... strange :) )
1305
		set (INDICATOR_APPLICATIONADDED_HAS_HINT 0)
1306
	endif()
2609 by Matthieu Baerts
CMakeLists.txt: INDICATOR_APPLICATIONADDED_HAS_HINT is used by Status-Notifier which doesn't need 'indicator' but only DBusMenu
1307
	message (STATUS "  Used old DBus name = ${INDICATOR_OLD_NAMES}")
2073 by Matthieu Baerts
CMakeLists.txt: Impulse is now considered as stable
1308
	message (STATUS "  ApplicationAdded signal has 'Hint' = ${INDICATOR_APPLICATIONADDED_HAS_HINT}")
2609 by Matthieu Baerts
CMakeLists.txt: INDICATOR_APPLICATIONADDED_HAS_HINT is used by Status-Notifier which doesn't need 'indicator' but only DBusMenu
1309
	message (STATUS "  ApplicationAdded signal has 'Title' = ${INDICATOR_APPLICATIONADDED_HAS_TITLE}")
1919 by Fabrice Rey
Status-Notifier: added the option in config to switch from compact to sub-dock mode
1310
	set (GETTEXT_STATUS_NOTIFIER ${GETTEXT_PLUGINS})
2585 by Matthieu Baerts
CMakeLists.txt: bumped the version of all applets (just to be sure :) )
1311
	set (VERSION_STATUS_NOTIFIER "0.1.8")
1919 by Fabrice Rey
Status-Notifier: added the option in config to switch from compact to sub-dock mode
1312
	set (PACKAGE_STATUS_NOTIFIER "cd-status-notifier")
2668 by Fabrice Rey
All applets: use the new icon rendering API
1313
	set (with_status_notifier yes)
1919 by Fabrice Rey
Status-Notifier: added the option in config to switch from compact to sub-dock mode
1314
	set (status_notifierdatadir "${pluginsdatadir}/Status-Notifier")
1315
	configure_file (${CMAKE_CURRENT_SOURCE_DIR}/Status-Notifier/data/Status-Notifier.conf.in ${CMAKE_CURRENT_BINARY_DIR}/Status-Notifier/data/Status-Notifier.conf)
1316
	add_subdirectory (Status-Notifier)
1608 by fabounet
Systray 2.0 : version alpha \!
1317
endif()
1318
1546.1.2 by fabounet
added the files for cimpiling with cmake
1319
############# SWITCHER #################
1981 by matttbe
CMakeLists.txt: Fixed a compilation error in Composite Manager + added a few messages in order to have a better debugging and removed a few blank messages in KDE
1320
message (STATUS "> Switcher:")
1546.1.2 by fabounet
added the files for cimpiling with cmake
1321
set (GETTEXT_SWITCHER ${GETTEXT_PLUGINS})
2724 by Fabrice Rey
Switcher: support the desktop names defined by the session
1322
set (VERSION_SWITCHER "2.2.0")
1546.1.2 by fabounet
added the files for cimpiling with cmake
1323
set (PACKAGE_SWITCHER "cd-switcher")
1546.1.4 by fabounet
cmake compilation is operational
1324
set (switcherdatadir "${pluginsdatadir}/switcher")
1663 by matttbe
CMakeLists:
1325
configure_file (${CMAKE_CURRENT_SOURCE_DIR}/switcher/data/switcher.conf.in ${CMAKE_CURRENT_BINARY_DIR}/switcher/data/switcher.conf)
1546.1.2 by fabounet
added the files for cimpiling with cmake
1326
add_subdirectory (switcher)
1327
1328
############# SYSTEM MONITOR #################
1981 by matttbe
CMakeLists.txt: Fixed a compilation error in Composite Manager + added a few messages in order to have a better debugging and removed a few blank messages in KDE
1329
message (STATUS "> System Monitor:")
2648 by Matthieu Baerts
CMakeLists.txt: big changes! We are now using booleans for CMake flags
1330
enable_if_not_defined (enable-sensors-support)
1331
if (enable-sensors-support)
1332
	find_package (Sensors)
1333
	if (NOT SENSORS_FOUND)
1334
		message (STATUS "Could not find libsensors; System-Monitor won't be able to monitor fan speed and CPU temperature.")
1335
		message (WARNING "This package is required to compile System Monitor applet with Sensors support: sensors")
1336
		set (PROGRAMS_MISSING "${PROGRAMS_MISSING} sensors")
2668 by Fabrice Rey
All applets: use the new icon rendering API
1337
		set (with_sensors no)
2648 by Matthieu Baerts
CMakeLists.txt: big changes! We are now using booleans for CMake flags
1338
	else ()
2668 by Fabrice Rey
All applets: use the new icon rendering API
1339
		set (with_sensors yes)
2648 by Matthieu Baerts
CMakeLists.txt: big changes! We are now using booleans for CMake flags
1340
	endif()
1771 by Fabrice Rey
weather: remove workaround for double-click since the dock handles it nicely + CMakeList: fixed the plug-in dir test + System-monitor: added data from sensors (work in progress)
1341
endif()
1546.1.2 by fabounet
added the files for cimpiling with cmake
1342
set (GETTEXT_SYSTEM_MONITOR ${GETTEXT_PLUGINS})
2585 by Matthieu Baerts
CMakeLists.txt: bumped the version of all applets (just to be sure :) )
1343
set (VERSION_SYSTEM_MONITOR "1.0.13")
1546.1.2 by fabounet
added the files for cimpiling with cmake
1344
set (PACKAGE_SYSTEM_MONITOR "cd-system-monitor")
1546.1.4 by fabounet
cmake compilation is operational
1345
set (system_monitordatadir "${pluginsdatadir}/System-monitor")
1663 by matttbe
CMakeLists:
1346
configure_file (${CMAKE_CURRENT_SOURCE_DIR}/System-Monitor/data/System-Monitor.conf.in ${CMAKE_CURRENT_BINARY_DIR}/System-Monitor/data/System-Monitor.conf)
1546.1.2 by fabounet
added the files for cimpiling with cmake
1347
add_subdirectory (System-Monitor)
1348
1349
############# SYSTRAY #################
1981 by matttbe
CMakeLists.txt: Fixed a compilation error in Composite Manager + added a few messages in order to have a better debugging and removed a few blank messages in KDE
1350
message (STATUS "> Systray:")
1546.1.2 by fabounet
added the files for cimpiling with cmake
1351
set (GETTEXT_SYSTRAY ${GETTEXT_PLUGINS})
2585 by Matthieu Baerts
CMakeLists.txt: bumped the version of all applets (just to be sure :) )
1352
set (VERSION_SYSTRAY "0.2.6")
1546.1.2 by fabounet
added the files for cimpiling with cmake
1353
set (PACKAGE_SYSTRAY "cd-systray")
1546.1.4 by fabounet
cmake compilation is operational
1354
set (systraydatadir "${pluginsdatadir}/systray")
1663 by matttbe
CMakeLists:
1355
configure_file (${CMAKE_CURRENT_SOURCE_DIR}/systray/data/systray.conf.in ${CMAKE_CURRENT_BINARY_DIR}/systray/data/systray.conf)
1546.1.2 by fabounet
added the files for cimpiling with cmake
1356
add_subdirectory (systray)
1357
1358
############# TERMINAL #################
1981 by matttbe
CMakeLists.txt: Fixed a compilation error in Composite Manager + added a few messages in order to have a better debugging and removed a few blank messages in KDE
1359
message (STATUS "> Terminal:")
2648 by Matthieu Baerts
CMakeLists.txt: big changes! We are now using booleans for CMake flags
1360
enable_if_not_defined (enable-terminal)
1361
if (enable-terminal)
1362
	if (gtkversion EQUAL 2)
1363
		set (TERMINAL_MODULE vte)
1364
	else()
1365
		set (TERMINAL_MODULE vte-2.90)
1366
	endif()
1367
	pkg_check_modules (TERMINAL_PACKAGE ${TERMINAL_MODULE})
1368
	if (NOT TERMINAL_PACKAGE_FOUND)
1369
		message (STATUS "Could not find ${TERMINAL_MODULE}; Cairo-Dock won't be built with terminal applet.")
1370
		message (WARNING "This module is required to compile Terminal applet: ${TERMINAL_MODULE}")
1371
		set (MODULES_MISSING "${MODULES_MISSING} ${TERMINAL_MODULE}")
2668 by Fabrice Rey
All applets: use the new icon rendering API
1372
		set (with_terminal no)
2648 by Matthieu Baerts
CMakeLists.txt: big changes! We are now using booleans for CMake flags
1373
	else()
1374
		set (GETTEXT_TERMINAL ${GETTEXT_PLUGINS})
1375
		set (VERSION_TERMINAL "1.0.14")
1376
		set (PACKAGE_TERMINAL "cd-terminal")
2668 by Fabrice Rey
All applets: use the new icon rendering API
1377
		set (with_terminal yes)
2648 by Matthieu Baerts
CMakeLists.txt: big changes! We are now using booleans for CMake flags
1378
		set (terminaldatadir "${pluginsdatadir}/terminal")
1379
		configure_file (${CMAKE_CURRENT_SOURCE_DIR}/terminal/data/terminal.conf.in ${CMAKE_CURRENT_BINARY_DIR}/terminal/data/terminal.conf)
1380
		add_subdirectory (terminal)
1381
	endif()
1546.1.2 by fabounet
added the files for cimpiling with cmake
1382
endif()
1383
1759 by matttbe
New Upstream Version => 2.2.0-1
1384
############# TOMBOY #################
1981 by matttbe
CMakeLists.txt: Fixed a compilation error in Composite Manager + added a few messages in order to have a better debugging and removed a few blank messages in KDE
1385
message (STATUS "> Tomboy:")
1546.1.2 by fabounet
added the files for cimpiling with cmake
1386
set (GETTEXT_TOMBOY ${GETTEXT_PLUGINS})
2585 by Matthieu Baerts
CMakeLists.txt: bumped the version of all applets (just to be sure :) )
1387
set (VERSION_TOMBOY "1.3.5")
1546.1.2 by fabounet
added the files for cimpiling with cmake
1388
set (PACKAGE_TOMBOY "cd-tomboy")
1546.1.4 by fabounet
cmake compilation is operational
1389
set (tomboydatadir "${pluginsdatadir}/tomboy")
1663 by matttbe
CMakeLists:
1390
configure_file (${CMAKE_CURRENT_SOURCE_DIR}/tomboy/data/tomboy.conf.in ${CMAKE_CURRENT_BINARY_DIR}/tomboy/data/tomboy.conf)
1546.1.2 by fabounet
added the files for cimpiling with cmake
1391
add_subdirectory (tomboy)
1392
1393
############# TOONS #################
1981 by matttbe
CMakeLists.txt: Fixed a compilation error in Composite Manager + added a few messages in order to have a better debugging and removed a few blank messages in KDE
1394
message (STATUS "> Toons:")
1546.1.2 by fabounet
added the files for cimpiling with cmake
1395
set (GETTEXT_TOONS ${GETTEXT_PLUGINS})
2585 by Matthieu Baerts
CMakeLists.txt: bumped the version of all applets (just to be sure :) )
1396
set (VERSION_TOONS "1.0.14")
1546.1.2 by fabounet
added the files for cimpiling with cmake
1397
set (PACKAGE_TOONS "cd-Toons")
1546.1.4 by fabounet
cmake compilation is operational
1398
set (toonsdatadir "${pluginsdatadir}/Toons")
1546.1.2 by fabounet
added the files for cimpiling with cmake
1399
set (toonsuserdirname "Toons")
1663 by matttbe
CMakeLists:
1400
configure_file (${CMAKE_CURRENT_SOURCE_DIR}/Toons/data/Toons.conf.in ${CMAKE_CURRENT_BINARY_DIR}/Toons/data/Toons.conf)
1546.1.2 by fabounet
added the files for cimpiling with cmake
1401
add_subdirectory (Toons)
1402
1403
############# WEATHER #################
1981 by matttbe
CMakeLists.txt: Fixed a compilation error in Composite Manager + added a few messages in order to have a better debugging and removed a few blank messages in KDE
1404
message (STATUS "> Weather:")
1546.1.2 by fabounet
added the files for cimpiling with cmake
1405
set (GETTEXT_WEATHER ${GETTEXT_PLUGINS})
2585 by Matthieu Baerts
CMakeLists.txt: bumped the version of all applets (just to be sure :) )
1406
set (VERSION_WEATHER "1.2.15")
1546.1.2 by fabounet
added the files for cimpiling with cmake
1407
set (PACKAGE_WEATHER "cd-weather")
1546.1.4 by fabounet
cmake compilation is operational
1408
set (weatherdatadir "${pluginsdatadir}/weather")
1546.1.2 by fabounet
added the files for cimpiling with cmake
1409
set (weatheruserdirname "weather")
1663 by matttbe
CMakeLists:
1410
configure_file (${CMAKE_CURRENT_SOURCE_DIR}/weather/data/weather.conf.in ${CMAKE_CURRENT_BINARY_DIR}/weather/data/weather.conf)
1546.1.2 by fabounet
added the files for cimpiling with cmake
1411
add_subdirectory (weather)
1412
1413
############# WEBLETS #################
1981 by matttbe
CMakeLists.txt: Fixed a compilation error in Composite Manager + added a few messages in order to have a better debugging and removed a few blank messages in KDE
1414
message (STATUS "> Weblets:")
2668 by Fabrice Rey
All applets: use the new icon rendering API
1415
set (with_weblets no)
2648 by Matthieu Baerts
CMakeLists.txt: big changes! We are now using booleans for CMake flags
1416
enable_if_not_defined (enable-weblets)
1417
if (enable-weblets)
1418
	if (gtkversion EQUAL 2)
2227 by Matthieu Baerts
CMakeLists.txt: GTK3: compiled 'terminal' and 'weblets' (+TODO: GMenu) applets with GTK3 libs + improved messages if a module is not found.
1419
		set (WEBKIT_MODULE webkit-1.0)
1420
	else()
1421
		set (WEBKIT_MODULE webkitgtk-3.0)
1422
	endif()
1423
	pkg_check_modules (WEBKIT ${WEBKIT_MODULE})
2648 by Matthieu Baerts
CMakeLists.txt: big changes! We are now using booleans for CMake flags
1424
	if (NOT WEBKIT_FOUND)
2227 by Matthieu Baerts
CMakeLists.txt: GTK3: compiled 'terminal' and 'weblets' (+TODO: GMenu) applets with GTK3 libs + improved messages if a module is not found.
1425
		message (STATUS "Could not find ${WEBKIT_MODULE}; Cairo-Dock won't be built with Weblets applet.")
1426
		message (WARNING "This module is required to compile Weblets applet: ${WEBKIT_MODULE}")
1427
		set (MODULES_MISSING "${MODULES_MISSING} ${WEBKIT_MODULE}")
1558 by fabounet
fixed the compilation of xfce-plug-in
1428
	else()
1429
		set (GETTEXT_WEBLETS ${GETTEXT_PLUGINS})
2585 by Matthieu Baerts
CMakeLists.txt: bumped the version of all applets (just to be sure :) )
1430
		set (VERSION_WEBLETS "0.0.14")
1558 by fabounet
fixed the compilation of xfce-plug-in
1431
		set (PACKAGE_WEBLETS "cd-weblets")
1432
		set (webletsdatadir "${pluginsdatadir}/weblets")
2668 by Fabrice Rey
All applets: use the new icon rendering API
1433
		set (with_weblets yes)
1663 by matttbe
CMakeLists:
1434
		configure_file (${CMAKE_CURRENT_SOURCE_DIR}/weblets/data/weblets.conf.in ${CMAKE_CURRENT_BINARY_DIR}/weblets/data/weblets.conf)
1558 by fabounet
fixed the compilation of xfce-plug-in
1435
		add_subdirectory ("weblets")
1436
	endif()
1546.1.2 by fabounet
added the files for cimpiling with cmake
1437
endif()
1438
1439
############# WIFI #################
1981 by matttbe
CMakeLists.txt: Fixed a compilation error in Composite Manager + added a few messages in order to have a better debugging and removed a few blank messages in KDE
1440
message (STATUS "> WiFi:")
1546.1.2 by fabounet
added the files for cimpiling with cmake
1441
set (GETTEXT_WIFI ${GETTEXT_PLUGINS})
2585 by Matthieu Baerts
CMakeLists.txt: bumped the version of all applets (just to be sure :) )
1442
set (VERSION_WIFI "1.3.2")
1546.1.2 by fabounet
added the files for cimpiling with cmake
1443
set (PACKAGE_WIFI "cd-wifi")
1546.1.4 by fabounet
cmake compilation is operational
1444
set (wifidatadir "${pluginsdatadir}/wifi")
1663 by matttbe
CMakeLists:
1445
configure_file (${CMAKE_CURRENT_SOURCE_DIR}/wifi/data/wifi.conf.in ${CMAKE_CURRENT_BINARY_DIR}/wifi/data/wifi.conf)
1546.1.2 by fabounet
added the files for cimpiling with cmake
1446
add_subdirectory (wifi)
1447
1448
############# XFCE-INTEGRATION #################
1981 by matttbe
CMakeLists.txt: Fixed a compilation error in Composite Manager + added a few messages in order to have a better debugging and removed a few blank messages in KDE
1449
message (STATUS "> XFCE-Integration:")
2668 by Fabrice Rey
All applets: use the new icon rendering API
1450
set (with_xfce_integration no)
2648 by Matthieu Baerts
CMakeLists.txt: big changes! We are now using booleans for CMake flags
1451
enable_if_not_defined (enable-xfce-integration)
1452
if (enable-xfce-integration)
2167 by Matthieu Baerts
XFCE: removed useless links to thunar-vfs if not used
1453
	pkg_check_modules (XFCE_INTEGRATION_THUNAR QUIET thunar-vfs-1) # thunar-vfs is not used if gvfs (gio) is available
1549 by Tofe
Tried to fix CMakeFile.txt
1454
	pkg_check_modules (XFCE_INTEGRATION_GVFS gio-2.0)
2648 by Matthieu Baerts
CMakeLists.txt: big changes! We are now using booleans for CMake flags
1455
	if (XFCE_INTEGRATION_THUNAR_FOUND AND XFCE_INTEGRATION_GVFS_FOUND)
1549 by Tofe
Tried to fix CMakeFile.txt
1456
		message (STATUS "Could find neither thunar-vfs or libgio-2.0; Cairo-Dock won't be built with XFCE support.")
2047 by matttbe
CMakeLists.txt: Added some warnings if a module or a program is missing + added some messages (+ fixed a few typos)
1457
		message (STATUS "This module is required to compile XFCE-Integration applet: gio-2.0 (or thunar-vfs-1)")
1458
		set (MODULES_INTEGRATION_MISSING "${MODULES_INTEGRATION_MISSING} gio-2.0")
1546.1.2 by fabounet
added the files for cimpiling with cmake
1459
	else()
2523 by Matthieu Baerts
Integration plugins: Even if there is no translatable strings in these plugins, use the right gettext domain (if we want to add translatable strings in the future)
1460
		set (GETTEXT_XFCE_INTEGRATION ${GETTEXT_PLUGINS})
2585 by Matthieu Baerts
CMakeLists.txt: bumped the version of all applets (just to be sure :) )
1461
		set (VERSION_XFCE_INTEGRATION "1.0.4")
1546.1.2 by fabounet
added the files for cimpiling with cmake
1462
		set (PACKAGE_XFCE_INTEGRATION "cd_xfce-integration")
2668 by Fabrice Rey
All applets: use the new icon rendering API
1463
		set (with_xfce_integration yes)
1546.1.4 by fabounet
cmake compilation is operational
1464
		set (xfce_integrationdatadir "${pluginsdatadir}/xfce-integration")
1546.1.2 by fabounet
added the files for cimpiling with cmake
1465
		add_subdirectory ("xfce-integration")
1466
	endif()
1467
endif()
1468
1469
############# XGAMMA #################
1981 by matttbe
CMakeLists.txt: Fixed a compilation error in Composite Manager + added a few messages in order to have a better debugging and removed a few blank messages in KDE
1470
message (STATUS "> XGamma:")
2648 by Matthieu Baerts
CMakeLists.txt: big changes! We are now using booleans for CMake flags
1471
enable_if_not_defined (enable-xgamma)
1472
if (enable-xgamma)
1473
	pkg_check_modules (XGAMMA_PACKAGE x11 xxf86vm)
1474
	if (NOT XGAMMA_PACKAGE_FOUND)
1475
		message (STATUS "Could not find xxf86vm; Cairo-Dock won't be built with Xgamma applet.")
1476
		message (WARNING "These modules are required to compile XGamma applet: x11 and xxf86vm")
1477
		set (MODULES_MISSING "${MODULES_MISSING} x11 xxf86vm")
2668 by Fabrice Rey
All applets: use the new icon rendering API
1478
		set (with_xgamma no)
2648 by Matthieu Baerts
CMakeLists.txt: big changes! We are now using booleans for CMake flags
1479
	else()
1480
		set (GETTEXT_XGAMMA ${GETTEXT_PLUGINS})
1481
		set (VERSION_XGAMMA "1.2.4")
1482
		set (PACKAGE_XGAMMA "cd-Xgamma")
2668 by Fabrice Rey
All applets: use the new icon rendering API
1483
		set (with_xgamma yes)
2648 by Matthieu Baerts
CMakeLists.txt: big changes! We are now using booleans for CMake flags
1484
		set (xgammadatadir "${pluginsdatadir}/Xgamma")
1485
		configure_file (${CMAKE_CURRENT_SOURCE_DIR}/Xgamma/data/Xgamma.conf.in ${CMAKE_CURRENT_BINARY_DIR}/Xgamma/data/Xgamma.conf)
1486
		add_subdirectory ("Xgamma")
1487
	endif()
1546.1.2 by fabounet
added the files for cimpiling with cmake
1488
endif()
1489
1820 by matttbe
DBus Interfaces: added the prefix (needed to build packages) + used complet path for python and ruby executable
1490
message ("")
1811.1.2 by Fabrice Rey
updated to libgldi 2.2.1
1491
message (STATUS "===============")
1492
message (STATUS "Language build:")
1493
message (STATUS "===============")
1820 by matttbe
DBus Interfaces: added the prefix (needed to build packages) + used complet path for python and ruby executable
1494
message ("")
1546.1.2 by fabounet
added the files for cimpiling with cmake
1495
add_subdirectory (po)
1811.1.2 by Fabrice Rey
updated to libgldi 2.2.1
1496
1820 by matttbe
DBus Interfaces: added the prefix (needed to build packages) + used complet path for python and ruby executable
1497
message ("")
1811.1.2 by Fabrice Rey
updated to libgldi 2.2.1
1498
message (STATUS "===============")
1499
message (STATUS "Plug-ins build:")
1500
message (STATUS "===============")
1820 by matttbe
DBus Interfaces: added the prefix (needed to build packages) + used complet path for python and ruby executable
1501
message ("")
1948 by matttbe
CMakeLists.txt: Added the status of applets (stable/unstable/unsupported)
1502
message (STATUS "Stable:")
2073 by Matthieu Baerts
CMakeLists.txt: Impulse is now considered as stable
1503
message (STATUS " Integration plug-ins:")
1504
message (STATUS " - with Gnome support:             ${with_gnome_integration}")
1505
message (STATUS " - with KDE support:               ${with_kde_integration}")
1506
message (STATUS " - with XFCE support:              ${with_xfce_integration}")
1507
message (STATUS " Plug-ins:")
1811.1.2 by Fabrice Rey
updated to libgldi 2.2.1
1508
message (STATUS " - with Alsa-Mixer applet:         ${with_alsa}")
1509
message (STATUS " - with GMenu applet:              ${with_gmenu}")
2073 by Matthieu Baerts
CMakeLists.txt: Impulse is now considered as stable
1510
message (STATUS " - with Impulse applet:            ${with_impulse}")
2730 by Matthieu Baerts
Indicator-Generic: new applet! A plugin to hold all your 'indicators' applets.
1511
message (STATUS " - with Indicator-Generic applet:  ${with_indicator_generic}")
1811.1.2 by Fabrice Rey
updated to libgldi 2.2.1
1512
message (STATUS " - with Keyboard-indicator applet: ${with_keyboard_indicator}")
1513
message (STATUS " - with Mail applet:               ${with_mail}")
2648 by Matthieu Baerts
CMakeLists.txt: big changes! We are now using booleans for CMake flags
1514
if (NOT INDICATOR_NEW_VERSION OR enable-memenu)  # oneiric or newer
2196 by Matthieu Baerts
CMakeLists.txt:
1515
message (STATUS " - with Me-Menu applet applet:     ${with_me_menu}")
2075 by Matthieu Baerts
CMakeLists.txt: it's MeMenu that has been automatically merged with Messaging Menu and not the opposite, sorry :)
1516
endif()
2196 by Matthieu Baerts
CMakeLists.txt:
1517
message (STATUS " - with Messaging-Menu applet:     ${with_messaging_menu}")
2221 by Matthieu Baerts
CMakeLists.txt: fixed a typo with the condition to compile Application-Menu + used only dash for the enable-* cmake flags + sorted the summary at the end by alphabetical order
1518
message (STATUS " - with Recent-Events applet:      ${with_recent_events}")
2646 by Matthieu Baerts
Sound-Effects: fixed two typos on this new vital applet :)
1519
message (STATUS " - with Sound Effects applet:      ${with_sound_effects}")
1820 by matttbe
DBus Interfaces: added the prefix (needed to build packages) + used complet path for python and ruby executable
1520
message (STATUS " - with Status-Notifier applet:    ${with_status_notifier}")
1811.1.2 by Fabrice Rey
updated to libgldi 2.2.1
1521
message (STATUS " - with Terminal applet:           ${with_terminal}")
1522
message (STATUS " - with Weblets applet:            ${with_weblets}")
1523
message (STATUS " - with Xgamma applet:             ${with_xgamma}")
2196 by Matthieu Baerts
CMakeLists.txt:
1524
message (STATUS "Add On:")
2255 by Matthieu Baerts
CMakeLists.txt: Sound-Control with Sound-Menu support: Checked if IDO is available and not with an old version
1525
message (STATUS " - with Sound-Menu support:        ${with_soundmenu}")
2196 by Matthieu Baerts
CMakeLists.txt:
1526
message (STATUS " - with Screen Resolution support: ${with_xrandr}")
1527
message (STATUS " - with Sensors support:           ${with_sensors}")
2000 by matttbe
Added a new applet: Impulse
1528
message (STATUS " - with UPower support:            ${with_upower_support}")
2254 by Fabrice Rey
Sound-Control: merged with Sound-Menu
1529
message (STATUS " - with iCal support:              ${with_ical}")
2668 by Fabrice Rey
All applets: use the new icon rendering API
1530
message (STATUS " - with Exif support:              ${with_exif}")
2219 by Fabrice Rey
new applet: Application-Menu (aka Global-Menu). Currently works with the Ubuntu's implementation of the global menu (com.canonical.AppMenu). Of course it's an early alpha ;-)
1531
message (STATUS "Third Party Interfaces:")
2872 by Matthieu Baerts
CMakeLists.txt: DBus: Python: support DESTDIR env var
1532
message (STATUS " - with Python2 interface:         ${with_python2}")
1533
message (STATUS " - with Python3 interface:         ${with_python3}")
1811.1.2 by Fabrice Rey
updated to libgldi 2.2.1
1534
message (STATUS " - with Ruby interface:            ${with_ruby}")
1535
message (STATUS " - with Mono interface:            ${with_mono}")
1811.1.9 by Fabrice Rey
added Recent Events applet (currently support recent files related to a launcher or an appli on right click)
1536
message (STATUS " - with Vala interface:            ${with_vala}")
1968 by matttbe
CMakeLists.txt: a 'with_status_notifier' was missing. Ok right, this is really a tiny tiny tiny detail :P
1537
message (STATUS " - with Vala Translator (valac):   ${with_valac}")
1948 by matttbe
CMakeLists.txt: Added the status of applets (stable/unstable/unsupported)
1538
message (STATUS "Unstable:")
2243 by Fabrice Rey
Global-menu: renamed + added animations on the buttons and the ability to use animated images
1539
message (STATUS " - with Global-Menu applet:        ${with_global_menu}")
1948 by matttbe
CMakeLists.txt: Added the status of applets (stable/unstable/unsupported)
1540
message (STATUS " - with Disks applet:              ${with_disks}")
1541
message (STATUS " - with Doncky applet:             ${with_doncky}")
2020 by matttbe
CMakeLists.txt: Fixed a compilation error (thanks to Tofe ;) )
1542
message (STATUS " - with KDE experimental support:  ${with_kde_integration2}")
1948 by matttbe
CMakeLists.txt: Added the status of applets (stable/unstable/unsupported)
1543
message (STATUS " - with Network-Monitor applet:    ${with_network_monitor}")
1544
message (STATUS " - with Scooby-Do applet:          ${with_scooby_do}")
1980 by Fabrice Rey
changed the .conf 'Icon' group layout + updated translations => beta1
1545
message (STATUS "Deprecated:")
1948 by matttbe
CMakeLists.txt: Added the status of applets (stable/unstable/unsupported)
1546
message (STATUS " - with old Gnome support:         ${with_gnome_integration_old}")
2047 by matttbe
CMakeLists.txt: Added some warnings if a module or a program is missing + added some messages (+ fixed a few typos)
1547
1548
if (NOT "${MODULES_MISSING}" STREQUAL "")
1549
	message ("")
1550
	message (STATUS "WARNING: It seems that one (or more) module(s) is (are) missing:${MODULES_MISSING}")
2186 by Fabrice Rey
Plug-ins: ported to GTK3 (GMenu and Systray code was really ugly, I had to clean it severly) (not tested with GTK2 yet)
1551
	message (STATUS "It can be interesting to install them (especially if you're a maintainer of Cairo-Dock's packages).")
2047 by matttbe
CMakeLists.txt: Added some warnings if a module or a program is missing + added some messages (+ fixed a few typos)
1552
endif ()
1553
1554
if (NOT "${PROGRAMS_MISSING}" STREQUAL "")
1555
	message ("")
1556
	message (STATUS "WARNING: It seems that one (or more) program(s) or package(s) is (are) missing:${PROGRAMS_MISSING}")
2191 by Fabrice Rey
some fixes with GTK3
1557
	message (STATUS "It can be interesting to install them (especially if you're a maintainer of Cairo-Dock's packages).")
2047 by matttbe
CMakeLists.txt: Added some warnings if a module or a program is missing + added some messages (+ fixed a few typos)
1558
endif ()
1559
1560
if (NOT "${MODULES_INTEGRATION_MISSING}" STREQUAL "")
1561
	message ("")
1562
	message (STATUS "WARNING: It seems that one (or more) module(s) for the integration with the system is (are) missing:${MODULES_INTEGRATION_MISSING}")
1563
	message (STATUS "It's maybe not required for the user but it's recommended to install them if you're a maintainer of Cairo-Dock's packages.")
1564
endif ()
2221 by Matthieu Baerts
CMakeLists.txt: fixed a typo with the condition to compile Application-Menu + used only dash for the enable-* cmake flags + sorted the summary at the end by alphabetical order
1565
message ("")