]> git.ipfire.org Git - thirdparty/chrony.git/commitdiff
configure: check for 64-bit time_t
authorMiroslav Lichvar <mlichvar@redhat.com>
Thu, 7 Aug 2014 12:11:17 +0000 (14:11 +0200)
committerMiroslav Lichvar <mlichvar@redhat.com>
Fri, 15 Aug 2014 08:58:44 +0000 (10:58 +0200)
configure

index 9a41d15d5fb096f37e18cfcb755335c4135bb481..cde0e17f9fe41821f41af4db53352468ffde3906 100755 (executable)
--- a/configure
+++ b/configure
@@ -376,6 +376,13 @@ case $SYSTEM in
     ;;
 esac
 
+if test_code '64-bit time_t' 'time.h' '' '' '
+  char x[sizeof(time_t) > 4 ? 1 : -1] = {0};
+  return x[0];'
+then
+  add_def HAVE_LONG_TIME_T 1
+fi
+
 MATHCODE='return (int) pow(2.0, log(sqrt((double)argc)));'
 if test_code 'math' 'math.h' '' '' "$MATHCODE"; then
   LIBS=""