On Fri, 23 Jul 2010 06:50:08 -0400, Michel Fortin
<[email protected]> wrote:
When manually calling the linker, which libraries should be linked with
a d object file? If I run dmd with the -v option on Mac OS X, I notice
dmd issues the following linker command:
gcc test.o -o test -m32 -Xlinker
-L/Library/Compilers/dmd2/osx/bin/../lib -lphobos2 -lpthread -lm
which includes library phobos2 but not druntime. I've made D for Xcode
link both phobos2 and druntime in the final executable; this cause no
problem on Mac OS X 10.6 (Snow Leopard) but I have a user on 10.5
(Leopard) who gets duplicate symbols in druntime and phobos2 because of
this.
So now I wonder, is druntime included into the phobos2 library? Is this
how it should be?
This is what happens. How should it be? Does it matter? Everything is
linked statically anyways. If it was a dynamic lib, then we need to
address it.
What I find odd is that libdruntime.a is in the lib subdir even though
it's never used.
-Steve