-
Notifications
You must be signed in to change notification settings - Fork 397
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
x86_64-pc-windows-msvc Link error with very large number of objects #1441
Comments
I should've read the last note in your report :) |
Can you show the entire build log with |
@Emilgardis unfortunately I cant post the log publicly. Can you tell me what you're looking for? I can confirm that the link command is extremely long 38k chars sounds right. If you look at the rust issue, their fix seemed trivial, however i am not familiar enough with how rust links to know if we can get in the middle of object generation and linking... |
I just wanted more context, but it's fine :) A way to reproduce this would be good though. Do you see any "linker failed with exit code" message? I suspect this is the root problem, the fallback is never invoked, and I think that's because WINE doesn't give us error code E2BIG (7) I think a fix would have to be done in rustc here or we wrap wine and translate the error code |
I ran into the same issue, but with macOS as the underlying system. Command I ran: # Cross.toml
[target.x86_64-pc-windows-msvc]
image = "ghcr.io/cross-rs/x86_64-pc-windows-msvc-cross:local"
pre-build = [
"dpkg --add-architecture $CROSS_DEB_ARCH",
"apt-get update && apt-get --assume-yes install libssl-dev:$CROSS_DEB_ARCH",
"ln -s /opt/msvc/vc/tools/msvc/14.43.34808/include /opt/msvc/vc/include",
]
[target.x86_64-pc-windows-msvc.env]
passthrough = [
# Needed by one dependency to find the required header files
"CROSS_INCLUDE_DIR=/opt/msvc/kits/10/include/10.0.22621.0/ucrt"
]
I hope that helps. |
Checklist
Describe your issue
Linking fails with a very large number of objects on x86_64-pc-windows-msvc.
What target(s) are you cross-compiling for?
other (specify in description)
Which operating system is the host (e.g computer cross is on) running?
What architecture is the host?
What container engine is cross using?
cross version
0.2.5
Example
Additional information / notes
I found this issue in rustc: rust-lang/rust#41190, and it makes me wonder if the workaround implemented there is somehow not getting triggered in the cross docker container.
Note: that the msvc docker container was built unmodified from the cross-toolchain image
The text was updated successfully, but these errors were encountered: