public inbox for gcc@gcc.gnu.org
 help / color / mirror / Atom feed
* Bootstrap broken on darwin / fink
@ 2009-06-01 10:08 Tobias Schlüter
  2009-06-01 10:44 ` Joseph S. Myers
                   ` (2 more replies)
  0 siblings, 3 replies; 6+ messages in thread
From: Tobias Schlüter @ 2009-06-01 10:08 UTC (permalink / raw)
  To: gcc


Hi,

I'm seeing this error:

/Users/tobi/src/hggcc/build/./prev-gcc/xgcc 
-B/Users/tobi/src/hggcc/build/./prev-gcc/ 
-B/usr/local/i386-apple-darwin8.11.1/bin/ 
-B/usr/local/i386-apple-darwin8.11.1/bin/ 
-B/usr/local/i386-apple-darwin8.11.1/lib/ -isystem 
/usr/local/i386-apple-darwin8.11.1/include -isystem 
/usr/local/i386-apple-darwin8.11.1/sys-include    -c  -g -O2 
-fomit-frame-pointer -DIN_GCC   -W -Wall -Wwrite-strings -Wstrict-prototype
  -Wmissing-prototypes -Wcast-qual -Wold-style-definition -Wc++-compat 
-Wmissing-format-attribute -pedantic -Wno-long-long -Wno-variadic-macros 
-Wno-overlength-strings -Werror -fno-common  -DHAVE_CONFIG_H -I. -I. 
-I../../gcc -I../../gcc/. -I../..
gcc/../include -I./../intl -I../../gcc/../libcpp/include -I/sw/include 
-I../../gcc/../libdecnumber -I../../gcc/../libdecnumber/dpd 
-I../libdecnumber    ../../gcc/
retty-print.c -o pretty-print.o
cc1: warnings being treated as errors
../../gcc/pretty-print.c: In function 'identifier_to_locale':
../../gcc/pretty-print.c:1016: error: passing argument 2 of 'libiconv' 
from incompatible pointer type
/sw/include/iconv.h:83: note: expected 'char **' but argument is of type 
'const char **'
make[3]: *** [pretty-print.o] Error 1
make[3]: *** Waiting for unfinished jobs....
make[2]: *** [all-stage2-gcc] Error 2
make[1]: *** [stage2-bubble] Error 2
make: *** [all] Error 2


My libiconv identifies itself as
#define _LIBICONV_VERSION 0x010B    /* version number: (major<<8) + minor */

The complaint is about:
	      ICONV_CONST char *inbuf = CONST_CAST (char *, ident);
	      [...snip...]
	      iconv_ret = iconv (cd, &inbuf, &inbytesleft,
				 &outbuf, &outbytesleft);


Cheers,
- Tobi

^ permalink raw reply	[flat|nested] 6+ messages in thread

* Re: Bootstrap broken on darwin / fink
  2009-06-01 10:08 Bootstrap broken on darwin / fink Tobias Schlüter
@ 2009-06-01 10:44 ` Joseph S. Myers
  2009-06-01 13:27   ` Tobias Schlüter
  2009-06-01 13:18 ` Peter O'Gorman
  2009-06-01 14:20 ` Jack Howarth
  2 siblings, 1 reply; 6+ messages in thread
From: Joseph S. Myers @ 2009-06-01 10:44 UTC (permalink / raw)
  To: Tobias Schlüter; +Cc: gcc

