mirror of
https://github.com/NixOS/nixpkgs.git
synced 2024-12-05 13:23:17 +00:00
621b3528ed
Diff: https://github.com/cargo-bins/cargo-binstall/compare/v1.4.9...v1.5.0 Changelog: https://github.com/cargo-bins/cargo-binstall/releases/tag/v1.5.0
65 lines
1.5 KiB
Nix
65 lines
1.5 KiB
Nix
{ lib
|
|
, rustPlatform
|
|
, fetchFromGitHub
|
|
, pkg-config
|
|
, bzip2
|
|
, xz
|
|
, zstd
|
|
, stdenv
|
|
, darwin
|
|
}:
|
|
|
|
rustPlatform.buildRustPackage rec {
|
|
pname = "cargo-binstall";
|
|
version = "1.5.0";
|
|
|
|
src = fetchFromGitHub {
|
|
owner = "cargo-bins";
|
|
repo = "cargo-binstall";
|
|
rev = "v${version}";
|
|
hash = "sha256-QPUZnqELncUCfm995NN0hYDGFZcKrYXskZIaN2ZRtzk=";
|
|
};
|
|
|
|
cargoHash = "sha256-85r0jDBuvfrJq776MSbQT6w60/xWQkC9zLmZwjdanCk=";
|
|
|
|
nativeBuildInputs = [
|
|
pkg-config
|
|
];
|
|
|
|
buildInputs = [
|
|
bzip2
|
|
xz
|
|
zstd
|
|
] ++ lib.optionals stdenv.isDarwin [
|
|
darwin.apple_sdk.frameworks.SystemConfiguration
|
|
];
|
|
|
|
buildNoDefaultFeatures = true;
|
|
buildFeatures = [
|
|
"fancy-no-backtrace"
|
|
"git"
|
|
"pkg-config"
|
|
"rustls"
|
|
"trust-dns"
|
|
"zstd-thin"
|
|
];
|
|
|
|
cargoBuildFlags = [ "-p" "cargo-binstall" ];
|
|
cargoTestFlags = [ "-p" "cargo-binstall" ];
|
|
|
|
checkFlags = [
|
|
# requires internet access
|
|
"--skip=download::test::test_and_extract"
|
|
"--skip=gh_api_client::test::test_gh_api_client_cargo_binstall_no_such_release"
|
|
"--skip=gh_api_client::test::test_gh_api_client_cargo_binstall_v0_20_1"
|
|
];
|
|
|
|
meta = with lib; {
|
|
description = "A tool for installing rust binaries as an alternative to building from source";
|
|
homepage = "https://github.com/cargo-bins/cargo-binstall";
|
|
changelog = "https://github.com/cargo-bins/cargo-binstall/releases/tag/v${version}";
|
|
license = licenses.gpl3Only;
|
|
maintainers = with maintainers; [ figsoda ];
|
|
};
|
|
}
|