[Top][All Lists]
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: [GNU Bison 2.4.2] testsuite: Failing tests of bison 2.4.2 on Solaris
From: |
Eric Blake |
Subject: |
Re: [GNU Bison 2.4.2] testsuite: Failing tests of bison 2.4.2 on Solaris 8+9 w/Sun Studio 11+12 |
Date: |
Tue, 20 Apr 2010 16:47:46 -0600 |
User-agent: |
Mozilla/5.0 (X11; U; Linux i686; en-US; rv:1.9.1.9) Gecko/20100330 Fedora/3.0.4-1.fc12 Lightning/1.0b1 Thunderbird/3.0.4 |
On 04/20/2010 04:37 PM, Joel E. Denny wrote:
> On Tue, 20 Apr 2010, Eric Blake wrote:
>
>>>>> if you use autoconf 2.64 (prior to that, if the existence and
>>>>> compilation checks disagree, autoconf went with the existence check).
>>>>
>>>> We are using autoconf 2.65.
>>
>> Then I'm confused how /opt/csw/include/getopt.h is getting included at
>> all in the first place.
>
> I guess the check only tries cc. Recall that bison is compiled with cc,
> but some test groups need CC.
>
>> What does config.log say about getopt?
>
> configure:6857: checking for getopt.h
> configure:6857: cc -c -g -I/opt/csw/include conftest.c >&5
> configure:6857: $? = 0
> configure:6857: result: yes
Okay, so the problem is that the header works for C, where getopt.h is
adequate, and we don't have the granularity at the moment to repeat
header checks for C++.
I'm assuming that later in configure we reject -lgnugetopt's getopt_long
as broken (unless libgnugetopt has somehow picked up this month's glibc
fix), meaning that we still want to declare rpl_getopt and friends; the
conflict in getopt() is irrelevant if we are going to be declaring a
replacement anyways.
Meanwhile, as you reported:
>>From /opt/csw/include/getopt.h:
>
> ------------------------------
> #if defined (__STDC__) && __STDC__
> #ifdef __GNU_LIBRARY__
> /* Many other libraries have conflicting prototypes for getopt, with
> differences in the consts, in stdlib.h. To avoid compilation
> errors, only prototype getopt for the GNU C library. */
> extern int getopt (int argc, char *const *argv, const char *shortopts);
> #else /* not __GNU_LIBRARY__ */
> extern int getopt ();
> #endif /* __GNU_LIBRARY__ */
> ...
> #else /* not __STDC__ */
> extern int getopt (); <---------- line 122, where the error is reported
> ...
> endif /* __STDC__ */
since __STDC__ is 0 under CC but 1 under g++, maybe the best fix would
be to make /opt/csw/include/getopt.h drop the check for the value of
__STDC__? Or have gnulib's getopt.h explicitly define __STDC__ to 1?
Or do we modify the logic in getopt.m4 that sets @HAVE_GETOPT_H@ to
instead check two language-dependent values, one for C and one for C++,
such that the #include_next <getopt.h> only occurs for languages where
it will work?
--
Eric Blake address@hidden +1-801-349-2682
Libvirt virtualization library http://libvirt.org
signature.asc
Description: OpenPGP digital signature
- Re: [GNU Bison 2.4.2] testsuite: Failing tests of bison 2.4.2 on Solaris 8+9 w/Sun Studio 11+12, (continued)
- Re: [GNU Bison 2.4.2] testsuite: Failing tests of bison 2.4.2 on Solaris 8+9 w/Sun Studio 11+12, Joel E. Denny, 2010/04/15
- Re: [GNU Bison 2.4.2] testsuite: Failing tests of bison 2.4.2 on Solaris 8+9 w/Sun Studio 11+12, Eric Blake, 2010/04/15
- Re: [GNU Bison 2.4.2] testsuite: Failing tests of bison 2.4.2 on Solaris 8+9 w/Sun Studio 11+12, Bruno Haible, 2010/04/15
- Re: [GNU Bison 2.4.2] testsuite: Failing tests of bison 2.4.2 on Solaris 8+9 w/Sun Studio 11+12, Paolo Bonzini, 2010/04/16
- Re: [GNU Bison 2.4.2] testsuite: Failing tests of bison 2.4.2 on Solaris 8+9 w/Sun Studio 11+12, Bruno Haible, 2010/04/16
- Re: [GNU Bison 2.4.2] testsuite: Failing tests of bison 2.4.2 on Solaris 8+9 w/Sun Studio 11+12, Eric Blake, 2010/04/16
- Re: [GNU Bison 2.4.2] testsuite: Failing tests of bison 2.4.2 on Solaris 8+9 w/Sun Studio 11+12, Joel E. Denny, 2010/04/20
- Re: [GNU Bison 2.4.2] testsuite: Failing tests of bison 2.4.2 on Solaris 8+9 w/Sun Studio 11+12, Dagobert Michelsen, 2010/04/20
- Re: [GNU Bison 2.4.2] testsuite: Failing tests of bison 2.4.2 on Solaris 8+9 w/Sun Studio 11+12, Eric Blake, 2010/04/20
- Re: [GNU Bison 2.4.2] testsuite: Failing tests of bison 2.4.2 on Solaris 8+9 w/Sun Studio 11+12, Joel E. Denny, 2010/04/20
- Re: [GNU Bison 2.4.2] testsuite: Failing tests of bison 2.4.2 on Solaris 8+9 w/Sun Studio 11+12,
Eric Blake <=
- Re: [GNU Bison 2.4.2] testsuite: Failing tests of bison 2.4.2 on Solaris 8+9 w/Sun Studio 11+12, Joel E. Denny, 2010/04/20
- Re: [GNU Bison 2.4.2] testsuite: Failing tests of bison 2.4.2 on Solaris 8+9 w/Sun Studio 11+12, Paolo Bonzini, 2010/04/21
- Re: [GNU Bison 2.4.2] testsuite: Failing tests of bison 2.4.2 on Solaris 8+9 w/Sun Studio 11+12, Joel E. Denny, 2010/04/22
- Re: [GNU Bison 2.4.2] testsuite: Failing tests of bison 2.4.2 on Solaris 8+9 w/Sun Studio 11+12, Dagobert Michelsen, 2010/04/25
- Re: [GNU Bison 2.4.2] testsuite: Failing tests of bison 2.4.2 on Solaris 8+9 w/Sun Studio 11+12, Bruno Haible, 2010/04/25
- Re: [GNU Bison 2.4.2] testsuite: Failing tests of bison 2.4.2 on Solaris 8+9 w/Sun Studio 11+12, Joel E. Denny, 2010/04/26
- Re: [GNU Bison 2.4.2] testsuite: Failing tests of bison 2.4.2 on Solaris 8+9 w/Sun Studio 11+12, Dagobert Michelsen, 2010/04/26
- Re: [GNU Bison 2.4.2] testsuite: Failing tests of bison 2.4.2 on Solaris 8+9 w/Sun Studio 11+12, Paolo Bonzini, 2010/04/26
- Re: [GNU Bison 2.4.2] testsuite: Failing tests of bison 2.4.2 on Solaris 8+9 w/Sun Studio 11+12, Eric Blake, 2010/04/26