/usr/lib/libldc.so: undefined reference to `ldc::ldc_version'

David Nadlinger code at klickverbot.at
Fri Apr 4 14:15:18 PDT 2014


Hi Konstantinos,

On 4 Apr 2014, at 22:48, Konstantinos Margaritis wrote:
> Oh, I must have misunderstood, I thought it was the shared version of
> libphobos-ldc.a, so that I would have smaller target binaries. Is it
> possible to have shared version of the libphobos-ldc.a libs for that?

Not yet.

To be precise, there actually is support for building druntime and 
Phobos as shared libraries in our CMake build system already. However, 
there is not much point to try using that yet, as the GC will not 
properly scan all the data yet, and module initialization might not work 
as expected either.

In theory, druntime has the required code in 2.064, or better, 2.065. 
But it still needs the attention of somebody to thoroughly test it and 
make any necessary adaptions for LDC. If you are interested in making 
druntime/Phobos work as a shared library, the best thing would probably 
just be to check out the merge-2.065 branch from Git, build with 
-DBUILD_SHARED_LIBS=ON and see what happens.

David


More information about the digitalmars-d-ldc mailing list