probe-run: modernize

Co-authored-by: Fabian Affolter <fabian@affolter-engineering.ch>
This commit is contained in:
Alex Martens 2022-10-07 07:58:38 -07:00
parent 436c831f9a
commit fc4fa263ff

View File

@ -1,5 +1,13 @@
{ lib, stdenv, rustPlatform, fetchCrate, pkg-config, libusb1
, libiconv, AppKit, IOKit }:
{ lib
, stdenv
, rustPlatform
, fetchCrate
, pkg-config
, libusb1
, libiconv
, AppKit
, IOKit
}:
rustPlatform.buildRustPackage rec {
pname = "probe-run";
@ -12,9 +20,17 @@ rustPlatform.buildRustPackage rec {
cargoSha256 = "sha256-kmdRwAq6EOniGHC7JhB6Iov1E4hbQbxHlOcc6gUDOhY=";
nativeBuildInputs = [ pkg-config ];
buildInputs = [ libusb1 ]
++ lib.optionals stdenv.isDarwin [ libiconv AppKit IOKit ];
nativeBuildInputs = [
pkg-config
];
buildInputs = [
libusb1
] ++ lib.optionals stdenv.isDarwin [
libiconv
AppKit
IOKit
];
meta = with lib; {
description = "Run embedded programs just like native ones";