This is the mail archive of the gcc-bugs@gcc.gnu.org mailing list for the GCC project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]

Problems building a shared library...


Hi,

I have a rather large shared library that I'm trying to build. I'm using
the 970922 snapshot (with the patches to reg-edit.c, loop.c and
rtlanal.c) on an i586-pc-linux-gnulibc1 configuration.

During the linking phase the linker spews out thousands (literally) of
warning messages before finally running out of memory and giving up.

Here is a very brief listing of the warnings I'm getting:


-- lexer.o: In function `ostream::~ostream(void)':
/usr/local/include/stl/bstring.h:1615: multiple definition of
`ios::fill(void) const'
parser.o:/usr/local/include/stl/bstring.h:1615: first defined here
lexer.o: In function `ostream::~ostream(void)':
/usr/local/include/stl/bstring.h:2448: multiple definition of
`ios::fill(short)'
parser.o:/usr/local/include/stl/bstring.h:2448: first defined here
lexer.o: In function `ostream::~ostream(void)':
/usr/local/include/stl/alloc.h:526: multiple definition of
`ios::flags(void) const'
parser.o:/usr/local/include/stl/alloc.h:526: first defined here
lexer.o:/usr/local/include/stl/bstring.h:1376: multiple definition of
`ios::flags(unsigned
long)'
parser.o:/usr/local/include/stl/bstring.h:1376: first defined here
lexer.o:/usr/local/include/stl/bstring.h:1376: multiple definition of
`ios::precision(void)
 const'
parser.o:/usr/local/include/stl/bstring.h:1376: first defined here
lexer.o:/usr/local/include/g++/iostream.h:152: multiple definition of
`ios::precision(int)'
parser.o:/usr/local/include/g++/iostream.h:152: first defined here
lexer.o:/usr/local/include/g++/iostream.h:229: multiple definition of
`ios::setf(unsigned l
ong)'



Here's a snippet right before it croaks including some warnings about
symbol sizes changing????:



/usr/bin/ld: Warning: size of symbol
`bad_exception::bad_exception(void)' changed from 87 t
o 44 in exception.o
/usr/local/lib/gcc-lib/i586-pc-linux-gnulibc1/egcs-2.90.09/libgcc.a(exception.o):
In functi
on `bad_exception::~bad_exception(void)':
/usr/src/egcs-970922/gcc/./cp/exception.cc(.text+0x80): multiple
definition of `bad_excepti
on::~bad_exception(void)'
parser.o:/usr/local/include/stl/alloc.h:498: first defined here
/usr/bin/ld: Warning: size of symbol
`bad_exception::~bad_exception(void)' changed from 33
to 55 in exception.o
/usr/local/lib/gcc-lib/i586-pc-linux-gnulibc1/egcs-2.90.09/libgcc.a(new.o):
In function `ba
d_alloc::~bad_alloc(void)':
/usr/src/egcs-970922/gcc/./cp/new.cc(.text+0x0): multiple definition of
`bad_alloc::what(vo
id) const'
parser.o:/usr/local/include/stl/alloc.h:498: first defined here
/usr/bin/ld: Warning: size of symbol `bad_alloc::what(void) const'
changed from 130 to 29 i
n new.o
collect2: ld returned 1 exit status


This a very large library which extensively uses templates, the STL and
also incorporates some RTTI features as well. It  doesn't appear as if
any errors are encountered, there are just seems to be so many warnings
that the linker dies.

While building the snapshot I did get a warning about the FSF version of
libg++ (I have version 2.7.2.8) I'm using with respect to I/O
routines???? It scrolled by before I could read the whole thing. Could
someone please explain?

I've successfully compiled some small non-STL libraries and executables
using this snapshot without any problems.

Any help is greatly appreciated.

Thanks

-- Rick Harding

====================================================================
   ...Be careful whose advice you buy, but be patient with those
   who supply it. Advice is a form of nostalgia.  Dispensing it
   is a way of fishing the past from the disposal, wiping it off,
   painting over the ugly parts and recycling it for more	
   than it's worth...
                                         - K. Vonnegut
====================================================================


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]