shishi-commit
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

CVS shishi/gl/m4


From: shishi-commit
Subject: CVS shishi/gl/m4
Date: Wed, 12 Oct 2005 15:24:43 +0200

Update of /home/cvs/shishi/gl/m4
In directory dopio:/tmp/cvs-serv26416/m4

Modified Files:
        getaddrinfo.m4 getdate.m4 gnulib-cache.m4 gnulib-comp.m4 
        mbchar.m4 mbiter.m4 mktime.m4 stdbool.m4 strcase.m4 
        xreadlink.m4 
Added Files:
        gc-hmac-sha1.m4 gc-pbkdf2-sha1.m4 gc.m4 hmac-sha1.m4 
        inttypes.m4 lib-ld.m4 lib-link.m4 lib-prefix.m4 memxor.m4 
        sha1.m4 stdint.m4 
Log Message:
Add.

--- /home/cvs/shishi/gl/m4/getaddrinfo.m4       2005/09/19 16:04:42     1.5
+++ /home/cvs/shishi/gl/m4/getaddrinfo.m4       2005/10/12 13:24:42     1.6
@@ -1,12 +1,14 @@
-# getaddrinfo.m4 serial 3
-dnl Copyright (C) 2004 Free Software Foundation, Inc.
+# getaddrinfo.m4 serial 7
+dnl Copyright (C) 2004, 2005 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.
 
 AC_DEFUN([gl_GETADDRINFO],
 [
-  AC_SEARCH_LIBS(getaddrinfo, nsl socket)
+  AC_SEARCH_LIBS(getaddrinfo, [nsl socket])
+  AC_SEARCH_LIBS(gethostbyname, [inet nsl])
+  AC_SEARCH_LIBS(getservbyname, [inet nsl socket xnet])
   AC_REPLACE_FUNCS(getaddrinfo gai_strerror)
   gl_PREREQ_GETADDRINFO
 ])
@@ -16,4 +18,19 @@
   AC_REQUIRE([gl_C_RESTRICT])
   AC_REQUIRE([gl_SOCKET_FAMILIES])
   AC_REQUIRE([AC_C_INLINE])
+  AC_REQUIRE([AC_GNU_SOURCE])
+  AC_CHECK_HEADERS_ONCE(netinet/in.h)
+  AC_CHECK_DECLS([getaddrinfo, freeaddrinfo, gai_strerror],,,[
+  /* sys/types.h is not needed according to POSIX, but the
+     sys/socket.h in i386-unknown-freebsd4.10 and
+     powerpc-apple-darwin5.5 required it. */
+#include <sys/types.h>
+#include <sys/socket.h>
+#include <netdb.h>
+])
+  AC_CHECK_TYPES([struct addrinfo],,,[
+#include <sys/types.h>
+#include <sys/socket.h>
+#include <netdb.h>
+])
 ])
--- /home/cvs/shishi/gl/m4/getdate.m4   2005/03/21 22:11:17     1.7
+++ /home/cvs/shishi/gl/m4/getdate.m4   2005/10/12 13:24:42     1.8
@@ -1,9 +1,22 @@
-# getdate.m4 serial 7
+# getdate.m4 serial 8
 dnl Copyright (C) 2002, 2003, 2004, 2005 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.
 
