Linker error when building dmd backend

Thomas Mader thomas.mader at gmail.com
Sat Dec 22 23:02:04 UTC 2018


On Saturday, 22 December 2018 at 22:40:18 UTC, Stefan Koch wrote:
> On Saturday, 22 December 2018 at 21:58:13 UTC, Thomas Mader 
> wrote:
>> Hello,
>>
>> I updated dmd on NixOS from 2.081.2 to 2.083.1 but get the 
>> following linker errors when the backend is linked:
>>
>> ../generated/linux/release/64/backend.a(evalu8.o):dmd/backend/evalu8.d:function evalu8(elem*, unsigned int): error: undefined reference to '_Z7_moduloeS_'
>> ../generated/linux/release/64/backend.a(evalu8.o):dmd/backend/evalu8.d:function evalu8(elem*, unsigned int): error: undefined reference to '_Z7_moduloeS_'
>> ../generated/linux/release/64/backend.a(evalu8.o):dmd/backend/evalu8.d:function evalu8(elem*, unsigned int): error: undefined reference to '_Z7_moduloeS_'
>> collect2: error: ld returned 1 exit status
>> Error: 
>> /nix/store/klci955kxil7q32ggran6lnhpnkk8yjz-gcc-wrapper-7.3.0/bin/c++ failed with status: 1
>>
>> I use ldc 1.13.0 as my bootstrap compiler but Archlinux does 
>> that too so I don't think that's the reason.
>> Anybody an idea?
>>
>> Thomas
>
> run a make clean.
> probably files which changed in the backend are not recompiled?
>
> Otherwise it's mangling bugs.

It's always a fresh build when building a NixOS package.
I looked into backend.a for the symbol:

objdump -D backend.a | grep modulo
0000000000000040 <_Z7_moduloee>:
   40:	e9 00 00 00 00       	jmpq   45 <_Z7_moduloee+0x5>

Maybe that's connected to 
https://forum.dlang.org/post/odimguuqtekosmtliyhf@forum.dlang.org



More information about the Digitalmars-d mailing list