ravedude: ensure avrdude is in the PATH (#270209)

This commit is contained in:
Rick van Schijndel 2024-10-16 21:10:06 +02:00 committed by GitHub
commit 6ced9c6711
No known key found for this signature in database
GPG Key ID: B5690EEEBB952194

View File

@ -3,6 +3,8 @@
, fetchCrate
, pkg-config
, udev
, avrdude
, makeBinaryWrapper
, nix-update-script
, testers
, ravedude
@ -19,10 +21,14 @@ rustPlatform.buildRustPackage rec {
cargoHash = "sha256-HeFmQsgr6uHrWi6s5sMQ6n63a44Msarb5p0+wUzKFkE=";
nativeBuildInputs = [ pkg-config ];
nativeBuildInputs = [ pkg-config makeBinaryWrapper ];
buildInputs = [ udev ];
postInstall = ''
wrapProgram $out/bin/ravedude --suffix PATH : ${lib.makeBinPath [ avrdude ]}
'';
passthru = {
updateScript = nix-update-script { };
tests.version = testers.testVersion {
@ -36,7 +42,7 @@ rustPlatform.buildRustPackage rec {
homepage = "https://crates.io/crates/ravedude";
license = with licenses; [ mit /* or */ asl20 ];
platforms = platforms.linux;
maintainers = with maintainers; [ rvarago ];
maintainers = with maintainers; [ rvarago liff ];
mainProgram = "ravedude";
};
}