+AC_DEFUN([gl_C_COMPOUND_LITERALS],
+[
+  AC_CACHE_CHECK([for compound literals], gl_cv_compound_literals,
+  [AC_TRY_COMPILE([struct s { int i, j; }; struct s s = (struct s) { 1, 2 };],
+    [struct s t = (struct s) { 3, 4 };],
+    gl_cv_compound_literals=yes,
+    gl_cv_compound_literals=no)])
+  if test $gl_cv_compound_literals = yes; then
+    AC_DEFINE(HAVE_COMPOUND_LITERALS, 1,
+      [Define if you have compound literals.])
+  fi
+])
+
 AC_DEFUN([gl_GETDATE],
 [
   AC_LIBSOURCES([getdate.h, getdate.y])
@@ -15,6 +28,7 @@
 
   dnl Prerequisites of lib/getdate.y.
   AC_REQUIRE([gl_BISON])
+  AC_REQUIRE([gl_C_COMPOUND_LITERALS])
   AC_REQUIRE([AC_HEADER_STDC])
   AC_CHECK_FUNCS_ONCE(isascii)
   AC_STRUCT_TIMEZONE
--- /home/cvs/shishi/gl/m4/gnulib-cache.m4      2005/09/19 16:07:55     1.2
+++ /home/cvs/shishi/gl/m4/gnulib-cache.m4      2005/10/12 13:24:42     1.3
@@ -14,10 +14,10 @@
 
 
 # Specification in the form of a command-line invocation:
-#   gnulib-tool --import --dir=. --lib=libgnu --source-base=gl --m4-base=gl/m4 
--aux-dir=. --avoid=xalloc-die --libtool --macro-prefix=gl base64 error 
getaddrinfo getdate gethostname getline getopt getpass getsubopt progname 
realloc setenv socklen strcase strchrnul strdup strndup strtok_r timegm 
vasnprintf vasprintf xalloc xgetdomainname xgethostname xreadlink xstrndup 
xvasprintf
+#   gnulib-tool --import --dir=. --lib=libgnu --source-base=gl --m4-base=gl/m4 
--aux-dir=. --avoid=xalloc-die --libtool --macro-prefix=gl base64 error 
gc-pbkdf2-sha1 getaddrinfo getdate gethostname getline getopt getpass getsubopt 
progname realloc setenv socklen strcase strchrnul strdup strndup strtok_r 
timegm vasnprintf vasprintf xalloc xgetdomainname xgethostname xreadlink 
xstrndup xvasprintf
 
 # Specification in the form of a few gnulib-tool.m4 macro invocations:
-gl_MODULES([base64 error getaddrinfo getdate gethostname getline getopt 
getpass getsubopt progname realloc setenv socklen strcase strchrnul strdup 
strndup strtok_r timegm vasnprintf vasprintf xalloc xgetdomainname xgethostname 
xreadlink xstrndup xvasprintf])
+gl_MODULES([base64 error gc-pbkdf2-sha1 getaddrinfo getdate gethostname 
getline getopt getpass getsubopt progname realloc setenv socklen strcase 
strchrnul strdup strndup strtok_r timegm vasnprintf vasprintf xalloc 
xgetdomainname xgethostname xreadlink xstrndup xvasprintf])
 gl_AVOID([xalloc-die])
 gl_SOURCE_BASE([gl])
 gl_M4_BASE([gl/m4])
--- /home/cvs/shishi/gl/m4/gnulib-comp.m4       2005/09/19 16:07:55     1.2
+++ /home/cvs/shishi/gl/m4/gnulib-comp.m4       2005/10/12 13:24:42     1.3
@@ -31,6 +31,9 @@
   gl_FUNC_BASE64
   gl_ERROR
   dnl gl_USE_SYSTEM_EXTENSIONS must be added quite early to configure.ac.
+  gl_GC
+  gl_GC_HMAC_SHA1
+  gl_GC_PBKDF2_SHA1
   gl_GETADDRINFO
   gl_GETDATE
   gl_FUNC_GETDELIM
@@ -54,14 +57,15 @@
   gl_SOCKLEN_T
   gt_TYPE_SSIZE_T
   AM_STDBOOL_H
+  gl_STDINT_H
   gl_STRCASE
   gl_FUNC_STRCHRNUL
   gl_FUNC_STRDUP
   gl_FUNC_STRNDUP
   gl_FUNC_STRNLEN
   gl_FUNC_STRTOK_R
-  gl_FUNC_TIMEGM
   gl_TIME_R
+  gl_FUNC_TIMEGM
   gl_TIMESPEC
   gl_FUNC_VASNPRINTF
   gl_FUNC_VASPRINTF
@@ -74,6 +78,7 @@
 # This macro records the list of files which have been installed by
 # gnulib-tool and may be removed by future gnulib-tool invocations.
 AC_DEFUN([gl_FILE_LIST], [
+  build-aux/config.rpath
   doc/getdate.texi
   lib/alloca_.h
   lib/allocsa.c
@@ -86,6 +91,10 @@
   lib/error.c
   lib/error.h
   lib/gai_strerror.c
+  lib/gc-gnulib.c
+  lib/gc-libgcrypt.c
+  lib/gc-pbkdf2-sha1.c
+  lib/gc.h
   lib/getaddrinfo.c
   lib/getaddrinfo.h
   lib/getdate.h
@@ -97,8 +106,8 @@
   lib/gethostname.c
   lib/getline.c
   lib/getline.h
-  lib/getopt1.c
   lib/getopt.c
+  lib/getopt1.c
   lib/getopt_.h
   lib/getopt_int.h
   lib/getpass.c
@@ -108,10 +117,14 @@
   lib/gettext.h
   lib/gettime.c
   lib/gettimeofday.c
+  lib/hmac-sha1.c
+  lib/hmac.h
   lib/mbchar.c
   lib/mbchar.h
   lib/mbuiter.h
   lib/memchr.c
+  lib/memxor.c
+  lib/memxor.h
   lib/mktime.c
   lib/printf-args.c
   lib/printf-args.h
@@ -123,10 +136,13 @@
   lib/realloc.c
   lib/setenv.c
   lib/setenv.h
+  lib/sha1.c
+  lib/sha1.h
   lib/size_max.h
   lib/stdbool_.h
-  lib/strcasecmp.c
+  lib/stdint_.h
   lib/strcase.h
+  lib/strcasecmp.c
   lib/strchrnul.c
   lib/strchrnul.h
   lib/strdup.c
@@ -134,16 +150,16 @@
   lib/strncasecmp.c
   lib/strndup.c
   lib/strndup.h
-  lib/strnlen1.c
-  lib/strnlen1.h
   lib/strnlen.c
   lib/strnlen.h
+  lib/strnlen1.c
+  lib/strnlen1.h
   lib/strtok_r.c
   lib/strtok_r.h
-  lib/timegm.c
-  lib/timegm.h
   lib/time_r.c
   lib/time_r.h
+  lib/timegm.c
+  lib/timegm.h
   lib/timespec.h
   lib/unsetenv.c
   lib/vasnprintf.c
@@ -173,6 +189,9 @@
   m4/eoverflow.m4
   m4/error.m4
   m4/extensions.m4
+  m4/gc-hmac-sha1.m4
+  m4/gc-pbkdf2-sha1.m4
+  m4/gc.m4
   m4/getaddrinfo.m4
   m4/getdate.m4
   m4/getdelim.m4
@@ -184,25 +203,33 @@
   m4/getsubopt.m4
   m4/gettime.m4
   m4/gettimeofday.m4
+  m4/hmac-sha1.m4
   m4/intmax_t.m4
+  m4/inttypes.m4
   m4/inttypes_h.m4
+  m4/lib-ld.m4
+  m4/lib-link.m4
+  m4/lib-prefix.m4
   m4/longdouble.m4
   m4/longlong.m4
   m4/mbchar.m4
   m4/mbiter.m4
   m4/mbrtowc.m4
   m4/memchr.m4
+  m4/memxor.m4
   m4/mktime.m4
   m4/onceonly_2_57.m4
   m4/readlink.m4
   m4/restrict.m4
   m4/setenv.m4
+  m4/sha1.m4
   m4/signed.m4
   m4/size_max.m4
   m4/socklen.m4
   m4/sockpfaf.m4
   m4/ssize_t.m4
   m4/stdbool.m4
+  m4/stdint.m4
   m4/stdint_h.m4
   m4/strcase.m4
   m4/strchrnul.m4
@@ -211,8 +238,8 @@
   m4/strndup.m4
   m4/strnlen.m4
   m4/strtok_r.m4
-  m4/timegm.m4
   m4/time_r.m4
+  m4/timegm.m4
   m4/timespec.m4
   m4/tm_gmtoff.m4
   m4/vasnprintf.m4
--- /home/cvs/shishi/gl/m4/lib-link.m4  2005/08/10 14:58:10     1.6
+++ /home/cvs/shishi/gl/m4/lib-link.m4  2005/10/12 13:24:42     1.7
@@ -1,4 +1,4 @@
-# lib-link.m4 serial 6 (gettext-0.14.3)
+# lib-link.m4 serial 7 (gettext-0.15)
 dnl Copyright (C) 2001-2005 Free Software Foundation, Inc.
 dnl This file is free software; the Free Software Foundation
 dnl gives unlimited permission to copy and/or distribute it,
@@ -126,6 +126,7 @@
 dnl Sets the LIB${NAME}, LTLIB${NAME} and INC${NAME} variables.
 AC_DEFUN([AC_LIB_LINKFLAGS_BODY],
 [
+  AC_REQUIRE([AC_LIB_PREPARE_MULTILIB])
   define([NAME],[translit([$1],[abcdefghijklmnopqrstuvwxyz./-],
                                [ABCDEFGHIJKLMNOPQRSTUVWXYZ___])])
   dnl By default, look in $includedir and $libdir.
@@ -148,7 +149,7 @@
         ])
       else
         additional_includedir="$withval/include"
-        additional_libdir="$withval/lib"
+        additional_libdir="$withval/$acl_libdirstem"
       fi
     fi
 ])
@@ -248,7 +249,7 @@
               dnl Linking with a shared library. We attempt to hardcode its
               dnl directory into the executable's runpath, unless it's the
               dnl standard /usr/lib.
-              if test "$enable_rpath" = no || test "X$found_dir" = 
"X/usr/lib"; then
+              if test "$enable_rpath" = no || test "X$found_dir" = 
"X/usr/$acl_libdirstem"; then
                 dnl No hardcoding is needed.
                 LIB[]NAME="${LIB[]NAME}${LIB[]NAME:+ }$found_so"
               else
@@ -334,8 +335,8 @@
             dnl Assume the include files are nearby.
             additional_includedir=
             case "$found_dir" in
-              */lib | */lib/)
-                basedir=`echo "X$found_dir" | sed -e 's,^X,,' -e 's,/lib/*$,,'`
+              */$acl_libdirstem | */$acl_libdirstem/)
+                basedir=`echo "X$found_dir" | sed -e 's,^X,,' -e 
"s,/$acl_libdirstem/"'*$,,'`
                 additional_includedir="$basedir/include"
                 ;;
             esac
