]> git.ipfire.org Git - thirdparty/gettext.git/commitdiff
Update from gnulib. Use AC_TYPE_LONG_LONG_INT instead of gl_AC_TYPE_LONG_LONG.
authorBruno Haible <bruno@clisp.org>
Wed, 11 Oct 2006 16:20:05 +0000 (16:20 +0000)
committerBruno Haible <bruno@clisp.org>
Tue, 23 Jun 2009 10:14:06 +0000 (12:14 +0200)
gettext-runtime/m4/ChangeLog
gettext-runtime/m4/intl.m4
gettext-runtime/m4/longlong.m4
gettext-runtime/m4/ulonglong.m4

index 1500c97a7705b021fd34d0177e322fae8aa3b635..0dec6a6b659a18006666fde20107ea9d81b5bb4f 100644 (file)
@@ -1,3 +1,26 @@
+2006-10-11  Bruno Haible  <bruno@clisp.org>
+
+       * intl.m4 (AM_INTL_SUBDIR): Invoke AC_TYPE_LONG_LONG_INT instead of
+       gl_AC_TYPE_LONG_LONG.
+
+2006-10-11  Bruno Haible  <bruno@clisp.org>
+
+       * longlong.m4: Add comments.
+       * ulonglong.m4: Likewise.
+
+2006-08-22  Eric Blake  <ebb9@byu.net>
+
+       * longlong.m4 (AC_TYPE_LONG_LONG_INT): Avoid compiler warning.
+
+2006-07-01  Paul Eggert  <eggert@cs.ucla.edu>
+
+       * longlong.m4 (AC_TYPE_LONG_LONG_INT): Backport from Autoconf 2.60,
+       but fix a bug, by requiring at least 64 bits.
+       * ulonglong.m4 (AC_TYPE_UNSIGNED_LONG_LONG_INT): Likewise.
+       * longlong.m4 (gl_AC_TYPE_LONG_LONG): Now just call
+       AC_TYPE_LONG_LONG_INT.  This macro is obsolete and will go soon.
+       * ulonglong.m4 (gl_AC_TYPE_UNSIGNED_LONG_LONG) Likewise.
+
 2006-10-01  Bruno Haible  <bruno@clisp.org>
 
        Make it possible to invoke AC_GNU_SOURCE after gl_LOCK_EARLY.
index e0ab3966f5723f4244b3ea932d1059cfa3b8b0bb..a5317fef327c8c1e32c7d4ff59ec2d9b64fb9447 100644 (file)
@@ -1,4 +1,4 @@
-# intl.m4 serial 2 (gettext-0.15.1)
+# intl.m4 serial 3 (gettext-0.15.1)
 dnl Copyright (C) 1995-2006 Free Software Foundation, Inc.
 dnl This file is free software; the Free Software Foundation
 dnl gives unlimited permission to copy and/or distribute it,
