summaryrefslogtreecommitdiffstats
path: root/ConfigureChecks.cmake
diff options
context:
space:
mode:
authorSlávek Banko <slavek.banko@axis.cz>2012-06-10 15:58:19 +0200
committerSlávek Banko <slavek.banko@axis.cz>2012-06-10 16:09:29 +0200
commit0c7737264e69a97c8ea2353b3bef4b776dd17695 (patch)
tree4e44880720a91dc3049e0071489bb13b318047fa /ConfigureChecks.cmake
parentf9e6898036e2521a695c27a87aeb90d71afbadaa (diff)
downloadtdebase-0c7737264e69a97c8ea2353b3bef4b776dd17695.tar.gz
tdebase-0c7737264e69a97c8ea2353b3bef4b776dd17695.zip
Add xscreensaver support to CMake
This closes Bug 859 (cherry picked from commit 80deb52955cbd917e10f015f37699d830cb681ce)
Diffstat (limited to 'ConfigureChecks.cmake')
-rw-r--r--ConfigureChecks.cmake20
1 files changed, 20 insertions, 0 deletions
diff --git a/ConfigureChecks.cmake b/ConfigureChecks.cmake
index 4a78853c9..3834f6d57 100644
--- a/ConfigureChecks.cmake
+++ b/ConfigureChecks.cmake
@@ -130,6 +130,26 @@ if( WITH_XTEST )
endif( )
+# xscreensaver ()
+if( WITH_XSCREENSAVER )
+ check_library_exists( Xss XScreenSaverQueryInfo "" HAVE_XSSLIB )
+ if( HAVE_XSSLIB )
+ pkg_search_module( XSS xscrnsaver )
+ else( )
+ check_library_exists( Xext XScreenSaverQueryInfo "" HAVE_XSSLIB )
+ if( HAVE_XSSLIB )
+ pkg_search_module( XSS xext )
+ endif( )
+ endif( )
+ check_include_file( X11/extensions/scrnsaver.h HAVE_XSCREENSAVER_H )
+ if( HAVE_XSSLIB AND HAVE_XSCREENSAVER_H )
+ set( HAVE_XSCREENSAVER 1 )
+ else( )
+ tde_message_fatal( "xscreensaver is requested, but was not found on your system" )
+ endif( )
+endif( )
+
+
# GL
if( BUILD_KDESKTOP OR BUILD_KCONTROL OR BUILD_KSCREENSAVER )
check_library_exists( GL glXChooseVisual "" HAVE_GLXCHOOSEVISUAL )