@@ -396,9 +397,9 @@
                     dnl   3. if it's already present in $LDFLAGS or the already
                     dnl      constructed $LIBNAME,
                     dnl   4. if it doesn't exist as a directory.
-                    if test "X$additional_libdir" != "X/usr/lib"; then
+                    if test "X$additional_libdir" != "X/usr/$acl_libdirstem"; 
then
                       haveit=
-                      if test "X$additional_libdir" = "X/usr/local/lib"; then
+                      if test "X$additional_libdir" = 
"X/usr/local/$acl_libdirstem"; then
                         if test -n "$GCC"; then
                           case $host_os in
                             linux* | gnu* | k*bsd*-gnu) haveit=yes;;
--- /home/cvs/shishi/gl/m4/lib-prefix.m4        2005/08/10 14:58:10     1.6
+++ /home/cvs/shishi/gl/m4/lib-prefix.m4        2005/10/12 13:24:42     1.7
@@ -1,4 +1,4 @@
-# lib-prefix.m4 serial 4 (gettext-0.14.2)
+# lib-prefix.m4 serial 5 (gettext-0.15)
 dnl Copyright (C) 2001-2005 Free Software Foundation, Inc.
 dnl This file is free software; the Free Software Foundation
 dnl gives unlimited permission to copy and/or distribute it,
