Merge pull request #114311 from bobrik/ivan/cargo-deb-1.29.1

cargo-deb: 1.24.0 -> 1.29.1 + build fix
This commit is contained in:
Maximilian Bosch 2021-02-26 00:50:03 +01:00 committed by GitHub
commit 3d9e721eaf
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

View File

@ -8,24 +8,26 @@
rustPlatform.buildRustPackage rec {
pname = "cargo-deb";
version = "1.24.0";
version = "1.29.1";
src = fetchFromGitHub {
owner = "mmstick";
repo = pname;
rev = "b49351f6770aa7aeb053dd1d4a02d6b086caad2a";
sha256 = "1hs96yv0awgi7ggpxp7k3n21jpv642sm0529b21hs9ib6kp4vs8s";
rev = "v${version}";
sha256 = "sha256-oWivGy2azF9zpeZ0UAi7Bxm4iXFWAjcBG0pN7qtkSU8=";
};
buildInputs = lib.optionals stdenv.isDarwin [ Security ];
cargoSha256 = "1vqnnqn6rzkdi239bh3lk7gaxr7w6v3c4ws4ya1ah04g6v9hkzlw";
checkType = "debug";
cargoSha256 = "0j9frvcmy9hydw73v0ffr0bjvq2ykylnpmiw700z344djpaaa08y";
preCheck = ''
substituteInPlace tests/command.rs \
--replace 'target/debug' "target/${rust.toRustTarget stdenv.buildPlatform}/debug"
--replace 'target/debug' "target/${rust.toRustTarget stdenv.buildPlatform}/release"
# This is an FHS specific assert depending on glibc location
substituteInPlace src/dependencies.rs \
--replace 'assert!(deps.iter().any(|d| d.starts_with("libc")));' '// no libc assert here'
'';
meta = with lib; {