This is the mail archive of the
cygwin-developers@cygwin.com
mailing list for the Cygwin project.
Re: building the gcc-3.2-3 bootstrap fails on libstdc++-v3
- From: Corinna Vinschen <vinschen at redhat dot com>
- To: cygwin-developers at cygwin dot com
- Date: Tue, 17 Dec 2002 14:05:20 +0100
- Subject: Re: building the gcc-3.2-3 bootstrap fails on libstdc++-v3
- References: <F0E13277A26BD311944600500454CCD064EC3C@antarctica.intern.net> <Pine.WNT.4.44.0212171005370.268-100000@algeria.intern.net>
- Reply-to: cygwin-developers at cygwin dot com
On Tue, Dec 17, 2002 at 10:12:47AM +0100, Thomas Pfaff wrote:
> On Mon, 16 Dec 2002, Christopher Faylor wrote:
>
> > On Mon, Dec 16, 2002 at 03:26:27AM -0800, James Michael DuPont wrote:
> > >As promised, I have started to check the releases
> > >of cygwin by bootstrapping them.
> > >This one got pretty far, all the way to libstdc++-v3.
> > >
> > >The error is :
> > >../../../../include/getopt.h:115: declaration of C function `int
> > >getopt()'
> > > conflicts with
> > >/usr/include/sys/unistd.h:125: previous declaration `int getopt(int,
> > >char* const*, const char*)' here
> >
> > In case it isn't clear, I *do not care* about this problem. I am able to
> > [more venting]
> > How many times do I have to say this???
>
> Chris,
>
> IMHO the easiest way to fix this is to remove the getopt prototype from
> unistd.h and include getopt.h instead. This will define HAVE_DECL_GETOPT
> and the build will not fail. I might create a patch if you agree.
Unfortunately this is newlib. Adding the getopt prototype unconditionally
in July was obviously not combined with testing this on Cygwin. :-(
AFAICS, the prototypes should be in a `#ifndef __CYGWIN__' bracket or
(better) in a `#ifndef __GETOPT_H__' bracket plus defining __GETOPT_H__.
> Otherwise you have to say this again and again i suppose.
Presumably you're right.
Corinna
--
Corinna Vinschen Please, send mails regarding Cygwin to
Cygwin Developer mailto:cygwin@cygwin.com
Red Hat, Inc.