Test suite for shared libraries and D
Switch branches/tags
Nothing to show
Fetching latest commit…
Cannot retrieve the latest commit at this time.
Failed to load latest commit information.


A small test suite for shared libraries and D

Supported compilers:

Only gdc is supported currently. See also http://gdcproject.org/wiki/SharedRuntime

Using the testsuite:

Use the Makefile/make to compile and run the tests:


  • libdso.so: build shared library

  • app: build app (shared druntime/phobos/libdso)

  • sapp: build sapp (static druntime/phobos/libdso)

  • sdapp: build sdapp (static druntime/phobos, shared libdso)

  • test: run app (shared druntime/phobos/libdso)

  • stest: run sapp (static druntime/phobos/libdso)

  • sdtest: run sdapp (static druntime/phobos, shared libdso)

  • ldd: ldd app (shared druntime/phobos/libdso)

  • sldd: ldd sapp (static druntime/phobos/libdso)

  • sdldd: ldd sdapp (static druntime/phobos, shared libdso)

Known problems

Problems that also happen with static runtime:

  • Collateral exceptions don't work. Grep for @@FIXME@@: Collateral exceptions
  • Some stuff should be moved out of dmain2.d: _d_assert, ... This functionality must be available even if the main app isn't written in D and dmain2.o is never linked in.

Problems that only happen with shared runtime:

  • TLS section, __gshared and static data in shared libraries is not scanned by GC (stack seems to be working)
  • Because of that a shared druntime/phobos will often crash after the first GC collection