Java > Scala

Martin Nowak dawg at dawgfoto.de
Wed Nov 30 07:36:24 PST 2011


On Wed, 30 Nov 2011 09:19:59 +0100, Walter Bright  
<newshound2 at digitalmars.com> wrote:

> On 11/29/2011 11:46 PM, Jacob Carlborg wrote:
>> I agree. The shared library problem is blocked by DMD not being able to
>> correctly generate PIC.
>
> The compiler does correctly generate PIC code on Linux. The problem is  
> nobody has figured out the details of making Phobos/Druntime a shared  
> library.
>
> I.e. there's more to creating a shared library than throwing -fPIC.

I just had a look at creating shared libraries yesterday.
The dynamic loader was complaining about some unsupported
relocations (R_X86_64_32 with fPIC).

What are the known remaining issues?

I was also wondering whether using the gc_proxy is the best decision for  
Windows.
On POSIX the GC symbols can be left undefined in the shared library
and are resolved by the dynamic loader.
The module infos could be added to a global list during _init and
removed during _fini. This approach works for runtime loading as well
as for linking to shared libs.

martin


More information about the Digitalmars-d mailing list