@@ -24,6 +24,7 @@
   AC_BEFORE([$0], [AC_LIB_LINKFLAGS])
   AC_REQUIRE([AC_PROG_CC])
   AC_REQUIRE([AC_CANONICAL_HOST])
+  AC_REQUIRE([AC_LIB_PREPARE_MULTILIB])
   AC_REQUIRE([AC_LIB_PREPARE_PREFIX])
   dnl By default, look in $includedir and $libdir.
   use_additional=yes
@@ -45,7 +46,7 @@
         ])
       else
         additional_includedir="$withval/include"
-        additional_libdir="$withval/lib"
+        additional_libdir="$withval/$acl_libdirstem"
       fi
     fi
 ])
@@ -87,7 +88,7 @@
     dnl   2. if it's already present in $LDFLAGS,
     dnl   3. if it's /usr/local/lib and we are using GCC on Linux,
     dnl   4. if it doesn't exist as a directory.
-    if test "X$additional_libdir" != "X/usr/lib"; then
+    if test "X$additional_libdir" != "X/usr/$acl_libdirstem"; then
       haveit=
       for x in $LDFLAGS; do
         AC_LIB_WITH_FINAL_PREFIX([eval x=\"$x\"])
@@ -97,7 +98,7 @@
         fi
       done
       if test -z "$haveit"; then
-        if test "X$additional_libdir" = "X/usr/local/lib"; then
+        if test "X$additional_libdir" = "X/usr/local/$acl_libdirstem"; then
           if test -n "$GCC"; then
             case $host_os in
               linux*) haveit=yes;;
@@ -151,3 +152,34 @@
   exec_prefix="$acl_save_exec_prefix"
   prefix="$acl_save_prefix"
 ])
