[D-runtime] Arghhh, DLLs broken on Win32 *again*!
Rainer Schuetze
r.sagitario at gmx.de
Sun Mar 25 10:48:58 PDT 2012
On 3/21/2012 6:29 PM, Walter Bright wrote:
> Nobody liked my .sh version of the win32 tests :-)
I guess that's because you are using your home-grown version of shell.exe.
I have made a few changes to the tests:
- static linking of DLLs work if you export the module info symbol (GDC
seems to do this by default)
- dynamic linking, but still importing the d file, can sometimes work if
you use a di file instead without further dependencies and without
static constructor/destructor.
Here's a pull request to fix the building and running of the tests:
https://github.com/D-Programming-Language/dmd/pull/841
but
- you still need the digital mars shell
- you have to add implib.exe to the build server (I would not mind
adding it together with coffimplib.exe to the dmd distrbution). The
optlink /IMPLIB is too buggy to be used.
- you should change the paths at the top of runtests.sh
> The documentation here:
>
> http://dlang.org/dll.html
>
> must work. The test cases, druntime, and the documentation must all be
> in sync.
As said some times before: the current examples of sharing the GC
between different DLLs are very limited, they don't support any other
sharing (threads, files, C-heap) and do not support multi-threading. I
would suggest to either nuke that part of the documentation or put a big
warning to this effect at the top of the respective paragraph.
Rainer
More information about the D-runtime
mailing list