ldc2 64 bit windows linking problem

Carl Sturtivant sturtivant at gmail.com
Mon Jun 29 00:19:15 UTC 2020


On Sunday, 28 June 2020 at 22:18:29 UTC, kinke wrote:
> On Sunday, 28 June 2020 at 21:56:26 UTC, Carl Sturtivant wrote:
>> Just got ldc2 for this machine/platform, want to use 
>> -link-internally .
>> Added the bin directory to my Path. lcd2 compiles but lld-link 
>> cannot find its libs. Any suggestions?
>
> Yeah, please mention the used LDC version explicitly as that 
> part has seen a bigger rework in v1.22 (as mentioned in the 
> changelog), and then run with -v, checking the trailing lines 
> right before the linker command ('Prepending to environment 
> variables', the MSVC toolchain auto-detection & setup).
>
> If auto-detection somehow finds an unsuited installation, you 
> can enforce a dir via LDC_VSDIR (see README.txt). In case your 
> environment variables play a role, dumping them via `set` and 
> posting them might provide insights.

Apologies, it's version 1.22.0

I see no line 'Prepending ...' before the linker related output 
from -v.

Here's the relevant text.

GC stats  0M used, 5M free, 5M total
code      hello2
lld-link /NOLOGO /OPT:REF /OPT:ICF /DEFAULTLIB:libcmt 
/DEFAULTLIB:libvcruntime /OUT:hello2.exe hello2.obj 
C:/Users/carl/ldc2-1.22.0-windows-x64/bin/../lib\ldc_rt.builtins.lib /LIBPATH:C:/Users/carl/ldc2-1.22.0-windows-x64/bin/../lib phobos2-ldc.lib druntime-ldc.lib kernel32.lib user32.lib gdi32.lib winspool.lib shell32.lib ole32.lib oleaut32.lib uuid.lib comdlg32.lib advapi32.lib oldnames.lib legacy_stdio_definitions.lib

The libs are present in 
C:\Users\carl\ldc2-1.22.0-windows-x64\lib\mingw







More information about the digitalmars-d-ldc mailing list