+
+dnl AC_LIB_PREPARE_MULTILIB creates a variable acl_libdirstem, containing
+dnl the basename of the libdir, either "lib" or "lib64".
+AC_DEFUN([AC_LIB_PREPARE_MULTILIB],
+[
+  dnl There is no formal standard regarding lib and lib64. The current
+  dnl practice is that on a system supporting 32-bit and 64-bit instruction
+  dnl sets or ABIs, 64-bit libraries go under $prefix/lib64 and 32-bit
+  dnl libraries go under $prefix/lib. We determine the compiler's default
+  dnl mode by looking at the compiler's library search path. If at least
+  dnl of its elements ends in /lib64 or points to a directory whose absolute
+  dnl pathname ends in /lib64, we assume a 64-bit ABI. Otherwise we use the
+  dnl default, namely "lib".
+  acl_libdirstem=lib
+  searchpath=`(LC_ALL=C $CC -print-search-dirs) 2>/dev/null | sed -n -e 
's,^libraries: ,,p' | sed -e 's,^=,,'`
+  if test -n "$searchpath"; then
+    acl_save_IFS="${IFS=       }"; IFS=":"
+    for searchdir in $searchpath; do
+      if test -d "$searchdir"; then
+        case "$searchdir" in
+          */lib64/ | */lib64 ) acl_libdirstem=lib64 ;;
+          *) searchdir=`cd "$searchdir" && pwd`
+             case "$searchdir" in
+               */lib64 ) acl_libdirstem=lib64 ;;
+             esac ;;
+        esac
+      fi
+    done
+    IFS="$acl_save_IFS"
+  fi
+])
--- /home/cvs/shishi/gl/m4/mbchar.m4    2005/09/19 16:04:42     1.1
+++ /home/cvs/shishi/gl/m4/mbchar.m4    2005/10/12 13:24:42     1.2
@@ -1,4 +1,4 @@
-# mbchar.m4 serial 1
+# mbchar.m4 serial 2
 dnl Copyright (C) 2005 Free Software Foundation, Inc.
 dnl This file is free software; the Free Software Foundation
 dnl gives unlimited permission to copy and/or distribute it,
@@ -10,5 +10,11 @@
 AC_DEFUN([gl_MBCHAR],
 [
   AC_REQUIRE([AC_GNU_SOURCE])
-  :
+  dnl The following line is that so the user can test
+  dnl HAVE_WCHAR_H && HAVE_WCTYPE_H before #include "mbchar.h".
+  AC_CHECK_HEADERS_ONCE(wchar.h wctype.h)
+  dnl Compile mbchar.c only if HAVE_WCHAR_H && HAVE_WCTYPE_H.
+  if test $ac_cv_header_wchar_h = yes && test $ac_cv_header_wctype_h = yes; 
then
+    AC_LIBOBJ([mbchar])
+  fi
 ])
--- /home/cvs/shishi/gl/m4/mbiter.m4    2005/09/19 16:04:42     1.1
+++ /home/cvs/shishi/gl/m4/mbiter.m4    2005/10/12 13:24:42     1.2
@@ -1,4 +1,4 @@
-# mbiter.m4 serial 1
+# mbiter.m4 serial 2
 dnl Copyright (C) 2005 Free Software Foundation, Inc.
 dnl This file is free software; the Free Software Foundation
 dnl gives unlimited permission to copy and/or distribute it,
@@ -10,5 +10,8 @@
 AC_DEFUN([gl_MBITER],
 [
   AC_REQUIRE([AC_TYPE_MBSTATE_T])
+  dnl The following line is that so the user can test HAVE_MBRTOWC before
+  dnl #include "mbiter.h" or "mbuiter.h".
+  AC_REQUIRE([gl_FUNC_MBRTOWC])
   :
 ])
