-
Notifications
You must be signed in to change notification settings - Fork 2.4k
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
Dependencies with custom build scripts cannot be built when vendored. #9127
Labels
Comments
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Problem
Since the end of November,
cargo vendor
will strip the executable flag from vendored dependencies. This means any repository with for example asetup.sh
executed by build.rs will now fail to build the project due to file permission errors.A good example of this is a crate that depends on jemalloc-sys. When building with vendored dependencies the following errors are produced:
With a non-vendored build, these files are executable.
Steps
Minimal reproduction:
cargo new --lib broken-vendor
mkdir .cargo && cargo vendor deps >> .cargo/config.toml
All
.sh
files in thejemalloc-sys
directory are missing `+x, and the build will break. If you do this with a normal build, the files are correctly copied into the filesystem with executable permissions preserved.Possible Solution(s)
I'm not entirely sure if this was an intentional change or not, I can't find much info on it. There's no way to hook this process to work around it currently.
Notes
Output of
cargo version
:Tested broken on these versions:
cargo 1.50.0-nightly (d274fcf 2020-12-07)
cargo 1.51.0-nightly (c3abcfe 2021-01-25)
Last working version I could find was November 25th 2020.
The text was updated successfully, but these errors were encountered: