I've tried several times now to compile the latest libstdc++ on my box. 
It makes just fine with libc5, but when I try to make a glibc cross
version it bombs out on me.

Everything moves along fine until it gets to the libio section, in
particular stdstrbufs.cc.  On this command, it gives me the following
error:

  c++ -c -O2 -g -fvtable-thunks -fno-implicit-templates -I. -I.
-nostdinc++ -D_IO_MTSAFE_IO -fpic stdstrbufs.cc -o pic/stdstrbufs.o

stdstrbufs.cc:67: syntax error before `='
stdstrbufs.cc:67: `_IO_stdfile_0_lock' was not declared in this scope
stdstrbufs.cc:67: warning: excess elements in aggregate initializer
stdstrbufs.cc:68: syntax error before `='
stdstrbufs.cc:68: `_IO_stdfile_1_lock' was not declared in this scope
stdstrbufs.cc:68: warning: excess elements in aggregate initializer
stdstrbufs.cc:69: syntax error before `='
stdstrbufs.cc:70: `_IO_stdfile_2_lock' was not declared in this scope
stdstrbufs.cc:70: warning: excess elements in aggregate initializer
make[1]: *** [stdstrbufs.o] Error 1
make[1]: Leaving directory
`/usr/home/shanew/libstdc++-2.8.1.1/libraries/libio'
make: *** [all-target-libio] Error 2



Now, taking a look at that file around line 57 we have:

#ifdef _IO_MTSAFE_IO
#define DEF_STDFILE(NAME, FD, CHAIN, FLAGS) \
  static _IO_lock_t _IO_stdfile_##FD##_lock = _IO_lock_initializer; \
  struct _IO_FILE_plus NAME \
    = {FILEBUF_LITERAL(CHAIN, FLAGS, FD), STD_VTABLE}
#else
#define DEF_STDFILE(NAME, FD, CHAIN, FLAGS) \
  struct _IO_FILE_plus NAME = {FILEBUF_LITERAL(CHAIN, FLAGS, FD),
STD_VTABLE}
#endif

DEF_STDFILE(_IO_stdin_, 0, 0, _IO_NO_WRITES);
DEF_STDFILE(_IO_stdout_, 1, &_IO_stdin_.file, _IO_NO_READS);
DEF_STDFILE(_IO_stderr_, 2, &_IO_stdout_.file,
            _IO_NO_READS+_IO_UNBUFFERED);


Which, since my knowledge of c++ is weak at best is mostly just
gobbledy-gook.  Anyone have any ideas?  Has anyone else upgraded to
glibc at all?  The newest g++?  I have read in some places that the way
to go is egcs, and I may explore that, but I would prefer not to further
complicate the choice of compilers on my system.  Anyway, any help is
much appreciated.  


-- 
Public key at www-swiss.ai.mit.edu |                 Shane Williams
/~bal/pks-toplev.html              | Systems Administrator UT-GSLIS
=----------------------------------+-------------------------------
All syllogisms contain three lines |         [EMAIL PROTECTED]
Therefore this is not a syllogism  |   www.gslis.utexas.edu/~shanew
---------------------------------------------------------------------------
Send administrative requests to [EMAIL PROTECTED]

Reply via email to