--- /home/cvs/shishi/gl/m4/mktime.m4    2005/01/29 01:04:46     1.4
+++ /home/cvs/shishi/gl/m4/mktime.m4    2005/10/12 13:24:42     1.5
@@ -1,5 +1,5 @@
-# mktime.m4 serial 5
-dnl Copyright (C) 2002, 2003 Free Software Foundation, Inc.
+#serial 7
+dnl Copyright (C) 2002, 2003, 2005 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.
@@ -14,8 +14,8 @@
 # --------------
 AC_DEFUN([AC_FUNC_MKTIME],
 [AC_REQUIRE([AC_HEADER_TIME])dnl
-AC_CHECK_HEADERS(stdlib.h sys/time.h unistd.h)
-AC_CHECK_FUNCS(alarm)
+AC_CHECK_HEADERS_ONCE(sys/time.h)
+AC_CHECK_FUNCS_ONCE(alarm)
 AC_CACHE_CHECK([for working mktime], ac_cv_func_working_mktime,
 [AC_RUN_IFELSE([AC_LANG_SOURCE(
 [[/* Test program from Paul Eggert and Tony Leneis.  */
@@ -30,13 +30,8 @@
 # endif
 #endif
 
-#if HAVE_STDLIB_H
-# include <stdlib.h>
-#endif
-
-#if HAVE_UNISTD_H
-# include <unistd.h>
-#endif
+#include <stdlib.h>
+#include <unistd.h>
 
 #if !HAVE_ALARM
 # define alarm(X) /* empty */
--- /home/cvs/shishi/gl/m4/stdbool.m4   2005/01/29 01:04:46     1.3
+++ /home/cvs/shishi/gl/m4/stdbool.m4   2005/10/12 13:24:42     1.4
@@ -1,6 +1,6 @@
 # Check for stdbool.h that conforms to C99.
 
-dnl Copyright (C) 2002-2004 Free Software Foundation, Inc.
+dnl Copyright (C) 2002-2005 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.
@@ -70,10 +70,11 @@
          enum { j = false, k = true, l = false * true, m = true * 256 };
          _Bool n[m];
          char o[sizeof n == m * sizeof n[0] ? 1 : -1];
+         char p[-1 - (_Bool) 0 < 0 && -1 - (bool) 0 < 0 ? 1 : -1];
        ],
        [
          return (!a + !b + !c + !d + !e + !f + !g + !h + !i + !j + !k + !l
-                 + !m + !n + !o);
+                 + !m + !n + !o + !p);
        ],
        [ac_cv_header_stdbool_h=yes],
        [ac_cv_header_stdbool_h=no])])
--- /home/cvs/shishi/gl/m4/strcase.m4   2005/09/19 16:04:42     1.3
+++ /home/cvs/shishi/gl/m4/strcase.m4   2005/10/12 13:24:42     1.4
@@ -1,4 +1,4 @@
-# strcase.m4 serial 2
+# strcase.m4 serial 3
 dnl Copyright (C) 2002, 2005 Free Software Foundation, Inc.
 dnl This file is free software; the Free Software Foundation
 dnl gives unlimited permission to copy and/or distribute it,
@@ -29,7 +29,8 @@
 
 # Prerequisites of lib/strcasecmp.c.
 AC_DEFUN([gl_PREREQ_STRCASECMP], [
-  gl_FUNC_MBRTOWC
+  AC_REQUIRE([gl_FUNC_MBRTOWC])
+  :
 ])
 
 # Prerequisites of lib/strncasecmp.c.
--- /home/cvs/shishi/gl/m4/xreadlink.m4 2005/01/29 01:04:46     1.2
+++ /home/cvs/shishi/gl/m4/xreadlink.m4 2005/10/12 13:24:42     1.3
@@ -1,12 +1,14 @@
-# xreadlink.m4 serial 5
-dnl Copyright (C) 2002, 2003 Free Software Foundation, Inc.
+#serial 7
+dnl Copyright (C) 2002, 2003, 2005 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.
 
 AC_DEFUN([gl_XREADLINK],
 [
+  AC_LIBSOURCES([xreadlink.c, xreadlink.h])
+  AC_LIBOBJ([xreadlink])
+
   dnl Prerequisites of lib/xreadlink.c.
   AC_REQUIRE([gt_TYPE_SSIZE_T])
-  AC_CHECK_HEADERS_ONCE(unistd.h)
 ])

--- /home/cvs/shishi/gl/m4/gc-hmac-sha1.m4      2005/10/12 13:24:43     NONE
+++ /home/cvs/shishi/gl/m4/gc-hmac-sha1.m4      2005/10/12 13:24:43     1.1
# gc-hmac-sha1.m4 serial 1
dnl Copyright (C) 2005 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.

AC_DEFUN([gl_GC_HMAC_SHA1],
[
  AC_REQUIRE([gl_GC])
  AC_DEFINE(GC_USE_HMAC_SHA1, 1,
    [Define to if you want to support HMAC-SHA1 through GC.])
  if test "$ac_cv_libgcrypt" != yes; then
    gl_SHA1
    gl_HMAC_SHA1
    gl_MEMXOR
  fi
])
--- /home/cvs/shishi/gl/m4/gc-pbkdf2-sha1.m4    2005/10/12 13:24:43     NONE
+++ /home/cvs/shishi/gl/m4/gc-pbkdf2-sha1.m4    2005/10/12 13:24:43     1.1
# gc-pbkdf2-sha1.m4 serial 1
dnl Copyright (C) 2005 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.

AC_DEFUN([gl_GC_PBKDF2_SHA1],
[
  AC_LIBSOURCES([gc-pbkdf2-sha1.c])
  AC_LIBOBJ([gc-pbkdf2-sha1])
])
--- /home/cvs/shishi/gl/m4/gc.m4        2005/10/12 13:24:43     NONE
+++ /home/cvs/shishi/gl/m4/gc.m4        2005/10/12 13:24:43     1.1
# gc.m4 serial 1
dnl Copyright (C) 2005 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.

AC_DEFUN([gl_GC],
[
  AC_LIBSOURCES([gc.h, gc-gnulib.c, gc-libgcrypt.c])
  AC_ARG_WITH(libgcrypt,
    AS_HELP_STRING([--with-libgcrypt], [use libgcrypt for low-level crypto]),
    libgcrypt=$withval, libgcrypt=no)
  if test "$libgcrypt" != no; then
    AC_LIB_HAVE_LINKFLAGS([gcrypt])
  fi
  if test "$ac_cv_libgcrypt" = yes; then
    AC_CHECK_HEADER(gcrypt.h)
    AC_LIBOBJ([gc-libgcrypt])
  else
    AC_LIBOBJ([gc-gnulib])

    # Devices with randomness.
    # FIXME: Are these the best defaults?

    case "${target}" in
      *-openbsd*)
        NAME_OF_RANDOM_DEVICE="/dev/srandom"
        NAME_OF_PSEUDO_RANDOM_DEVICE="/dev/prandom"
        NAME_OF_NONCE_DEVICE="/dev/urandom"
          ;;
  
      *-netbsd*)
        NAME_OF_RANDOM_DEVICE="/dev/srandom"
        NAME_OF_PSEUDO_RANDOM_DEVICE="/dev/urandom"
        NAME_OF_NONCE_DEVICE="/dev/urandom"
          ;;
  
      *-solaris* | *-irix* | *-dec-osf* )
        NAME_OF_RANDOM_DEVICE="/dev/random"
        NAME_OF_PSEUDO_RANDOM_DEVICE="/dev/random"
        NAME_OF_NONCE_DEVICE="/dev/random"
          ;;
  
      *)
        NAME_OF_RANDOM_DEVICE="/dev/random"
        NAME_OF_PSEUDO_RANDOM_DEVICE="/dev/urandom"
        NAME_OF_NONCE_DEVICE="/dev/urandom"
          ;;
    esac
  
    AC_MSG_CHECKING([device with (strong) random data...])
    AC_ARG_ENABLE(random-device,
        AC_HELP_STRING([--enable-random-device],
                [device with (strong) randomness (for Nettle)]),
        NAME_OF_RANDOM_DEVICE=$enableval)
    AC_MSG_RESULT($NAME_OF_RANDOM_DEVICE)
  
    AC_MSG_CHECKING([device with pseudo random data...])
    AC_ARG_ENABLE(pseudo-random-device,
        AC_HELP_STRING([--enable-pseudo-random-device],
                [device with pseudo randomness (for Nettle)]),
        NAME_OF_PSEUDO_RANDOM_DEVICE=$enableval)
    AC_MSG_RESULT($NAME_OF_PSEUDO_RANDOM_DEVICE)
  
    AC_MSG_CHECKING([device with unpredictable data for nonces...])
    AC_ARG_ENABLE(nonce-device,
        AC_HELP_STRING([--enable-nonce-device],
                [device with unpredictable nonces (for Nettle)]),
        NAME_OF_NONCE_DEVICE=$enableval)
    AC_MSG_RESULT($NAME_OF_NONCE_DEVICE)
  
    if test "$cross_compiling" != yes; then
      AC_CHECK_FILE($NAME_OF_RANDOM_DEVICE,, AC_MSG_ERROR([[
        *** Device for (strong) random data $NAME_OF_RANDOM_DEVICE does not 
exist
      ]]))
      AC_CHECK_FILE($NAME_OF_PSEUDO_RANDOM_DEVICE,, AC_MSG_ERROR([[
        *** Device for pseudo-random data $NAME_OF_PSEUDO_RANDOM_DEVICE does 
not exist
      ]]))
      AC_CHECK_FILE($NAME_OF_NONCE_DEVICE,, AC_MSG_ERROR([[
        *** Device for unpredictable nonces $NAME_OF_NONCE_DEVICE does not exist
      ]]))
    else
      AC_MSG_NOTICE([[Cross compiling, assuming random devices exists...]])  
    fi
  
    # FIXME: Open+read 42 bytes+close twice and compare data.  Should differ.
  
    AC_DEFINE_UNQUOTED(NAME_OF_RANDOM_DEVICE, "$NAME_OF_RANDOM_DEVICE",
                     [defined to the name of the (strong) random device])
    AC_DEFINE_UNQUOTED(NAME_OF_PSEUDO_RANDOM_DEVICE,
                         "$NAME_OF_PSEUDO_RANDOM_DEVICE",
                     [defined to the name of the pseudo random device])
    AC_DEFINE_UNQUOTED(NAME_OF_NONCE_DEVICE, "$NAME_OF_NONCE_DEVICE",
                     [defined to the name of the unpredictable nonce device])
  fi
])

