Ticket #145: m4-update.001.diff
File m4-update.001.diff, 45.4 KB (added by anonymous, 16 years ago) |
---|
-
ChangeLog
diff --git a/ChangeLog b/ChangeLog index 291791f..e1fd9ba 100644
a b 1 2 2009-01-10 Enrico Weigelt, metux ITS <weigelt@metux.de> 3 4 * m4/*: updated several .m4 files to what gets changed by 5 autogen.sh 6 1 7 2008-12-18 Roland Illig <roland.illig@gmx.de> 2 8 3 9 * doc/mcedit.1: Documented the newly added filename:lineno -
m4/codeset.m4
diff --git a/m4/codeset.m4 b/m4/codeset.m4 index 223955b..a6e67ec 100644
a b 1 # codeset.m4 serial 2 (gettext-0.16)2 dnl Copyright (C) 2000-2002 , 2006Free Software Foundation, Inc.1 # codeset.m4 serial AM1 (gettext-0.10.40) 2 dnl Copyright (C) 2000-2002 Free Software Foundation, Inc. 3 3 dnl This file is free software; the Free Software Foundation 4 4 dnl gives unlimited permission to copy and/or distribute it, 5 5 dnl with or without modifications, as long as this notice is preserved. … … AC_DEFUN([AM_LANGINFO_CODESET], 10 10 [ 11 11 AC_CACHE_CHECK([for nl_langinfo and CODESET], am_cv_langinfo_codeset, 12 12 [AC_TRY_LINK([#include <langinfo.h>], 13 [char* cs = nl_langinfo(CODESET); return !cs;],13 [char* cs = nl_langinfo(CODESET);], 14 14 am_cv_langinfo_codeset=yes, 15 15 am_cv_langinfo_codeset=no) 16 16 ]) -
m4/iconv.m4
diff --git a/m4/iconv.m4 b/m4/iconv.m4 index 8e36b52..654c415 100644
a b 1 # iconv.m4 serial AM 6 (gettext-0.16.2)2 dnl Copyright (C) 2000-2002 , 2007Free Software Foundation, Inc.1 # iconv.m4 serial AM4 (gettext-0.11.3) 2 dnl Copyright (C) 2000-2002 Free Software Foundation, Inc. 3 3 dnl This file is free software; the Free Software Foundation 4 4 dnl gives unlimited permission to copy and/or distribute it, 5 5 dnl with or without modifications, as long as this notice is preserved. … … AC_DEFUN([AM_ICONV_LINK], 21 21 [ 22 22 dnl Some systems have iconv in libc, some have it in libiconv (OSF/1 and 23 23 dnl those with the standalone portable GNU libiconv installed). 24 AC_REQUIRE([AC_CANONICAL_HOST]) dnl for cross-compiles25 24 26 25 dnl Search for libiconv and define LIBICONV, LTLIBICONV and INCICONV 27 26 dnl accordingly. … … AC_DEFUN([AM_ICONV_LINK], 34 33 am_save_CPPFLAGS="$CPPFLAGS" 35 34 AC_LIB_APPENDTOVAR([CPPFLAGS], [$INCICONV]) 36 35 37 AC_CACHE_CHECK( [for iconv], am_cv_func_iconv, [36 AC_CACHE_CHECK(for iconv, am_cv_func_iconv, [ 38 37 am_cv_func_iconv="no, consider installing GNU libiconv" 39 38 am_cv_lib_iconv=no 40 39 AC_TRY_LINK([#include <stdlib.h> … … AC_DEFUN([AM_ICONV_LINK], 57 56 fi 58 57 ]) 59 58 if test "$am_cv_func_iconv" = yes; then 60 AC_CACHE_CHECK([for working iconv], am_cv_func_iconv_works, [ 61 dnl This tests against bugs in AIX 5.1 and HP-UX 11.11. 62 am_save_LIBS="$LIBS" 63 if test $am_cv_lib_iconv = yes; then 64 LIBS="$LIBS $LIBICONV" 65 fi 66 AC_TRY_RUN([ 67 #include <iconv.h> 68 #include <string.h> 69 int main () 70 { 71 /* Test against AIX 5.1 bug: Failures are not distinguishable from successful 72 returns. */ 73 { 74 iconv_t cd_utf8_to_88591 = iconv_open ("ISO8859-1", "UTF-8"); 75 if (cd_utf8_to_88591 != (iconv_t)(-1)) 76 { 77 static const char input[] = "\342\202\254"; /* EURO SIGN */ 78 char buf[10]; 79 const char *inptr = input; 80 size_t inbytesleft = strlen (input); 81 char *outptr = buf; 82 size_t outbytesleft = sizeof (buf); 83 size_t res = iconv (cd_utf8_to_88591, 84 (char **) &inptr, &inbytesleft, 85 &outptr, &outbytesleft); 86 if (res == 0) 87 return 1; 88 } 89 } 90 #if 0 /* This bug could be worked around by the caller. */ 91 /* Test against HP-UX 11.11 bug: Positive return value instead of 0. */ 92 { 93 iconv_t cd_88591_to_utf8 = iconv_open ("utf8", "iso88591"); 94 if (cd_88591_to_utf8 != (iconv_t)(-1)) 95 { 96 static const char input[] = "\304rger mit b\366sen B\374bchen ohne Augenma\337"; 97 char buf[50]; 98 const char *inptr = input; 99 size_t inbytesleft = strlen (input); 100 char *outptr = buf; 101 size_t outbytesleft = sizeof (buf); 102 size_t res = iconv (cd_88591_to_utf8, 103 (char **) &inptr, &inbytesleft, 104 &outptr, &outbytesleft); 105 if ((int)res > 0) 106 return 1; 107 } 108 } 109 #endif 110 /* Test against HP-UX 11.11 bug: No converter from EUC-JP to UTF-8 is 111 provided. */ 112 if (/* Try standardized names. */ 113 iconv_open ("UTF-8", "EUC-JP") == (iconv_t)(-1) 114 /* Try IRIX, OSF/1 names. */ 115 && iconv_open ("UTF-8", "eucJP") == (iconv_t)(-1) 116 /* Try AIX names. */ 117 && iconv_open ("UTF-8", "IBM-eucJP") == (iconv_t)(-1) 118 /* Try HP-UX names. */ 119 && iconv_open ("utf8", "eucJP") == (iconv_t)(-1)) 120 return 1; 121 return 0; 122 }], [am_cv_func_iconv_works=yes], [am_cv_func_iconv_works=no], 123 [case "$host_os" in 124 aix* | hpux*) am_cv_func_iconv_works="guessing no" ;; 125 *) am_cv_func_iconv_works="guessing yes" ;; 126 esac]) 127 LIBS="$am_save_LIBS" 128 ]) 129 case "$am_cv_func_iconv_works" in 130 *no) am_func_iconv=no am_cv_lib_iconv=no ;; 131 *) am_func_iconv=yes ;; 132 esac 133 else 134 am_func_iconv=no am_cv_lib_iconv=no 135 fi 136 if test "$am_func_iconv" = yes; then 137 AC_DEFINE(HAVE_ICONV, 1, 138 [Define if you have the iconv() function and it works.]) 59 AC_DEFINE(HAVE_ICONV, 1, [Define if you have the iconv() function.]) 139 60 fi 140 61 if test "$am_cv_lib_iconv" = yes; then 141 62 AC_MSG_CHECKING([how to link with libiconv]) -
m4/intdiv0.m4
diff --git a/m4/intdiv0.m4 b/m4/intdiv0.m4 index 534134a..b8d7817 100644
a b 1 # intdiv0.m4 serial 2 (gettext-0.16.2)2 dnl Copyright (C) 2002 , 2007Free Software Foundation, Inc.1 # intdiv0.m4 serial 1 (gettext-0.11.3) 2 dnl Copyright (C) 2002 Free Software Foundation, Inc. 3 3 dnl This file is free software; the Free Software Foundation 4 4 dnl gives unlimited permission to copy and/or distribute it, 5 5 dnl with or without modifications, as long as this notice is preserved. … … AC_DEFUN([gt_INTDIV0], 14 14 AC_CACHE_CHECK([whether integer division by zero raises SIGFPE], 15 15 gt_cv_int_divbyzero_sigfpe, 16 16 [ 17 gt_cv_int_divbyzero_sigfpe= 18 changequote(,)dnl 19 case "$host_os" in 20 macos* | darwin[6-9]* | darwin[1-9][0-9]*) 21 # On MacOS X 10.2 or newer, just assume the same as when cross- 22 # compiling. If we were to perform the real test, 1 Crash Report 23 # dialog window would pop up. 24 case "$host_cpu" in 25 i[34567]86 | x86_64) 26 gt_cv_int_divbyzero_sigfpe="guessing yes" ;; 27 esac 28 ;; 29 esac 30 changequote([,])dnl 31 if test -z "$gt_cv_int_divbyzero_sigfpe"; then 32 AC_TRY_RUN([ 17 AC_TRY_RUN([ 33 18 #include <stdlib.h> 34 19 #include <signal.h> 35 20 36 21 static void 22 #ifdef __cplusplus 37 23 sigfpe_handler (int sig) 24 #else 25 sigfpe_handler (sig) int sig; 26 #endif 38 27 { 39 28 /* Exit with code 0 if SIGFPE, with code 1 if any other signal. */ 40 29 exit (sig != SIGFPE); … … int main () 62 51 exit (1); 63 52 } 64 53 ], gt_cv_int_divbyzero_sigfpe=yes, gt_cv_int_divbyzero_sigfpe=no, 65 [ 66 # Guess based on the CPU. 67 changequote(,)dnl 68 case "$host_cpu" in 69 alpha* | i[34567]86 | x86_64 | m68k | s390*) 70 gt_cv_int_divbyzero_sigfpe="guessing yes";; 71 *) 72 gt_cv_int_divbyzero_sigfpe="guessing no";; 73 esac 74 changequote([,])dnl 75 ]) 76 fi 54 [ 55 # Guess based on the CPU. 56 case "$host_cpu" in 57 alpha* | i[34567]86 | m68k | s390*) 58 gt_cv_int_divbyzero_sigfpe="guessing yes";; 59 *) 60 gt_cv_int_divbyzero_sigfpe="guessing no";; 61 esac 62 ]) 77 63 ]) 78 64 case "$gt_cv_int_divbyzero_sigfpe" in 79 65 *yes) value=1;; -
m4/intmax.m4
diff --git a/m4/intmax.m4 b/m4/intmax.m4 index ce7a8a4..d99c999 100644
a b 1 # intmax.m4 serial 3 (gettext-0.16)1 # intmax.m4 serial 2 (gettext-0.14.2) 2 2 dnl Copyright (C) 2002-2005 Free Software Foundation, Inc. 3 3 dnl This file is free software; the Free Software Foundation 4 4 dnl gives unlimited permission to copy and/or distribute it, … … AC_DEFUN([gt_TYPE_INTMAX_T], 22 22 #if HAVE_INTTYPES_H_WITH_UINTMAX 23 23 #include <inttypes.h> 24 24 #endif 25 ], [intmax_t x = -1; 26 return !x;], 27 gt_cv_c_intmax_t=yes, 28 gt_cv_c_intmax_t=no)]) 25 ], [intmax_t x = -1;], gt_cv_c_intmax_t=yes, gt_cv_c_intmax_t=no)]) 29 26 if test $gt_cv_c_intmax_t = yes; then 30 27 AC_DEFINE(HAVE_INTMAX_T, 1, 31 28 [Define if you have the 'intmax_t' type in <stdint.h> or <inttypes.h>.]) -
m4/inttypes-pri.m4
diff --git a/m4/inttypes-pri.m4 b/m4/inttypes-pri.m4 index 7c7f894..4d56a9a 100644
a b 1 # inttypes-pri.m4 serial 4 (gettext-0.16)2 dnl Copyright (C) 1997-2002 , 2006Free Software Foundation, Inc.1 # inttypes-pri.m4 serial 1 (gettext-0.11.4) 2 dnl Copyright (C) 1997-2002 Free Software Foundation, Inc. 3 3 dnl This file is free software; the Free Software Foundation 4 4 dnl gives unlimited permission to copy and/or distribute it, 5 5 dnl with or without modifications, as long as this notice is preserved. 6 6 7 7 dnl From Bruno Haible. 8 8 9 AC_PREREQ(2.52)10 11 9 # Define PRI_MACROS_BROKEN if <inttypes.h> exists and defines the PRI* 12 10 # macros to non-string values. This is the case on AIX 4.3.3. 13 11 14 12 AC_DEFUN([gt_INTTYPES_PRI], 15 13 [ 16 AC_ CHECK_HEADERS([inttypes.h])17 if test $ ac_cv_header_inttypes_h = yes; then14 AC_REQUIRE([gt_HEADER_INTTYPES_H]) 15 if test $gt_cv_header_inttypes_h = yes; then 18 16 AC_CACHE_CHECK([whether the inttypes.h PRIxNN macros are broken], 19 17 gt_cv_inttypes_pri_broken, 20 18 [ … … char *p = PRId32; 28 26 if test "$gt_cv_inttypes_pri_broken" = yes; then 29 27 AC_DEFINE_UNQUOTED(PRI_MACROS_BROKEN, 1, 30 28 [Define if <inttypes.h> exists and defines unusable PRI* macros.]) 31 PRI_MACROS_BROKEN=132 else33 PRI_MACROS_BROKEN=034 29 fi 35 AC_SUBST([PRI_MACROS_BROKEN])36 30 ]) -
m4/inttypes_h.m4
diff --git a/m4/inttypes_h.m4 b/m4/inttypes_h.m4 index edc8ecb..a5d075d 100644
a b 1 # inttypes_h.m4 serial 72 dnl Copyright (C) 1997-2004 , 2006Free Software Foundation, Inc.1 # inttypes_h.m4 serial 6 2 dnl Copyright (C) 1997-2004 Free Software Foundation, Inc. 3 3 dnl This file is free software; the Free Software Foundation 4 4 dnl gives unlimited permission to copy and/or distribute it, 5 5 dnl with or without modifications, as long as this notice is preserved. … … AC_DEFUN([gl_AC_HEADER_INTTYPES_H], 15 15 [AC_TRY_COMPILE( 16 16 [#include <sys/types.h> 17 17 #include <inttypes.h>], 18 [uintmax_t i = (uintmax_t) -1; return !i;],18 [uintmax_t i = (uintmax_t) -1;], 19 19 gl_cv_header_inttypes_h=yes, 20 20 gl_cv_header_inttypes_h=no)]) 21 21 if test $gl_cv_header_inttypes_h = yes; then -
m4/lib-link.m4
diff --git a/m4/lib-link.m4 b/m4/lib-link.m4 index f157d98..ea0b0c4 100644
a b 1 # lib-link.m4 serial 13 (gettext-0.16.2)2 dnl Copyright (C) 2001-200 7Free Software Foundation, Inc.1 # lib-link.m4 serial 6 (gettext-0.14.3) 2 dnl Copyright (C) 2001-2005 Free Software Foundation, Inc. 3 3 dnl This file is free software; the Free Software Foundation 4 4 dnl gives unlimited permission to copy and/or distribute it, 5 5 dnl with or without modifications, as long as this notice is preserved. 6 6 7 7 dnl From Bruno Haible. 8 8 9 AC_PREREQ(2.5 4)9 AC_PREREQ(2.50) 10 10 11 11 dnl AC_LIB_LINKFLAGS(name [, dependencies]) searches for libname and 12 12 dnl the libraries corresponding to explicit and implicit dependencies. 13 13 dnl Sets and AC_SUBSTs the LIB${NAME} and LTLIB${NAME} variables and 14 14 dnl augments the CPPFLAGS variable. 15 dnl Sets and AC_SUBSTs the LIB${NAME}_PREFIX variable to nonempty if libname16 dnl was found in ${LIB${NAME}_PREFIX}/$acl_libdirstem.17 15 AC_DEFUN([AC_LIB_LINKFLAGS], 18 16 [ 19 17 AC_REQUIRE([AC_LIB_PREPARE_PREFIX]) … … AC_DEFUN([AC_LIB_LINKFLAGS], 26 24 ac_cv_lib[]Name[]_libs="$LIB[]NAME" 27 25 ac_cv_lib[]Name[]_ltlibs="$LTLIB[]NAME" 28 26 ac_cv_lib[]Name[]_cppflags="$INC[]NAME" 29 ac_cv_lib[]Name[]_prefix="$LIB[]NAME[]_PREFIX"30 27 ]) 31 28 LIB[]NAME="$ac_cv_lib[]Name[]_libs" 32 29 LTLIB[]NAME="$ac_cv_lib[]Name[]_ltlibs" 33 30 INC[]NAME="$ac_cv_lib[]Name[]_cppflags" 34 LIB[]NAME[]_PREFIX="$ac_cv_lib[]Name[]_prefix"35 31 AC_LIB_APPENDTOVAR([CPPFLAGS], [$INC]NAME) 36 32 AC_SUBST([LIB]NAME) 37 33 AC_SUBST([LTLIB]NAME) 38 AC_SUBST([LIB]NAME[_PREFIX])39 34 dnl Also set HAVE_LIB[]NAME so that AC_LIB_HAVE_LINKFLAGS can reuse the 40 35 dnl results of this search when this library appears as a dependency. 41 36 HAVE_LIB[]NAME=yes … … dnl sets and AC_SUBSTs HAVE_LIB${NAME}=yes and the LIB${NAME} and 51 46 dnl LTLIB${NAME} variables and augments the CPPFLAGS variable, and 52 47 dnl #defines HAVE_LIB${NAME} to 1. Otherwise, it sets and AC_SUBSTs 53 48 dnl HAVE_LIB${NAME}=no and LIB${NAME} and LTLIB${NAME} to empty. 54 dnl Sets and AC_SUBSTs the LIB${NAME}_PREFIX variable to nonempty if libname55 dnl was found in ${LIB${NAME}_PREFIX}/$acl_libdirstem.56 49 AC_DEFUN([AC_LIB_HAVE_LINKFLAGS], 57 50 [ 58 51 AC_REQUIRE([AC_LIB_PREPARE_PREFIX]) … … AC_DEFUN([AC_LIB_HAVE_LINKFLAGS], 89 82 CPPFLAGS="$ac_save_CPPFLAGS" 90 83 LIB[]NAME= 91 84 LTLIB[]NAME= 92 LIB[]NAME[]_PREFIX=93 85 fi 94 86 AC_SUBST([HAVE_LIB]NAME) 95 87 AC_SUBST([LIB]NAME) 96 88 AC_SUBST([LTLIB]NAME) 97 AC_SUBST([LIB]NAME[_PREFIX])98 89 undefine([Name]) 99 90 undefine([NAME]) 100 91 ]) 101 92 102 93 dnl Determine the platform dependent parameters needed to use rpath: 103 dnl acl_libext, 104 dnl acl_shlibext, 105 dnl acl_hardcode_libdir_flag_spec, 106 dnl acl_hardcode_libdir_separator, 107 dnl acl_hardcode_direct, 108 dnl acl_hardcode_minus_L. 94 dnl libext, shlibext, hardcode_libdir_flag_spec, hardcode_libdir_separator, 95 dnl hardcode_direct, hardcode_minus_L. 109 96 AC_DEFUN([AC_LIB_RPATH], 110 97 [ 111 98 dnl Tell automake >= 1.10 to complain if config.rpath is missing. … … AC_DEFUN([AC_LIB_RPATH], 122 109 acl_cv_rpath=done 123 110 ]) 124 111 wl="$acl_cv_wl" 125 acl_libext="$acl_cv_libext" 126 acl_shlibext="$acl_cv_shlibext" 127 acl_libname_spec="$acl_cv_libname_spec" 128 acl_library_names_spec="$acl_cv_library_names_spec" 129 acl_hardcode_libdir_flag_spec="$acl_cv_hardcode_libdir_flag_spec" 130 acl_hardcode_libdir_separator="$acl_cv_hardcode_libdir_separator" 131 acl_hardcode_direct="$acl_cv_hardcode_direct" 132 acl_hardcode_minus_L="$acl_cv_hardcode_minus_L" 112 libext="$acl_cv_libext" 113 shlibext="$acl_cv_shlibext" 114 hardcode_libdir_flag_spec="$acl_cv_hardcode_libdir_flag_spec" 115 hardcode_libdir_separator="$acl_cv_hardcode_libdir_separator" 116 hardcode_direct="$acl_cv_hardcode_direct" 117 hardcode_minus_L="$acl_cv_hardcode_minus_L" 133 118 dnl Determine whether the user wants rpath handling at all. 134 119 AC_ARG_ENABLE(rpath, 135 120 [ --disable-rpath do not hardcode runtime library paths], … … AC_DEFUN([AC_LIB_RPATH], 139 124 dnl AC_LIB_LINKFLAGS_BODY(name [, dependencies]) searches for libname and 140 125 dnl the libraries corresponding to explicit and implicit dependencies. 141 126 dnl Sets the LIB${NAME}, LTLIB${NAME} and INC${NAME} variables. 142 dnl Also, sets the LIB${NAME}_PREFIX variable to nonempty if libname was found143 dnl in ${LIB${NAME}_PREFIX}/$acl_libdirstem.144 127 AC_DEFUN([AC_LIB_LINKFLAGS_BODY], 145 128 [ 146 AC_REQUIRE([AC_LIB_PREPARE_MULTILIB])147 129 define([NAME],[translit([$1],[abcdefghijklmnopqrstuvwxyz./-], 148 130 [ABCDEFGHIJKLMNOPQRSTUVWXYZ___])]) 149 dnl Autoconf >= 2.61 supports dots in --with options.150 define([N_A_M_E],[m4_if(m4_version_compare(m4_defn([m4_PACKAGE_VERSION]),[2.61]),[-1],[translit([$1],[.],[_])],[$1])])151 131 dnl By default, look in $includedir and $libdir. 152 132 use_additional=yes 153 133 AC_LIB_WITH_FINAL_PREFIX([ 154 134 eval additional_includedir=\"$includedir\" 155 135 eval additional_libdir=\"$libdir\" 156 136 ]) 157 AC_LIB_ARG_WITH([lib ]N_A_M_E[-prefix],158 [ --with-lib ]N_A_M_E[-prefix[=DIR] search for lib$1 in DIR/include and DIR/lib159 --without-lib ]N_A_M_E[-prefix don't search for lib$1 in includedir and libdir],137 AC_LIB_ARG_WITH([lib$1-prefix], 138 [ --with-lib$1-prefix[=DIR] search for lib$1 in DIR/include and DIR/lib 139 --without-lib$1-prefix don't search for lib$1 in includedir and libdir], 160 140 [ 161 141 if test "X$withval" = "Xno"; then 162 142 use_additional=no … … AC_DEFUN([AC_LIB_LINKFLAGS_BODY], 168 148 ]) 169 149 else 170 150 additional_includedir="$withval/include" 171 additional_libdir="$withval/ $acl_libdirstem"151 additional_libdir="$withval/lib" 172 152 fi 173 153 fi 174 154 ]) … … AC_DEFUN([AC_LIB_LINKFLAGS_BODY], 177 157 LIB[]NAME= 178 158 LTLIB[]NAME= 179 159 INC[]NAME= 180 LIB[]NAME[]_PREFIX=181 160 rpathdirs= 182 161 ltrpathdirs= 183 162 names_already_handled= … … AC_DEFUN([AC_LIB_LINKFLAGS_BODY], 217 196 found_la= 218 197 found_so= 219 198 found_a= 220 eval libname=\"$acl_libname_spec\" # typically: libname=lib$name221 if test -n "$acl_shlibext"; then222 shrext=".$acl_shlibext" # typically: shrext=.so223 else224 shrext=225 fi226 199 if test $use_additional = yes; then 227 dir="$additional_libdir" 228 dnl The same code as in the loop below: 229 dnl First look for a shared library. 230 if test -n "$acl_shlibext"; then 231 if test -f "$dir/$libname$shrext"; then 232 found_dir="$dir" 233 found_so="$dir/$libname$shrext" 234 else 235 if test "$acl_library_names_spec" = '$libname$shrext$versuffix'; then 236 ver=`(cd "$dir" && \ 237 for f in "$libname$shrext".*; do echo "$f"; done \ 238 | sed -e "s,^$libname$shrext\\\\.,," \ 239 | sort -t '.' -n -r -k1,1 -k2,2 -k3,3 -k4,4 -k5,5 \ 240 | sed 1q ) 2>/dev/null` 241 if test -n "$ver" && test -f "$dir/$libname$shrext.$ver"; then 242 found_dir="$dir" 243 found_so="$dir/$libname$shrext.$ver" 244 fi 245 else 246 eval library_names=\"$acl_library_names_spec\" 247 for f in $library_names; do 248 if test -f "$dir/$f"; then 249 found_dir="$dir" 250 found_so="$dir/$f" 251 break 252 fi 253 done 254 fi 200 if test -n "$shlibext" && test -f "$additional_libdir/lib$name.$shlibext"; then 201 found_dir="$additional_libdir" 202 found_so="$additional_libdir/lib$name.$shlibext" 203 if test -f "$additional_libdir/lib$name.la"; then 204 found_la="$additional_libdir/lib$name.la" 255 205 fi 256 fi 257 dnl Then look for a static library. 258 if test "X$found_dir" = "X"; then 259 if test -f "$dir/$libname.$acl_libext"; then 260 found_dir="$dir" 261 found_a="$dir/$libname.$acl_libext" 262 fi 263 fi 264 if test "X$found_dir" != "X"; then 265 if test -f "$dir/$libname.la"; then 266 found_la="$dir/$libname.la" 206 else 207 if test -f "$additional_libdir/lib$name.$libext"; then 208 found_dir="$additional_libdir" 209 found_a="$additional_libdir/lib$name.$libext" 210 if test -f "$additional_libdir/lib$name.la"; then 211 found_la="$additional_libdir/lib$name.la" 212 fi 267 213 fi 268 214 fi 269 215 fi … … AC_DEFUN([AC_LIB_LINKFLAGS_BODY], 273 219 case "$x" in 274 220 -L*) 275 221 dir=`echo "X$x" | sed -e 's/^X-L//'` 276 dnl First look for a shared library. 277 if test -n "$acl_shlibext"; then 278 if test -f "$dir/$libname$shrext"; then 279 found_dir="$dir" 280 found_so="$dir/$libname$shrext" 281 else 282 if test "$acl_library_names_spec" = '$libname$shrext$versuffix'; then 283 ver=`(cd "$dir" && \ 284 for f in "$libname$shrext".*; do echo "$f"; done \ 285 | sed -e "s,^$libname$shrext\\\\.,," \ 286 | sort -t '.' -n -r -k1,1 -k2,2 -k3,3 -k4,4 -k5,5 \ 287 | sed 1q ) 2>/dev/null` 288 if test -n "$ver" && test -f "$dir/$libname$shrext.$ver"; then 289 found_dir="$dir" 290 found_so="$dir/$libname$shrext.$ver" 291 fi 292 else 293 eval library_names=\"$acl_library_names_spec\" 294 for f in $library_names; do 295 if test -f "$dir/$f"; then 296 found_dir="$dir" 297 found_so="$dir/$f" 298 break 299 fi 300 done 301 fi 222 if test -n "$shlibext" && test -f "$dir/lib$name.$shlibext"; then 223 found_dir="$dir" 224 found_so="$dir/lib$name.$shlibext" 225 if test -f "$dir/lib$name.la"; then 226 found_la="$dir/lib$name.la" 302 227 fi 303 fi 304 dnl Then look for a static library. 305 if test "X$found_dir" = "X"; then 306 if test -f "$dir/$libname.$acl_libext"; then 228 else 229 if test -f "$dir/lib$name.$libext"; then 307 230 found_dir="$dir" 308 found_a="$dir/$libname.$acl_libext" 309 fi 310 fi 311 if test "X$found_dir" != "X"; then 312 if test -f "$dir/$libname.la"; then 313 found_la="$dir/$libname.la" 231 found_a="$dir/lib$name.$libext" 232 if test -f "$dir/lib$name.la"; then 233 found_la="$dir/lib$name.la" 234 fi 314 235 fi 315 236 fi 316 237 ;; … … AC_DEFUN([AC_LIB_LINKFLAGS_BODY], 327 248 dnl Linking with a shared library. We attempt to hardcode its 328 249 dnl directory into the executable's runpath, unless it's the 329 250 dnl standard /usr/lib. 330 if test "$enable_rpath" = no || test "X$found_dir" = "X/usr/ $acl_libdirstem"; then251 if test "$enable_rpath" = no || test "X$found_dir" = "X/usr/lib"; then 331 252 dnl No hardcoding is needed. 332 253 LIB[]NAME="${LIB[]NAME}${LIB[]NAME:+ }$found_so" 333 254 else … … AC_DEFUN([AC_LIB_LINKFLAGS_BODY], 346 267 ltrpathdirs="$ltrpathdirs $found_dir" 347 268 fi 348 269 dnl The hardcoding into $LIBNAME is system dependent. 349 if test "$ acl_hardcode_direct" = yes; then270 if test "$hardcode_direct" = yes; then 350 271 dnl Using DIR/libNAME.so during linking hardcodes DIR into the 351 272 dnl resulting binary. 352 273 LIB[]NAME="${LIB[]NAME}${LIB[]NAME:+ }$found_so" 353 274 else 354 if test -n "$ acl_hardcode_libdir_flag_spec" && test "$acl_hardcode_minus_L" = no; then275 if test -n "$hardcode_libdir_flag_spec" && test "$hardcode_minus_L" = no; then 355 276 dnl Use an explicit option to hardcode DIR into the resulting 356 277 dnl binary. 357 278 LIB[]NAME="${LIB[]NAME}${LIB[]NAME:+ }$found_so" … … AC_DEFUN([AC_LIB_LINKFLAGS_BODY], 382 303 if test -z "$haveit"; then 383 304 LIB[]NAME="${LIB[]NAME}${LIB[]NAME:+ }-L$found_dir" 384 305 fi 385 if test "$ acl_hardcode_minus_L" != no; then306 if test "$hardcode_minus_L" != no; then 386 307 dnl FIXME: Not sure whether we should use 387 308 dnl "-L$found_dir -l$name" or "-L$found_dir $found_so" 388 309 dnl here. 389 310 LIB[]NAME="${LIB[]NAME}${LIB[]NAME:+ }$found_so" 390 311 else 391 dnl We cannot use $ acl_hardcode_runpath_var and LD_RUN_PATH312 dnl We cannot use $hardcode_runpath_var and LD_RUN_PATH 392 313 dnl here, because this doesn't fit in flags passed to the 393 314 dnl compiler. So give up. No hardcoding. This affects only 394 315 dnl very old systems. … … AC_DEFUN([AC_LIB_LINKFLAGS_BODY], 413 334 dnl Assume the include files are nearby. 414 335 additional_includedir= 415 336 case "$found_dir" in 416 */$acl_libdirstem | */$acl_libdirstem/) 417 basedir=`echo "X$found_dir" | sed -e 's,^X,,' -e "s,/$acl_libdirstem/"'*$,,'` 418 LIB[]NAME[]_PREFIX="$basedir" 337 */lib | */lib/) 338 basedir=`echo "X$found_dir" | sed -e 's,^X,,' -e 's,/lib/*$,,'` 419 339 additional_includedir="$basedir/include" 420 340 ;; 421 341 esac … … AC_DEFUN([AC_LIB_LINKFLAGS_BODY], 476 396 dnl 3. if it's already present in $LDFLAGS or the already 477 397 dnl constructed $LIBNAME, 478 398 dnl 4. if it doesn't exist as a directory. 479 if test "X$additional_libdir" != "X/usr/ $acl_libdirstem"; then399 if test "X$additional_libdir" != "X/usr/lib"; then 480 400 haveit= 481 if test "X$additional_libdir" = "X/usr/local/ $acl_libdirstem"; then401 if test "X$additional_libdir" = "X/usr/local/lib"; then 482 402 if test -n "$GCC"; then 483 403 case $host_os in 484 404 linux* | gnu* | k*bsd*-gnu) haveit=yes;; … … AC_DEFUN([AC_LIB_LINKFLAGS_BODY], 577 497 done 578 498 done 579 499 if test "X$rpathdirs" != "X"; then 580 if test -n "$ acl_hardcode_libdir_separator"; then500 if test -n "$hardcode_libdir_separator"; then 581 501 dnl Weird platform: only the last -rpath option counts, the user must 582 502 dnl pass all path elements in one option. We can arrange that for a 583 503 dnl single library, but not when more than one $LIBNAMEs are used. 584 504 alldirs= 585 505 for found_dir in $rpathdirs; do 586 alldirs="${alldirs}${alldirs:+$ acl_hardcode_libdir_separator}$found_dir"506 alldirs="${alldirs}${alldirs:+$hardcode_libdir_separator}$found_dir" 587 507 done 588 dnl Note: acl_hardcode_libdir_flag_spec uses $libdir and $wl.508 dnl Note: hardcode_libdir_flag_spec uses $libdir and $wl. 589 509 acl_save_libdir="$libdir" 590 510 libdir="$alldirs" 591 eval flag=\"$ acl_hardcode_libdir_flag_spec\"511 eval flag=\"$hardcode_libdir_flag_spec\" 592 512 libdir="$acl_save_libdir" 593 513 LIB[]NAME="${LIB[]NAME}${LIB[]NAME:+ }$flag" 594 514 else … … AC_DEFUN([AC_LIB_LINKFLAGS_BODY], 596 516 for found_dir in $rpathdirs; do 597 517 acl_save_libdir="$libdir" 598 518 libdir="$found_dir" 599 eval flag=\"$ acl_hardcode_libdir_flag_spec\"519 eval flag=\"$hardcode_libdir_flag_spec\" 600 520 libdir="$acl_save_libdir" 601 521 LIB[]NAME="${LIB[]NAME}${LIB[]NAME:+ }$flag" 602 522 done … … AC_DEFUN([AC_LIB_APPENDTOVAR], 631 551 fi 632 552 done 633 553 ]) 634 635 dnl For those cases where a variable contains several -L and -l options636 dnl referring to unknown libraries and directories, this macro determines the637 dnl necessary additional linker options for the runtime path.638 dnl AC_LIB_LINKFLAGS_FROM_LIBS([LDADDVAR], [LIBSVALUE], [USE-LIBTOOL])639 dnl sets LDADDVAR to linker options needed together with LIBSVALUE.640 dnl If USE-LIBTOOL evaluates to non-empty, linking with libtool is assumed,641 dnl otherwise linking without libtool is assumed.642 AC_DEFUN([AC_LIB_LINKFLAGS_FROM_LIBS],643 [644 AC_REQUIRE([AC_LIB_RPATH])645 AC_REQUIRE([AC_LIB_PREPARE_MULTILIB])646 $1=647 if test "$enable_rpath" != no; then648 if test -n "$acl_hardcode_libdir_flag_spec" && test "$acl_hardcode_minus_L" = no; then649 dnl Use an explicit option to hardcode directories into the resulting650 dnl binary.651 rpathdirs=652 next=653 for opt in $2; do654 if test -n "$next"; then655 dir="$next"656 dnl No need to hardcode the standard /usr/lib.657 if test "X$dir" != "X/usr/$acl_libdirstem"; then658 rpathdirs="$rpathdirs $dir"659 fi660 next=661 else662 case $opt in663 -L) next=yes ;;664 -L*) dir=`echo "X$opt" | sed -e 's,^X-L,,'`665 dnl No need to hardcode the standard /usr/lib.666 if test "X$dir" != "X/usr/$acl_libdirstem"; then667 rpathdirs="$rpathdirs $dir"668 fi669 next= ;;670 *) next= ;;671 esac672 fi673 done674 if test "X$rpathdirs" != "X"; then675 if test -n ""$3""; then676 dnl libtool is used for linking. Use -R options.677 for dir in $rpathdirs; do678 $1="${$1}${$1:+ }-R$dir"679 done680 else681 dnl The linker is used for linking directly.682 if test -n "$acl_hardcode_libdir_separator"; then683 dnl Weird platform: only the last -rpath option counts, the user684 dnl must pass all path elements in one option.685 alldirs=686 for dir in $rpathdirs; do687 alldirs="${alldirs}${alldirs:+$acl_hardcode_libdir_separator}$dir"688 done689 acl_save_libdir="$libdir"690 libdir="$alldirs"691 eval flag=\"$acl_hardcode_libdir_flag_spec\"692 libdir="$acl_save_libdir"693 $1="$flag"694 else695 dnl The -rpath options are cumulative.696 for dir in $rpathdirs; do697 acl_save_libdir="$libdir"698 libdir="$dir"699 eval flag=\"$acl_hardcode_libdir_flag_spec\"700 libdir="$acl_save_libdir"701 $1="${$1}${$1:+ }$flag"702 done703 fi704 fi705 fi706 fi707 fi708 AC_SUBST([$1])709 ]) -
m4/lib-prefix.m4
diff --git a/m4/lib-prefix.m4 b/m4/lib-prefix.m4 index a8684e1..0d895ca 100644
a b 1 # lib-prefix.m4 serial 5 (gettext-0.15)1 # lib-prefix.m4 serial 4 (gettext-0.14.2) 2 2 dnl Copyright (C) 2001-2005 Free Software Foundation, Inc. 3 3 dnl This file is free software; the Free Software Foundation 4 4 dnl gives unlimited permission to copy and/or distribute it, … … AC_DEFUN([AC_LIB_PREFIX], 24 24 AC_BEFORE([$0], [AC_LIB_LINKFLAGS]) 25 25 AC_REQUIRE([AC_PROG_CC]) 26 26 AC_REQUIRE([AC_CANONICAL_HOST]) 27 AC_REQUIRE([AC_LIB_PREPARE_MULTILIB])28 27 AC_REQUIRE([AC_LIB_PREPARE_PREFIX]) 29 28 dnl By default, look in $includedir and $libdir. 30 29 use_additional=yes … … AC_DEFUN([AC_LIB_PREFIX], 46 45 ]) 47 46 else 48 47 additional_includedir="$withval/include" 49 additional_libdir="$withval/ $acl_libdirstem"48 additional_libdir="$withval/lib" 50 49 fi 51 50 fi 52 51 ]) … … AC_DEFUN([AC_LIB_PREFIX], 88 87 dnl 2. if it's already present in $LDFLAGS, 89 88 dnl 3. if it's /usr/local/lib and we are using GCC on Linux, 90 89 dnl 4. if it doesn't exist as a directory. 91 if test "X$additional_libdir" != "X/usr/ $acl_libdirstem"; then90 if test "X$additional_libdir" != "X/usr/lib"; then 92 91 haveit= 93 92 for x in $LDFLAGS; do 94 93 AC_LIB_WITH_FINAL_PREFIX([eval x=\"$x\"]) … … AC_DEFUN([AC_LIB_PREFIX], 98 97 fi 99 98 done 100 99 if test -z "$haveit"; then 101 if test "X$additional_libdir" = "X/usr/local/ $acl_libdirstem"; then100 if test "X$additional_libdir" = "X/usr/local/lib"; then 102 101 if test -n "$GCC"; then 103 102 case $host_os in 104 103 linux*) haveit=yes;; … … AC_DEFUN([AC_LIB_WITH_FINAL_PREFIX], 152 151 exec_prefix="$acl_save_exec_prefix" 153 152 prefix="$acl_save_prefix" 154 153 ]) 155 156 dnl AC_LIB_PREPARE_MULTILIB creates a variable acl_libdirstem, containing157 dnl the basename of the libdir, either "lib" or "lib64".158 AC_DEFUN([AC_LIB_PREPARE_MULTILIB],159 [160 dnl There is no formal standard regarding lib and lib64. The current161 dnl practice is that on a system supporting 32-bit and 64-bit instruction162 dnl sets or ABIs, 64-bit libraries go under $prefix/lib64 and 32-bit163 dnl libraries go under $prefix/lib. We determine the compiler's default164 dnl mode by looking at the compiler's library search path. If at least165 dnl of its elements ends in /lib64 or points to a directory whose absolute166 dnl pathname ends in /lib64, we assume a 64-bit ABI. Otherwise we use the167 dnl default, namely "lib".168 acl_libdirstem=lib169 searchpath=`(LC_ALL=C $CC -print-search-dirs) 2>/dev/null | sed -n -e 's,^libraries: ,,p' | sed -e 's,^=,,'`170 if test -n "$searchpath"; then171 acl_save_IFS="${IFS= }"; IFS=":"172 for searchdir in $searchpath; do173 if test -d "$searchdir"; then174 case "$searchdir" in175 */lib64/ | */lib64 ) acl_libdirstem=lib64 ;;176 *) searchdir=`cd "$searchdir" && pwd`177 case "$searchdir" in178 */lib64 ) acl_libdirstem=lib64 ;;179 esac ;;180 esac181 fi182 done183 IFS="$acl_save_IFS"184 fi185 ]) -
m4/longlong.m4
diff --git a/m4/longlong.m4 b/m4/longlong.m4 index 1f9e862..7b399e0 100644
a b 1 # longlong.m4 serial 102 dnl Copyright (C) 1999-200 6Free Software Foundation, Inc.1 # longlong.m4 serial 5 2 dnl Copyright (C) 1999-2004 Free Software Foundation, Inc. 3 3 dnl This file is free software; the Free Software Foundation 4 4 dnl gives unlimited permission to copy and/or distribute it, 5 5 dnl with or without modifications, as long as this notice is preserved. 6 6 7 7 dnl From Paul Eggert. 8 8 9 # Define HAVE_LONG_LONG_INT if 'long long int' works. 10 # This fixes a bug in Autoconf 2.60, but can be removed once we 11 # assume 2.61 everywhere. 9 # Define HAVE_LONG_LONG if 'long long' works. 12 10 13 # Note: If the type 'long long int' exists but is only 32 bits large14 # (as on some very old compilers), HAVE_LONG_LONG_INT will not be15 # defined. In this case you can treat 'long long int' like 'long int'.16 17 AC_DEFUN([AC_TYPE_LONG_LONG_INT],18 [19 AC_CACHE_CHECK([for long long int], [ac_cv_type_long_long_int],20 [AC_LINK_IFELSE(21 [AC_LANG_PROGRAM(22 [[long long int ll = 9223372036854775807ll;23 long long int nll = -9223372036854775807LL;24 typedef int a[((-9223372036854775807LL < 025 && 0 < 9223372036854775807ll)26 ? 1 : -1)];27 int i = 63;]],28 [[long long int llmax = 9223372036854775807ll;29 return ((ll << 63) | (ll >> 63) | (ll < i) | (ll > i)30 | (llmax / ll) | (llmax % ll));]])],31 [dnl This catches a bug in Tandem NonStop Kernel (OSS) cc -O circa 2004.32 dnl If cross compiling, assume the bug isn't important, since33 dnl nobody cross compiles for this platform as far as we know.34 AC_RUN_IFELSE(35 [AC_LANG_PROGRAM(36 [[@%:@include <limits.h>37 @%:@ifndef LLONG_MAX38 @%:@ define HALF \39 (1LL << (sizeof (long long int) * CHAR_BIT - 2))40 @%:@ define LLONG_MAX (HALF - 1 + HALF)41 @%:@endif]],42 [[long long int n = 1;43 int i;44 for (i = 0; ; i++)45 {46 long long int m = n << i;47 if (m >> i != n)48 return 1;49 if (LLONG_MAX / 2 < m)50 break;51 }52 return 0;]])],53 [ac_cv_type_long_long_int=yes],54 [ac_cv_type_long_long_int=no],55 [ac_cv_type_long_long_int=yes])],56 [ac_cv_type_long_long_int=no])])57 if test $ac_cv_type_long_long_int = yes; then58 AC_DEFINE([HAVE_LONG_LONG_INT], 1,59 [Define to 1 if the system has the type `long long int'.])60 fi61 ])62 63 # This macro is obsolescent and should go away soon.64 11 AC_DEFUN([gl_AC_TYPE_LONG_LONG], 65 12 [ 66 AC_REQUIRE([AC_TYPE_LONG_LONG_INT]) 67 ac_cv_type_long_long=$ac_cv_type_long_long_int 13 AC_CACHE_CHECK([for long long], ac_cv_type_long_long, 14 [AC_TRY_LINK([long long ll = 1LL; int i = 63;], 15 [long long llmax = (long long) -1; 16 return ll << i | ll >> i | llmax / ll | llmax % ll;], 17 ac_cv_type_long_long=yes, 18 ac_cv_type_long_long=no)]) 68 19 if test $ac_cv_type_long_long = yes; then 69 20 AC_DEFINE(HAVE_LONG_LONG, 1, 70 21 [Define if you have the 'long long' type.]) -
m4/printf-posix.m4
diff --git a/m4/printf-posix.m4 b/m4/printf-posix.m4 index 33e387c..af10170 100644
a b 1 # printf-posix.m4 serial 3 (gettext-0.16.2)2 dnl Copyright (C) 2003 , 2007Free Software Foundation, Inc.1 # printf-posix.m4 serial 2 (gettext-0.13.1) 2 dnl Copyright (C) 2003 Free Software Foundation, Inc. 3 3 dnl This file is free software; the Free Software Foundation 4 4 dnl gives unlimited permission to copy and/or distribute it, 5 5 dnl with or without modifications, as long as this notice is preserved. … … int main () 28 28 }], gt_cv_func_printf_posix=yes, gt_cv_func_printf_posix=no, 29 29 [ 30 30 AC_EGREP_CPP(notposix, [ 31 #if defined __NetBSD__ || defined _ _BEOS__ || defined _MSC_VER || defined __MINGW32__ || defined __CYGWIN__31 #if defined __NetBSD__ || defined _MSC_VER || defined __MINGW32__ || defined __CYGWIN__ 32 32 notposix 33 33 #endif 34 34 ], gt_cv_func_printf_posix="guessing no", -
m4/size_max.m4
diff --git a/m4/size_max.m4 b/m4/size_max.m4 index 6cb4868..4fe81c7 100644
a b 1 # size_max.m4 serial 62 dnl Copyright (C) 2003 , 2005-2006Free Software Foundation, Inc.1 # size_max.m4 serial 2 2 dnl Copyright (C) 2003 Free Software Foundation, Inc. 3 3 dnl This file is free software; the Free Software Foundation 4 4 dnl gives unlimited permission to copy and/or distribute it, 5 5 dnl with or without modifications, as long as this notice is preserved. … … AC_DEFUN([gl_SIZE_MAX], 11 11 AC_CHECK_HEADERS(stdint.h) 12 12 dnl First test whether the system already has SIZE_MAX. 13 13 AC_MSG_CHECKING([for SIZE_MAX]) 14 AC_CACHE_VAL([gl_cv_size_max], [ 15 gl_cv_size_max= 16 AC_EGREP_CPP([Found it], [ 14 result= 15 AC_EGREP_CPP([Found it], [ 17 16 #include <limits.h> 18 17 #if HAVE_STDINT_H 19 18 #include <stdint.h> … … AC_DEFUN([gl_SIZE_MAX], 21 20 #ifdef SIZE_MAX 22 21 Found it 23 22 #endif 24 ], gl_cv_size_max=yes) 25 if test -z "$gl_cv_size_max"; then 26 dnl Define it ourselves. Here we assume that the type 'size_t' is not wider 27 dnl than the type 'unsigned long'. Try hard to find a definition that can 28 dnl be used in a preprocessor #if, i.e. doesn't contain a cast. 29 AC_COMPUTE_INT([size_t_bits_minus_1], [sizeof (size_t) * CHAR_BIT - 1], 30 [#include <stddef.h> 31 #include <limits.h>], size_t_bits_minus_1=) 32 AC_COMPUTE_INT([fits_in_uint], [sizeof (size_t) <= sizeof (unsigned int)], 33 [#include <stddef.h>], fits_in_uint=) 34 if test -n "$size_t_bits_minus_1" && test -n "$fits_in_uint"; then 35 if test $fits_in_uint = 1; then 36 dnl Even though SIZE_MAX fits in an unsigned int, it must be of type 37 dnl 'unsigned long' if the type 'size_t' is the same as 'unsigned long'. 38 AC_TRY_COMPILE([#include <stddef.h> 39 extern size_t foo; 40 extern unsigned long foo; 41 ], [], fits_in_uint=0) 42 fi 43 dnl We cannot use 'expr' to simplify this expression, because 'expr' 44 dnl works only with 'long' integers in the host environment, while we 45 dnl might be cross-compiling from a 32-bit platform to a 64-bit platform. 46 if test $fits_in_uint = 1; then 47 gl_cv_size_max="(((1U << $size_t_bits_minus_1) - 1) * 2 + 1)" 48 else 49 gl_cv_size_max="(((1UL << $size_t_bits_minus_1) - 1) * 2 + 1)" 50 fi 23 ], result=yes) 24 if test -z "$result"; then 25 dnl Define it ourselves. Here we assume that the type 'size_t' is not wider 26 dnl than the type 'unsigned long'. 27 dnl The _AC_COMPUTE_INT macro works up to LONG_MAX, since it uses 'expr', 28 dnl which is guaranteed to work from LONG_MIN to LONG_MAX. 29 _AC_COMPUTE_INT([~(size_t)0 / 10], res_hi, 30 [#include <stddef.h>], result=?) 31 _AC_COMPUTE_INT([~(size_t)0 % 10], res_lo, 32 [#include <stddef.h>], result=?) 33 _AC_COMPUTE_INT([sizeof (size_t) <= sizeof (unsigned int)], fits_in_uint, 34 [#include <stddef.h>], result=?) 35 if test "$fits_in_uint" = 1; then 36 dnl Even though SIZE_MAX fits in an unsigned int, it must be of type 37 dnl 'unsigned long' if the type 'size_t' is the same as 'unsigned long'. 38 AC_TRY_COMPILE([#include <stddef.h> 39 extern size_t foo; 40 extern unsigned long foo; 41 ], [], fits_in_uint=0) 42 fi 43 if test -z "$result"; then 44 if test "$fits_in_uint" = 1; then 45 result="$res_hi$res_lo"U 51 46 else 52 dnl Shouldn't happen, but who knows... 53 gl_cv_size_max='((size_t)~(size_t)0)' 47 result="$res_hi$res_lo"UL 54 48 fi 49 else 50 dnl Shouldn't happen, but who knows... 51 result='~(size_t)0' 55 52 fi 56 ])57 AC_MSG_RESULT([$ gl_cv_size_max])58 if test "$ gl_cv_size_max" != yes; then59 AC_DEFINE_UNQUOTED([SIZE_MAX], [$ gl_cv_size_max],53 fi 54 AC_MSG_RESULT([$result]) 55 if test "$result" != yes; then 56 AC_DEFINE_UNQUOTED([SIZE_MAX], [$result], 60 57 [Define as the maximum value of type 'size_t', if the system doesn't define it.]) 61 58 fi 62 59 ]) 63 64 dnl Autoconf >= 2.61 has AC_COMPUTE_INT built-in.65 dnl Remove this when we can assume autoconf >= 2.61.66 m4_ifdef([AC_COMPUTE_INT], [], [67 AC_DEFUN([AC_COMPUTE_INT], [_AC_COMPUTE_INT([$2],[$1],[$3],[$4])])68 ]) -
m4/stdint_h.m4
diff --git a/m4/stdint_h.m4 b/m4/stdint_h.m4 index db9a8ac..3355f35 100644
a b 1 # stdint_h.m4 serial 62 dnl Copyright (C) 1997-2004 , 2006Free Software Foundation, Inc.1 # stdint_h.m4 serial 5 2 dnl Copyright (C) 1997-2004 Free Software Foundation, Inc. 3 3 dnl This file is free software; the Free Software Foundation 4 4 dnl gives unlimited permission to copy and/or distribute it, 5 5 dnl with or without modifications, as long as this notice is preserved. … … AC_DEFUN([gl_AC_HEADER_STDINT_H], 15 15 [AC_TRY_COMPILE( 16 16 [#include <sys/types.h> 17 17 #include <stdint.h>], 18 [uintmax_t i = (uintmax_t) -1; return !i;],18 [uintmax_t i = (uintmax_t) -1;], 19 19 gl_cv_header_stdint_h=yes, 20 20 gl_cv_header_stdint_h=no)]) 21 21 if test $gl_cv_header_stdint_h = yes; then -
m4/ulonglong.m4
diff --git a/m4/ulonglong.m4 b/m4/ulonglong.m4 index 9fae98e..dee10cc 100644
a b 1 # ulonglong.m4 serial 62 dnl Copyright (C) 1999-200 6Free Software Foundation, Inc.1 # ulonglong.m4 serial 4 2 dnl Copyright (C) 1999-2004 Free Software Foundation, Inc. 3 3 dnl This file is free software; the Free Software Foundation 4 4 dnl gives unlimited permission to copy and/or distribute it, 5 5 dnl with or without modifications, as long as this notice is preserved. 6 6 7 7 dnl From Paul Eggert. 8 8 9 # Define HAVE_UNSIGNED_LONG_LONG_INT if 'unsigned long long int' works. 10 # This fixes a bug in Autoconf 2.60, but can be removed once we 11 # assume 2.61 everywhere. 9 # Define HAVE_UNSIGNED_LONG_LONG if 'unsigned long long' works. 12 10 13 # Note: If the type 'unsigned long long int' exists but is only 32 bits14 # large (as on some very old compilers), AC_TYPE_UNSIGNED_LONG_LONG_INT15 # will not be defined. In this case you can treat 'unsigned long long int'16 # like 'unsigned long int'.17 18 AC_DEFUN([AC_TYPE_UNSIGNED_LONG_LONG_INT],19 [20 AC_CACHE_CHECK([for unsigned long long int],21 [ac_cv_type_unsigned_long_long_int],22 [AC_LINK_IFELSE(23 [AC_LANG_PROGRAM(24 [[unsigned long long int ull = 18446744073709551615ULL;25 typedef int a[(18446744073709551615ULL <= (unsigned long long int) -126 ? 1 : -1)];27 int i = 63;]],28 [[unsigned long long int ullmax = 18446744073709551615ull;29 return (ull << 63 | ull >> 63 | ull << i | ull >> i30 | ullmax / ull | ullmax % ull);]])],31 [ac_cv_type_unsigned_long_long_int=yes],32 [ac_cv_type_unsigned_long_long_int=no])])33 if test $ac_cv_type_unsigned_long_long_int = yes; then34 AC_DEFINE([HAVE_UNSIGNED_LONG_LONG_INT], 1,35 [Define to 1 if the system has the type `unsigned long long int'.])36 fi37 ])38 39 # This macro is obsolescent and should go away soon.40 11 AC_DEFUN([gl_AC_TYPE_UNSIGNED_LONG_LONG], 41 12 [ 42 AC_REQUIRE([AC_TYPE_UNSIGNED_LONG_LONG_INT]) 43 ac_cv_type_unsigned_long_long=$ac_cv_type_unsigned_long_long_int 13 AC_CACHE_CHECK([for unsigned long long], ac_cv_type_unsigned_long_long, 14 [AC_TRY_LINK([unsigned long long ull = 1ULL; int i = 63;], 15 [unsigned long long ullmax = (unsigned long long) -1; 16 return ull << i | ull >> i | ullmax / ull | ullmax % ull;], 17 ac_cv_type_unsigned_long_long=yes, 18 ac_cv_type_unsigned_long_long=no)]) 44 19 if test $ac_cv_type_unsigned_long_long = yes; then 45 20 AC_DEFINE(HAVE_UNSIGNED_LONG_LONG, 1, 46 21 [Define if you have the 'unsigned long long' type.]) -
m4/wint_t.m4
diff --git a/m4/wint_t.m4 b/m4/wint_t.m4 index 2cac1a7..b8fff9c 100644
a b 1 # wint_t.m4 serial 2 (gettext-0.16.2)2 dnl Copyright (C) 2003 , 2007Free Software Foundation, Inc.1 # wint_t.m4 serial 1 (gettext-0.12) 2 dnl Copyright (C) 2003 Free Software Foundation, Inc. 3 3 dnl This file is free software; the Free Software Foundation 4 4 dnl gives unlimited permission to copy and/or distribute it, 5 5 dnl with or without modifications, as long as this notice is preserved. … … dnl Prerequisite: AC_PROG_CC 11 11 AC_DEFUN([gt_TYPE_WINT_T], 12 12 [ 13 13 AC_CACHE_CHECK([for wint_t], gt_cv_c_wint_t, 14 [AC_TRY_COMPILE([ 15 /* Tru64 with Desktop Toolkit C has a bug: <stdio.h> must be included before 16 <wchar.h>. 17 BSD/OS 4.0.1 has a bug: <stddef.h>, <stdio.h> and <time.h> must be included 18 before <wchar.h>. */ 19 #include <stddef.h> 20 #include <stdio.h> 21 #include <time.h> 22 #include <wchar.h> 14 [AC_TRY_COMPILE([#include <wchar.h> 23 15 wint_t foo = (wchar_t)'\0';], , 24 16 gt_cv_c_wint_t=yes, gt_cv_c_wint_t=no)]) 25 17 if test $gt_cv_c_wint_t = yes; then