1kdecmake(1) General Commands Manual kdecmake(1)
2
3
4
6 kdecmake - Reference of available CMake custom modules.
7
8
10 The "cmake" executable is the CMake command-line interface. It may be
11 used to configure projects in scripts. Project configuration settings
12 may be specified on the command line with the -D option. The -i option
13 will cause cmake to interactively prompt for such settings.
14
15
16 CMake is a cross-platform build system generator. Projects specify
17 their build process with platform-independent CMake listfiles included
18 in each directory of a source tree with the name CMakeLists.txt. Users
19 build a project by using CMake to generate a build system for a native
20 tool on their platform.
21
22
24 The following modules are also available for CMake. They can be used
25 with INCLUDE(ModuleName).
26
27
28 Custom CMake Modules - Additional Modules for CMake.
29
30
31 This is the documentation for additional modules and scripts for CMake.
32 Using these modules you can check the computer system for installed
33 software packages, features of the compiler and the existance of head‐
34 ers to name just a few.
35
36
37 CMakeParseArguments
38
39
40 CMAKE_PARSE_ARGUMENTS(<prefix> <options> <one_value_keywords>
41 <multi_value_keywords> args...)
42
43
44 CMAKE_PARSE_ARGUMENTS() is intended to be used in macros or
45 functions for parsing the arguments given to that macro or func‐
46 tion. It processes the arguments and defines a set of variables
47 which hold the values of the respective options.
48
49
50 The <options> argument contains all options for the respective
51 macro, i.e. keywords which can be used when calling the macro
52 without any value following, like e.g. the OPTIONAL keyword of
53 the install() command.
54
55
56 The <one_value_keywords> argument contains all keywords for this
57 macro which are followed by one value, like e.g. DESTINATION
58 keyword of the install() command.
59
60
61 The <multi_value_keywords> argument contains all keywords for
62 this macro which can be followed by more than one value, like
63 e.g. the TARGETS or FILES keywords of the install() command.
64
65
66 When done, CMAKE_PARSE_ARGUMENTS() will have defined for each of
67 the keywords listed in <options>, <one_value_keywords> and
68 <multi_value_keywords> a variable composed of the given <prefix>
69 followed by "_" and the name of the respective keyword. These
70 variables will then hold the respective value from the argument
71 list. For the <options> keywords this will be TRUE or FALSE.
72
73
74 All remaining arguments are collected in a variable <pre‐
75 fix>_UNPARSED_ARGUMENTS, this can be checked afterwards to see
76 whether your macro was called with unrecognized parameters.
77
78
79 As an example here a my_install() macro, which takes similar
80 arguments as the real install() command:
81
82
83 function(MY_INSTALL)
84 set(options OPTIONAL FAST)
85 set(oneValueArgs DESTINATION RENAME)
86 set(multiValueArgs TARGETS CONFIGURATIONS)
87 cmake_parse_arguments(MY_INSTALL "${options}" "${oneValueArgs}" "${multiValueArgs}" ${ARGN} )
88 ...
89
90
91
92
93 Assume my_install() has been called like this:
94
95
96 my_install(TARGETS foo bar DESTINATION bin OPTIONAL blub)
97
98
99
100
101 After the cmake_parse_arguments() call the macro will have set
102 the following variables:
103
104
105 MY_INSTALL_OPTIONAL = TRUE
106 MY_INSTALL_FAST = FALSE (this option was not used when calling my_install()
107 MY_INSTALL_DESTINATION = "bin"
108 MY_INSTALL_RENAME = "" (was not used)
109 MY_INSTALL_TARGETS = "foo;bar"
110 MY_INSTALL_CONFIGURATIONS = "" (was not used)
111 MY_INSTALL_UNPARSED_ARGUMENTS = "blub" (no value expected after "OPTIONAL"
112
113
114
115
116 You can the continue and process these variables.
117
118
119 Keywords terminate lists of values, e.g. if directly after a
120 one_value_keyword another recognized keyword follows, this is
121 interpreted as the beginning of the new option. E.g.
122 my_install(TARGETS foo DESTINATION OPTIONAL) would result in
123 MY_INSTALL_DESTINATION set to "OPTIONAL", but MY_INSTALL_DESTI‐
124 NATION would be empty and MY_INSTALL_OPTIONAL would be set to
125 TRUE therefor.
126
127
128 CheckCXXSourceCompiles
129 macro which checks if the source code compiles
130
131 CHECK_CXX_SOURCE_COMPILES(SOURCE VAR)
132
133
134 SOURCE - source code to try to compile
135 VAR - variable to store whether the source code compiled
136
137
138
139
140 The following variables may be set before calling this macro to
141 modify the way the check is run:
142
143
144 CMAKE_REQUIRED_FLAGS = string of compile command line flags
145 CMAKE_REQUIRED_DEFINITIONS = list of macros to define (-DFOO=bar)
146 CMAKE_REQUIRED_INCLUDES = list of include directories
147 CMAKE_REQUIRED_LIBRARIES = list of libraries to link
148
149
150 CheckCXXSourceRuns
151 Check if the C++ source code provided in the SOURCE argument
152 compiles and runs.
153
154 CHECK_CXX_SOURCE_RUNS(SOURCE VAR)
155
156
157 SOURCE - source code to try to compile
158 VAR - variable to store the result, 1 for success, empty for failure
159
160
161
162
163 The following variables may be set before calling this macro to
164 modify the way the check is run:
165
166
167 CMAKE_REQUIRED_FLAGS = string of compile command line flags
168 CMAKE_REQUIRED_DEFINITIONS = list of macros to define (-DFOO=bar)
169 CMAKE_REQUIRED_INCLUDES = list of include directories
170 CMAKE_REQUIRED_LIBRARIES = list of libraries to link
171
172
173 CheckCXXSymbolExists
174 Check if the symbol exists in include files, in C++ mode
175
176 Forked off cmake's CheckSymbolExists.cmake CHECK_CXX_SYM‐
177 BOL_EXISTS(SYMBOL FILES VARIABLE)
178
179
180 SYMBOL - symbol
181 FILES - include files to check
182 VARIABLE - variable to return result
183
184
185
186
187 The following variables may be set before calling this macro to
188 modify the way the check is run:
189
190
191 CMAKE_REQUIRED_FLAGS = string of compile command line flags
192 CMAKE_REQUIRED_DEFINITIONS = list of macros to define (-DFOO=bar)
193 CMAKE_REQUIRED_INCLUDES = list of include directories
194 CMAKE_REQUIRED_LIBRARIES = list of libraries to link
195
196
197 CheckPointerMember
198 Check if the given struct or class has the specified member
199 variable
200
201 CHECK_POINTER_MEMBER (POINTER MEMBER HEADER VARIABLE)
202
203
204 POINTER - the name of the struct or class you are interested in
205 MEMBER - the member which existence you want to check
206 HEADER - the header(s) where the prototype should be declared
207 VARIABLE - variable to store the result
208
209
210
211
212 The following variables may be set before calling this macro to
213 modify the way the check is run:
214
215
216 CMAKE_REQUIRED_FLAGS = string of compile command line flags
217 CMAKE_REQUIRED_DEFINITIONS = list of macros to define (-DFOO=bar)
218 CMAKE_REQUIRED_INCLUDES = list of include directories
219
220
221 CheckPrototypeExists
222 Check if the prototype for a function exists.
223
224 CHECK_PROTOTYPE_EXISTS (FUNCTION HEADER VARIABLE)
225
226
227 FUNCTION - the name of the function you are looking for
228 HEADER - the header(s) where the prototype should be declared
229 VARIABLE - variable to store the result
230
231
232
233
234 The following variables may be set before calling this macro to
235 modify the way the check is run:
236
237
238 CMAKE_REQUIRED_FLAGS = string of compile command line flags
239 CMAKE_REQUIRED_DEFINITIONS = list of macros to define (-DFOO=bar)
240 CMAKE_REQUIRED_INCLUDES = list of include directories
241
242
243 CheckStructMember
244 Check if the given struct or class has the specified member
245 variable
246
247 CHECK_STRUCT_MEMBER (STRUCT MEMBER HEADER VARIABLE)
248
249
250 STRUCT - the name of the struct or class you are interested in
251 MEMBER - the member which existence you want to check
252 HEADER - the header(s) where the prototype should be declared
253 VARIABLE - variable to store the result
254
255
256
257
258 The following variables may be set before calling this macro to
259 modify the way the check is run:
260
261
262 CMAKE_REQUIRED_FLAGS = string of compile command line flags
263 CMAKE_REQUIRED_DEFINITIONS = list of macros to define (-DFOO=bar)
264 CMAKE_REQUIRED_INCLUDES = list of include directories
265
266
267 FindACL
268 Try to find the ACL library
269
270 Once done this will define
271
272
273 ACL_FOUND - system has the ACL library
274 ACL_LIBS - The libraries needed to use ACL
275
276
277 FindAGG
278 Try to find the AGG graphics library
279
280 Once done this will define
281
282
283 AGG_FOUND - system has AGG
284 AGG_INCLUDE_DIR - the AGG include directory
285 AGG_LIBRARIES - Link these to use AGG
286 AGG_DEFINITIONS - Compiler switches required for using AGG
287
288
289 FindAkode
290 Try to find the aKode library
291
292 Once done this will define
293
294
295 AKODE_FOUND - system has the aKode library
296 AKODE_INCLUDE_DIR - the aKode include directory
297 AKODE_LIBRARIES - The libraries needed to use aKode
298
299
300 FindAlsa
301
302
303 Alsa check, based on libkmid/configure.in.in. Only the support
304 for Alsa >= 0.9.x was included; 0.5.x was dropped (but feel free
305 to re-add it if you need it) It defines ... It offers the fol‐
306 lowing macros:
307
308
309 ALSA_CONFIGURE_FILE(config_header) - generate a config.h, typical usage:
310 ALSA_CONFIGURE_FILE(${CMAKE_BINARY_DIR}/config-alsa.h)
311 ALSA_VERSION_STRING(version_string) looks for alsa/version.h and reads the version string into
312 the first argument passed to the macro
313
314
315 FindAutomoc4
316 Try to find automoc4
317
318 Once done this will define
319
320
321 AUTOMOC4_FOUND - automoc4 has been found
322 AUTOMOC4_EXECUTABLE - the automoc4 tool
323 AUTOMOC4_VERSION - the full version of automoc4
324 AUTOMOC4_VERSION_MAJOR, AUTOMOC4_VERSION_MINOR, AUTOMOC4_VERSION_PATCH - AUTOMOC4_VERSION
325 broken into its components
326
327
328
329
330 It also adds the following macros
331
332
333 AUTOMOC4(<target> <SRCS_VAR>)
334 Use this to run automoc4 on all files contained in the list <SRCS_VAR>.
335
336
337
338
339 AUTOMOC4_MOC_HEADERS(<target> header1.h header2.h ...)
340 Use this to add more header files to be processed with automoc4.
341
342
343
344
345 AUTOMOC4_ADD_EXECUTABLE(<target_NAME> src1 src2 ...)
346 This macro does the same as ADD_EXECUTABLE, but additionally
347 adds automoc4 handling for all source files.
348
349
350
351
352 AUTOMOC4_ADD_LIBRARY(<target_NAME> src1 src2 ...)
353
354
355 This macro does the same as ADD_LIBRARY, but additionally
356 adds automoc4 handling for all source files.
357
358
359 FindAvahi
360
361
362 Find Avahi. Only avahi-common/defs.h is really needed
363
364
365 FindBerkeleyDB
366 Try to find Berkeley DB
367
368 Once done this will define
369
370
371 BERKELEY_DB_FOUND - system has Berkeley DB
372 BERKELEY_DB_INCLUDE_DIR - the Berkeley DB include directory
373 BERKELEY_DB_LIBRARIES - Link these to use Berkeley DB
374 BERKELEY_DB_DEFINITIONS - Compiler switches required for using Berkeley DB
375
376
377 FindBlitz
378 Try to find blitz lib
379
380 ##########################################################
381 ######## DEPRECATED, use FindQImageBlitz instead #########
382 ########################################################## Once
383 done this will define
384
385
386 BLITZ_FOUND - system has blitz lib
387 BLITZ_INCLUDES - the blitz include directory
388 BLITZ_LIBRARIES - The libraries needed to use blitz
389
390
391 FindBlueZ
392 Try to find BlueZ
393
394 Once done this will define
395
396
397 BLUEZ_FOUND - system has BlueZ
398 BLUEZ_INCLUDE_DIR - the BlueZ include directory
399 BLUEZ_LIBRARIES - Link these to use BlueZ
400 BLUEZ_DEFINITIONS - Compiler switches required for using BlueZ
401
402 Redistribution and use is allowed according to the terms of the
403 BSD license. For details see the accompanying COPY‐
404 ING-CMAKE-SCRIPTS file.
405
406
407
408 FindBoost
409 Try to find Boost include dirs and libraries
410
411
412
413
414 Please see the Documentation for Boost in the CMake Manual for
415 details This module only forwards to the one included in cmake
416 for compatibility reasons.
417
418
419 FindCarbon
420 Find Carbon on Mac
421
422
423
424
425 CARBON_LIBRARY - the library to use Carbon
426 CARBON_FOUND - true if Carbon has been found
427
428
429 FindDBusMenuQt
430 Try to find dbusmenu-qt
431
432 This module helps finding an installation of the DBusMenuQt
433 library (see https://launchpad.net/libdbusmenu-qt/) Once done
434 this will define
435
436
437 DBUSMENUQT_FOUND - system has dbusmenu-qt
438 DBUSMENUQT_INCLUDE_DIR - the dbusmenu-qt include directory
439 DBUSMENUQT_LIBRARIES - the libraries needed to use dbusmenu-qt
440 DBUSMENUQT_DEFINITIONS - Compiler switches required for using dbusmenu-qt
441
442
443
444
445 The minimum required version of DBusMenuQt can be specified
446 using the standard syntax, e.g. find_package(DBusMenuQt 0.6)
447
448
449 WARNING: versions below 0.4.0 cannot be checked for. So if you
450 want to have a version check, require at least 0.4.0 of dbus‐
451 menuqt.
452
453
454 FindDNSSD
455 Try to find DNSSD
456
457 Once done this will define
458
459
460 DNSSD_FOUND - system has DNSSD
461 DNSSD_INCLUDE_DIR - the DNSSD include directory
462 DNSSD_LIBRARIES - Link these to use dnssd
463 DNSSD_DEFINITIONS - Compiler switches required for using DNSSD
464
465
466
467
468 need more test: look at into dnssd/configure.in.in
469
470
471 FindDocBookXML
472
473
474 Try to find DocBook XML DTDs Once done, it will define:
475
476
477 DOCBOOKXML_FOUND - system has the required DocBook XML DTDs
478 DOCBOOKXML_CURRENTDTD_VERSION - the version of currently used DocBook XML
479 DTD
480 DOCBOOKXML_CURRENTDTD_DIR - the directory containing the definition of
481 the currently used DocBook XML version
482
483
484 FindDocBookXSL
485
486
487 Try to find DocBook XSL stylesheet Once done, it will define:
488
489
490 DOCBOOKXSL_FOUND - system has the required DocBook XML DTDs
491 DOCBOOKXSL_DIR - the directory containing the stylesheets
492 used to process DocBook XML
493
494
495 FindENCHANT
496 Try to find the Enchant spell checker
497
498 Once done this will define
499
500
501 ENCHANT_FOUND - system has ENCHANT
502 ENCHANT_INCLUDE_DIR - the ENCHANT include directory
503 ENCHANT_LIBRARIES - Link these to use ENCHANT
504 ENCHANT_DEFINITIONS - Compiler switches required for using ENCHANT
505
506
507 FindEigen
508 Try to find Eigen1 library
509
510 Note that Eigen1 is deprecated in favor of Eigen2. So this file
511 is deprecated in favor of FindEigen2.cmake. It is kept only for
512 compatibility.
513
514
515 Once done this will define
516
517
518 EIGEN_FOUND - system has eigen lib
519 EIGEN_INCLUDE_DIR - the eigen include directory
520
521
522 FindEigen2
523 Try to find Eigen2 lib
524
525
526
527
528 This module supports requiring a minimum version, e.g. you can
529 do
530
531
532 find_package(Eigen2 2.0.3)
533
534 to require version 2.0.3 to newer of Eigen2.
535
536
537 Once done this will define
538
539
540 EIGEN2_FOUND - system has eigen lib with correct version
541 EIGEN2_INCLUDE_DIR - the eigen include directory
542 EIGEN2_VERSION - eigen version
543
544
545 FindExiv2
546 Try to find the Exiv2 library
547
548
549
550
551 EXIV2_MIN_VERSION - You can set this variable to the minimum version you need
552 before doing FIND_PACKAGE(Exiv2). The default is 0.12.
553
554
555
556
557 Once done this will define
558
559
560 EXIV2_FOUND - system has libexiv2
561 EXIV2_INCLUDE_DIR - the libexiv2 include directory
562 EXIV2_LIBRARIES - Link these to use libexiv2
563 EXIV2_DEFINITIONS - Compiler switches required for using libexiv2
564
565
566
567
568 The minimum required version of Exiv2 can be specified using the
569 standard syntax, e.g. find_package(Exiv2 0.17)
570
571
572 For compatiblity, also the variable EXIV2_MIN_VERSION can be set
573 to the minimum version you need before doing FIND_PACK‐
574 AGE(Exiv2). The default is 0.12.
575
576
577 FindFAM
578 Try to find the FAM directory notification library
579
580 Once done this will define
581
582
583 FAM_FOUND - system has FAM
584 FAM_INCLUDE_DIR - the FAM include directory
585 FAM_LIBRARIES - The libraries needed to use FAM
586
587
588 FindFFmpeg
589 Try to find ffmpeg
590
591 Once done this will define
592
593
594 FFMPEG_FOUND - system has ffmpeg
595 FFMPEG_INCLUDE_DIR - Include directory necessary for using the ffmpeg headers
596 FFMPEG_LIBRARIES - Link these to use ffmpeg
597 FFMPEG_DEFINITIONS - Compiler switches required for using ffmpeg
598
599
600 FindFlac
601 Try to find Flac, the Free Lossless Audio Codec
602
603 Once done this will define
604
605
606 FLAC_FOUND - system has Flac
607 FLAC_INCLUDE_DIR - the Flac include directory
608 FLAC_LIBRARIES - Link these to use Flac
609 FLAC_OGGFLAC_LIBRARIES - Link these to use OggFlac
610
611
612
613
614 No version checking is done - use FLAC_API_VERSION_CURRENT to
615 conditionally compile version-dependent code
616
617
618 FindFlex
619 Try to find Flex
620
621 Once done this will define
622
623
624 FLEX_FOUND - system has Flex
625 FLEX_EXECUTABLE - path of the flex executable
626 FLEX_VERSION - the version string, like "2.5.31"
627
628
629
630
631 The minimum required version of Flex can be specified using the
632 standard syntax, e.g. find_package(Flex 2.5)
633
634
635 FindFontconfig
636 Try to find the Fontconfig
637
638 Once done this will define
639
640
641 FONTCONFIG_FOUND - system has Fontconfig
642 FONTCONFIG_INCLUDE_DIR - The include directory to use for the fontconfig headers
643 FONTCONFIG_LIBRARIES - Link these to use FONTCONFIG
644 FONTCONFIG_DEFINITIONS - Compiler switches required for using FONTCONFIG
645
646
647 FindFreetype
648 Try to find the freetype library
649
650 Once done this will define
651
652
653 FREETYPE_FOUND - system has Freetype
654 FREETYPE_INCLUDE_DIRS - the FREETYPE include directories
655 FREETYPE_LIBRARIES - Link these to use FREETYPE
656 FREETYPE_INCLUDE_DIR - internal
657
658
659 FindGIF
660 Try to find GIF
661
662 Once done this will define
663
664
665 GIF_FOUND - system has GIF
666 GIF_INCLUDE_DIR - the GIF include directory
667 GIF_LIBRARIES - Libraries needed to use GIF
668 GIF_DEFINITIONS - Compiler switches required for using GIF
669
670
671 FindGLIB2
672 Try to find the GLIB2 libraries
673
674 Once done this will define
675
676
677 GLIB2_FOUND - system has glib2
678 GLIB2_INCLUDE_DIR - the glib2 include directory
679 GLIB2_LIBRARIES - glib2 library
680
681
682 FindGMP
683
684
685 Try to find the GMP librairies
686
687
688 GMP_FOUND - system has GMP lib
689 GMP_INCLUDE_DIR - the GMP include directory
690 GMP_LIBRARIES - Libraries needed to use GMP
691
692
693 FindGObject
694 Try to find GObject
695
696 Once done this will define
697
698
699 GOBJECT_FOUND - system has GObject
700 GOBJECT_INCLUDE_DIR - the GObject include directory
701 GOBJECT_LIBRARIES - the libraries needed to use GObject
702 GOBJECT_DEFINITIONS - Compiler switches required for using GObject
703
704
705 FindGSSAPI
706 Try to detect the GSSAPI support
707
708 Once done this will define
709
710
711 GSSAPI_FOUND - system supports GSSAPI
712 GSSAPI_INCS - the GSSAPI include directory
713 GSSAPI_LIBS - the libraries needed to use GSSAPI
714 GSSAPI_FLAVOR - the type of API - MIT or HEIMDAL
715
716
717 FindGStreamer
718 Try to find GStreamer
719
720 Once done this will define
721
722
723 GSTREAMER_FOUND - system has GStreamer
724 GSTREAMER_INCLUDE_DIR - the GStreamer include directory
725 GSTREAMER_LIBRARIES - the libraries needed to use GStreamer
726 GSTREAMER_DEFINITIONS - Compiler switches required for using GStreamer
727
728
729 FindGettext
730
731
732 Try to find Gettext functionality Once done this will define
733
734
735 GETTEXT_FOUND - system has Gettext
736 GETTEXT_INCLUDE_DIR - Gettext include directory
737 GETTEXT_LIBRARIES - Libraries needed to use Gettext
738
739
740 FindGphoto2
741
742
743 cmake macro to test if we use gphoto2
744
745
746 GPHOTO2_FOUND - system has the GPHOTO2 library
747 GPHOTO2_INCLUDE_DIR - the GPHOTO2 include directory
748 GPHOTO2_LIBRARIES - The libraries needed to use GPHOTO2
749
750
751 FindHUNSPELL
752 Try to find HUNSPELL
753
754 Once done this will define
755
756
757 HUNSPELL_FOUND - system has HUNSPELL
758 HUNSPELL_INCLUDE_DIR - the HUNSPELL include directory
759 HUNSPELL_LIBRARIES - The libraries needed to use HUNSPELL
760 HUNSPELL_DEFINITIONS - Compiler switches required for using HUNSPELL
761
762
763 FindHUpnp
764 Try to find HUPnP library
765
766 Once done this will define
767
768
769
770
771 HUPNP_FOUND - system has HUPnP
772 HUPNP_INCLUDE_DIR - the LIBHUpnp include directory
773 HUPNP_LIBS - the LIBHUpnp libraries
774
775
776
777
778 Copyright (c) 2010, Paulo Romulo Alves Barros <paulo.romulo@kde‐
779 mail.net>
780
781
782 FindIOKit
783 Find IOKit on Mac
784
785
786
787
788 IOKIT_LIBRARY - the library to use IOKit
789 IOKIT_FOUND - true if IOKit has been found
790
791
792 FindKDE4Internal
793 Find the KDE4 include and library dirs, KDE preprocessors and
794 define a some macros
795
796
797
798
799 This module defines the following variables:
800
801
802 KDE4_FOUND - set to TRUE if everything required for building KDE software has been found
803
804
805
806
807 KDE4_DEFINITIONS - compiler definitions required for compiling KDE software
808 KDE4_INCLUDE_DIR - the KDE 4 include directory
809 KDE4_INCLUDES - all include directories required for KDE, i.e.
810 KDE4_INCLUDE_DIR, but also the Qt4 include directories
811 and other platform specific include directories
812 KDE4_LIB_DIR - the directory where the KDE libraries are installed,
813 intended to be used with LINK_DIRECTORIES(). In general, this is not necessary.
814 KDE4_LIBEXEC_INSTALL_DIR - the directory where libexec executables from kdelibs are installed
815 KDE4_BIN_INSTALL_DIR - the directory where executables from kdelibs are installed
816 KDE4_SBIN_INSTALL_DIR - the directory where system executables from kdelibs are installed
817 KDE4_DATA_INSTALL_DIR - the parent directory where kdelibs applications install their data
818 KDE4_HTML_INSTALL_DIR - the directory where HTML documentation from kdelibs is installed
819 KDE4_CONFIG_INSTALL_DIR - the directory where config files from kdelibs are installed
820 KDE4_ICON_INSTALL_DIR - the directory where icons from kdelibs are
821 KDE4_IMPORTS_INSTALL_DIR - the directory where imports from kdelibs are
822 KDE4_KCFG_INSTALL_DIR - the directory where kconfig files from kdelibs are installed
823 KDE4_LOCALE_INSTALL_DIR - the directory where translations from kdelibs are installed
824 KDE4_MIME_INSTALL_DIR - the directory where mimetype desktop files from kdelibs are installed
825 KDE4_SOUND_INSTALL_DIR - the directory where sound files from kdelibs are installed
826 KDE4_TEMPLATES_INSTALL_DIR - the directory where templates (Create new file...) from kdelibs are installed
827 KDE4_WALLPAPER_INSTALL_DIR - the directory where wallpapers from kdelibs are installed
828 KDE4_KCONF_UPDATE_INSTALL_DIR - the directory where kconf_update files from kdelibs are installed
829 KDE4_AUTOSTART_INSTALL_DIR - the directory where autostart from kdelibs are installed
830 KDE4_XDG_APPS_INSTALL_DIR - the XDG apps dir from kdelibs
831 KDE4_XDG_DIRECTORY_INSTALL_DIR - the XDG directory from kdelibs
832 KDE4_SYSCONF_INSTALL_DIR - the directory where sysconfig files from kdelibs are installed
833 KDE4_MAN_INSTALL_DIR - the directory where man pages from kdelibs are installed
834 KDE4_INFO_INSTALL_DIR - the directory where info files from kdelibs are installed
835 KDE4_DBUS_INTERFACES_DIR - the directory where dbus interfaces from kdelibs are installed
836 KDE4_DBUS_SERVICES_DIR - the directory where dbus service files from kdelibs are installed
837
838
839
840
841 The following variables are defined for the various tools
842 required to compile KDE software:
843
844
845 KDE4_KCFGC_EXECUTABLE - the kconfig_compiler4 executable
846 KDE4_AUTOMOC_EXECUTABLE - the kde4automoc executable, deprecated, use AUTOMOC4_EXECUTABLE instead
847 KDE4_MEINPROC_EXECUTABLE - the meinproc4 executable
848 KDE4_MAKEKDEWIDGETS_EXECUTABLE - the makekdewidgets4 executable
849
850
851
852
853 The following variables point to the location of the KDE
854 libraries, but shouldn't be used directly:
855
856
857 KDE4_KDECORE_LIBRARY - the kdecore library
858 KDE4_KDEUI_LIBRARY - the kdeui library
859 KDE4_KIO_LIBRARY - the kio library
860 KDE4_KPARTS_LIBRARY - the kparts library
861 KDE4_KUTILS_LIBRARY - the kutils library
862 KDE4_KEMOTICONS_LIBRARY - the kemoticons library
863 KDE4_KIDLETIME_LIBRARY - the kidletime library
864 KDE4_KCMUTILS_LIBRARY - the kcmutils library
865 KDE4_KPRINTUTILS_LIBRARY - the kprintutils library
866 KDE4_KDE3SUPPORT_LIBRARY - the kde3support library
867 KDE4_KFILE_LIBRARY - the kfile library
868 KDE4_KHTML_LIBRARY - the khtml library
869 KDE4_KJS_LIBRARY - the kjs library
870 KDE4_KJSAPI_LIBRARY - the kjs public api library
871 KDE4_KNEWSTUFF2_LIBRARY - the knewstuff2 library
872 KDE4_KNEWSTUFF3_LIBRARY - the knewstuff3 library
873 KDE4_KDNSSD_LIBRARY - the kdnssd library
874 KDE4_PHONON_LIBRARY - the phonon library
875 KDE4_THREADWEAVER_LIBRARY- the threadweaver library
876 KDE4_SOLID_LIBRARY - the solid library
877 KDE4_KNOTIFYCONFIG_LIBRARY- the knotifyconfig library
878 KDE4_KROSSCORE_LIBRARY - the krosscore library
879 KDE4_KTEXTEDITOR_LIBRARY - the ktexteditor library
880 KDE4_NEPOMUK_LIBRARY - the nepomuk library
881 KDE4_PLASMA_LIBRARY - the plasma library
882 KDE4_KUNITCONVERSION_LIBRARY - the kunitconversion library
883 KDE4_KDEWEBKIT_LIBRARY - the kdewebkit library
884
885
886
887
888 KDE4_PLASMA_OPENGL_FOUND - TRUE if the OpenGL support of Plasma has been found, NOTFOUND otherwise
889
890
891
892
893 Compared to the variables above, the following variables also
894 contain all of the depending libraries, so the variables below
895 should be used instead of the ones above:
896
897
898 KDE4_KDECORE_LIBS - the kdecore library and all depending libraries
899 KDE4_KDEUI_LIBS - the kdeui library and all depending libraries
900 KDE4_KIO_LIBS - the kio library and all depending libraries
901 KDE4_KPARTS_LIBS - the kparts library and all depending libraries
902 KDE4_KUTILS_LIBS - the kutils library and all depending libraries
903 KDE4_KEMOTICONS_LIBS - the kemoticons library and all depending libraries
904 KDE4_KIDLETIME_LIBS - the kidletime library and all depending libraries
905 KDE4_KCMUTILS_LIBS - the kcmutils library and all depending libraries
906 KDE4_KPRINTUTILS_LIBS - the kprintutils library and all depending libraries
907 KDE4_KDE3SUPPORT_LIBS - the kde3support library and all depending libraries
908 KDE4_KFILE_LIBS - the kfile library and all depending libraries
909 KDE4_KHTML_LIBS - the khtml library and all depending libraries
910 KDE4_KJS_LIBS - the kjs library and all depending libraries
911 KDE4_KJSAPI_LIBS - the kjs public api library and all depending libraries
912 KDE4_KNEWSTUFF2_LIBS - the knewstuff2 library and all depending libraries
913 KDE4_KNEWSTUFF3_LIBS - the knewstuff3 library and all depending libraries
914 KDE4_KDNSSD_LIBS - the kdnssd library and all depending libraries
915 KDE4_KDESU_LIBS - the kdesu library and all depending libraries
916 KDE4_KPTY_LIBS - the kpty library and all depending libraries
917 KDE4_PHONON_LIBS - the phonon library and all depending librairies
918 KDE4_THREADWEAVER_LIBRARIES- the threadweaver library and all depending libraries
919 KDE4_SOLID_LIBS - the solid library and all depending libraries
920 KDE4_KNOTIFYCONFIG_LIBS - the knotify config library and all depending libraries
921 KDE4_KROSSCORE_LIBS - the kross core library and all depending libraries
922 KDE4_KROSSUI_LIBS - the kross ui library which includes core and all depending libraries
923 KDE4_KTEXTEDITOR_LIBS - the ktexteditor library and all depending libraries
924 KDE4_NEPOMUK_LIBS - the nepomuk library and all depending libraries
925 KDE4_PLASMA_LIBS - the plasma library and all depending librairies
926 KDE4_KUNITCONVERSION_LIBS - the kunitconversion library and all depending libraries
927 KDE4_KDEWEBKIT_LIBS - the kdewebkit library and all depending libraries
928
929
930
931
932 This module defines also a bunch of variables used as locations
933 for install directories for files of the package which is using
934 this module. These variables don't say anything about the loca‐
935 tion of the installed KDE. They can be relative (to
936 CMAKE_INSTALL_PREFIX) or absolute. Under Windows they are always
937 relative.
938
939
940 BIN_INSTALL_DIR - the directory where executables will be installed (default is prefix/bin)
941 BUNDLE_INSTALL_DIR - Mac only: the directory where application bundles will be installed (default is /Applications/KDE4 )
942 SBIN_INSTALL_DIR - the directory where system executables will be installed (default is prefix/sbin)
943 LIB_INSTALL_DIR - the directory where libraries will be installed (default is prefix/lib)
944 CONFIG_INSTALL_DIR - the directory where config files will be installed
945 DATA_INSTALL_DIR - the parent directory where applications can install their data
946 HTML_INSTALL_DIR - the directory where HTML documentation will be installed
947 ICON_INSTALL_DIR - the directory where the icons will be installed (default prefix/share/icons/)
948 INFO_INSTALL_DIR - the directory where info files will be installed (default prefix/info)
949 KCFG_INSTALL_DIR - the directory where kconfig files will be installed
950 LOCALE_INSTALL_DIR - the directory where translations will be installed
951 MAN_INSTALL_DIR - the directory where man pages will be installed (default prefix/man/)
952 MIME_INSTALL_DIR - the directory where mimetype desktop files will be installed
953 PLUGIN_INSTALL_DIR - the subdirectory relative to the install prefix where plugins will be installed (default is ${KDE4_LIB_INSTALL_DIR}/kde4)
954 IMPORTS_INSTALL_DIR - the subdirectory relative to the install prefix where imports will be installed
955 SERVICES_INSTALL_DIR - the directory where service (desktop, protocol, ...) files will be installed
956 SERVICETYPES_INSTALL_DIR - the directory where servicestypes desktop files will be installed
957 SOUND_INSTALL_DIR - the directory where sound files will be installed
958 TEMPLATES_INSTALL_DIR - the directory where templates (Create new file...) will be installed
959 WALLPAPER_INSTALL_DIR - the directory where wallpapers will be installed
960 AUTOSTART_INSTALL_DIR - the directory where autostart files will be installed
961 DEMO_INSTALL_DIR - the directory where demos will be installed
962 KCONF_UPDATE_INSTALL_DIR - the directory where kconf_update files will be installed
963 SYSCONF_INSTALL_DIR - the directory where sysconfig files will be installed (default /etc)
964 XDG_APPS_INSTALL_DIR - the XDG apps dir
965 XDG_DIRECTORY_INSTALL_DIR- the XDG directory
966 XDG_MIME_INSTALL_DIR - the XDG mimetypes install dir
967 DBUS_INTERFACES_INSTALL_DIR - the directory where dbus interfaces will be installed (default is prefix/share/dbus-1/interfaces)
968 DBUS_SERVICES_INSTALL_DIR - the directory where dbus services will be installed (default is prefix/share/dbus-1/services )
969 DBUS_SYSTEM_SERVICES_INSTALL_DIR - the directory where dbus system services will be installed (default is prefix/share/dbus-1/system-services )
970
971
972
973
974 The variable INSTALL_TARGETS_DEFAULT_ARGS can be used when
975 installing libraries or executables into the default locations.
976 The INSTALL_TARGETS_DEFAULT_ARGS variable should be used when
977 libraries are installed. It should also be used when installing
978 applications, since then on OS X application bundles will be
979 installed to BUNDLE_INSTALL_DIR. The variable MUST NOT be used
980 for installing plugins. It also MUST NOT be used for executables
981 which are intended to go into sbin/ or libexec/.
982
983
984 Usage is like this:
985
986
987 install(TARGETS kdecore kdeui ${INSTALL_TARGETS_DEFAULT_ARGS} )
988
989
990
991
992 This will install libraries correctly under UNIX, OSX and Win‐
993 dows (i.e. dll's go into bin/.
994
995
996
997
998
999 The following variable is provided, but seem to be unused:
1000
1001
1002 LIBS_HTML_INSTALL_DIR /share/doc/HTML CACHE STRING "Is this still used ?")
1003
1004
1005
1006
1007 The following user adjustable options are provided:
1008
1009
1010 KDE4_ENABLE_FINAL - enable KDE-style enable-final all-in-one-compilation
1011 KDE4_BUILD_TESTS - enable this to build the testcases
1012 KDE4_ENABLE_FPIE - enable it to use gcc Position Independent Executables feature
1013 KDE4_USE_COMMON_CMAKE_PACKAGE_CONFIG_DIR - only present for CMake >= 2.6.3, defaults to TRUE
1014 If enabled, the package should install its <package>Config.cmake file to
1015 lib/cmake/<package>/ instead to lib/<package>/cmake
1016 KDE4_SERIALIZE_TOOL - wrapper to serialize potentially resource-intensive commands during
1017 parallel builds (set to 'icecc' when using icecream)
1018
1019
1020
1021
1022 It also adds the following macros and functions (from
1023 KDE4Macros.cmake)
1024
1025
1026 KDE4_ADD_UI_FILES (SRCS_VAR file1.ui ... fileN.ui)
1027 Use this to add Qt designer ui files to your application/library.
1028
1029
1030
1031
1032 KDE4_ADD_UI3_FILES (SRCS_VAR file1.ui ... fileN.ui)
1033 Use this to add Qt designer ui files from Qt version 3 to your application/library.
1034
1035
1036
1037
1038 KDE4_ADD_KCFG_FILES (SRCS_VAR [GENERATE_MOC] [USE_RELATIVE_PATH] file1.kcfgc ... fileN.kcfgc)
1039 Use this to add KDE config compiler files to your application/library.
1040 Use optional GENERATE_MOC to generate moc if you use signals in your kcfg files.
1041 Use optional USE_RELATIVE_PATH to generate the classes in the build following the given
1042 relative path to the file.
1043
1044
1045
1046
1047 KDE4_ADD_WIDGET_FILES (SRCS_VAR file1.widgets ... fileN.widgets)
1048 Use this to add widget description files for the makekdewidgets4 code generator
1049 for Qt Designer plugins.
1050
1051
1052
1053
1054 KDE4_CREATE_FINAL_FILES (filename_CXX filename_C file1 ... fileN)
1055 This macro is intended mainly for internal uses.
1056 It is used for enable-final. It will generate two source files,
1057 one for the C files and one for the C++ files.
1058 These files will have the names given in filename_CXX and filename_C.
1059
1060
1061
1062
1063 KDE4_ADD_PLUGIN ( name [WITH_PREFIX] file1 ... fileN )
1064 Create a KDE plugin (KPart, kioslave, etc.) from the given source files.
1065 It supports KDE4_ENABLE_FINAL.
1066 If WITH_PREFIX is given, the resulting plugin will have the prefix "lib", otherwise it won't.
1067
1068
1069
1070
1071 KDE4_ADD_KDEINIT_EXECUTABLE (name [NOGUI] [RUN_UNINSTALLED] file1 ... fileN)
1072 Create a KDE application in the form of a module loadable via kdeinit.
1073 A library named kdeinit_<name> will be created and a small executable which links to it.
1074 It supports KDE4_ENABLE_FINAL
1075 If the executable doesn't have a GUI, use the option NOGUI. By default on OS X
1076 application bundles are created, with the NOGUI option no bundles but simple executables
1077 are created. Under Windows this flag is also necessary to separate between applications
1078 with GUI and without. On other UNIX systems this flag has no effect.
1079 RUN_UNINSTALLED is deprecated and is ignored, for details see the documentation for
1080 KDE4_ADD_EXECUTABLE().
1081
1082
1083
1084
1085 KDE4_ADD_EXECUTABLE (name [NOGUI] [TEST] [RUN_UNINSTALLED] file1 ... fileN)
1086 Equivalent to ADD_EXECUTABLE(), but additionally adds some more features:
1087 -support for KDE4_ENABLE_FINAL
1088 -support for automoc
1089 -automatic RPATH handling
1090 If the executable doesn't have a GUI, use the option NOGUI. By default on OS X
1091 application bundles are created, with the NOGUI option no bundles but simple executables
1092 are created. Under Windows this flag is also necessary to separate between applications
1093 with GUI and without. On other UNIX systems this flag has no effect.
1094 The option TEST is for internal use only.
1095 The option RUN_UNINSTALLED is ignored. It was necessary with KDE 4.0 and 4.1
1096 if the executable had to be run from the build tree. Since KDE 4.2 all
1097 executables can be always run uninstalled (the RPATH of executables which are not
1098 yet installed points since then into the buildtree and is changed
1099 to the proper location when installing, so RUN_UNINSTALLED is not necessary anymore).
1100
1101
1102
1103
1104 KDE4_ADD_LIBRARY (name [STATIC | SHARED | MODULE ] file1 ... fileN)
1105 Equivalent to ADD_LIBRARY(). Additionally it supports KDE4_ENABLE_FINAL,
1106 includes automoc-handling and sets LINK_INTERFACE_LIBRARIES target property empty.
1107 The RPATH is set according to the global RPATH settings as set up by FindKDE4Internal.cmake
1108 (CMAKE_SKIP_BUILD_RPATH=FALSE, CMAKE_BUILD_WITH_INSTALL_RPATH=FALSE, CMAKE_INSTALL_RPATH_USE_LINK_PATH=TRUE)
1109 Under Windows it adds a -DMAKE_<name>_LIB definition to the compilation.
1110
1111
1112
1113
1114 KDE4_ADD_UNIT_TEST (testname [TESTNAME targetname] file1 ... fileN)
1115 add a unit test, which is executed when running make test
1116 it will be built with RPATH poiting to the build dir
1117 The targets are always created, but only built for the "all"
1118 target if the option KDE4_BUILD_TESTS is enabled. Otherwise the rules for the target
1119 are created but not built by default. You can build them by manually building the target.
1120 The name of the target can be specified using TESTNAME <targetname>, if it is not given
1121 the macro will default to the <testname>
1122 KDESRCDIR is set to the source directory of the test, this can be used with
1123 KGlobal::dirs()->addResourceDir( "data", KDESRCDIR )
1124
1125
1126
1127
1128
1129
1130
1131 KDE4_ADD_APP_ICON (SRCS_VAR pattern)
1132 adds an application icon to target source list.
1133 Make sure you have a 128x128 icon, or the icon won't display on Mac OS X.
1134 Mac OSX notes : the application icon is added to a Mac OS X bundle so that Finder and friends show the right thing.
1135 Win32 notes: the application icon(s) are compiled into the application
1136 There is some workaround in kde4_add_kdeinit_executable to make it possible for those applications as well.
1137
1138 Parameters:
1139
1140
1141 SRCS_VAR - specifies the list of source files
1142 pattern - regular expression for searching application icons
1143 Example: KDE4_ADD_APP_ICON( myapp_SOURCES "pics/cr*-myapp.png")
1144 Example: KDE4_ADD_APP_ICON( myapp_KDEINIT_SRCS "icons/oxygen/*/apps/myapp.png")
1145
1146
1147
1148
1149 KDE4_UPDATE_ICONCACHE()
1150 Notifies the icon cache that new icons have been installed by updating
1151 mtime of ${ICON_INSTALL_DIR}/hicolor directory.
1152
1153
1154
1155
1156 KDE4_INSTALL_ICONS( path theme)
1157 Installs all png and svgz files in the current directory to the icon
1158 directoy given in path, in the subdirectory for the given icon theme.
1159
1160
1161
1162
1163 KDE4_CREATE_HANDBOOK( docbookfile [INSTALL_DESTINATION installdest] [SUBDIR subdir])
1164 Create the handbook from the docbookfile (using meinproc4)
1165 The resulting handbook will be installed to <installdest> when using
1166 INSTALL_DESTINATION <installdest>, or to <installdest>/<subdir> if
1167 SUBDIR <subdir> is specified.
1168
1169
1170
1171
1172 KDE4_CREATE_MANPAGE( docbookfile section )
1173 Create the manpage for the specified section from the docbookfile (using meinproc4)
1174 The resulting manpage will be installed to <installdest> when using
1175 INSTALL_DESTINATION <installdest>, or to <installdest>/<subdir> if
1176 SUBDIR <subdir> is specified.
1177
1178
1179
1180
1181 KDE4_INSTALL_AUTH_ACTIONS( HELPER_ID ACTIONS_FILE )
1182 This macro generates an action file, depending on the backend used, for applications using KAuth.
1183 It accepts the helper id (the DBUS name) and a file containing the actions (check kdelibs/kdecore/auth/example
1184 for file format). The macro will take care of generating the file according to the backend specified,
1185 and to install it in the right location. This (at the moment) means that on Linux (PolicyKit) a .policy
1186 file will be generated and installed into the policykit action directory (usually /usr/share/PolicyKit/policy/),
1187 and on Mac (Authorization Services) will be added to the system action registry using the native MacOS API during
1188 the install phase
1189
1190
1191
1192
1193 KDE4_INSTALL_AUTH_HELPER_FILES( HELPER_TARGET HELPER_ID HELPER_USER )
1194 This macro adds the needed files for an helper executable meant to be used by applications using KAuth.
1195 It accepts the helper target, the helper ID (the DBUS name) and the user under which the helper will run on.
1196 This macro takes care of generate the needed files, and install them in the right location. This boils down
1197 to a DBus policy to let the helper register on the system bus, and a service file for letting the helper
1198 being automatically activated by the system bus.
1199 *WARNING* You have to install the helper in ${LIBEXEC_INSTALL_DIR} to make sure everything will work.
1200
1201
1202
1203
1204
1205
1206
1207
1208
1209
1210 A note on the possible values for CMAKE_BUILD_TYPE and how KDE handles
1211 the flags for those buildtypes. FindKDE4Internal supports the values
1212 Debug, Release, RelWithDebInfo, Profile and Debugfull:
1213
1214
1215
1216
1217 Release
1218 optimised for speed, qDebug/kDebug turned off, no debug symbols, no asserts
1219 RelWithDebInfo (Release with debug info)
1220 similar to Release, optimised for speed, but with debugging symbols on (-g)
1221 Debug
1222 optimised but debuggable, debugging on (-g)
1223 (-fno-reorder-blocks -fno-schedule-insns -fno-inline)
1224 DebugFull
1225 no optimisation, full debugging on (-g3)
1226 Profile
1227 DebugFull + -ftest-coverage -fprofile-arcs
1228
1229
1230
1231
1232
1233
1234
1235 The default buildtype is RelWithDebInfo.
1236 It is expected that the "Debug" build type be still debuggable with gdb
1237 without going all over the place, but still produce better performance.
1238 It's also important to note that gcc cannot detect all warning conditions
1239 unless the optimiser is active.
1240
1241
1242
1243
1244
1245
1246
1247 This module allows to depend on a particular minimum version of kdelibs.
1248 To acomplish that one should use the apropriate cmake syntax for
1249 find_package. For example to depend on kdelibs >= 4.1.0 one should use
1250
1251
1252
1253
1254 find_package(KDE4 4.1.0 REQUIRED)
1255
1256
1257
1258
1259 In earlier versions of KDE you could use the variable KDE_MIN_VERSION to
1260 have such a dependency. This variable is deprecated with KDE 4.2.0, but
1261 will still work to make the module backwards-compatible.
1262
1263
1264 FindKDE4Workspace
1265
1266
1267 Find if we installed kdebase/workspaces. Once done this will
1268 define
1269
1270
1271 KDE4WORKSPACE_FOUND - system has KDE workspace installed
1272 KDE4WORKSPACE_INCLUDE_DIR - the KDE workspace include directory
1273
1274
1275
1276
1277 It also sets variables for the following libraries:
1278
1279
1280 KDE4WORKSPACE_TASKMANAGER_LIBRARY, KDE4WORKSPACE_TASKMANAGER_LIBS
1281 KDE4WORKSPACE_KWORKSPACE_LIBRARY, KDE4WORKSPACE_KWORKSPACE_LIBS
1282 KDE4WORKSPACE_SOLIDCONTROLIFACES_LIBRARY, KDE4WORKSPACE_SOLIDCONTROLIFACES_LIBS
1283 KDE4WORKSPACE_SOLIDCONTROL_LIBRARY, KDE4WORKSPACE_SOLIDCONTROL_LIBS
1284 KDE4WORKSPACE_PROCESSUI_LIBRARY, KDE4WORKSPACE_PROCESSUI_LIBS
1285 KDE4WORKSPACE_LSOFUI_LIBRARY, KDE4WORKSPACE_LSOFUI_LIBS
1286 KDE4WORKSPACE_PLASMACLOCK_LIBRARY, KDE4WORKSPACE_PLASMACLOCK_LIBS
1287 KDE4WORKSPACE_NEPOMUKQUERYCLIENT_LIBRARY, KDE4WORKSPACE_NEPOMUKQUERYCLIENT_LIBS
1288 KDE4WORKSPACE_NEPOMUKQUERY_LIBRARY, KDE4WORKSPACE_NEPOMUKQUERY_LIBS
1289 KDE4WORKSPACE_KSCREENSAVER_LIBRARY, KDE4WORKSPACE_KSCREENSAVER_LIBS
1290 KDE4WORKSPACE_WEATHERION_LIBRARY, KDE4WORKSPACE_WEATHERION_LIBS
1291 KDE4WORKSPACE_KWINEFFECTS_LIBRARY, KDE4WORKSPACE_KWINEFFECTS_LIBS
1292 KDE4WORKSPACE_KDECORATIONS_LIBRARY, KDE4WORKSPACE_KDECORATIONS_LIBS
1293 KDE4WORKSPACE_KSGRD_LIBRARY, KDE4WORKSPACE_KSGRD_LIBS
1294 KDE4WORKSPACE_KEPHAL_LIBRARY, KDE4WORKSPACE_KEPHAL_LIBS
1295
1296
1297
1298
1299 And the following locations:
1300
1301
1302 KDE4WORKSPACE_LIB_DIR
1303 KDE4WORKSPACE_LIBEXEC_DIR
1304 KDE4WORKSPACE_INCLUDE_DIR
1305 KDE4WORKSPACE_BIN_DIR
1306 KDE4WORKSPACE_SBIN_DIR
1307 KDE4WORKSPACE_DATA_DIR
1308 KDE4WORKSPACE_HTML_DIR
1309 KDE4WORKSPACE_CONFIG_DIR
1310 KDE4WORKSPACE_ICON_DIR
1311 KDE4WORKSPACE_KCFG_DIR
1312 KDE4WORKSPACE_LOCALE_DIR
1313 KDE4WORKSPACE_MIME_DIR
1314 KDE4WORKSPACE_SOUND_DIR
1315 KDE4WORKSPACE_TEMPLATES_DIR
1316 KDE4WORKSPACE_WALLPAPER_DIR
1317 KDE4WORKSPACE_KCONF_UPDATE_DIR
1318 KDE4WORKSPACE_AUTOSTART_DIR
1319 KDE4WORKSPACE_XDG_APPS_DIR
1320 KDE4WORKSPACE_XDG_DIRECTORY_DIR
1321 KDE4WORKSPACE_SYSCONF_DIR
1322 KDE4WORKSPACE_MAN_DIR
1323 KDE4WORKSPACE_INFO_DIR
1324 KDE4WORKSPACE_DBUS_INTERFACES_DIR
1325 KDE4WORKSPACE_DBUS_SERVICES_DIR
1326 KDE4WORKSPACE_SERVICES_DIR
1327 KDE4WORKSPACE_SERVICETYPES_DIR
1328
1329
1330 FindKDEWIN32
1331 Try to find the KDEWIN32 library - deprecated
1332
1333
1334
1335
1336 Once done this will define
1337
1338
1339 KDEWIN32_FOUND - system has KDEWIN32
1340 KDEWIN32_INCLUDES - the KDEWIN32 include directories
1341 KDEWIN32_LIBRARIES - The libraries needed to use KDEWIN32
1342
1343
1344 FindKDEWIN_Packager
1345
1346
1347
1348
1349
1350 KDEWIN packager http://www.winkde.org/pub/kde/ports/win32/in‐
1351 staller
1352
1353
1354 The kdewin packager is searched in the following pathes and
1355 order
1356
1357
1358 path specified by the environment dir KDEWIN_PACKAGER_DIR
1359 <ProgramFiles>/kdewin-packager
1360 <ProgramFiles>/kdewin-installer
1361
1362
1363
1364
1365 The macro KDEWIN_PACKAGER provides package building support and
1366 should be added to the top level CMakeLists.txt as shown below
1367
1368
1369 if (KDEWIN_PACKAGER_FOUND)
1370
1371
1372 KDEWIN_PACKAGER(
1373 "projectname"
1374 "version"
1375 "description"
1376 "additional options"
1377 )
1378
1379 endif (KDEWIN_PACKAGER_FOUND)
1380
1381
1382 FindKDEWin
1383 Try to find the KDEWIN library
1384
1385
1386
1387
1388 Once done this will define
1389
1390
1391 KDEWIN_FOUND - system has KDEWIN
1392 KDEWIN_INCLUDES - the KDEWIN include directories
1393 KDEWIN_LIBRARIES - The libraries needed to use KDEWIN
1394
1395
1396 FindKDevPlatform
1397
1398
1399
1400
1401
1402 Find the KDevelop Platform modules and sets various variables
1403 accordingly
1404
1405
1406 Example usage of this module: find_package(KDevPlatform 1.0.0
1407 REQUIRED)
1408
1409
1410 The version number and REQUIRED flag are optional. You can set
1411 CMAKE_PREFIX_PATH variable to help it find the required files
1412 and directories
1413
1414
1415 FindKNepomuk
1416
1417
1418 Once done this will define
1419
1420
1421 KNEPOMUK_FOUND - system has the Nepomuk-KDE backbone lib KNep
1422 KNEPOMUK_INCLUDES - the libKNep include directory
1423 KNEPOMUK_LIBRARIES - Link these to use libKNep
1424
1425
1426
1427
1428
1429 FindKdcraw
1430 Try to find the Kdcraw library
1431
1432 Once done this will define
1433
1434
1435 KDCRAW_FOUND - system has libkdcraw
1436 KDCRAW_INCLUDE_DIR - the libkdcraw include directory
1437 KDCRAW_LIBRARIES - Link these to use libkdcraw
1438 KDCRAW_DEFINITIONS - Compiler switches required for using libkdcraw
1439
1440
1441
1442
1443
1444 FindKdeMultimedia
1445
1446
1447 Module to see if we have KDE4 kdemultimedia installed
1448
1449
1450 This module defines
1451
1452
1453 KDEMULTIMEDIA_INCLUDE_DIR - the include dir
1454 KCDDB_LIBRARY - the kcddb library
1455 KCOMPACTDISC_LIBRARY - the kcompactdisk library
1456 KDEMULTIMEDIA_LIBRARIES - all of the KDE multimedia libraries together
1457 KDEMULTIMEDIA_FOUND - true if the above have been found
1458
1459
1460 FindKdepim
1461
1462
1463 Nothing should require kdepim. We'll show a fatal error and an
1464 explanation.
1465
1466
1467 FindKdepimLibs
1468
1469
1470 Find if we installed kdepimlibs before to compile it Once done
1471 this will define
1472
1473
1474 KDEPIMLIBS_FOUND - system has KDE PIM Libraries
1475 KDEPIMLIBS_INCLUDE_DIR - the KDE PIM Libraries include directory
1476 KDEPIMLIBS_INCLUDE_DIRS - the KDE PIM Libraries include directory and CamelCase headers
1477
1478
1479
1480
1481 It also sets variables for the following libraries:
1482
1483
1484 KDEPIMLIBS_AKONADI_LIBS
1485 KDEPIMLIBS_AKONADI_CONTACT_LIBS
1486 KDEPIMLIBS_AKONADI_KABC_LIBS
1487 KDEPIMLIBS_AKONADI_KMIME_LIBS
1488 KDEPIMLIBS_GPGMEPP_LIBS
1489 KDEPIMLIBS_KABC_LIBS
1490 KDEPIMLIBS_KBLOG_LIBS
1491 KDEPIMLIBS_KCAL_LIBS
1492 KDEPIMLIBS_KCALCORE_LIBS
1493 KDEPIMLIBS_KCALUTILS_LIBS
1494 KDEPIMLIBS_KHOLIDAYS_LIBS
1495 KDEPIMLIBS_KIMAP_LIBS
1496 KDEPIMLIBS_KLDAP_LIBS
1497 KDEPIMLIBS_KMIME_LIBS
1498 KDEPIMLIBS_KONTACTINTERFACE_LIBS
1499 KDEPIMLIBS_KPIMIDENTITIES_LIBS
1500 KDEPIMLIBS_KPIMTEXTEDIT_LIBS
1501 KDEPIMLIBS_KPIMUTILS_LIBS
1502 KDEPIMLIBS_KRESOURCES_LIBS
1503 KDEPIMLIBS_KTNEF_LIBS
1504 KDEPIMLIBS_KXMLRPCCLIENT_LIBS
1505 KDEPIMLIBS_MAILTRANSPORT_LIBS
1506 KDEPIMLIBS_MICROBLOG_LIBS
1507 KDEPIMLIBS_QGPGME_LIBS
1508 KDEPIMLIBS_SYNDICATION_LIBS
1509
1510
1511
1512
1513 And the following locations:
1514
1515
1516 KDEPIMLIBS_DATA_DIR
1517 KDEPIMLIBS_DBUS_INTERFACES_DIR
1518 KDEPIMLIBS_DBUS_SERVICES_DIR
1519 KDEPIMLIBS_INCLUDE_DIR
1520 KDEPIMLIBS_INCLUDE_DIRS
1521 KDEPIMLIBS_LIB_DIR
1522 KDEPIMLIBS_BIN_DIR
1523 KDEPIMLIBS_LIBEXEC_DIR
1524 KDEPIMLIBS_SBIN_DIR
1525 KDEPIMLIBS_HTML_DIR
1526 KDEPIMLIBS_CONFIG_DIR
1527 KDEPIMLIBS_ICON_DIR
1528 KDEPIMLIBS_KCFG_DIR
1529 KDEPIMLIBS_LOCALE_DIR
1530 KDEPIMLIBS_MIME_DIR
1531 KDEPIMLIBS_SOUND_DIR
1532 KDEPIMLIBS_TEMPLATES_DIR
1533 KDEPIMLIBS_KCONF_UPDATE_DIR
1534 KDEPIMLIBS_AUTOSTART_DIR
1535 KDEPIMLIBS_XDG_APPS_DIR
1536 KDEPIMLIBS_XDG_DIRECTORY_DIR
1537 KDEPIMLIBS_SYSCONF_DIR
1538 KDEPIMLIBS_MAN_DIR
1539 KDEPIMLIBS_INFO_DIR
1540 KDEPIMLIBS_SERVICES_DIR
1541 KDEPIMLIBS_SERVICETYPES_DIR
1542
1543
1544 FindKexiv2
1545 Try to find the KExiv2 library
1546
1547 Once done this will define
1548
1549
1550 KEXIV2_FOUND - system has libkexiv2
1551 KEXIV2_INCLUDE_DIR - the libkexiv2 include directory
1552 KEXIV2_LIBRARIES - Link these to use libkexiv2
1553 KEXIV2_DEFINITIONS - Compiler switches required for using libkexiv2
1554
1555
1556
1557
1558
1559 FindKipi
1560 Try to find the Kipi library
1561
1562 Once done this will define
1563
1564
1565 KIPI_FOUND - system has libkipi
1566 KIPI_INCLUDE_DIR - the libkipi include directory
1567 KIPI_LIBRARIES - Link these to use libkipi
1568 KIPI_DEFINITIONS - Compiler switches required for using libkipi
1569
1570
1571
1572
1573
1574 FindKonto
1575
1576
1577 Once done this will define
1578
1579
1580 KONTO_FOUND - system has the Nepomuk-KDE backbone lib Konto
1581 KONTO_INCLUDES - the libKonto include directory
1582 KONTO_LIBRARIES - Link these to use libKonto
1583
1584
1585
1586
1587
1588 FindKopete
1589 Try to find the Kopete library
1590
1591 Once done this will define
1592
1593
1594 Kopete_FOUND - system has kopete
1595 KOPETE_INCLUDE_DIR - the kopete include directory
1596 KOPETE_LIBRARIES - Link these to use kopete
1597
1598
1599 FindKorundum
1600 Find Korundum - the KDE Ruby bindings
1601
1602
1603
1604
1605 This module finds if Korundum is installed. It defines the fol‐
1606 lowing variables:
1607
1608
1609 KORUNDUM_PATH - the path to the korundum ruby file
1610 KORUNDUM_FOUND - true if it has been found
1611
1612
1613 FindLCMS
1614 Find LCMS
1615
1616 Find the LCMS (Little Color Management System) library and
1617 includes and This module defines
1618
1619
1620 LCMS_INCLUDE_DIR, where to find lcms.h
1621 LCMS_LIBRARIES, the libraries needed to use LCMS.
1622 LCMS_DOT_VERSION, The version number of the LCMS library, e.g. "1.19"
1623 LCMS_VERSION, Similar to LCMS_DOT_VERSION, but without the dots, e.g. "119"
1624 LCMS_FOUND, If false, do not try to use LCMS.
1625
1626
1627
1628
1629 The minimum required version of LCMS can be specified using the
1630 standard syntax, e.g. find_package(LCMS 1.10)
1631
1632
1633 FindLibArt
1634 Try to find the LibArt 2D graphics library
1635
1636 Once done this will define
1637
1638
1639 LIBART_FOUND - system has the LibArt
1640 LIBART_INCLUDE_DIR - the LibArt include directory
1641 LIBART_LIBRARIES - The libraries needed to use LibArt
1642
1643
1644 FindLibAttica
1645
1646
1647 Try to find the Attica library Once done this will define
1648
1649
1650 LIBATTICA_FOUND Indicates that Attica was found
1651 LIBATTICA_LIBRARIES Libraries needed to use Attica
1652 LIBATTICA_LIBRARY_DIRS Paths needed for linking against Attica
1653 LIBATTICA_INCLUDE_DIR Path needed for finding Attica include files
1654
1655
1656
1657
1658 The minimum required version of LibAttica can be specified using
1659 the standard syntax, e.g. find_package(LibAttica 0.20)
1660
1661
1662 FindLibKonq
1663 Try to find konqueror library
1664
1665 Once done this will define
1666
1667
1668 LIBKONQ_FOUND - system has libkonq library
1669 LIBKONQ_INCLUDE_DIR - the LIBKONQ include directory
1670 LIBKONQ_LIBRARY - the libkonq library
1671
1672
1673 FindLibLZMA
1674 Find LibLZMA
1675
1676 Find LibLZMA headers and library
1677
1678
1679 LIBLZMA_FOUND - True if liblzma is found.
1680 LIBLZMA_INCLUDE_DIRS - Directory where liblzma headers are located.
1681 LIBLZMA_LIBRARIES - Lzma libraries to link against.
1682 LIBLZMA_HAS_AUTO_DECODER - True if lzma_auto_decoder() is found (required).
1683 LIBLZMA_HAS_EASY_ENCODER - True if lzma_easy_encoder() is found (required).
1684 LIBLZMA_HAS_LZMA_PRESET - True if lzma_lzma_preset() is found (required).
1685
1686
1687 FindLibXml2
1688 Try to find LibXml2
1689
1690 Once done this will define
1691
1692
1693 LIBXML2_FOUND - System has LibXml2
1694 LIBXML2_INCLUDE_DIR - The LibXml2 include directory
1695 LIBXML2_LIBRARIES - The libraries needed to use LibXml2
1696 LIBXML2_DEFINITIONS - Compiler switches required for using LibXml2
1697 LIBXML2_XMLLINT_EXECUTABLE - The XML checking tool xmllint coming with LibXml2
1698
1699
1700 FindLibXslt
1701 Try to find LibXslt
1702
1703 Once done this will define
1704
1705
1706 LIBXSLT_FOUND - system has LibXslt
1707 LIBXSLT_INCLUDE_DIR - the LibXslt include directory
1708 LIBXSLT_LIBRARIES - Link these to LibXslt
1709 LIBXSLT_DEFINITIONS - Compiler switches required for using LibXslt
1710 LIBXSLT_XSLTPROC_EXECUTABLE - path to the xsltproc tool
1711
1712
1713 FindLibintl
1714
1715
1716 Try to find Libintl functionality Once done this will define
1717
1718
1719 LIBINTL_FOUND - system has Libintl
1720 LIBINTL_INCLUDE_DIR - Libintl include directory
1721 LIBINTL_LIBRARIES - Libraries needed to use Libintl
1722
1723
1724
1725
1726 TODO: This will enable translations only if Gettext functional‐
1727 ity is present in libc. Must have more robust system for
1728 release, where Gettext functionality can also reside in stand‐
1729 alone Gettext library, or the one embedded within kdelibs (cf.
1730 gettext.m4 from Gettext source).
1731
1732
1733 FindLibraryWithDebug
1734
1735
1736
1737
1738
1739 FIND_LIBRARY_WITH_DEBUG
1740 -> enhanced FIND_LIBRARY to allow the search for an
1741 optional debug library with a WIN32_DEBUG_POSTFIX similar
1742 to CMAKE_DEBUG_POSTFIX when creating a shared lib
1743 it has to be the second and third argument
1744
1745
1746 FindLinuxWirelesstools
1747 Try to find wireless extensions support libraries
1748
1749 Once done this will define
1750
1751
1752 IW_FOUND - system has IW
1753 IW_INCLUDE_DIR - the IW include directory
1754 IW_LIBRARIES - Link to these to use IW
1755
1756
1757 FindMsgfmt
1758 Try to find msgfmt
1759
1760 Once done this will define
1761
1762
1763 MSGFMT_FOUND - system has msgfmt
1764
1765
1766 FindMusicBrainz
1767
1768
1769 Module to find the musicbrainz library
1770
1771
1772 It defines
1773
1774
1775 MUSICBRAINZ_INCLUDE_DIR - the include dir
1776 MUSICBRAINZ_LIBRARIES - the required libraries
1777 MUSICBRAINZ_FOUND - true if both of the above have been found
1778
1779
1780 FindMySQL
1781 Try to find MySQL / MySQL Embedded library
1782
1783 Find the MySQL includes and client library This module defines
1784
1785
1786 MYSQL_INCLUDE_DIR, where to find mysql.h
1787 MYSQL_LIBRARIES, the libraries needed to use MySQL.
1788 MYSQL_LIB_DIR, path to the MYSQL_LIBRARIES
1789 MYSQL_EMBEDDED_LIBRARIES, the libraries needed to use MySQL Embedded.
1790 MYSQL_EMBEDDED_LIB_DIR, path to the MYSQL_EMBEDDED_LIBRARIES
1791 MYSQL_FOUND, If false, do not try to use MySQL.
1792 MYSQL_EMBEDDED_FOUND, If false, do not try to use MySQL Embedded.
1793
1794
1795 FindNepomuk
1796
1797
1798 Once done this will define
1799
1800
1801 NEPOMUK_FOUND - system has Nepomuk
1802 NEPOMUK_INCLUDE_DIR - the Nepomuk include directory
1803 NEPOMUK_LIBRARIES - Link these to use Nepomuk
1804 NEPOMUK_QUERY_LIBRARIES - Link these to use Nepomuk query
1805 NEPOMUK_UTILS_LIBRARIES - Link these to use Nepomuk utils
1806 NEPOMUK_DEFINITIONS - Compiler switches required for using Nepomuk
1807
1808
1809
1810
1811 Nepomuk requires Soprano, so this module checks for Soprano too.
1812
1813
1814
1815 FindNetworkManager
1816 Try to find NetworkManager
1817
1818 Once done this will define
1819
1820
1821 NETWORKMANAGER_FOUND - system has NetworkManager
1822 NETWORKMANAGER_INCLUDE_DIRS - the NetworkManager include directories
1823 NETWORKMANAGER_LIBRARIES - the libraries needed to use NetworkManager
1824 NETWORKMANAGER_CFLAGS - Compiler switches required for using NetworkManager
1825 NETWORKMANAGER_VERSION - version number of NetworkManager
1826
1827
1828 FindOggVorbis
1829 Try to find the OggVorbis libraries
1830
1831 Once done this will define
1832
1833
1834 OGGVORBIS_FOUND - system has OggVorbis
1835 OGGVORBIS_VERSION - set either to 1 or 2
1836 OGGVORBIS_INCLUDE_DIR - the OggVorbis include directory
1837 OGGVORBIS_LIBRARIES - The libraries needed to use OggVorbis
1838 OGG_LIBRARY - The Ogg library
1839 VORBIS_LIBRARY - The Vorbis library
1840 VORBISFILE_LIBRARY - The VorbisFile library
1841 VORBISENC_LIBRARY - The VorbisEnc library
1842
1843
1844 FindOpenEXR
1845
1846
1847 Try to find the OpenEXR libraries This check defines:
1848
1849
1850 OPENEXR_FOUND - system has OpenEXR
1851 OPENEXR_INCLUDE_DIR - OpenEXR include directory
1852 OPENEXR_LIBRARIES - Libraries needed to use OpenEXR
1853 OPENEXR_DEFINITIONS - definitions required to use OpenEXR
1854
1855
1856 FindOpenSSL
1857 Try to find the OpenSSL encryption library
1858
1859 Once done this will define
1860
1861
1862 OPENSSL_FOUND - system has the OpenSSL library
1863 OPENSSL_INCLUDE_DIR - the OpenSSL include directory
1864 OPENSSL_LIBRARIES - The libraries needed to use OpenSSL
1865 OPENSSL_EAY_LIBRARIES - The additional libraries needed to use OpenSSL on windows
1866
1867
1868 FindPCRE
1869 Try to find the PCRE regular expression library
1870
1871 Once done this will define
1872
1873
1874 PCRE_FOUND - system has the PCRE library
1875 PCRE_INCLUDE_DIR - the PCRE include directory
1876 PCRE_LIBRARIES - The libraries needed to use PCRE
1877
1878
1879 FindPackageHandleStandardArgs
1880
1881
1882 FIND_PACKAGE_HANDLE_STANDARD_ARGS(<name> ... )
1883
1884
1885 This function is intended to be used in FindXXX.cmake modules
1886 files. It handles the REQUIRED, QUIET and version-related argu‐
1887 ments to FIND_PACKAGE(). It also sets the <UPPER‐
1888 CASED_NAME>_FOUND variable. The package is considered found if
1889 all variables <var1>... listed contain valid results, e.g. valid
1890 filepaths.
1891
1892
1893 There are two modes of this function. The first argument in both
1894 modes is the name of the Find-module where it is called (in
1895 original casing).
1896
1897
1898 The first simple mode looks like this:
1899
1900
1901 FIND_PACKAGE_HANDLE_STANDARD_ARGS(<name> (DEFAULT_MSG|"Custom failure message") <var1>...<varN> )
1902
1903 If the variables <var1> to <varN> are all valid, then <UPPER‐
1904 CASED_NAME>_FOUND will be set to TRUE. If DEFAULT_MSG is given
1905 as second argument, then the function will generate itself use‐
1906 ful success and error messages. You can also supply a custom
1907 error message for the failure case. This is not recommended.
1908
1909
1910 The second mode is more powerful and also supports version
1911 checking:
1912
1913
1914 FIND_PACKAGE_HANDLE_STANDARD_ARGS(NAME [REQUIRED_VARS <var1>...<varN>]
1915 [VERSION_VAR <versionvar>
1916 [FAIL_MESSAGE "Custom failure message"] )
1917
1918
1919
1920
1921 As above, if <var1> through <varN> are all valid, <UPPER‐
1922 CASED_NAME>_FOUND will be set to TRUE. Via FAIL_MESSAGE a custom
1923 failure message can be specified, if this is not used, the
1924 default message will be displayed. Following VERSION_VAR the
1925 name of the variable can be specified which holds the version of
1926 the package which has been found. If this is done, this version
1927 will be checked against the (potentially) specified required
1928 version used in the find_package() call. The EXACT keyword is
1929 also handled. The default messages include information about the
1930 required version and the version which has been actually found,
1931 both if the version is ok or not.
1932
1933
1934 Example for mode 1:
1935
1936
1937 FIND_PACKAGE_HANDLE_STANDARD_ARGS(LibXml2 DEFAULT_MSG LIBXML2_LIBRARY LIBXML2_INCLUDE_DIR)
1938
1939
1940
1941
1942 LibXml2 is considered to be found, if both LIBXML2_LIBRARY and
1943 LIBXML2_INCLUDE_DIR are valid. Then also LIBXML2_FOUND is set to
1944 TRUE. If it is not found and REQUIRED was used, it fails with
1945 FATAL_ERROR, independent whether QUIET was used or not. If it is
1946 found, success will be reported, including the content of
1947 <var1>. On repeated Cmake runs, the same message won't be
1948 printed again.
1949
1950
1951 Example for mode 2:
1952
1953
1954 FIND_PACKAGE_HANDLE_STANDARD_ARGS(BISON REQUIRED_VARS BISON_EXECUTABLE
1955 VERSION_VAR BISON_VERSION)
1956
1957 In this case, BISON is considered to be found if the variable(s)
1958 listed after REQUIRED_VAR are all valid, i.e. BISON_EXECUTABLE
1959 in this case. Also the version of BISON will be checked by using
1960 the version contained in BISON_VERSION. Since no FAIL_MESSAGE is
1961 given, the default messages will be printed.
1962
1963
1964 FindPhonon
1965
1966
1967 Find libphonon Once done this will define
1968
1969
1970 PHONON_FOUND - system has Phonon Library
1971 PHONON_INCLUDES - the Phonon include directory
1972 PHONON_LIBS - link these to use Phonon
1973 PHONON_VERSION - the version of the Phonon Library
1974
1975
1976 FindPkgConfig
1977 a pkg-config module for CMake
1978
1979
1980
1981
1982 Usage:
1983
1984
1985 pkg_check_modules(<PREFIX> [REQUIRED] [QUIET] <MODULE> [<MODULE>]*)
1986 checks for all the given modules
1987
1988
1989
1990
1991 pkg_search_module(<PREFIX> [REQUIRED] [QUIET] <MODULE> [<MODULE>]*)
1992 checks for given modules and uses the first working one
1993
1994
1995
1996
1997 When the 'REQUIRED' argument was set, macros will fail with an
1998 error when module(s) could not be found
1999
2000
2001 When the 'QUIET' argument is set, no status messages will be
2002 printed.
2003
2004
2005 It sets the following variables:
2006
2007
2008 PKG_CONFIG_FOUND ... true if pkg-config works on the system
2009 PKG_CONFIG_EXECUTABLE ... pathname of the pkg-config program
2010 <PREFIX>_FOUND ... set to 1 if module(s) exist
2011
2012
2013
2014
2015 For the following variables two sets of values exist; first one
2016 is the common one and has the given PREFIX. The second set con‐
2017 tains flags which are given out when pkgconfig was called with
2018 the '--static' option.
2019
2020
2021 <XPREFIX>_LIBRARIES ... only the libraries (w/o the '-l')
2022 <XPREFIX>_LIBRARY_DIRS ... the paths of the libraries (w/o the '-L')
2023 <XPREFIX>_LDFLAGS ... all required linker flags
2024 <XPREFIX>_LDFLAGS_OTHER ... all other linker flags
2025 <XPREFIX>_INCLUDE_DIRS ... the '-I' preprocessor flags (w/o the '-I')
2026 <XPREFIX>_CFLAGS ... all required cflags
2027 <XPREFIX>_CFLAGS_OTHER ... the other compiler flags
2028
2029
2030
2031
2032 <XPREFIX> = <PREFIX> for common case
2033 <XPREFIX> = <PREFIX>_STATIC for static linking
2034
2035
2036
2037
2038 There are some special variables whose prefix depends on the
2039 count of given modules. When there is only one module, <PREFIX>
2040 stays unchanged. When there are multiple modules, the prefix
2041 will be changed to <PREFIX>_<MODNAME>:
2042
2043
2044 <XPREFIX>_VERSION ... version of the module
2045 <XPREFIX>_PREFIX ... prefix-directory of the module
2046 <XPREFIX>_INCLUDEDIR ... include-dir of the module
2047 <XPREFIX>_LIBDIR ... lib-dir of the module
2048
2049
2050
2051
2052 <XPREFIX> = <PREFIX> when |MODULES| == 1, else
2053 <XPREFIX> = <PREFIX>_<MODNAME>
2054
2055
2056
2057
2058 A <MODULE> parameter can have the following formats:
2059
2060
2061 {MODNAME} ... matches any version
2062 {MODNAME}>={VERSION} ... at least version <VERSION> is required
2063 {MODNAME}={VERSION} ... exactly version <VERSION> is required
2064 {MODNAME}<={VERSION} ... modules must not be newer than <VERSION>
2065
2066
2067
2068
2069 Examples
2070
2071
2072 pkg_check_modules (GLIB2 glib-2.0)
2073
2074
2075
2076
2077 pkg_check_modules (GLIB2 glib-2.0>=2.10)
2078 requires at least version 2.10 of glib2 and defines e.g.
2079 GLIB2_VERSION=2.10.3
2080
2081
2082
2083
2084 pkg_check_modules (FOO glib-2.0>=2.10 gtk+-2.0)
2085 requires both glib2 and gtk2, and defines e.g.
2086 FOO_glib-2.0_VERSION=2.10.3
2087 FOO_gtk+-2.0_VERSION=2.8.20
2088
2089
2090
2091
2092 pkg_check_modules (XRENDER REQUIRED xrender)
2093 defines e.g.:
2094 XRENDER_LIBRARIES=Xrender;X11
2095 XRENDER_STATIC_LIBRARIES=Xrender;X11;pthread;Xau;Xdmcp
2096
2097
2098
2099
2100 pkg_search_module (BAR libxml-2.0 libxml2 libxml>=2)
2101
2102
2103 FindPolkitQt-1
2104 Try to find PolkitQt-1
2105
2106 Once done this will define
2107
2108
2109 POLKITQT-1_FOUND - system has Polkit-qt
2110 POLKITQT-1_INCLUDE_DIR - the Polkit-qt include directory
2111 POLKITQT-1_LIBRARIES - Link these to use all Polkit-qt libs
2112 POLKITQT-1_CORE_LIBRARY - Link this to use the polkit-qt-core library only
2113 POLKITQT-1_GUI_LIBRARY - Link this to use GUI elements in polkit-qt (polkit-qt-gui)
2114 POLKITQT-1_AGENT_LIBRARY - Link this to use the agent wrapper in polkit-qt
2115 POLKITQT-1_DEFINITIONS - Compiler switches required for using Polkit-qt
2116
2117
2118
2119
2120 The minimum required version of PolkitQt-1 can be specified
2121 using the standard syntax, e.g. find_package(PolkitQt-1 1.0)
2122
2123
2124 FindPolkitQt
2125 Try to find Polkit-qt
2126
2127 Once done this will define
2128
2129
2130 POLKITQT_FOUND - system has Polkit-qt
2131 POLKITQT_INCLUDE_DIR - the Polkit-qt include directory
2132 POLKITQT_LIBRARIES - Link these to use all Polkit-qt libs
2133 POLKITQT_CORE_LIBRARY - Link this to use the polkit-qt-core library only
2134 POLKITQT_GUI_LIBRARY - Link this to use GUI elements in polkit-qt (polkit-qt-gui)
2135 POLKITQT_DEFINITIONS - Compiler switches required for using Polkit-qt
2136 POLKITQT_POLICY_FILES_INSTALL_DIR - The directory where policy files should be installed to.
2137
2138
2139
2140
2141 The minimum required version of PolkitQt can be specified using
2142 the standard syntax, e.g. find_package(PolkitQt 1.0) For compat‐
2143 iblity, this can also be done by setting the POLKITQT_MIN_VER‐
2144 SION variable.
2145
2146
2147 FindPopplerQt4
2148 Try to find the Qt4 binding of the Poppler library
2149
2150 Once done this will define
2151
2152
2153 POPPLER_QT4_FOUND - system has poppler-qt4
2154 POPPLER_QT4_INCLUDE_DIR - the poppler-qt4 include directory
2155 POPPLER_QT4_LIBRARIES - Link these to use poppler-qt4
2156 POPPLER_QT4_DEFINITIONS - Compiler switches required for using poppler-qt4
2157
2158
2159
2160
2161
2162 FindPostgreSQL
2163 Find PostgreSQL
2164
2165 Find the PostgreSQL includes and client library This module
2166 defines
2167
2168
2169 POSTGRESQL_INCLUDE_DIR, where to find POSTGRESQL.h
2170 POSTGRESQL_LIBRARIES, the libraries needed to use POSTGRESQL.
2171 POSTGRESQL_FOUND, If false, do not try to use PostgreSQL.
2172
2173
2174 FindPulseAudio
2175
2176
2177 Try to find the PulseAudio library
2178
2179
2180 Once done this will define:
2181
2182
2183 PULSEAUDIO_FOUND - system has the PulseAudio library
2184 PULSEAUDIO_INCLUDE_DIR - the PulseAudio include directory
2185 PULSEAUDIO_LIBRARY - the libraries needed to use PulseAudio
2186 PULSEAUDIO_MAINLOOP_LIBRARY - the libraries needed to use PulsAudio Mainloop
2187
2188
2189
2190
2191 The minimum required version of PulseAudio can be specified
2192 using the standard syntax, e.g. find_package(PulseAudio 1.0)
2193
2194
2195 FindPyKDE4
2196
2197
2198 FindPyKDE4
2199
2200
2201 Checks that Python and PyKDE4 are installed and defines a couple
2202 macros:
2203
2204
2205 * PYKDE4_INSTALL_PYTHON_FILES
2206 * PYKDE4_ADD_UI_FILES
2207 * PYKDE4_ADD_EXECUTABLE
2208
2209
2210 FindPyQt4
2211
2212
2213 Find PyQt4 ~~~~~~~~~~ Copyright (c) 2007-2008, Simon Edwards
2214 <simon@simonzone.com> Redistribution and use is allowed accord‐
2215 ing to the terms of the BSD license. For details see the accom‐
2216 panying COPYING-CMAKE-SCRIPTS file.
2217
2218
2219 PyQt4 website: http://www.riverbankcomput‐
2220 ing.co.uk/pyqt/index.php
2221
2222
2223 Find the installed version of PyQt4. FindPyQt4 should only be
2224 called after Python has been found.
2225
2226
2227 This file defines the following variables:
2228
2229
2230 PYQT4_VERSION - The version of PyQt4 found expressed as a 6
2231 digit hex number
2232
2233
2234 suitable for comparision as a string
2235
2236
2237
2238
2239 PYQT4_VERSION_STR - The version of PyQt4 as a human readable
2240 string.
2241
2242
2243 PYQT4_VERSION_TAG - The PyQt version tag using by PyQt's sip
2244 files.
2245
2246
2247 PYQT4_SIP_DIR - The directory holding the PyQt4 .sip files.
2248
2249
2250 PYQT4_SIP_FLAGS - The SIP flags used to build PyQt.
2251
2252
2253 FindPythonLibrary
2254
2255
2256 Find Python ~~~~~~~~~~~ Find the Python interpreter and related
2257 Python directories.
2258
2259
2260 This file defines the following variables:
2261
2262
2263 PYTHON_EXECUTABLE - The path and filename of the Python inter‐
2264 preter.
2265
2266
2267 PYTHON_SHORT_VERSION - The version of the Python interpreter
2268 found,
2269
2270
2271 excluding the patch version number. (e.g. 2.5 and not 2.5.1))
2272
2273
2274
2275
2276 PYTHON_LONG_VERSION - The version of the Python interpreter
2277 found as a human
2278
2279
2280 readable string.
2281
2282
2283
2284
2285 PYTHON_SITE_PACKAGES_INSTALL_DIR - this cache variable can be
2286 used for installing
2287
2288
2289 own python modules. You may want to adjust this to be the
2290 same as ${PYTHON_SITE_PACKAGES_DIR}, but then admin
2291 privileges may be required for installation.
2292
2293
2294
2295
2296 PYTHON_SITE_PACKAGES_DIR - Location of the Python site-packages
2297 directory.
2298
2299
2300 PYTHON_INCLUDE_PATH - Directory holding the python.h include
2301 file.
2302
2303
2304 PYTHON_LIBRARY, PYTHON_LIBRARIES- Location of the Python
2305 library.
2306
2307
2308 FindQCA2
2309 Try to find QCA2 (Qt Cryptography Architecture 2)
2310
2311 Once done this will define
2312
2313
2314 QCA2_FOUND - system has QCA2
2315 QCA2_INCLUDE_DIR - the QCA2 include directory
2316 QCA2_LIBRARIES - the libraries needed to use QCA2
2317 QCA2_DEFINITIONS - Compiler switches required for using QCA2
2318
2319
2320
2321
2322 use pkg-config to get the directories and then use these values
2323 in the FIND_PATH() and FIND_LIBRARY() calls
2324
2325
2326 FindQImageBlitz
2327 Try to find the qimageblitz lib
2328
2329 Once done this will define
2330
2331
2332 QIMAGEBLITZ_FOUND - system has qimageblitz lib
2333 QIMAGEBLITZ_INCLUDES - the qimageblitz include directory
2334 QIMAGEBLITZ_LIBRARIES - The libraries needed to use qimageblitz
2335
2336
2337 FindQt4
2338 Find QT 4
2339
2340 This module can be used to find Qt4. The most important issue is
2341 that the Qt4 qmake is available via the system path. This qmake
2342 is then used to detect basically everything else. This module
2343 defines a number of key variables and macros. The variable
2344 QT_USE_FILE is set which is the path to a CMake file that can be
2345 included to compile Qt 4 applications and libraries. It sets
2346 up the compilation environment for include directories, pre‐
2347 processor defines and populates a QT_LIBRARIES variable.
2348
2349
2350 Typical usage could be something like:
2351
2352
2353 find_package(Qt4 4.4.3 COMPONENTS QtCore QtGui QtXml REQUIRED )
2354 include(${QT_USE_FILE})
2355 add_executable(myexe main.cpp)
2356 target_link_libraries(myexe ${QT_LIBRARIES})
2357
2358
2359
2360
2361 The minimum required version can be specified using the standard
2362 find_package()-syntax (see example above). For compatibility
2363 with older versions of FindQt4.cmake it is also possible to set
2364 the variable QT_MIN_VERSION to the minimum required version of
2365 Qt4 before the find_package(Qt4) command. If both are used,
2366 the version used in the find_package() command overrides the one
2367 from QT_MIN_VERSION.
2368
2369
2370 When using the components argument, QT_USE_QT* variables are
2371 automatically set for the QT_USE_FILE to pick up. If one wishes
2372 to manually set them, the available ones to set include:
2373
2374
2375 QT_DONT_USE_QTCORE
2376 QT_DONT_USE_QTGUI
2377 QT_USE_QT3SUPPORT
2378 QT_USE_QTASSISTANT
2379 QT_USE_QAXCONTAINER
2380 QT_USE_QAXSERVER
2381 QT_USE_QTDESIGNER
2382 QT_USE_QTMOTIF
2383 QT_USE_QTMAIN
2384 QT_USE_QTMULTIMEDIA
2385 QT_USE_QTNETWORK
2386 QT_USE_QTNSPLUGIN
2387 QT_USE_QTOPENGL
2388 QT_USE_QTSQL
2389 QT_USE_QTXML
2390 QT_USE_QTSVG
2391 QT_USE_QTTEST
2392 QT_USE_QTUITOOLS
2393 QT_USE_QTDBUS
2394 QT_USE_QTSCRIPT
2395 QT_USE_QTASSISTANTCLIENT
2396 QT_USE_QTHELP
2397 QT_USE_QTWEBKIT
2398 QT_USE_QTXMLPATTERNS
2399 QT_USE_PHONON
2400 QT_USE_QTSCRIPTTOOLS
2401 QT_USE_QTDECLARATIVE
2402
2403
2404
2405
2406 QT_USE_IMPORTED_TARGETS
2407 If this variable is set to TRUE, FindQt4.cmake will create imported
2408 library targets for the various Qt libraries and set the
2409 library variables like QT_QTCORE_LIBRARY to point at these imported
2410 targets instead of the library file on disk. This provides much better
2411 handling of the release and debug versions of the Qt libraries and is
2412 also always backwards compatible, except for the case that dependencies
2413 of libraries are exported, these will then also list the names of the
2414 imported targets as dependency and not the file location on disk. This
2415 is much more flexible, but requires that FindQt4.cmake is executed before
2416 such an exported dependency file is processed.
2417
2418
2419
2420
2421 There are also some files that need processing by some Qt tools
2422 such as moc and uic. Listed below are macros that may be used
2423 to process those files.
2424
2425
2426
2427 macro QT4_WRAP_CPP(outfiles inputfile ... OPTIONS ...)
2428 create moc code from a list of files containing Qt class with
2429 the Q_OBJECT declaration. Per-direcotry preprocessor definitions
2430 are also added. Options may be given to moc, such as those found
2431 when executing "moc -help".
2432
2433
2434
2435
2436 macro QT4_WRAP_UI(outfiles inputfile ... OPTIONS ...)
2437 create code from a list of Qt designer ui files.
2438 Options may be given to uic, such as those found
2439 when executing "uic -help"
2440
2441
2442
2443
2444 macro QT4_ADD_RESOURCES(outfiles inputfile ... OPTIONS ...)
2445 create code from a list of Qt resource files.
2446 Options may be given to rcc, such as those found
2447 when executing "rcc -help"
2448
2449
2450
2451
2452 macro QT4_GENERATE_MOC(inputfile outputfile )
2453 creates a rule to run moc on infile and create outfile.
2454 Use this if for some reason QT4_WRAP_CPP() isn't appropriate, e.g.
2455 because you need a custom filename for the moc file or something similar.
2456
2457
2458
2459
2460 macro QT4_AUTOMOC(sourcefile1 sourcefile2 ... )
2461 This macro is still experimental.
2462 It can be used to have moc automatically handled.
2463 So if you have the files foo.h and foo.cpp, and in foo.h a
2464 a class uses the Q_OBJECT macro, moc has to run on it. If you don't
2465 want to use QT4_WRAP_CPP() (which is reliable and mature), you can insert
2466 #include "foo.moc"
2467 in foo.cpp and then give foo.cpp as argument to QT4_AUTOMOC(). This will the
2468 scan all listed files at cmake-time for such included moc files and if it finds
2469 them cause a rule to be generated to run moc at build time on the
2470 accompanying header file foo.h.
2471 If a source file has the SKIP_AUTOMOC property set it will be ignored by this macro.
2472
2473
2474
2475
2476 macro QT4_ADD_DBUS_INTERFACE(outfiles interface basename)
2477 create a the interface header and implementation files with the
2478 given basename from the given interface xml file and add it to
2479 the list of sources.
2480 To disable generating a namespace header, set the source file property
2481 NO_NAMESPACE to TRUE on the interface file.
2482 To include a header in the interface header, set the source file property
2483 INCLUDE to the name of the header.
2484 To specify a class name to use, set the source file property CLASSNAME
2485 to the name of the class.
2486
2487
2488
2489
2490 macro QT4_ADD_DBUS_INTERFACES(outfiles inputfile ... )
2491 create the interface header and implementation files
2492 for all listed interface xml files
2493 the name will be automatically determined from the name of the xml file
2494 To disable generating namespace headers, set the source file property
2495 NO_NAMESPACE to TRUE for these inputfiles.
2496 To include a header in the interface header, set the source file property
2497 INCLUDE to the name of the header.
2498 To specify a class name to use, set the source file property CLASSNAME
2499 to the name of the class.
2500
2501
2502
2503
2504 macro QT4_ADD_DBUS_ADAPTOR(outfiles xmlfile parentheader parentclassname [basename] [classname])
2505 create a dbus adaptor (header and implementation file) from the xml file
2506 describing the interface, and add it to the list of sources. The adaptor
2507 forwards the calls to a parent class, defined in parentheader and named
2508 parentclassname. The name of the generated files will be
2509 <basename>adaptor.{cpp,h} where basename defaults to the basename of the xml file.
2510 If <classname> is provided, then it will be used as the classname of the
2511 adaptor itself.
2512
2513
2514
2515
2516 macro QT4_GENERATE_DBUS_INTERFACE( header [interfacename] OPTIONS ...)
2517 generate the xml interface file from the given header.
2518 If the optional argument interfacename is omitted, the name of the
2519 interface file is constructed from the basename of the header with
2520 the suffix .xml appended.
2521 Options may be given to qdbuscpp2xml, such as those found when executing "qdbuscpp2xml --help"
2522
2523
2524
2525
2526 macro QT4_CREATE_TRANSLATION( qm_files directories ... sources ...
2527 ts_files ... OPTIONS ...)
2528 out: qm_files
2529 in: directories sources ts_files
2530 options: flags to pass to lupdate, such as -extensions to specify
2531 extensions for a directory scan.
2532 generates commands to create .ts (vie lupdate) and .qm
2533 (via lrelease) - files from directories and/or sources. The ts files are
2534 created and/or updated in the source tree (unless given with full paths).
2535 The qm files are generated in the build tree.
2536 Updating the translations can be done by adding the qm_files
2537 to the source list of your library/executable, so they are
2538 always updated, or by adding a custom target to control when
2539 they get updated/generated.
2540
2541
2542
2543
2544 macro QT4_ADD_TRANSLATION( qm_files ts_files ... )
2545 out: qm_files
2546 in: ts_files
2547 generates commands to create .qm from .ts - files. The generated
2548 filenames can be found in qm_files. The ts_files
2549 must exists and are not updated in any way.
2550
2551
2552
2553
2554
2555
2556
2557 Below is a detailed list of variables that FindQt4.cmake sets.
2558 QT_FOUND If false, don't try to use Qt.
2559 QT4_FOUND If false, don't try to use Qt 4.
2560
2561
2562
2563
2564 QT_VERSION_MAJOR The major version of Qt found.
2565 QT_VERSION_MINOR The minor version of Qt found.
2566 QT_VERSION_PATCH The patch version of Qt found.
2567
2568
2569
2570
2571 QT_EDITION Set to the edition of Qt (i.e. DesktopLight)
2572 QT_EDITION_DESKTOPLIGHT True if QT_EDITION == DesktopLight
2573 QT_QTCORE_FOUND True if QtCore was found.
2574 QT_QTGUI_FOUND True if QtGui was found.
2575 QT_QT3SUPPORT_FOUND True if Qt3Support was found.
2576 QT_QTASSISTANT_FOUND True if QtAssistant was found.
2577 QT_QTASSISTANTCLIENT_FOUND True if QtAssistantClient was found.
2578 QT_QAXCONTAINER_FOUND True if QAxContainer was found (Windows only).
2579 QT_QAXSERVER_FOUND True if QAxServer was found (Windows only).
2580 QT_QTDBUS_FOUND True if QtDBus was found.
2581 QT_QTDESIGNER_FOUND True if QtDesigner was found.
2582 QT_QTDESIGNERCOMPONENTS True if QtDesignerComponents was found.
2583 QT_QTHELP_FOUND True if QtHelp was found.
2584 QT_QTMOTIF_FOUND True if QtMotif was found.
2585 QT_QTMULTIMEDIA_FOUND True if QtMultimedia was found (since Qt 4.6.0).
2586 QT_QTNETWORK_FOUND True if QtNetwork was found.
2587 QT_QTNSPLUGIN_FOUND True if QtNsPlugin was found.
2588 QT_QTOPENGL_FOUND True if QtOpenGL was found.
2589 QT_QTSQL_FOUND True if QtSql was found.
2590 QT_QTSVG_FOUND True if QtSvg was found.
2591 QT_QTSCRIPT_FOUND True if QtScript was found.
2592 QT_QTSCRIPTTOOLS_FOUND True if QtScriptTools was found.
2593 QT_QTTEST_FOUND True if QtTest was found.
2594 QT_QTUITOOLS_FOUND True if QtUiTools was found.
2595 QT_QTWEBKIT_FOUND True if QtWebKit was found.
2596 QT_QTXML_FOUND True if QtXml was found.
2597 QT_QTXMLPATTERNS_FOUND True if QtXmlPatterns was found.
2598 QT_PHONON_FOUND True if phonon was found.
2599 QT_QTDECLARATIVE_FOUND True if QtDeclarative was found.
2600
2601
2602
2603
2604 QT_MAC_USE_COCOA For Mac OS X, its whether Cocoa or Carbon is used.
2605 In general, this should not be used, but its useful
2606 when having platform specific code.
2607
2608
2609
2610
2611 QT_DEFINITIONS Definitions to use when compiling code that uses Qt.
2612 You do not need to use this if you include QT_USE_FILE.
2613 The QT_USE_FILE will also define QT_DEBUG and QT_NO_DEBUG
2614 to fit your current build type. Those are not contained
2615 in QT_DEFINITIONS.
2616
2617 QT_INCLUDES List of paths to all include directories of
2618 Qt4 QT_INCLUDE_DIR and QT_QTCORE_INCLUDE_DIR are
2619 always in this variable even if NOTFOUND,
2620 all other INCLUDE_DIRS are
2621 only added if they are found.
2622 You do not need to use this if you include QT_USE_FILE.
2623
2624
2625
2626
2627
2628 Include directories for the Qt modules are listed here.
2629 You do not need to use these variables if you include QT_USE_FILE.
2630
2631
2632
2633
2634 QT_INCLUDE_DIR Path to "include" of Qt4
2635 QT_QT_INCLUDE_DIR Path to "include/Qt"
2636 QT_QT3SUPPORT_INCLUDE_DIR Path to "include/Qt3Support"
2637 QT_QTASSISTANT_INCLUDE_DIR Path to "include/QtAssistant"
2638 QT_QTASSISTANTCLIENT_INCLUDE_DIR Path to "include/QtAssistant"
2639 QT_QAXCONTAINER_INCLUDE_DIR Path to "include/ActiveQt" (Windows only)
2640 QT_QAXSERVER_INCLUDE_DIR Path to "include/ActiveQt" (Windows only)
2641 QT_QTCORE_INCLUDE_DIR Path to "include/QtCore"
2642 QT_QTDBUS_INCLUDE_DIR Path to "include/QtDBus"
2643 QT_QTDESIGNER_INCLUDE_DIR Path to "include/QtDesigner"
2644 QT_QTDESIGNERCOMPONENTS_INCLUDE_DIR Path to "include/QtDesigner"
2645 QT_QTGUI_INCLUDE_DIR Path to "include/QtGui"
2646 QT_QTHELP_INCLUDE_DIR Path to "include/QtHelp"
2647 QT_QTMOTIF_INCLUDE_DIR Path to "include/QtMotif"
2648 QT_QTMULTIMEDIA_INCLUDE_DIR Path to "include/QtMultimedia"
2649 QT_QTNETWORK_INCLUDE_DIR Path to "include/QtNetwork"
2650 QT_QTNSPLUGIN_INCLUDE_DIR Path to "include/QtNsPlugin"
2651 QT_QTOPENGL_INCLUDE_DIR Path to "include/QtOpenGL"
2652 QT_QTSCRIPT_INCLUDE_DIR Path to "include/QtScript"
2653 QT_QTSQL_INCLUDE_DIR Path to "include/QtSql"
2654 QT_QTSVG_INCLUDE_DIR Path to "include/QtSvg"
2655 QT_QTTEST_INCLUDE_DIR Path to "include/QtTest"
2656 QT_QTWEBKIT_INCLUDE_DIR Path to "include/QtWebKit"
2657 QT_QTXML_INCLUDE_DIR Path to "include/QtXml"
2658 QT_QTXMLPATTERNS_INCLUDE_DIR Path to "include/QtXmlPatterns"
2659 QT_PHONON_INCLUDE_DIR Path to "include/phonon"
2660 QT_QTSCRIPTTOOLS_INCLUDE_DIR Path to "include/QtScriptTools"
2661 QT_QTDECLARATIVE_INCLUDE_DIR Path to "include/QtDeclarative"
2662
2663
2664
2665
2666 QT_BINARY_DIR Path to "bin" of Qt4
2667 QT_LIBRARY_DIR Path to "lib" of Qt4
2668 QT_PLUGINS_DIR Path to "plugins" for Qt4
2669 QT_TRANSLATIONS_DIR Path to "translations" of Qt4
2670 QT_IMPORTS_DIR Path to "imports" of Qt4
2671 QT_DOC_DIR Path to "doc" of Qt4
2672 QT_MKSPECS_DIR Path to "mkspecs" of Qt4
2673
2674
2675
2676
2677
2678
2679
2680 For every library of Qt, a QT_QTFOO_LIBRARY variable is defined,
2681 with the full path to the library.
2682
2683
2684 So there are the following variables: The Qt3Support library:
2685 QT_QT3SUPPORT_LIBRARY
2686
2687
2688 The QtAssistant library: QT_QTASSISTANT_LIBRARY
2689
2690
2691 The QtAssistantClient library: QT_QTASSISTANTCLIENT_LIBRARY
2692
2693
2694 The QAxServer library: QT_QAXSERVER_LIBRARY
2695
2696
2697 The QAxContainer library: QT_QAXCONTAINER_LIBRARY
2698
2699
2700 The QtCore library: QT_QTCORE_LIBRARY
2701
2702
2703 The QtDBus library: QT_QTDBUS_LIBRARY
2704
2705
2706 The QtDesigner library: QT_QTDESIGNER_LIBRARY
2707
2708
2709 The QtDesignerComponents library: QT_QTDESIGNERCOMPO‐
2710 NENTS_LIBRARY
2711
2712
2713 The QtGui library: QT_QTGUI_LIBRARY
2714
2715
2716 The QtHelp library: QT_QTHELP_LIBRARY
2717
2718
2719 The QtMotif library: QT_QTMOTIF_LIBRARY
2720
2721
2722 The QtMultimedia library: QT_QTMULTIMEDIA_LIBRARY
2723
2724
2725 The QtNetwork library: QT_QTNETWORK_LIBRARY
2726
2727
2728 The QtNsPLugin library: QT_QTNSPLUGIN_LIBRARY
2729
2730
2731 The QtOpenGL library: QT_QTOPENGL_LIBRARY
2732
2733
2734 The QtScript library: QT_QTSCRIPT_LIBRARY
2735
2736
2737 The QtScriptTools library: QT_QTSCRIPTTOOLS_LIBRARY
2738
2739
2740 The QtSql library: QT_QTSQL_LIBRARY
2741
2742
2743 The QtSvg library: QT_QTSVG_LIBRARY
2744
2745
2746 The QtTest library: QT_QTTEST_LIBRARY
2747
2748
2749 The QtUiTools library: QT_QTUITOOLS_LIBRARY
2750
2751
2752 The QtWebKit library: QT_QTWEBKIT_LIBRARY
2753
2754
2755 The QtXml library: QT_QTXML_LIBRARY
2756
2757
2758 The QtXmlPatterns library: QT_QTXMLPATTERNS_LIBRARY
2759
2760
2761 The qtmain library for Windows QT_QTMAIN_LIBRARY
2762
2763
2764 The Phonon library: QT_PHONON_LIBRARY
2765
2766
2767
2768
2769 The QtDeclarative library: QT_QTDECLARATIVE_LIBRARY
2770
2771
2772 also defined, but NOT for general use are
2773
2774
2775 QT_MOC_EXECUTABLE Where to find the moc tool.
2776 QT_UIC_EXECUTABLE Where to find the uic tool.
2777 QT_UIC3_EXECUTABLE Where to find the uic3 tool.
2778 QT_RCC_EXECUTABLE Where to find the rcc tool
2779 QT_DBUSCPP2XML_EXECUTABLE Where to find the qdbuscpp2xml tool.
2780 QT_DBUSXML2CPP_EXECUTABLE Where to find the qdbusxml2cpp tool.
2781 QT_LUPDATE_EXECUTABLE Where to find the lupdate tool.
2782 QT_LRELEASE_EXECUTABLE Where to find the lrelease tool.
2783 QT_QCOLLECTIONGENERATOR_EXECUTABLE Where to find the qcollectiongenerator tool.
2784 QT_DESIGNER_EXECUTABLE Where to find the Qt designer tool.
2785 QT_LINGUIST_EXECUTABLE Where to find the Qt linguist tool.
2786
2787
2788
2789
2790
2791 These are around for backwards compatibility they will be set
2792
2793
2794 QT_WRAP_CPP Set true if QT_MOC_EXECUTABLE is found
2795 QT_WRAP_UI Set true if QT_UIC_EXECUTABLE is found
2796
2797
2798 These variables do _NOT_ have any effect anymore (compared to
2799 FindQt.cmake)
2800
2801
2802 QT_MT_REQUIRED Qt4 is now always multithreaded
2803
2804
2805 These variables are set to "" Because Qt structure changed
2806 (They make no sense in Qt4)
2807
2808
2809 QT_QT_LIBRARY Qt-Library is now split
2810
2811
2812 FindRUBY
2813 Find Ruby
2814
2815 This module finds if Ruby is installed and determines where the
2816 include files and libraries are. It also determines what the
2817 name of the library is. This code sets the following variables:
2818
2819
2820 RUBY_LIBRARY = full path+file to the ruby library
2821 RUBY_INCLUDE_PATH = path to where ruby.h can be found
2822 RUBY_EXECUTABLE = full path+file to the ruby binary
2823 RUBY_FOUND = Ruby was found under system.
2824
2825
2826 FindSIP
2827
2828
2829 Find SIP ~~~~~~~~
2830
2831
2832 SIP website: http://www.riverbankcomputing.co.uk/sip/index.php
2833
2834
2835 Find the installed version of SIP. FindSIP should be called
2836 after Python has been found.
2837
2838
2839 This file defines the following variables:
2840
2841
2842 SIP_VERSION - The version of SIP found expressed as a 6 digit
2843 hex number
2844
2845
2846 suitable for comparision as a string.
2847
2848
2849
2850
2851 SIP_VERSION_STR - The version of SIP found as a human readable
2852 string.
2853
2854
2855 SIP_EXECUTABLE - Path and filename of the SIP command line exe‐
2856 cutable.
2857
2858
2859 SIP_INCLUDE_DIR - Directory holding the SIP C++ header file.
2860
2861
2862 SIP_DEFAULT_SIP_DIR - Default directory where .sip files should
2863 be installed
2864
2865
2866 into.
2867
2868
2869 FindSamba
2870 Try to find the samba directory library
2871
2872 Once done this will define
2873
2874
2875 SAMBA_FOUND - system has SAMBA
2876 SAMBA_INCLUDE_DIR - the SAMBA include directory
2877 SAMBA_LIBRARIES - The libraries needed to use SAMBA
2878 Set SAMBA_REQUIRE_SMBC_SET_CONTEXT to TRUE if you need a version of Samba
2879 which comes with smbc_set_context()
2880
2881
2882 FindSane
2883
2884
2885 cmake macro to test if we use sane
2886
2887
2888 SANE_FOUND - system has SANE libs
2889 SANE_INCLUDE_DIR - the SANE include directory
2890 SANE_LIBRARIES - The libraries needed to use SANE
2891
2892
2893 FindSasl2
2894 Try to find the sasl2 directory library
2895
2896 Once done this will define
2897
2898
2899 SASL2_FOUND - system has SASL2
2900 SASL2_INCLUDE_DIR - the SASL2 include directory
2901 SASL2_LIBRARIES - The libraries needed to use SASL2
2902
2903
2904 FindSharedDesktopOntologies
2905 Try to find shared-desktop-ontologies
2906
2907 The shared-desktop-ontologies package is a direct dependancy of
2908 the Nepomuk semantic desktop system and provides all necessary
2909 ontology files like RDF, RDFS, NRL, or NIE.
2910
2911
2912 The package is created by the OSCAF project
2913 (http://oscaf.sourceforge.net).
2914
2915
2916 Once done this will define
2917
2918
2919 SHAREDDESKTOPONTOLOGIES_FOUND - system has shared-desktop-ontologies
2920 SHAREDDESKTOPONTOLOGIES_ROOT_DIR - Folder where the ontologies are stored
2921 SHAREDDESKTOPONTOLOGIES_VERSION_MAJOR - The major version number, i.e. '1' in '1.2'
2922 SHAREDDESKTOPONTOLOGIES_VERSION_MINOR - The minor version number, i.e. '2' in '1.2'
2923 SHAREDDESKTOPONTOLOGIES_VERSION - The complete version string, i.e. '1.2'
2924
2925
2926
2927
2928
2929 FindSharedMimeInfo
2930 Try to find the shared-mime-info package
2931
2932
2933
2934
2935 Once done this will define
2936
2937
2938 SHAREDMIMEINFO_FOUND - system has the shared-mime-info package
2939 UPDATE_MIME_DATABASE_EXECUTABLE - the update-mime-database executable
2940
2941
2942
2943
2944 The minimum required version of SharedMimeInfo can be specified
2945 using the standard syntax, e.g. find_package(SharedMimeInfo
2946 0.20)
2947
2948
2949 For backward compatiblity, the following two variables are also
2950 supported:
2951
2952
2953 SHARED_MIME_INFO_FOUND - same as SHAREDMIMEINFO_FOUND
2954 SHARED_MIME_INFO_MINIMUM_VERSION - set to the minimum version you need, default is 0.18.
2955 When both are used, i.e. the version is set in the find_package() call and
2956 SHARED_MIME_INFO_MINIMUM_VERSION is set, the version specified in the find_package()
2957 call takes precedence.
2958
2959
2960 FindSoprano
2961
2962
2963
2964
2965
2966 Find an installation of Soprano
2967
2968
2969 Sets the following variables:
2970
2971
2972 Soprano_FOUND, SOPRANO_FOUND - true is Soprano has been found
2973 SOPRANO_ONTO2VOCABULARYCLASS_EXECUTABLE - the onto2vocabularyclass program, required for adding ontologies
2974 SOPRANO_SOPRANOCMD_EXECUTABLE - the sopranocmd program
2975 SOPRANO_INCLUDE_DIR - The include directory
2976 SOPRANO_LIBRARIES - The Soprano core library to link to (libsoprano)
2977 SOPRANO_INDEX_LIBRARIES - The Soprano index library (libsopranoindex)
2978 SOPRANO_CLIENT_LIBRARIES - The Soprano client library (libsopranoclient)
2979 SOPRANO_SERVER_LIBRARIES - The Soprano server library (libsopranoserver)
2980 SOPRANO_VERSION - The Soprano version (string value)
2981
2982
2983
2984
2985 SOPRANO_PLUGIN_NQUADPARSER_FOUND - true if the nquadparser
2986 plugin is found SOPRANO_PLUGIN_NQUADSERIALIZER_FOUND - true if
2987 the nquadserializer plugin is found SOPRANO_PLUGIN_RAPTOR‐
2988 PARSER_FOUND - true if the raptorparser plugin is found
2989 SOPRANO_PLUGIN_RAPTORSERIALIZER_FOUND - true if the raptorseri‐
2990 alizer plugin is found SOPRANO_PLUGIN_REDLANDBACKEND_FOUND -
2991 true if the redlandbackend plugin is found SOPRANO_PLUG‐
2992 IN_SESAME2BACKEND_FOUND - true if the sesame2backend plugin is
2993 found SOPRANO_PLUGIN_VIRTUOSOBACKEND_FOUND - true if the virtu‐
2994 osobackend plugin is found
2995
2996
2997 Options:
2998
2999
3000 Set SOPRANO_MIN_VERSION to set the minimum required Soprano version (default: 1.99)
3001
3002
3003
3004
3005 FindSoprano.cmake supports the COMPONENTS keyword of find_pack‐
3006 age(). If the REQUIRED keyword is used and any of the specified
3007 components have not been found, SOPRANO_FOUND will be set to
3008 FALSE.
3009
3010
3011 The following components are supported:
3012
3013
3014 PLUGIN_NQUADPARSER
3015 PLUGIN_NQUADSERIALIZER
3016 PLUGIN_RAPTORPARSER
3017 PLUGIN_RAPTORSERIALIZER
3018 PLUGIN_REDLANDBACKEND
3019 PLUGIN_SESAME2BACKEND
3020 PLUGIN_VIRTUOSOBACKEND
3021
3022
3023 FindSqlite
3024 Try to find Sqlite
3025
3026 Once done this will define
3027
3028
3029 SQLITE_FOUND - system has Sqlite
3030 SQLITE_INCLUDE_DIR - the Sqlite include directory
3031 SQLITE_LIBRARIES - Link these to use Sqlite
3032 SQLITE_DEFINITIONS - Compiler switches required for using Sqlite
3033
3034 Redistribution and use is allowed according to the terms of the
3035 BSD license. For details see the accompanying COPY‐
3036 ING-CMAKE-SCRIPTS file.
3037
3038
3039
3040 FindStrigi
3041 Try to find Strigi, a fast and small desktop search program
3042 (http://strigi.sourceforge.net )
3043
3044 Once done this will define
3045
3046
3047 STRIGI_FOUND - system has Strigi
3048 STRIGI_INCLUDE_DIR - the Strigi include directory
3049 STRIGI_STREAMANALYZER_LIBRARY - Link these to use Strigi streamanalyzer
3050 STRIGI_STREAMS_LIBRARY - Link these to use Strigi streams
3051 STRIGI_LINE_ANALYZER_PREFIX - strigi plugin prefix
3052 STRIGI_THROUGH_ANALYZER_PREFIX - strigi plugin prefix
3053
3054
3055 FindTaglib
3056 Try to find the Taglib library
3057
3058 Once done this will define
3059
3060
3061 TAGLIB_FOUND - system has the taglib library
3062 TAGLIB_CFLAGS - the taglib cflags
3063 TAGLIB_LIBRARIES - The libraries needed to use taglib
3064
3065
3066 FindUDev
3067 Try to find UDev
3068
3069 Once done this will define
3070
3071
3072 UDEV_FOUND - system has UDev
3073 UDEV_INCLUDE_DIR - the libudev include directory
3074 UDEV_LIBS - The libudev libraries
3075
3076
3077 FindUSB
3078 Try to find the freetype library
3079
3080 Once done this defines
3081
3082
3083 LIBUSB_FOUND - system has libusb
3084 LIBUSB_INCLUDE_DIR - the libusb include directory
3085 LIBUSB_LIBRARIES - Link these to use libusb
3086
3087
3088 FindWcecompat
3089
3090
3091 Try to find Wcecompat functionality Once done this will define
3092
3093
3094 WCECOMPAT_FOUND - system has Wcecompat
3095 WCECOMPAT_INCLUDE_DIR - Wcecompat include directory
3096 WCECOMPAT_LIBRARIES - Libraries needed to use Wcecompat
3097
3098
3099
3100
3101 Copyright (c) 2010, Andreas Holzammer, <andy@kdab.com>
3102
3103
3104 Redistribution and use is allowed according to the terms of the
3105 BSD license.
3106
3107
3108 FindX11
3109 Find X11 installation
3110
3111 Try to find X11 on UNIX systems. The following values are
3112 defined
3113
3114
3115 X11_FOUND - True if X11 is available
3116 X11_INCLUDE_DIR - include directories to use X11
3117 X11_LIBRARIES - link against these to use X11
3118
3119
3120
3121
3122 and also the following more fine grained variables:
3123
3124
3125 X11_ICE_INCLUDE_PATH, X11_ICE_LIB, X11_ICE_FOUND
3126 X11_SM_INCLUDE_PATH, X11_SM_LIB, X11_SM_FOUND
3127 X11_X11_INCLUDE_PATH, X11_X11_LIB
3128 X11_Xaccessrules_INCLUDE_PATH, X11_Xaccess_FOUND
3129 X11_Xaccessstr_INCLUDE_PATH, X11_Xaccess_FOUND
3130 X11_Xau_INCLUDE_PATH, X11_Xau_LIB, X11_Xau_FOUND
3131 X11_Xcomposite_INCLUDE_PATH, X11_Xcomposite_LIB, X11_Xcomposite_FOUND
3132 X11_Xcursor_INCLUDE_PATH, X11_Xcursor_LIB, X11_Xcursor_FOUND
3133 X11_Xdamage_INCLUDE_PATH, X11_Xdamage_LIB, X11_Xdamage_FOUND
3134 X11_Xdmcp_INCLUDE_PATH, X11_Xdmcp_LIB, X11_Xdmcp_FOUND
3135 X11_Xext_LIB, X11_Xext_FOUND
3136 X11_dpms_INCLUDE_PATH, (in X11_Xext_LIB), X11_dpms_FOUND
3137 X11_XShm_INCLUDE_PATH, (in X11_Xext_LIB), X11_XShm_FOUND
3138 X11_Xshape_INCLUDE_PATH, (in X11_Xext_LIB), X11_Xshape_FOUND
3139 X11_xf86misc_INCLUDE_PATH, X11_Xxf86misc_LIB, X11_xf86misc_FOUND
3140 X11_xf86vmode_INCLUDE_PATH, X11_xf86vmode_FOUND
3141 X11_Xfixes_INCLUDE_PATH, X11_Xfixes_LIB, X11_Xfixes_FOUND
3142 X11_Xft_INCLUDE_PATH, X11_Xft_LIB, X11_Xft_FOUND
3143 X11_Xinerama_INCLUDE_PATH, X11_Xinerama_LIB, X11_Xinerama_FOUND
3144 X11_Xinput_INCLUDE_PATH, X11_Xinput_LIB, X11_Xinput_FOUND
3145 X11_Xkb_INCLUDE_PATH, X11_Xkb_FOUND
3146 X11_Xkblib_INCLUDE_PATH, X11_Xkb_FOUND
3147 X11_Xkbfile_INCLUDE_PATH, X11_Xkbfile_LIB, X11_Xkbfile_FOUND
3148 X11_Xpm_INCLUDE_PATH, X11_Xpm_LIB, X11_Xpm_FOUND
3149 X11_XTest_INCLUDE_PATH, X11_XTest_LIB, X11_XTest_FOUND
3150 X11_Xrandr_INCLUDE_PATH, X11_Xrandr_LIB, X11_Xrandr_FOUND
3151 X11_Xrender_INCLUDE_PATH, X11_Xrender_LIB, X11_Xrender_FOUND
3152 X11_Xscreensaver_INCLUDE_PATH, X11_Xscreensaver_LIB, X11_Xscreensaver_FOUND
3153 X11_Xt_INCLUDE_PATH, X11_Xt_LIB, X11_Xt_FOUND
3154 X11_Xutil_INCLUDE_PATH, X11_Xutil_FOUND
3155 X11_Xv_INCLUDE_PATH, X11_Xv_LIB, X11_Xv_FOUND
3156 X11_XSync_INCLUDE_PATH, (in X11_Xext_LIB), X11_XSync_FOUND
3157
3158
3159 FindXine
3160 Try to find the XINE library
3161
3162 Once done this will define
3163
3164
3165 XINE_FOUND - system has the XINE library
3166 XINE_VERSION - XINE version
3167 XINE_BUGFIX_VERSION - the XINE bugfix version
3168 XINE_INCLUDE_DIR - the XINE include directory
3169 XINE_LIBRARY - The libraries needed to use XINE
3170 XINE_XCB_FOUND - libxine can use XCB for video output
3171
3172
3173 FindXmms
3174
3175
3176 Search xmms Once done this will define
3177
3178
3179 XMMS_FOUND - system has xmms
3180 XMMS_INCLUDE_DIRS - the xmms include directory
3181 XMMS_LIBRARIES - Link these to use xmms
3182 XMMS_LDFLAGS - for compatibility only, same as XMMS_LIBRARIES
3183
3184
3185 KDE4Macros
3186
3187
3188 for documentation look at FindKDE4Internal.cmake
3189
3190
3191 MacroAddCompileFlags
3192 MACRO_ADD_COMPILE_FLAGS(<_target> "flags...")
3193
3194
3195 MacroAddLinkFlags
3196 MACRO_ADD_LINK_FLAGS(<_target> "flags...")
3197
3198
3199 MacroAdditionalCleanFiles
3200 MACRO_ADDITIONAL_CLEAN_FILES(files...)
3201
3202 MACRO_OPTIONAL_FIND_PACKAGE( <name> [QUIT] )
3203
3204
3205 MacroAppendIf
3206
3207
3208 MACRO_APPEND_IF(CONDITION VAR VALUE1...VALUEN ) This convenience
3209 macro appends the values VALUE1 up to VALUEN to the list given
3210 in VAR, but only if the variable CONDITION is TRUE:
3211
3212
3213 usage example: IF(SOMELIB_FOUND)
3214
3215
3216 SET(my_sources ${my_sources} somefile.c someotherfile.c)
3217
3218 ENDIF(SOMELIB_FOUND)
3219
3220
3221 becomes: MACRO_APPEND_IF(SOMELIB_FOUND my_sources somefile.c
3222 someotherfile.c)
3223
3224
3225 MacroBoolTo01
3226
3227
3228 MACRO_BOOL_TO_01( VAR RESULT0 ... RESULTN ) This macro evaluates
3229 its first argument and sets all the given vaiables either to 0
3230 or 1 depending on the value of the first one
3231
3232
3233 MacroEnsureOutOfSourceBuild
3234 MACRO_ENSURE_OUT_OF_SOURCE_BUILD(<errorMessage>)
3235
3236 MACRO_ENSURE_OUT_OF_SOURCE_BUILD(<errorMessage>)
3237
3238
3239 Call this macro in your project if you want to enforce out-of-source builds.
3240 If an in-source build is detected, it will abort with the given error message.
3241 This macro works in any of the CMakeLists.txt of your project, but the recommended
3242 location to call this is close to the beginning of the top level CMakeLists.txt
3243
3244
3245 MacroEnsureVersion
3246
3247
3248 This file defines the following macros for developers to use in
3249 ensuring that installed software is of the right version:
3250
3251
3252 MACRO_ENSURE_VERSION - test that a version number is
3253 greater than
3254
3255
3256 or equal to some minimum
3257
3258 MACRO_ENSURE_VERSION_RANGE - test that a version number is
3259 greater than
3260
3261
3262 or equal to some minimum and less than some
3263 maximum
3264
3265 MACRO_ENSURE_VERSION2 - deprecated, do not use in new code
3266
3267
3268
3269 MacroLibrary
3270 include MacroLibrary offers a collection of macros which extend
3271 the built-in cmake commands
3272
3273
3274 MacroLogFeature
3275
3276
3277 This file defines the Feature Logging macros.
3278
3279
3280 MACRO_LOG_FEATURE(VAR FEATURE DESCRIPTION URL [REQUIRED
3281 [MIN_VERSION [COMMENTS]]])
3282
3283
3284 Logs the information so that it can be displayed at the end
3285 of the configure run
3286 VAR : TRUE or FALSE, indicating whether the feature is supported
3287 FEATURE: name of the feature, e.g. "libjpeg"
3288 DESCRIPTION: description what this feature provides
3289 URL: home page
3290 REQUIRED: TRUE or FALSE, indicating whether the featue is required
3291 MIN_VERSION: minimum version number. empty string if unneeded
3292 COMMENTS: More info you may want to provide. empty string if unnecessary
3293
3294
3295
3296
3297 MACRO_DISPLAY_FEATURE_LOG()
3298
3299
3300 Call this to display the collected results.
3301 Exits CMake with a FATAL error message if a required feature is missing
3302
3303
3304
3305
3306 Example:
3307
3308
3309 INCLUDE(MacroLogFeature)
3310
3311
3312 FIND_PACKAGE(JPEG) MACRO_LOG_FEATURE(JPEG_FOUND "libjpeg" "Sup‐
3313 port JPEG images" "http://www.ijg.org" TRUE "3.2a" "") ...
3314 MACRO_DISPLAY_FEATURE_LOG()
3315
3316
3317 MacroOptionalAddSubdirectory
3318 MACRO_OPTIONAL_ADD_SUBDIRECTORY() combines ADD_SUBDIRECTORY()
3319 with an OPTION()
3320
3321 MACRO_OPTIONAL_ADD_SUBDIRECTORY( <dir> ) If you use
3322 MACRO_OPTIONAL_ADD_SUBDIRECTORY() instead of ADD_SUBDIRECTORY(),
3323 this will have two effects 1 - CMake will not complain if the
3324 directory doesn't exist
3325
3326
3327 This makes sense if you want to distribute just one of the subdirs
3328 in a source package, e.g. just one of the subdirs in kdeextragear.
3329
3330 2 - If the directory exists, it will offer an option to skip the
3331
3332
3333 subdirectory.
3334 This is useful if you want to compile only a subset of all
3335 directories.
3336
3337
3338
3339
3340 If the CMake variable DISABLE_ALL_OPTIONAL_SUBDIRECTORIES is set
3341 to TRUE for the first CMake run on the project, all optional
3342 subdirectories will be disabled by default (but can of course be
3343 enabled via the respective options). E.g. the following will
3344 disable all optional subdirectories except the one named
3345 "kcalc":
3346
3347
3348 $ cmake -DDISABLE_ALL_OPTIONAL_SUBDIRECTORIES=TRUE -DBUILD_kcalc=TRUE <srcdir>
3349
3350
3351 MacroOptionalDependPackage
3352
3353
3354 Search if cmake module is installed in computer cmake will not
3355 fail but signal that we must install depend package before. add
3356 as previously name of cmake module "_name" and define package
3357 needed "_module_needed" if return DEPEND_PACKAGE_${_name}
3358
3359
3360 MacroOptionalFindPackage
3361 MACRO_OPTIONAL_FIND_PACKAGE() combines FIND_PACKAGE() with an
3362 OPTION()
3363
3364 MACRO_OPTIONAL_FIND_PACKAGE( <name> [QUIT] ) This macro is a
3365 combination of OPTION() and FIND_PACKAGE(), it works like
3366 FIND_PACKAGE(), but additionally it automatically creates an
3367 option name WITH_<name>, which can be disabled via the cmake
3368 GUI. or via -DWITH_<name>=OFF The standard <name>_FOUND vari‐
3369 ables can be used in the same way as when using the normal
3370 FIND_PACKAGE()
3371
3372
3373 MacroPushRequiredVars
3374
3375
3376 this module defines two macros: MACRO_PUSH_REQUIRED_VARS() and
3377 MACRO_POP_REQUIRED_VARS() use these if you call cmake macros
3378 which use any of the CMAKE_REQUIRED_XXX variables
3379
3380
3381 Usage: MACRO_PUSH_REQUIRED_VARS() SET(CMAKE_REQUIRED_DEFINITIONS
3382 ${CMAKE_REQUIRED_DEFINITIONS} -DSOME_MORE_DEF) CHECK_FUNC‐
3383 TION_EXISTS(...) MACRO_POP_REQUIRED_VARS()
3384
3385
3386 MacroWriteBasicCMakeVersionFile
3387
3388
3389 MACRO_WRITE_BASIC_CMAKE_VERSION_FILE( _filename _major _minor _patch)
3390 Writes a file for use as <package>ConfigVersion.cmake file to <_filename>.
3391 See the documentation of FIND_PACKAGE() for details on this.
3392 _filename is the output filename, it should be in the build tree.
3393 _major is the major version number of the project to be installed
3394 _minor is the minor version number of the project to be installed
3395 _patch is the patch version number of the project to be installed
3396
3397
3398
3399
3400
3401 NepomukAddOntologyClasses
3402
3403
3404
3405
3406
3407 Use the Nepomuk resource class generator to generate convinient
3408 Resource subclasses from ontologies.
3409
3410
3411 Usage:
3412
3413
3414 NEPOMUK_ADD_ONTOLOGY_CLASSES(<sources-var>
3415 [FAST]
3416 [ONTOLOGIES] <onto-file1> [<onto-file2> ...]
3417 [CLASSES <class1> [<class2> ...]]
3418 [VISIBILITY <visibility-name>]
3419 )
3420
3421
3422
3423
3424 If FAST is specified the rcgen parameter --fast will be used
3425 which results in resource classes not based on Nepomuk::Resource
3426 but on a custom class which does not perform any checks and sim‐
3427 ply writes the data to Nepomuk (hence the name fast).
3428
3429
3430 The optional CLASSES parameter allows to specify the classes to
3431 be generated (RDF URIs) in case one does not want all classes in
3432 the ontologies to be generated.
3433
3434
3435 The optional VISIBILITY parameter can only be used in non-fast
3436 mode and allows to set the gcc visibility to make the generated
3437 classes usable in a publically exported API. The <visibil‐
3438 ity-name> is used to create the name of the export macro and the
3439 export include file. Thus, when using "VISIBILITY foobar"
3440 include file "foobar_export.h" needs to define FOOBAR_EXPORT.
3441
3442
3443 Copyright (c) 2009 Sebastian Trueg <trueg@kde.org>
3444
3445
3446 Redistribution and use is allowed according to the terms of the
3447 BSD license. For details see the accompanying COPY‐
3448 ING-CMAKE-SCRIPTS file.
3449
3450
3451
3452 NepomukMacros
3453
3454
3455 This file contains the following macros:
3456
3457
3458 NEPOMUK_GENERATE_FROM_ONTOLOGY Parameters:
3459
3460
3461 ontofile - Path to the NRL ontology defining the resources to be generated.
3462 targetdir - Folder to which the generated sources should be written.
3463 out_headers - Variable which will be filled with the names of all generated headers.
3464 out_sources - Variable which will be filled with the names of all generated sources.
3465 out_includes - Variable which will be filled with complete include statements of all
3466 generated resource classes.
3467
3468
3469
3470
3471 In addition to the parameters an arbitrary number of template
3472 filenames can be set as arguments
3473
3474
3475 In case of success NEPOMUK_RESOURCES_GENERATED is true, other‐
3476 wise false
3477
3478
3479 PythonMacros
3480
3481
3482 Python macros ~~~~~~~~~~~~~ Copyright (c) 2007, Simon Edwards
3483 <simon@simonzone.com>
3484
3485
3486 Redistribution and use is allowed according to the terms of the
3487 BSD license. For details see the accompanying COPY‐
3488 ING-CMAKE-SCRIPTS file.
3489
3490
3491 This file defines the following macros:
3492
3493
3494 PYTHON_INSTALL (SOURCE_FILE DESINATION_DIR)
3495
3496
3497 Install the SOURCE_FILE, which is a Python .py file, into the
3498 destination directory during install. The file will be byte compiled
3499 and both the .py file and .pyc file will be installed.
3500
3501
3502 Qt4ConfigDependentSettings
3503
3504
3505 This file is included by FindQt4.cmake, don't include it
3506 directly.
3507
3508
3509 Qt4Macros
3510
3511
3512 This file is included by FindQt4.cmake, don't include it
3513 directly.
3514
3515
3516 SIPMacros
3517
3518
3519 Macros for SIP ~~~~~~~~~~~~~~ Copyright (c) 2007, Simon Edwards
3520 <simon@simonzone.com> Redistribution and use is allowed accord‐
3521 ing to the terms of the BSD license. For details see the accom‐
3522 panying COPYING-CMAKE-SCRIPTS file.
3523
3524
3525 SIP website: http://www.riverbankcomputing.co.uk/sip/index.php
3526
3527
3528 This file defines the following macros:
3529
3530
3531 ADD_SIP_PYTHON_MODULE (MODULE_NAME MODULE_SIP [library1,
3532 libaray2, ...])
3533
3534
3535 Specifies a SIP file to be built into a Python module and installed.
3536 MODULE_NAME is the name of Python module including any path name. (e.g.
3537 os.sys, Foo.bar etc). MODULE_SIP the path and filename of the .sip file
3538 to process and compile. libraryN are libraries that the Python module,
3539 which is typically a shared library, should be linked to. The built
3540 module will also be install into Python's site-packages directory.
3541
3542
3543
3544
3545 The behaviour of the ADD_SIP_PYTHON_MODULE macro can be con‐
3546 trolled by a number of variables:
3547
3548
3549 SIP_INCLUDES - List of directories which SIP will scan through
3550 when looking
3551
3552
3553 for included .sip files. (Corresponds to the -I option for SIP.)
3554
3555
3556
3557
3558 SIP_TAGS - List of tags to define when running SIP. (Corresponds
3559 to the -t
3560
3561
3562 option for SIP.)
3563
3564
3565
3566
3567 SIP_CONCAT_PARTS - An integer which defines the number of parts
3568 the C++ code
3569
3570
3571 of each module should be split into. Defaults to 8. (Corresponds to the
3572 -j option for SIP.)
3573
3574
3575
3576
3577 SIP_DISABLE_FEATURES - List of feature names which should be
3578 disabled
3579
3580
3581 running SIP. (Corresponds to the -x option for SIP.)
3582
3583
3584
3585
3586 SIP_EXTRA_OPTIONS - Extra command line options which should be
3587 passed on to
3588
3589
3590 SIP.
3591
3592
3593 Win32Macros
3594
3595
3596 win32 macros
3597
3598
3599 ADDEXPLORERWRAPPER(project)
3600
3601
3602 Exists only under Win32 !
3603
3604
3605 addExplorerWrapper creates batch files for fast access to the
3606 build environment from the win32 explorer.
3607
3608
3609 For mingw and nmake projects it opens a command shell, for Vis‐
3610 ual Studio IDE's (at least tested with VS 8 2005) it opens the
3611 related .sln file with paths setting specified at configure
3612 time.
3613
3614
3615 create_exe_symlink
3616
3617
3618 Create an executable symlink to a Python script. This also sets
3619 the target script's permission bits.
3620
3621
3623 ccmake(1), cpack(1), ctest(1), cmakecommands(1), cmakecompat(1), cmake‐
3624 modules(1), cmakeprops(1), cmakevars(1)
3625
3626
3627 The following resources are available to get help using CMake:
3628
3629
3630 Home Page
3631 http://www.cmake.org
3632
3633 The primary starting point for learning about CMake.
3634
3635
3636 Frequently Asked Questions
3637 http://www.cmake.org/Wiki/CMake_FAQ
3638
3639 A Wiki is provided containing answers to frequently asked ques‐
3640 tions.
3641
3642
3643 Online Documentation
3644 http://www.cmake.org/HTML/Documentation.html
3645
3646 Links to available documentation may be found on this web page.
3647
3648
3649 Mailing List
3650 http://www.cmake.org/HTML/MailingLists.html
3651
3652 For help and discussion about using cmake, a mailing list is
3653 provided at cmake@cmake.org. The list is member-post-only but
3654 one may sign up on the CMake web page. Please first read the
3655 full documentation at http://www.cmake.org before posting ques‐
3656 tions to the list.
3657
3658
3659 Summary of helpful links:
3660
3661
3662 Home: http://www.cmake.org
3663 Docs: http://www.cmake.org/HTML/Documentation.html
3664 Mail: http://www.cmake.org/HTML/MailingLists.html
3665 FAQ: http://www.cmake.org/Wiki/CMake_FAQ
3666
3667
3668
3669
3670cmake 2.8.4 November 14, 2011 kdecmake(1)