# Prerequisites of lib/gc.h
AC_DEFUN([gl_PREREQ_GC], [:])
--- /home/cvs/shishi/gl/m4/hmac-sha1.m4 2005/10/12 13:24:43     NONE
+++ /home/cvs/shishi/gl/m4/hmac-sha1.m4 2005/10/12 13:24:43     1.1
# hmac-sha1.m4 serial 1
dnl Copyright (C) 2005 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.

AC_DEFUN([gl_HMAC_SHA1],
[
  AC_LIBSOURCES([hmac.h, hmac-sha1.c])
  AC_LIBOBJ([hmac-sha1])
])
--- /home/cvs/shishi/gl/m4/memxor.m4    2005/10/12 13:24:43     NONE
+++ /home/cvs/shishi/gl/m4/memxor.m4    2005/10/12 13:24:43     1.1
# memxor.m4 serial 1
dnl Copyright (C) 2005 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.

AC_DEFUN([gl_MEMXOR],
[
  AC_LIBSOURCES([memxor.h, memxor.c])
  AC_LIBOBJ([memxor])
])
--- /home/cvs/shishi/gl/m4/sha1.m4      2005/10/12 13:24:43     NONE
+++ /home/cvs/shishi/gl/m4/sha1.m4      2005/10/12 13:24:43     1.1
# sha1.m4 serial 6
dnl Copyright (C) 2002, 2003, 2004, 2005 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.

