mirror of
https://github.com/NixOS/nixpkgs.git
synced 2024-11-22 15:03:28 +00:00
987d32bbac
This breaks the builder when a nix-shell or keepBuildTree is used. The issue occurs because paths to cargo lockfiles are read with NIX_BUILD_TOP, which is not reliable. This breaks a nix-shell because NIX_BUILD_TOP simply is not set, causing an invalid path to be used. This can be worked around using NIX_BUILD_TOP=$PWD, but that obviously is not great. This breaks keepBuildTree because it changes the working directory to a different path than NIX_BUILD_TOP. Since the lockfiles are copied based on the working directory, but read based on NIX_BUILD_TOP, this causes the hook to not be able to find them. This was solved by both reading these files based on the working directory, using absolute paths to avoid having to traverse back in the directory tree. Fixes: #138554 |
||
---|---|---|
.. | ||
cargo-build-hook.sh | ||
cargo-check-hook.sh | ||
cargo-install-hook.sh | ||
cargo-setup-hook.sh | ||
default.nix | ||
maturin-build-hook.sh | ||
rust-bindgen-hook.sh |