How to set the linker ldmd2 LTS uses.

Georgi D via digitalmars-d-ldc digitalmars-d-ldc at puremagic.com
Fri Mar 3 13:35:13 PST 2017


Hi,

I am trying to build LDC 1.1.1 using LDC LTS for bootstrap in a 
crosscompile environment where the system /usr/bin/gcc cannot be 
used. During the CMake generation I get:

```
Error: failed to locate gcc
CMake Error at cmake/Modules/ExtractDMDSystemLinker.cmake:40 
(message):
   Failed to compile empty program using D compiler
   '<toolchain>/bin/ldmd2'
Call Stack (most recent call first):
   CMakeLists.txt:559 (include)
```

When I run ldmd2 -v test.d manually I see it is using:

/usr/bin/gcc test.o -o test

for linking.

How can I specify the gcc location on the command line or in the 
environment?

Thanks


More information about the digitalmars-d-ldc mailing list