AC_DEFUN([gl_SHA1],
[
  AC_LIBSOURCES([sha1.c, sha1.h])
  AC_LIBOBJ([sha1])

  dnl Prerequisites of lib/sha1.c.
  AC_REQUIRE([AC_C_BIGENDIAN])
  :
])
--- /home/cvs/shishi/gl/m4/stdint.m4    2005/10/12 13:24:43     NONE
+++ /home/cvs/shishi/gl/m4/stdint.m4    2005/10/12 13:24:43     1.1
# stdint.m4 serial 4
dnl Copyright (C) 2001-2002, 2004-2005 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 Bruno Haible.
dnl Test whether <stdint.h> is supported or must be substituted.

AC_DEFUN([gl_STDINT_H],
[dnl Check for <inttypes.h>.
AC_REQUIRE([gt_HEADER_INTTYPES_H])
dnl Check for <sys/inttypes.h>.
AC_CHECK_HEADERS([sys/inttypes.h])

AC_MSG_CHECKING([for stdint.h])
AC_CACHE_VAL(gl_cv_header_stdint_h, [
  AC_TRY_COMPILE([#include <stdint.h>], [],
    gl_cv_header_stdint_h=yes, gl_cv_header_stdint_h=no)])
AC_MSG_RESULT([$gl_cv_header_stdint_h])
if test $gl_cv_header_stdint_h = yes; then
  AC_DEFINE(HAVE_STDINT_H, 1,
            [Define if you have a working <stdint.h> header file.])
  STDINT_H=''
else
  STDINT_H='stdint.h'

  dnl Is long == int64_t ?
  AC_CACHE_CHECK([whether 'long' is 64 bit wide], gl_cv_long_bitsize_64, [
    AC_TRY_COMPILE([
#define POW63  ((((((long) 1 << 15) << 15) << 15) << 15) << 3)
#define POW64  ((((((long) 1 << 15) << 15) << 15) << 15) << 4)
typedef int array [2 * (POW63 != 0 && POW64 == 0) - 1];
], , gl_cv_long_bitsize_64=yes, gl_cv_long_bitsize_64=no)])
  if test $gl_cv_long_bitsize_64 = yes; then
    HAVE_LONG_64BIT=1
  else
    HAVE_LONG_64BIT=0
  fi
  AC_SUBST(HAVE_LONG_64BIT)

  dnl Is long long == int64_t ?
  AC_CACHE_CHECK([whether 'long long' is 64 bit wide], 
gl_cv_longlong_bitsize_64, [
    AC_TRY_COMPILE([
#define POW63  ((((((long long) 1 << 15) << 15) << 15) << 15) << 3)
#define POW64  ((((((long long) 1 << 15) << 15) << 15) << 15) << 4)
typedef int array [2 * (POW63 != 0 && POW64 == 0) - 1];
], , gl_cv_longlong_bitsize_64=yes, gl_cv_longlong_bitsize_64=no)])
  if test $gl_cv_longlong_bitsize_64 = yes; then
    HAVE_LONG_LONG_64BIT=1
  else
    HAVE_LONG_LONG_64BIT=0
  fi
  AC_SUBST(HAVE_LONG_LONG_64BIT)

fi
AC_SUBST(STDINT_H)
])




reply via email to

[Prev in Thread] Current Thread [Next in Thread]