summaryrefslogtreecommitdiffstats
path: root/ConfigureChecks.cmake
diff options
context:
space:
mode:
authorDarrell Anderson <humanreadable@yahoo.com>2012-10-22 20:12:42 -0500
committerDarrell Anderson <humanreadable@yahoo.com>2012-10-22 20:12:42 -0500
commitf932984e6c6fd78cc42bfbc74e974eadd9524678 (patch)
treeb9d5f73406db3a0a6e31a433832cd4cfb069bc94 /ConfigureChecks.cmake
parent6a79b632d987db365646b244f65096598398a44e (diff)
downloadkpowersave-f932984e6c6fd78cc42bfbc74e974eadd9524678.tar.gz
kpowersave-f932984e6c6fd78cc42bfbc74e974eadd9524678.zip
Add cmake support for WITH_GCC_VISIBILITY.
Diffstat (limited to 'ConfigureChecks.cmake')
-rw-r--r--ConfigureChecks.cmake14
1 files changed, 14 insertions, 0 deletions
diff --git a/ConfigureChecks.cmake b/ConfigureChecks.cmake
index 2e2826b..34742b8 100644
--- a/ConfigureChecks.cmake
+++ b/ConfigureChecks.cmake
@@ -9,6 +9,20 @@
#
#################################################
+##### check for gcc visibility support #########
+# FIXME
+# This should check for [T]Qt3 visibility support
+
+if( WITH_GCC_VISIBILITY )
+ if( NOT UNIX )
+ tde_message_fatal(FATAL_ERROR "\ngcc visibility support was requested, but your system is not *NIX" )
+ endif( NOT UNIX )
+ set( __KDE_HAVE_GCC_VISIBILITY 1 )
+ set( CMAKE_C_FLAGS "${CMAKE_C_FLAGS} -fvisibility=hidden -fvisibility-inlines-hidden")
+ set( CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} -fvisibility=hidden -fvisibility-inlines-hidden")
+endif( )
+
+
# check for hal
pkg_search_module( HAL hal )
if( HAL_FOUND )