Status of Dynamically Loadable D Libraries

Maxim Fomin maxim at maxim-fomin.ru
Sun Feb 10 22:25:55 PST 2013


On Sunday, 10 February 2013 at 22:11:52 UTC, Nick Ulle wrote:
> What's the current status of dynamic loading (and/or linking) 
> for D libraries?
>
> I've been playing with this a bit in hopes of calling a D 
> shared library from R through the C ABI, and noticed that on 
> Windows it seems fine, but on Linux dmd won't build my library 
> unless it includes main(), and it segfaults if I call writeln().

Dynamic linking works in linux (at least observed features work, 
see example 
http://forum.dlang.org/thread/k3vfm9$1tq$1@digitalmars.com?page=2). 
Dynamic loading does not work.

> Is supporting dynamically loadable libraries a priority for the 
> developers, or something that might not happen for a while?

Yes, couple of days ago Walter announced that shared libraries is 
priority and he will get into this after releasing new dmd 
version.


More information about the Digitalmars-d mailing list