]> git.ipfire.org Git - thirdparty/gettext.git/commitdiff
Use argz_stringify instead of __argz_stringify when available.
authorBruno Haible <bruno@clisp.org>
Fri, 23 Jun 2006 16:29:25 +0000 (16:29 +0000)
committerBruno Haible <bruno@clisp.org>
Tue, 23 Jun 2009 10:13:26 +0000 (12:13 +0200)
gettext-runtime/intl/ChangeLog
gettext-runtime/intl/l10nflist.c
gettext-runtime/m4/ChangeLog
gettext-runtime/m4/gettext.m4

index 64d6e40b56a48f9d8ef2a6fc364a4b7710233e66..a620c53f68dc5fafb63200323a0fe58c8f824093 100644 (file)
@@ -1,3 +1,10 @@
+2006-06-23  Bruno Haible  <bruno@clisp.org>
+
+       * l10nflist.c (__argz_count, __argz_stringify, __argz_next): Define
+       using the non-underscored functions when available. Avoids warnings
+       on Cygwin.
+       Reported by Eric Blake.
+
 2006-06-19  Bruno Haible  <bruno@clisp.org>
 
        * libgnuintl.h.in (libintl_printf): Define to __printf__ on NetBSD,
index adcaa7f84a23b21c9d9167a9682f922b14576d51..365aeb708584575421404e091a10e3ac45a1caa7 100644 (file)
@@ -1,4 +1,4 @@
-/* Copyright (C) 1995-1999, 2000-2005 Free Software Foundation, Inc.
+/* Copyright (C) 1995-1999, 2000-2006 Free Software Foundation, Inc.
    Contributed by Ulrich Drepper <drepper@gnu.ai.mit.edu>, 1995.
 
    This program is free software; you can redistribute it and/or modify it
@@ -82,7 +82,12 @@ static char *stpcpy (char *dest, const char *src);
 
 /* Define function which are usually not available.  */
 
-#if !defined _LIBC && !defined HAVE___ARGZ_COUNT
+#ifdef _LIBC
+# define __argz_count(argz, len) INTUSE(__argz_count) (argz, len)
+#elif defined HAVE_ARGZ_COUNT
+# undef __argz_count
+# define __argz_count argz_count
+#else
 /* Returns the number of strings in ARGZ.  */
 static size_t
 argz_count__ (const char *argz, size_t len)
@@ -99,13 +104,15 @@ argz_count__ (const char *argz, size_t len)
 }
 # undef __argz_count
 # define __argz_count(argz, len) argz_count__ (argz, len)
-#else
-# ifdef _LIBC
-#  define __argz_count(argz, len) INTUSE(__argz_count) (argz, len)
-# endif
-#endif /* !_LIBC && !HAVE___ARGZ_COUNT */
+#endif /* !_LIBC && !HAVE_ARGZ_COUNT */
 
-#if !defined _LIBC && !defined HAVE___ARGZ_STRINGIFY
+#ifdef _LIBC
+# define __argz_stringify(argz, len, sep) \
+  INTUSE(__argz_stringify) (argz, len, sep)
+#elif defined HAVE_ARGZ_STRINGIFY
+# undef __argz_stringify
+# define __argz_stringify argz_stringify
+#else
 /* Make '\0' separated arg vector ARGZ printable by converting all the '\0's
    except the last into the character SEP.  */
 static void
@@ -122,14 +129,13 @@ argz_stringify__ (char *argz, size_t len, int sep)
 }
 # undef __argz_stringify
 # define __argz_stringify(argz, len, sep) argz_stringify__ (argz, len, sep)
-#else
-# ifdef _LIBC
-#  define __argz_stringify(argz, len, sep) \
-  INTUSE(__argz_stringify) (argz, len, sep)
-# endif
-#endif /* !_LIBC && !HAVE___ARGZ_STRINGIFY */
+#endif /* !_LIBC && !HAVE_ARGZ_STRINGIFY */
 
-#if !defined _LIBC && !defined HAVE___ARGZ_NEXT
+#ifdef _LIBC
+#elif defined HAVE_ARGZ_NEXT
+# undef __argz_next
+# define __argz_next argz_next
+#else
 static char *
 argz_next__ (char *argz, size_t argz_len, const char *entry)
 {
@@ -148,7 +154,7 @@ argz_next__ (char *argz, size_t argz_len, const char *entry)
 }
 # undef __argz_next
 # define __argz_next(argz, len, entry) argz_next__ (argz, len, entry)
-#endif /* !_LIBC && !HAVE___ARGZ_NEXT */
+#endif /* !_LIBC && !HAVE_ARGZ_NEXT */
 
 
 /* Return number of bits set in X.  */
index d9335684ac505d227fa4426da2e3b4ab473d84af..58e7614071ab6ceed167b22344d489f30afe0f01 100644 (file)
@@ -1,3 +1,9 @@
+2006-06-23  Bruno Haible  <bruno@clisp.org>
+
+       * gettext.m4 (gt_INTL_SUBDIR_CORE): Check for argz_* functions,
+       not __argz*. Avoids warnings on Cygwin.
+       Reported by Eric Blake.
+
 2006-06-17  Bruno Haible  <bruno@clisp.org>
 
        * gettext.m4 (AM_INTL_SUBDIR): Don't redefine __libc_rwlock_* symbols.
index 5f834100e2cf66a4e6a98c9fd5e744ba3d5849fe..0aca24a40fdf28e54e00d35775130047c7f9da87 100644 (file)
@@ -1,4 +1,4 @@
-# gettext.m4 serial 51 (gettext-0.15)
+# gettext.m4 serial 52 (gettext-0.15)
 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,
@@ -511,8 +511,8 @@ AC_DEFUN([gt_INTL_SUBDIR_CORE],
 
   AC_CHECK_HEADERS([argz.h limits.h unistd.h sys/param.h])
   AC_CHECK_FUNCS([getcwd getegid geteuid getgid getuid mempcpy munmap \
-    stpcpy strcasecmp strdup strtoul tsearch __argz_count __argz_stringify \
-    __argz_next __fsetlocking])
+    stpcpy strcasecmp strdup strtoul tsearch argz_count argz_stringify \
+    argz_next __fsetlocking])
 
   dnl Use the *_unlocked functions only if they are declared.
   dnl (because some of them were defined without being declared in Solaris