[sword-devel] Answers: gcc vs egcs and linking statically
Troy A. Griffitts
sword-devel@crosswire.org
Mon, 10 Apr 2000 02:47:09 -0700
Thanks for the feedback!!! This will come in very handy. I will try to
use these compiler flags when linking the final binaries. I'll let ya
know how it goes.
> there are two questions / problems that I can help with:
>
> 1. gcc vs egcs
> gcc 2.8 is dead and egcs is the official gnu compiler. gcc 2.95.x is
> really egcs heading for gcc 3
>
> 2. statically linking
> there are two possible ways for linking some specific libraries static
> while all the others remain dynamically:
>
> - present the full path of libLIB.a to the linker (this solution is
> dependent to your personal system and should not be used in public
> makefiles)
>
> - command the linker explicit to link some libraries static:
> g++ [...] -Wl,-Bstatic -lqt -Wl,-Bdynamic [...]
> `-Wl,OPTION'
> Pass OPTION as an option to the linker. If OPTION contains
> commas, it is split into multiple options at the commas.
> [from gcc.info]
> This one should be used for public Makefiles.
>
> BTW: Reading the manuals (like the bible) is a great thing to do ;-))