nixpkgs mirror (for testing) github.com/NixOS/nixpkgs
nix
at netboot-syslinux-multiplatform 51 lines 1.2 kB view raw
1{ lib 2, rustPlatform 3, fetchFromGitHub 4, nix-update-script 5, pkg-config 6, rustup 7, openssl 8, stdenv 9, libiconv 10, Security 11, makeWrapper 12}: 13 14rustPlatform.buildRustPackage rec { 15 pname = "cargo-msrv"; 16 version = "0.15.1"; 17 18 src = fetchFromGitHub { 19 owner = "foresterre"; 20 repo = pname; 21 rev = "v${version}"; 22 sha256 = "sha256-rmWPkxxrpVamYHII0xkZq62ubL3/jrcqXUvFH9VuNtg="; 23 }; 24 25 cargoSha256 = "sha256-/Bspy94uIP/e4uJY8qo+UPK1tnPjglxiMWeYWx2qoHk="; 26 27 passthru = { 28 updateScript = nix-update-script { }; 29 }; 30 31 # Integration tests fail 32 doCheck = false; 33 34 buildInputs = if stdenv.isDarwin 35 then [ libiconv Security ] 36 else [ openssl ]; 37 38 nativeBuildInputs = [ pkg-config makeWrapper ]; 39 40 # Depends at run-time on having rustup in PATH 41 postInstall = '' 42 wrapProgram $out/bin/cargo-msrv --prefix PATH : ${lib.makeBinPath [ rustup ]}; 43 ''; 44 45 meta = with lib; { 46 description = "Cargo subcommand \"msrv\": assists with finding your minimum supported Rust version (MSRV)"; 47 homepage = "https://github.com/foresterre/cargo-msrv"; 48 license = with licenses; [ asl20 /* or */ mit ]; 49 maintainers = with maintainers; [ otavio ]; 50 }; 51}