cargo-geiger
cargo-geiger copied to clipboard
Failed to build on Windows with GCC target
I tried to install cargo-geiger on my machine
- OS: win 10 pro 64 bit
- rustc toolchain
$ rustup toolchain list stable-x86_64-pc-windows-gnu stable-x86_64-pc-windows-msvc nightly-x86_64-pc-windows-gnu (default) nightly-x86_64-pc-windows-msvc
It is probably related to libssh2-sys crate or cc create but i did not see it in my projects so reporting it here
the build log is attached
Your message is formatted unreadably. Can you please fix the formatting.
I apologize for messy formatting. Can I attach a build log as a file here? I couldn't find a right button
the error message is
running: "gcc.exe" "-O3" "-ffunction-sections" "-fdata-sections" "-m64" "-I" "C:\\Users\\rucoder\\AppData\\Local\\Temp\\cargo-install9qJxdc\\release\\build\\libssh2-sys-1dc13e65c2e981c0\\out\\include" "-I" "libssh2/src" "-I" "libssh2/win32" "-I" "C:\\Users\\rucoder\\AppD ata\\Local\\Temp\\cargo-install9qJxdc\\release\\build\\libz-sys-6e51e6a8827f4b5d\\out/include" "-DHAVE_LONGLONG" "-DLIBSSH2_WINCNG" "-DLIBSSH2_DH_GEX_NEW" "-DLIBSSH2_HAVE_ZLIB" "-o" "C:\\Users\\rucoder\\AppData\\Local\\Temp\\cargo-install9qJxdc\\release\\build\\libssh2-s ys-1dc13e65c2e981c0\\out\\build\\libssh2/src/wincng.o" "-c" "libssh2/src/wincng.c" exit code: 0 exit code: 0 cargo:warning=libssh2/src/wincng.c:63:28: fatal error: versionhelpers.h: No such file or directory cargo:warning=compilation terminated. exit code: 1 exit code: 0
Just put whatever you want to attach in triple backticks: put ``` before and after the text
And I just switched to msvc target and I can build without any problems. It seems some INCLUDE is missing in a build.ts
Related to: #84
It seems like Cargo requires MSVC on Windows, we should probably add that to the known issues list.
I just dug Win10 ISO from M$ for free.. down the rabbithole I go :)
Rust does offer toolchain for gnu thus cargo should be fine with it and related to ssh2 I saw Alex addressing it as ssh related to it so gcc should be good...
https://github.com/alexcrichton/ssh2-rs/issues/14