summaryrefslogtreecommitdiffstats
path: root/kcontrol/ConfigureChecks.cmake
diff options
context:
space:
mode:
Diffstat (limited to 'kcontrol/ConfigureChecks.cmake')
-rw-r--r--kcontrol/ConfigureChecks.cmake87
1 files changed, 87 insertions, 0 deletions
diff --git a/kcontrol/ConfigureChecks.cmake b/kcontrol/ConfigureChecks.cmake
new file mode 100644
index 000000000..1ff4f0635
--- /dev/null
+++ b/kcontrol/ConfigureChecks.cmake
@@ -0,0 +1,87 @@
+#################################################
+#
+# (C) 2010-2011 Serghei Amelian
+# serghei (DOT) amelian (AT) gmail.com
+#
+# Improvements and feedback are welcome
+#
+# This file is released under GPL >= 2
+#
+#################################################
+
+
+##### getopt.h ##################################
+
+check_include_file( getopt.h HAVE_GETOPT_H )
+
+
+##### check for freetype2 #######################
+
+pkg_search_module( FREETYPE freetype2 )
+if( FREETYPE_FOUND )
+ set( HAVE_FREETYPE2 1 CACHE INTERNAL "" FORCE )
+else( )
+ tde_message_fatal( "freetype2 are required, but not found on your system" )
+endif( )
+
+
+##### check for fontconfig ######################
+
+pkg_search_module( FONTCONFIG fontconfig )
+if( FONTCONFIG_FOUND )
+ set( HAVE_FONTCONFIG 1 CACHE INTERNAL "" FORCE )
+else( )
+ tde_message_fatal( "fontconfig are required, but not found on your system" )
+endif( )
+
+
+##### check for xft #############################
+
+pkg_search_module( XFT xft )
+if( XFT_FOUND )
+ set( HAVE_XFT 1 CACHE INTERNAL "" FORCE )
+else( )
+ tde_message_fatal( "xft are required, but not found on your system" )
+endif( )
+
+
+##### check for Xrandr ##########################
+
+if( WITH_XRANDR )
+ pkg_search_module( XRANDR xrandr )
+ if( NOT XRANDR_FOUND )
+ tde_message_fatal( "xrandr are requested, but not found on your system" )
+ endif( )
+endif( )
+
+
+##### check for libusb ##########################
+
+if( WITH_LIBUSB )
+ pkg_search_module( LIBUSB libusb )
+ if( LIBUSB_FOUND )
+ set( HAVE_LIBUSB 1 CACHE INTERNAL "" FORCE )
+ else( )
+ tde_message_fatal( "libusb are requested, but not found on your system" )
+ endif( )
+endif( )
+
+
+##### check for libraw1394 ######################
+
+if( WITH_LIBRAW1394 )
+ pkg_search_module( LIBRAW1394 libraw1394 )
+ if( NOT LIBRAW1394_FOUND )
+ tde_message_fatal( "libraw1394 are requested, but not found on your system" )
+ endif( )
+endif( )
+
+
+##### check for fontenc #########################
+
+# fontenc seems unused in sources
+
+# pkg_search_module( FONTENC fontenc )
+# if( FONTENC_FOUND )
+# set( HAVE_FONT_ENC 1 CACHE INTERNAL "" FORCE )
+# endif( )