On Saturday 11 December 2010 11:48:36 David Nadlinger wrote: > On 12/11/10 8:30 PM, Jonathan M Davis wrote: > > You don't need that compatability with dlls? _That_ I did not know. That > > would help a _lot_ in my case then, because most of our projects are > > shared libraries. It doesn't entirely solve the problem, but in this > > case, it's enough that it may make it feasible to actually do some stuff > > in D. > > Yes, you don't need object file compatibility if you don't link in the > DLL via an implib, but instead look up the symbols dynamically (e.g. via > LoadLibrary/GetProcAddress on Windows). > > If I remember correctly, there are some tools for generating OMF implibs > as well, but they have never worked for me… > > By the way, this reminds me that we desperately need solid > cross-platform dynamic library support in Phobos – std.loader is > undocumented, does not conform to the Phobos coding style, and exposes a > very strange API (ExeModule is a scope class? WTF?). In SWIG, for > example, I use a homegrown solution based on the loading code from > Derelict2, but I'd very much prefer having this in Phobos. > > This will probably get even more important if shared library support > will eventually be added to DMD (When was this scheduled to happen > again? After 64bit support and fixing the const system?).
I expect that the loader would be fixed after shared library support in the compiler was fixed. Shared library support was supposed to be after 64-bit support, but there has been talk about fixing the const stuff next, so I don't know if shared library support is really going to happen immediately following 64-bit support or not. It's high on the list though. - Jonathan M Davis
