Compilation problems with GDC/GCC
DRex via Digitalmars-d-learn
digitalmars-d-learn at puremagic.com
Fri Apr 14 06:03:22 PDT 2017
On Friday, 14 April 2017 at 12:01:39 UTC, DRex wrote:
>
> the -r option redirects the linked object files into another
> object file, so the point being I can pass a D object and a C
> object to the linker and produce another object file.
>
> As for linking D files, do you mean passing the druntime
> libraries to ld? I used gdc -v and it gave me a whole bunch of
> info, it showed the an entry 'LIBRARY_PATH' which contains the
> path to libgphobos and libgdruntime as well as a whole bunch of
> other libs, i'm assuming that is what you are telling me to
> pass to the linker?
I have tried passing libgphobos2.a and libgdruntime.a (and at one
point every library in the folder I found those two libs in) to
ld to link with my D source, but it still throws a billion
'undefined reference' errors.
I really need help here, I have tried so many different things
and am losing my mind trying to get this to work.
the problem I have with passing the -r option to ld through gdc
is that -Wl is looking for libgcc_s.a which doesnt even exist on
the computer, which is annoying
More information about the Digitalmars-d-learn
mailing list