Hello,
Currently I have a projet that use CMake to generate Visual Studio 2019 solutions.
Everything works fine, except that when I want to compile the project to target x86 (32bits) platform with clang-cl.
I have an exception when the 32 clang-cl linker (lld-link.exe) is used : Out of Memory. Apparently, I have to use the x64 linker to link the 32 bits object files.
I can’t find a way to do it.
When I’m generating the VS solution I do the following command :
CMake C:\../Sources -G "Visual Studio 16 2019" -A Win32 -T ClangCL
The selected compiler is :
C:\Program Files (x86)\Microsoft Visual Studio\2019\Professional\VC\Tools\Llvm\bin\clang-cl.exe
and the linker is :
C:\Program Files (x86)\Microsoft Visual Studio\2019\Professional\VC\Tools\Llvm\bin\lld-link.exe
The following also don’t works:
CMake C:\../Sources -G "Visual Studio 16 2019" -A Win32 -T ClangCL,host=x64
How can I set the linker to use C:\Program Files (x86)\Microsoft Visual Studio\2019\Professional\VC\Tools\Llvm\x64\bin\ldd-link.exe
instead?
Thank you,