This is the mail archive of the
mailing list for the GCC project.
Using --disable-shared to build non-apple gcc on darwin
- From: Peter O'Gorman <pogma at opendarwin dot org>
- To: gcc at gcc dot gnu dot org
- Date: Tue, 07 Sep 2004 21:59:56 +0900
- Subject: Using --disable-shared to build non-apple gcc on darwin
First, I'd like to apologize if this is a silly question, sorry...
When gcc is built having been configured --disable-shared, it builds libgcc,
libstdc++ etc without any pic flags, so on darwin, the fortran libraries,
for example, contain common symbols (gcc-3.4.1) and cannot be used as input
to ld when building a shared library (.dylib). Also, in the FSF gcc (not the
apple branch), there's no comcept of private external symbols, so generating
multiple shared libraries (obviously not fortran ones :-p) and then using
these to create a program will likely give you errors about multiple
definitions of symbols (these symbols having made their way into many shared
libs by virtue of being global symbols in libgcc).
My questions is, is this by design? Should we not expect to be able to build
working shared libraries with a compiler built --disable-shared?