D-Programming-GDC/gdc — pull request #32 by jpf91 (2012-09-28 10:34:11+00:00)
Title: Preliminary shared runtime support in build system

This only adjusts the build system, no changes to the compiler or runtime are included. This allows specifying a ```PIC_FLAGS``` environment available to enable ```-fPIC``` when compiling and adds two new targets to the Makefiles: ```libgdruntime.so``` and ```libgphobos2.so```

This is meant to make the development of a shared runtime easier, but not for production use. The shared libraries are not built by default and they are not installed into the target system.

(The libraries are also not correctly versioned, but as shared library versioning depends on stable ABIs we can't decide anything here without phobos upstream)

When the shared runtime support is finished, we probably want to ship both static and shared libraries. But we probably wouldn't want the static library to be built with -fPIC so we'd have to make some changes in the Makefile to compile all files twice.

See also: http://gdcproject.org/wiki/SharedRuntime