-
Notifications
You must be signed in to change notification settings - Fork 730
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Unable to cross compile to Windows from Linux #894
Comments
I'm not sure cygwin supplies a cross compiler. I've successfully cross-compiled from Windows to Linux using the cross musl toolchain from https://win.musl.cc/. |
Did you try using clang instead of GCC? Then it might work. |
For anyone coming to this issue, I managed to cross-compile ring with a custom clang toolchain this way: In .cargo/config.toml: [target.x86_64-pc-windows-gnu]
linker = "x86_64-w64-mingw32-clang++"
env = { TARGET_CC="x86_64-w64-mingw32-clang", TARGET_AR="llvm-ar" }
rustflags = [ "-L", "/usr/lib/gcc/x86_64-w64-mingw32/10-win32" ] and then building as
I'm not sure if the linker path above is strictly needed for |
give Rust a config file (from sztomi here briansmith/ring#894) so that CLANG64/32 Rust compilations actually work, fix some issues with mismatched variables in the batch file, delimit some right parenthesis in the batch file to prevent reconfiguration, point to the exact location of cargo.exe when on CLANG64/32, fix malformed srt & kvazaar pkgconfig files on CLANG64/32, link pthread when compiling vpx on CLANG64/32, make local64_*clang/bin's batch files point to relevant clang counterparts, and probably some other things i missed. i know it's a lot
I use windows 10 and compiling my rust app as target windows is successful.
Now I tried to compile it for linux but its failed.
I installed cygwin on windows 10 to get a linux compiler.
.cargo/config:
created a bat-file for compiling:
Its compiling about 190 modules successul but stops always for "ring v0.13.5". Last lines of failed build:
Is here a solution? Make I a mistake in settings?
Dependencies: "rocket_http" "cookie" "ring"
UPDATE:
I have forced rocket to use master which use cookie v12 instead v11 with now ring v14. But this still fails with the same errors.
The text was updated successfully, but these errors were encountered: