Linux shared libraries - I'm confused

Matthias Walter walter at mail.math.uni-magdeburg.de
Thu Aug 16 04:33:06 PDT 2007


Steve Teale Wrote:

> I've seen it said that dmd does not support creation of Linux shared libraries, but I've also seen it said that you can use dmd -c to create a .o file, and then use gcc -shared ... to create an so. Can anyone clarify the position here please?
> 

AFAIK dmd cannot create position independent code. So, you can link it this way but the code is not guaranteed to work. But with gdc you can use -fpic to generate such code.

best regards
Matthias



More information about the Digitalmars-d mailing list