summaryrefslogtreecommitdiffstats
path: root/kopete/ConfigureChecks.cmake
diff options
context:
space:
mode:
authorSlávek Banko <[email protected]>2016-11-13 01:52:56 +0100
committerSlávek Banko <[email protected]>2016-11-13 01:53:46 +0100
commit56484e2a730772015af966860f220867a2f0b580 (patch)
treedd2a34abb2445888d66480895d729396081bdcfa /kopete/ConfigureChecks.cmake
parent1f93335507d8bf855393527ff2a2802b47418075 (diff)
downloadtdenetwork-56484e2a730772015af966860f220867a2f0b580.tar.gz
tdenetwork-56484e2a730772015af966860f220867a2f0b580.zip
Kopete: Improve check for videodev header
This resolves bug 2725 Signed-off-by: Slávek Banko <[email protected]> (cherry picked from commit c7ed96db836509bfc933c2be08dcbd63dff54589)
Diffstat (limited to 'kopete/ConfigureChecks.cmake')
-rw-r--r--kopete/ConfigureChecks.cmake27
1 files changed, 15 insertions, 12 deletions
diff --git a/kopete/ConfigureChecks.cmake b/kopete/ConfigureChecks.cmake
index ef0a250f..44939818 100644
--- a/kopete/ConfigureChecks.cmake
+++ b/kopete/ConfigureChecks.cmake
@@ -19,19 +19,22 @@ if( BUILD_KOPETE_PROTOCOL_JABBER AND WITH_JINGLE )
endif( )
endif( )
-# -- Check for libv4l1-videodev.h presence --------------------
-CHECK_INCLUDE_FILE ( "libv4l1-videodev.h" HAVE_LIBV4L1_VIDEODEV_H )
-if ( HAVE_LIBV4L1_VIDEODEV_H )
- add_definitions( -DHAVE_LIBV4L1_VIDEODEV_H )
-endif ( )
-# -- End libv4l1-videodev.h ----------------------------------------------
-# -- Check for linux/videodev.h presence --------------------
-CHECK_INCLUDE_FILE ( "linux/videodev.h" HAVE_LINUX_VIDEODEV_H )
-if ( HAVE_LINUX_VIDEODEV_H )
- add_definitions( -DHAVE_LINUX_VIDEODEV_H )
-endif ( )
-# -- End linux-videodev.h ----------------------------------------------
+### Check for videodev header
+check_include_file( "libv4l1-videodev.h" HAVE_LIBV4L1_VIDEODEV_H )
+if( HAVE_LIBV4L1_VIDEODEV_H )
+ set( VIDEODEV_HEADER "libv4l1-videodev.h" CACHE INTERNAL "" )
+else( )
+ check_include_file( "linux/videodev.h" HAVE_VIDEODEV_H )
+ if( HAVE_VIDEODEV_H )
+ set( VIDEODEV_HEADER "linux/videodev.h" CACHE INTERNAL "" )
+ else( )
+ if( BUILD_KOPETE_PLUGIN_MOTIONAUTOAWAY )
+ tde_message_fatal( "libv4l1-videodev.h or linux/videodev.h is required, but not found on your system" )
+ endif( BUILD_KOPETE_PLUGIN_MOTIONAUTOAWAY )
+ endif( )
+endif( )
+
### Check for tm_gmtoff in tm struct
check_struct_has_member( "struct tm" tm_gmtoff time.h HAVE_TM_GMTOFF )