Shared library ld issue?
Mineko
uminekorox at gmail.com
Sun Dec 29 01:41:13 PST 2013
So, these are the commands I put in:
../gdc/x86_64/gdc -c -fPIC -B ../gdc/x86_64 -I
../gdc/x86_64/phobos test.d
This one worked fine, as expected.
The problem is here:
../gdc/x86_64/gdc -lgphobos2 -shared -B ../gdc/x86_64 test.o -o
test.so
And this is what the problem outputs:
ld: /lib/../lib64/libgphobos2.a(minfo.o): relocation R_X86_64_32
against `_D32TypeInfo_APxS6object10ModuleInfo6__initZ' can not be
used when making a shared object; recompile with -fPIC
/lib/../lib64/libgphobos2.a: error adding symbols: Bad value
I'm obviously compiling with -fPIC.
I've been googling this for hours straight and still don't know
what to do, perhaps someone here could impart on me some
knowledge?
More information about the Digitalmars-d-learn
mailing list