Building LDC on windows, woe is me!
claptrap
clap at trap.com
Sat Aug 19 19:47:15 UTC 2023
Ok been banging my head against this for a few hours and getting
nowhere. Following the windows build instructions up to the point
of generating NINJA build files...
cmake -G Ninja ..\ldc -DCMAKE_INSTALL_PREFIX="C:\LDCDEV\LDC-x64"
-DCMAKE_BUILD_TYPE=RelWithDebInfo
-DLLVM_ROOT_DIR="C:/LDCDEV/LLVM-x64"
gives me this...
=================
kind: "try_compile-v1"
backtrace:
- "C:/Program
Files/CMake/share/cmake-3.27/Modules/CMakeDetermineCompilerABI.cmake:57 (try_compile)"
- "C:/Program
Files/CMake/share/cmake-3.27/Modules/CMakeTestCCompiler.cmake:26
(CMAKE_DETERMINE_COMPILER_ABI)"
- "CMakeLists.txt:15 (project)"
checks:
- "Detecting C compiler ABI info"
directories:
source:
"C:/LDCDEV/build-ldc-x64/CMakeFiles/CMakeScratch/TryCompile-bp4cti"
binary:
"C:/LDCDEV/build-ldc-x64/CMakeFiles/CMakeScratch/TryCompile-bp4cti"
cmakeVariables:
CMAKE_C_FLAGS: ""
CMAKE_EXE_LINKER_FLAGS: ""
buildResult:
variable: "CMAKE_C_ABI_COMPILED"
cached: true
stdout: |
Change Dir:
'C:/LDCDEV/build-ldc-x64/CMakeFiles/CMakeScratch/TryCompile-bp4cti'
Run Build Command(s): C:/NINJA/ninja.exe -v cmTC_90234
[1/2]
C:\\PROGRA~2\\MICROS~2\\2019\\COMMUN~1\\VC\\Tools\\MSVC\\1429~1.301\\bin\\Hostx64\\x64\\cl.exe /nologo /MDd /Zi /Ob0 /Od /RTC1 /showIncludes /FoCMakeFiles\\cmTC_90234.dir\\CMakeCCompilerABI.c.obj /FdCMakeFiles\\cmTC_90234.dir\\ /FS -c "C:\\Program Files\\CMake\\share\\cmake-3.27\\Modules\\CMakeCCompilerABI.c"
[2/2] cmd.exe /C "cd . && "C:\\Program
Files\\CMake\\bin\\cmake.exe" -E vs_link_exe
--intdir=CMakeFiles\\cmTC_90234.dir --rc=rc
--mt=CMAKE_MT-NOTFOUND --manifests --
C:\\PROGRA~2\\MICROS~2\\2019\\COMMUN~1\\VC\\Tools\\MSVC\\1429~1.301\\bin\\Hostx64\\x64\\link.exe /nologo CMakeFiles\\cmTC_90234.dir\\CMakeCCompilerABI.c.obj /out:cmTC_90234.exe /implib:cmTC_90234.lib /pdb:cmTC_90234.pdb /version:0.0 /debug /INCREMENTAL /subsystem:console kernel32.lib user32.lib gdi32.lib winspool.lib shell32.lib ole32.lib oleaut32.lib uuid.lib comdlg32.lib advapi32.lib && cd ."
FAILED: cmTC_90234.exe
cmd.exe /C "cd . && "C:\\Program
Files\\CMake\\bin\\cmake.exe" -E vs_link_exe
--intdir=CMakeFiles\\cmTC_90234.dir --rc=rc
--mt=CMAKE_MT-NOTFOUND --manifests --
C:\\PROGRA~2\\MICROS~2\\2019\\COMMUN~1\\VC\\Tools\\MSVC\\1429~1.301\\bin\\Hostx64\\x64\\link.exe /nologo CMakeFiles\\cmTC_90234.dir\\CMakeCCompilerABI.c.obj /out:cmTC_90234.exe /implib:cmTC_90234.lib /pdb:cmTC_90234.pdb /version:0.0 /debug /INCREMENTAL /subsystem:console kernel32.lib user32.lib gdi32.lib winspool.lib shell32.lib ole32.lib oleaut32.lib uuid.lib comdlg32.lib advapi32.lib && cd ."
RC Pass 1: command "rc /fo
CMakeFiles\\cmTC_90234.dir/manifest.res
CMakeFiles\\cmTC_90234.dir/manifest.rc" failed (exit code 0) with
the following output:
The system cannot find the file specified
ninja: build stopped: subcommand failed.
exitCode: 1
============
It works with the MVSC 2019 generator, but I have no idea why it
wont generate the NINJA build files. I tried running it from the
VS Developer Command prompt, and that doesnt work either,
different error messages, and looks like it might be trying to
link to x86 libs instead of x64, but cant seem to figure out how
to change that.
disclaimer: total newbie on CMAKE, build scripts, etc...
More information about the digitalmars-d-ldc
mailing list