@@ -32,7 +32,7 @@ AC_DEFUN([AM_INTL_SUBDIR],
   AC_REQUIRE([AC_PROG_RANLIB])dnl
   AC_REQUIRE([gl_VISIBILITY])dnl
   AC_REQUIRE([gt_INTL_SUBDIR_CORE])dnl
-  AC_REQUIRE([gl_AC_TYPE_LONG_LONG])dnl
+  AC_REQUIRE([AC_TYPE_LONG_LONG_INT])dnl
   AC_REQUIRE([gt_TYPE_LONGDOUBLE])dnl
   AC_REQUIRE([gt_TYPE_WCHAR_T])dnl
   AC_REQUIRE([gt_TYPE_WINT_T])dnl
index 7b399e012828f10870999edcb98757ba07217d72..3716c09f6caf562c8b70eb0c8ff498f3e210c6b7 100644 (file)
@@ -1,21 +1,46 @@
-# longlong.m4 serial 5
-dnl Copyright (C) 1999-2004 Free Software Foundation, Inc.
+# longlong.m4 serial 8
+dnl Copyright (C) 1999-2006 Free Software Foundation, Inc.
 dnl This file is free software; the Free Software Foundation
 dnl gives unlimited permission to copy and/or distribute it,
 dnl with or without modifications, as long as this notice is preserved.
 
 dnl From Paul Eggert.
 
-# Define HAVE_LONG_LONG if 'long long' works.
+# Define HAVE_LONG_LONG_INT if 'long long int' works.
+# This fixes a bug in Autoconf 2.60, but can be removed once we
+# assume 2.61 everywhere.
 
+# Note: If the type 'long long int' exists but is only 32 bits large
+# (as on some very old compilers), AC_TYPE_LONG_LONG_INT will not be
+# defined. In this case you can treat 'long long int' like 'long int'.
+
+AC_DEFUN([AC_TYPE_LONG_LONG_INT],
+[
+  AC_CACHE_CHECK([for long long int], [ac_cv_type_long_long_int],
+    [AC_LINK_IFELSE(
+       [AC_LANG_PROGRAM(
+         [[long long int ll = 9223372036854775807ll;
+           long long int nll = -9223372036854775807LL;
+           typedef int a[((-9223372036854775807LL < 0
+                           && 0 < 9223372036854775807ll)
+                          ? 1 : -1)];
+           int i = 63;]],
+         [[long long int llmax = 9223372036854775807ll;
+           return ((ll << 63) | (ll >> 63) | (ll < i) | (ll > i)
+                   | (llmax / ll) | (llmax % ll));]])],
+       [ac_cv_type_long_long_int=yes],
+       [ac_cv_type_long_long_int=no])])
+  if test $ac_cv_type_long_long_int = yes; then
+    AC_DEFINE([HAVE_LONG_LONG_INT], 1,
+      [Define to 1 if the system has the type `long long int'.])
+  fi
+])
+
+# This macro is obsolescent and should go away soon.
 AC_DEFUN([gl_AC_TYPE_LONG_LONG],
 [
-  AC_CACHE_CHECK([for long long], ac_cv_type_long_long,
-  [AC_TRY_LINK([long long ll = 1LL; int i = 63;],
-    [long long llmax = (long long) -1;
-     return ll << i | ll >> i | llmax / ll | llmax % ll;],
-    ac_cv_type_long_long=yes,
-    ac_cv_type_long_long=no)])
+  AC_REQUIRE([AC_TYPE_LONG_LONG_INT])
+  ac_cv_type_long_long=$ac_cv_type_long_long_int
   if test $ac_cv_type_long_long = yes; then
     AC_DEFINE(HAVE_LONG_LONG, 1,
       [Define if you have the 'long long' type.])
index dee10ccc3ee641a63153f7b29ae2339c1e56c723..9fae98e3a6c839221c28ee7e206e225828ec8b64 100644 (file)
@@ -1,21 +1,46 @@
-# ulonglong.m4 serial 4
-dnl Copyright (C) 1999-2004 Free Software Foundation, Inc.
+# ulonglong.m4 serial 6
+dnl Copyright (C) 1999-2006 Free Software Foundation, Inc.
 dnl This file is free software; the Free Software Foundation
 dnl gives unlimited permission to copy and/or distribute it,
 dnl with or without modifications, as long as this notice is preserved.
 
 dnl From Paul Eggert.
 
-# Define HAVE_UNSIGNED_LONG_LONG if 'unsigned long long' works.
+# Define HAVE_UNSIGNED_LONG_LONG_INT if 'unsigned long long int' works.
+# This fixes a bug in Autoconf 2.60, but can be removed once we
+# assume 2.61 everywhere.
 
+# Note: If the type 'unsigned long long int' exists but is only 32 bits
+# large (as on some very old compilers), AC_TYPE_UNSIGNED_LONG_LONG_INT
+# will not be defined. In this case you can treat 'unsigned long long int'
+# like 'unsigned long int'.
+
+AC_DEFUN([AC_TYPE_UNSIGNED_LONG_LONG_INT],
+[
+  AC_CACHE_CHECK([for unsigned long long int],
+    [ac_cv_type_unsigned_long_long_int],
+    [AC_LINK_IFELSE(
+       [AC_LANG_PROGRAM(
+         [[unsigned long long int ull = 18446744073709551615ULL;
+           typedef int a[(18446744073709551615ULL <= (unsigned long long int) -1
+                          ? 1 : -1)];
+          int i = 63;]],
+         [[unsigned long long int ullmax = 18446744073709551615ull;
+           return (ull << 63 | ull >> 63 | ull << i | ull >> i
+                   | ullmax / ull | ullmax % ull);]])],
+       [ac_cv_type_unsigned_long_long_int=yes],
+       [ac_cv_type_unsigned_long_long_int=no])])
+  if test $ac_cv_type_unsigned_long_long_int = yes; then
+    AC_DEFINE([HAVE_UNSIGNED_LONG_LONG_INT], 1,
+      [Define to 1 if the system has the type `unsigned long long int'.])
+  fi
+])
+
+# This macro is obsolescent and should go away soon.
 AC_DEFUN([gl_AC_TYPE_UNSIGNED_LONG_LONG],
 [
-  AC_CACHE_CHECK([for unsigned long long], ac_cv_type_unsigned_long_long,
-  [AC_TRY_LINK([unsigned long long ull = 1ULL; int i = 63;],
-    [unsigned long long ullmax = (unsigned long long) -1;
-     return ull << i | ull >> i | ullmax / ull | ullmax % ull;],
-    ac_cv_type_unsigned_long_long=yes,
-    ac_cv_type_unsigned_long_long=no)])
+  AC_REQUIRE([AC_TYPE_UNSIGNED_LONG_LONG_INT])
+  ac_cv_type_unsigned_long_long=$ac_cv_type_unsigned_long_long_int
   if test $ac_cv_type_unsigned_long_long = yes; then
     AC_DEFINE(HAVE_UNSIGNED_LONG_LONG, 1,
       [Define if you have the 'unsigned long long' type.])