]> git.mxchange.org Git - flightgear.git/commitdiff
#537 linker issues due to clock_gettime/librt dependencies
authorThorstenB <brehmt@gmail.com>
Fri, 24 Feb 2012 21:22:14 +0000 (22:22 +0100)
committerThorstenB <brehmt@gmail.com>
Fri, 24 Feb 2012 21:22:14 +0000 (22:22 +0100)
Simplify dependency check and make it work for Debian.

CMakeModules/FindSimGear.cmake

index 0be68ba0d0c6c7dd9e473078c94b8924d89d6179..2764fa7eb651d71c538d4eb590065608b0a31d01 100644 (file)
@@ -205,13 +205,10 @@ else(SIMGEAR_SHARED)
 
     if(NOT MSVC)
         # basic timing routines on non windows systems, may be also cygwin?!
-        check_function_exists(clock_gettime clock_gettime_in_libc)
-        if(NOT clock_gettime_in_libc)
-            check_library_exists(rt clock_gettime "" have_rt)
-            if(have_rt)
-                list(APPEND SIMGEAR_CORE_LIBRARY_DEPENDENCIES rt)
-            endif(have_rt)
-        endif(NOT clock_gettime_in_libc)
+        check_library_exists(rt clock_gettime "" have_rt)
+        if(have_rt)
+            list(APPEND SIMGEAR_CORE_LIBRARY_DEPENDENCIES rt)
+        endif(have_rt)
     endif(NOT MSVC)
 endif(SIMGEAR_SHARED)