Linker error when building dmd backend

Thomas Mader thomas.mader at gmail.com
Sun Dec 23 02:29:19 UTC 2018


On Sunday, 23 December 2018 at 00:11:05 UTC, Walter Bright wrote:
> On 12/22/2018 1:58 PM, Thomas Mader wrote:
>> Anybody an idea?
>
> It means the file evalu8.d was referencing a function or symbol 
> named "modulo" and the linker couldn't find it.
>
> 1) Look in evalu8.d for the reference.
>
> 2) grep "modulo" *.d to see where it may be.

To me it looks like fp.c has the implementation and evalu8 is 
using it.
The name mangling of fp.c compiled with g++ is different from 
evalu8.d compiled with ldc.
drtlsym.d seems to be creating a symbol and I guess that's 
somehow not working in my case.
But if I am right I also don't understand why drtlsym is needed 
at all. Wouldn't it be possible to just declare _modulo as 
extern( C++ ) in evalu8.d?

And how is it possible that drtlsym is not working in my case 
when it is for Archlinux with the same dependencies?
I have not yet found a difference which could explain the problem.


More information about the Digitalmars-d mailing list