Merge pull request #196777 from figsoda/cargo-about

cargo-about: unbreak on darwin
main
figsoda 2 years ago committed by GitHub
commit b7d8c68778
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
  1. 25
      pkgs/development/tools/rust/cargo-about/default.nix
  2. 26
      pkgs/development/tools/rust/cargo-about/update-mimalloc.patch

@ -1,4 +1,11 @@
{ lib, rustPlatform, fetchFromGitHub, pkg-config, zstd, stdenv }:
{ lib
, rustPlatform
, fetchFromGitHub
, pkg-config
, zstd
, stdenv
, darwin
}:
rustPlatform.buildRustPackage rec {
pname = "cargo-about";
@ -11,14 +18,21 @@ rustPlatform.buildRustPackage rec {
sha256 = "sha256-T8Hhody0jMmZb6/xMkSvKCv4STZPbcrf/UB3APspYDM=";
};
# enable pkg-config feature of zstd
cargoPatches = [ ./zstd-pkg-config.patch ];
cargoPatches = [
# update mimalloc to fix build with older apple sdks
./update-mimalloc.patch
cargoSha256 = "sha256-x/HzDYNy0FDxJmhjSUUEiyahM7Sw27aC+ULP/Ii0X/8=";
# enable pkg-config feature of zstd
./zstd-pkg-config.patch
];
cargoSha256 = "sha256-2Reqj+WP6OoaB/3Z5llZP4c5ToVmMNX0Fe0IqDwcg2E=";
nativeBuildInputs = [ pkg-config ];
buildInputs = [ zstd ];
buildInputs = [ zstd ] ++ lib.optionals stdenv.isDarwin [
darwin.apple_sdk.frameworks.Security
];
meta = with lib; {
description = "Cargo plugin to generate list of all licenses for a crate";
@ -26,6 +40,5 @@ rustPlatform.buildRustPackage rec {
changelog = "https://github.com/EmbarkStudios/cargo-about/blob/${version}/CHANGELOG.md";
license = with licenses; [ mit /* or */ asl20 ];
maintainers = with maintainers; [ evanjs figsoda ];
broken = stdenv.isDarwin;
};
}

@ -0,0 +1,26 @@
--- a/Cargo.lock
+++ b/Cargo.lock
@@ -829,9 +829,9 @@ checksum = "efaa7b300f3b5fe8eb6bf21ce3895e1751d9665086af2d64b42f19701015ff4f"
[[package]]
name = "libmimalloc-sys"
-version = "0.1.24"
+version = "0.1.26"
source = "registry+https://github.com/rust-lang/crates.io-index"
-checksum = "7705fc40f6ed493f73584abbb324e74f96b358ff60dfe5659a0f8fc12c590a69"
+checksum = "8fc093ab289b0bfda3aa1bdfab9c9542be29c7ef385cfcbe77f8c9813588eb48"
dependencies = [
"cc",
]
@@ -884,9 +884,9 @@ dependencies = [
[[package]]
name = "mimalloc"
-version = "0.1.28"
+version = "0.1.30"
source = "registry+https://github.com/rust-lang/crates.io-index"
-checksum = "b0dfa131390c2f6bdb3242f65ff271fcdaca5ff7b6c08f28398be7f2280e3926"
+checksum = "76ce6a4b40d3bff9eb3ce9881ca0737a85072f9f975886082640cd46a75cdb35"
dependencies = [
"libmimalloc-sys",
]
Loading…
Cancel
Save