autoconf-patches
[Top][All Lists]
Advanced

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

Re: warning in AC_CHECK_DECL


From: Eric Blake
Subject: Re: warning in AC_CHECK_DECL
Date: Thu, 16 Feb 2006 12:36:58 -0700
User-agent: Mozilla Thunderbird 1.0.2 (Windows/20050317)

-----BEGIN PGP SIGNED MESSAGE-----
Hash: SHA1

According to Eric Blake on 2/15/2006 6:40 AM:
> Without this patch, AC_FUNC_STRERROR_R (and anything else that uses
> AC_CHECK_DECL) gets set incorrectly when configuring with gcc and
> CFLAGS='-Wall -Werror'.  For example, CVS head tar grabbed the wrong value
> (leading to another bug report against gnulib argp-help's unused variable
> when strerror_r is not found):

Followup - with the earlier patch fixed, now AC_FUNC_STRERROR_R has a
warning, that was making the -Wall -Werror compilation think that
strerror_r returned int instead of char* on cygwin.

2006-02-16  Eric Blake  <address@hidden>

        * lib/autoconf/functions.m4 (AC_FUNC_STRERROR_R): Avoid unused
        variable warning.

- --
Life is short - so eat dessert first!

Eric Blake             address@hidden
-----BEGIN PGP SIGNATURE-----
Version: GnuPG v1.4.1 (Cygwin)
Comment: Public key at home.comcast.net/~ericblake/eblake.gpg
Comment: Using GnuPG with Thunderbird - http://enigmail.mozdev.org

iD8DBQFD9NRZ84KuGfSFAYARAv1bAKCEuHiiOQpJJTbvqflD1L4WgHA7UgCgk5sR
QeXYktY6ZjON/T5hjuDeyBY=
=+5zc
-----END PGP SIGNATURE-----
Index: lib/autoconf/functions.m4
===================================================================
RCS file: /sources/autoconf/autoconf/lib/autoconf/functions.m4,v
retrieving revision 1.95
diff -u -p -r1.95 functions.m4
--- lib/autoconf/functions.m4   24 Jan 2006 00:20:15 -0000      1.95
+++ lib/autoconf/functions.m4   16 Feb 2006 19:35:33 -0000
@@ -1521,6 +1521,7 @@ AC_CACHE_CHECK([whether strerror_r retur
          char buf[100];
          char x = *strerror_r (0, buf, sizeof buf);
          char *p = strerror_r (0, buf, sizeof buf);
+         return !p || x;
        ]])],
                        ac_cv_func_strerror_r_char_p=yes)
     else

reply via email to

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