(Solved) Re: Compilation phobos errors with DMD 2.071,2.072 or dub
Ozan (ONS) via Digitalmars-d-learn
digitalmars-d-learn at puremagic.com
Fri Nov 4 02:13:45 PDT 2016
On Thursday, 3 November 2016 at 14:52:26 UTC, Ozan (ONS) wrote:
> Hi,
>
> with a fresh Ubuntu 16.10 installation using "Hello, World" I
> got a list of following errors like:
> /usr/bin/ld:
> /usr/lib/x86_64-linux-gnu/libphobos2.a(thread_256_713.o):
> relocation R_X86_64_32 against symbol
> `_D6object9Throwable7__ClassZ' can not be used when making a
> shared object; recompile with -fPIC
>
> Example: Using dmd 2.071 and dub; dub init appName; compile
> appName with dub.
> Or direct with dmd
>
> What I'm missing? Any hints?
>
> Thanks & Regards, Ozan
Solved through changing content of /etc/dmd.conf to
[Environment32]
DFLAGS=-I/usr/include/dmd/phobos
-I/usr/include/dmd/druntime/import -L-L/usr/lib/i386-linux-gnu
-L--export-dynamic -fPIC -defaultlib=libphobos2.so
[Environment64]
DFLAGS=-I/usr/include/dmd/phobos
-I/usr/include/dmd/druntime/import -L-L/usr/lib/x86_64-linux-gnu
-L--export-dynamic -fPIC -defaultlib=libphobos2.so
Thanks for the hints,
Ozan
More information about the Digitalmars-d-learn
mailing list