Linker error for d.o: relocation R_X86_64_32 against `__dmd_personality_v0'

Rene Zwanenburg via Digitalmars-d-learn digitalmars-d-learn at puremagic.com
Fri Apr 22 02:49:02 PDT 2016


On Thursday, 21 April 2016 at 16:29:14 UTC, rcorre wrote:
>> - What happens when you compile a binary without phobos and 
>> druntime, and with a custom entry point? I've never done that 
>> myself and don't remember how to do that off the top of my 
>> head, but the info should be somewhere on dlang.org.
>
> I'll look into it.

Declaring a C-like main and the -defaultlib switch do the trick:

---- cmain.d
extern(C) void main() nothrow {}
---
> dmd cmain.d -defaultlib=""

If even that fails to link I honestly wouldn't know where to look 
next..


More information about the Digitalmars-d-learn mailing list