[-- Attachment #1: Type: TEXT/PLAIN, Size: 730 bytes --]

On Mon, 1 Jun 2009, Tobias Schlüter wrote:

> The complaint is about:
> 	      ICONV_CONST char *inbuf = CONST_CAST (char *, ident);
> 	      [...snip...]
> 	      iconv_ret = iconv (cd, &inbuf, &inbytesleft,
> 				 &outbuf, &outbytesleft);

The types are exactly the same as in the corresponding code in 
libcpp/charset.c.

  ICONV_CONST char *inbuf;
      iconv (cd, &inbuf, &inbytesleft, &outbuf, &outbytesleft);

You'll need to work out what's different on your system between gcc and 
libcpp to make it work in one place only.  Note that iconv.m4 comes from 
gettext; it's possible the configure support has since been refined 
upstream and should be updated.

-- 
Joseph S. Myers
joseph@codesourcery.com

^ permalink raw reply	[flat|nested] 6+ messages in thread

* Re: Bootstrap broken on darwin / fink
  2009-06-01 10:08 Bootstrap broken on darwin / fink Tobias Schlüter
  2009-06-01 10:44 ` Joseph S. Myers
@ 2009-06-01 13:18 ` Peter O'Gorman
  2009-06-01 14:20 ` Jack Howarth
  2 siblings, 0 replies; 6+ messages in thread
From: Peter O'Gorman @ 2009-06-01 13:18 UTC (permalink / raw)
  To: Tobias Schlüter; +Cc: gcc

Tobias Schlüter wrote:

> cc1: warnings being treated as errors
> ../../gcc/pretty-print.c: In function 'identifier_to_locale':
> ../../gcc/pretty-print.c:1016: error: passing argument 2 of 'libiconv'
> from incompatible pointer type
> /sw/include/iconv.h:83: note: expected 'char **' but argument is of type
> 'const char **'

This would probably have been more appropriate on a fink related mailing
list.

As Joseph pointed out, configure is finding a different iconv.h than the
compiler, and they provide different prototypes for iconv(). I suggest
looking at Jack Howarth's gcc package in fink to see what he's doing
with this.

Peter
-- 
Peter O'Gorman
http://pogma.com

^ permalink raw reply	[flat|nested] 6+ messages in thread

* Re: Bootstrap broken on darwin / fink
  2009-06-01 10:44 ` Joseph S. Myers
@ 2009-06-01 13:27   ` Tobias Schlüter
  0 siblings, 0 replies; 6+ messages in thread
From: Tobias Schlüter @ 2009-06-01 13:27 UTC (permalink / raw)
  To: Joseph S. Myers; +Cc: gcc

Joseph S. Myers wrote:
> On Mon, 1 Jun 2009, Tobias Schlüter wrote:
> 
>> The complaint is about:
>> 	      ICONV_CONST char *inbuf = CONST_CAST (char *, ident);
>> 	      [...snip...]
>> 	      iconv_ret = iconv (cd, &inbuf, &inbytesleft,
>> 				 &outbuf, &outbytesleft);
> 
> The types are exactly the same as in the corresponding code in 
> libcpp/charset.c.
> 
>   ICONV_CONST char *inbuf;
>       iconv (cd, &inbuf, &inbytesleft, &outbuf, &outbytesleft);
> 
> You'll need to work out what's different on your system between gcc and 
> libcpp to make it work in one place only.  Note that iconv.m4 comes from 
> gettext; it's possible the configure support has since been refined 
> upstream and should be updated.
> 
In gcc/auto-host.h I have #define HAVE_ICONV_H, whereas in libcpp/ I 
haven't.  From PR31932, I presume that HAVE_ICONV_H should never be 
defined.  The check is explicitly made in AC_CHECK_HEADERS in 
gcc/configure.ac.  I can't see what happens if I remove the check as 
fink symlinks autoconf-2.59 to autoconf which in turn is a symlink to 
autoconf-2.63.

Cheers,
- Tobi

^ permalink raw reply	[flat|nested] 6+ messages in thread

* Re: Bootstrap broken on darwin / fink
  2009-06-01 10:08 Bootstrap broken on darwin / fink Tobias Schlüter
  2009-06-01 10:44 ` Joseph S. Myers
  2009-06-01 13:18 ` Peter O'Gorman
@ 2009-06-01 14:20 ` Jack Howarth
  2009-06-01 15:03   ` Tobias Schlüter
  2 siblings, 1 reply; 6+ messages in thread
From: Jack Howarth @ 2009-06-01 14:20 UTC (permalink / raw)
  To: Tobias Schlüter; +Cc: gcc

On Mon, Jun 01, 2009 at 12:07:56PM +0200, Tobias Schlüter wrote:
>
> Hi,
>
> I'm seeing this error:
>
> /Users/tobi/src/hggcc/build/./prev-gcc/xgcc  
> -B/Users/tobi/src/hggcc/build/./prev-gcc/  
> -B/usr/local/i386-apple-darwin8.11.1/bin/  
> -B/usr/local/i386-apple-darwin8.11.1/bin/  
> -B/usr/local/i386-apple-darwin8.11.1/lib/ -isystem  
> /usr/local/i386-apple-darwin8.11.1/include -isystem  
> /usr/local/i386-apple-darwin8.11.1/sys-include    -c  -g -O2  
> -fomit-frame-pointer -DIN_GCC   -W -Wall -Wwrite-strings 
> -Wstrict-prototype
>  -Wmissing-prototypes -Wcast-qual -Wold-style-definition -Wc++-compat  
> -Wmissing-format-attribute -pedantic -Wno-long-long -Wno-variadic-macros  
> -Wno-overlength-strings -Werror -fno-common  -DHAVE_CONFIG_H -I. -I.  
> -I../../gcc -I../../gcc/. -I../..
> gcc/../include -I./../intl -I../../gcc/../libcpp/include -I/sw/include  
> -I../../gcc/../libdecnumber -I../../gcc/../libdecnumber/dpd  
> -I../libdecnumber    ../../gcc/
> retty-print.c -o pretty-print.o
> cc1: warnings being treated as errors
> ../../gcc/pretty-print.c: In function 'identifier_to_locale':
> ../../gcc/pretty-print.c:1016: error: passing argument 2 of 'libiconv'  
> from incompatible pointer type
> /sw/include/iconv.h:83: note: expected 'char **' but argument is of type  
> 'const char **'
> make[3]: *** [pretty-print.o] Error 1
> make[3]: *** Waiting for unfinished jobs....
> make[2]: *** [all-stage2-gcc] Error 2
> make[1]: *** [stage2-bubble] Error 2
> make: *** [all] Error 2
>
>
> My libiconv identifies itself as
> #define _LIBICONV_VERSION 0x010B    /* version number: (major<<8) + minor */
>
> The complaint is about:
> 	      ICONV_CONST char *inbuf = CONST_CAST (char *, ident);
> 	      [...snip...]
> 	      iconv_ret = iconv (cd, &inbuf, &inbytesleft,
> 				 &outbuf, &outbytesleft);
>
>
> Cheers,
> - Tobi
>

Tobi,
  You didn't show the configure options you used to build gcc trunk against
the fink libraries. You need at least...

--with-gmp=/sw --with-libiconv-prefix=/sw --with-system-zlib --x-includes=/usr/X11R6/include  --x-libraries=/usr/X11R6/lib

Note that we don't set CPPFLAGS or LDFLAGS to have -I/sw/include or -L/sw/lib in the fink gcc packaging so that
only those libraries that we explicitly set are picked up from fink. All other cases should be picked up from
the system libraries.
                  Jack

^ permalink raw reply	[flat|nested] 6+ messages in thread

* Re: Bootstrap broken on darwin / fink
  2009-06-01 14:20 ` Jack Howarth
@ 2009-06-01 15:03   ` Tobias Schlüter
  0 siblings, 0 replies; 6+ messages in thread
From: Tobias Schlüter @ 2009-06-01 15:03 UTC (permalink / raw)
  To: Jack Howarth; +Cc: gcc


Hi Jack,

Jack Howarth wrote:
> You didn't show the configure options you used to build gcc trunk
> against the fink libraries. You need at least...
> 
> --with-gmp=/sw --with-libiconv-prefix=/sw --with-system-zlib
> --x-includes=/usr/X11R6/include  --x-libraries=/usr/X11R6/lib
> 
> Note that we don't set CPPFLAGS or LDFLAGS to have -I/sw/include or
> -L/sw/lib in the fink gcc packaging so that only those libraries that
> we explicitly set are picked up from fink. All other cases should be
> picked up from the system libraries.


I wasn't aware of this.  So far, I've only used --with-gmp=/sw and it 
worked like a charm, but I've not tried buildig gcc in a while, maybe I 
updated my fink tree in the meantime.  My guess is, that as libcpp 
doesn't use gmp it doesn't get the -I/sw/include, whereas gcc/ gets it 
from --with-gmp.  There are libiconvs in both /usr and /sw.

Both with --with-libiconv-prefix=/sw and --with-libiconv-prefix=/usr, 
the build still fails in the same place, i.e. the libiconv from /usr is 
not picked up even if explicitly requested.

Cheers,
- Tobi

^ permalink raw reply	[flat|nested] 6+ messages in thread

end of thread, other threads:[~2009-06-01 15:03 UTC | newest]

Thread overview: 6+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2009-06-01 10:08 Bootstrap broken on darwin / fink Tobias Schlüter
2009-06-01 10:44 ` Joseph S. Myers
2009-06-01 13:27   ` Tobias Schlüter
2009-06-01 13:18 ` Peter O'Gorman
2009-06-01 14:20 ` Jack Howarth
2009-06-01 15:03   ` Tobias Schlüter

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).