Illegal Instruction

David Nadlinger code at klickverbot.at
Sat Mar 24 21:34:06 UTC 2018


On Saturday, 24 March 2018 at 16:07:47 UTC, Russel Winder wrote:
> I just did a brand new rebuild on Debian Sid and this is still 
> seeming to happen. Does anyone have a workaround that doesn't 
> involve using dmd instead of ldc2?

Ubuntu 17.10 works as expected:

---
$ . ~/dlang/ldc-1.8.0/activate
$ cat > test.d
void foo() {}
^D
$ cat > main.d
import test;
void main() {
   foo();
}
^D
$ ldmd2 -fPIC -g -shared test.d
$ ldmd2 main.d -g -L-ltest -L-L. -L-R.
$ ./main
Aborting from rt/sections_elf_shared.d(477) Only one D shared 
object allowed for static runtime. Link with shared runtime via 
LDC switch '-link-defaultlib-shared'.
Aborted (core dumped)
$ ldmd2 main.d -g -L-ltest -L-L. -L-R. -link-defaultlib-shared
$ ./main
---

  — David


More information about the digitalmars-d-ldc mailing list