lol
1{ lib
2, stdenv
3, rustPlatform
4, fetchCrate
5, pkg-config
6, DarwinTools
7, libusb1
8, libiconv
9, AppKit
10, IOKit
11}:
12
13rustPlatform.buildRustPackage rec {
14 pname = "probe-run";
15 version = "0.3.10";
16
17 src = fetchCrate {
18 inherit pname version;
19 hash = "sha256-PIUL7aUIHyHuetkMbJsZ3x1coyzKGwI/AJE/R6uFBM4=";
20 };
21
22 cargoHash = "sha256-7q5M3huI7Qje5E3Rl2i/9I4g90R8vhJD9Hk78biewBE=";
23
24 nativeBuildInputs = [
25 pkg-config
26 ] ++ lib.optionals stdenv.isDarwin [
27 DarwinTools
28 ];
29
30 buildInputs = [
31 libusb1
32 ] ++ lib.optionals stdenv.isDarwin [
33 libiconv
34 AppKit
35 IOKit
36 ];
37
38 meta = with lib; {
39 description = "Run embedded programs just like native ones";
40 homepage = "https://github.com/knurling-rs/probe-run";
41 changelog = "https://github.com/knurling-rs/probe-run/blob/v${version}/CHANGELOG.md";
42 license = with licenses; [ asl20 /* or */ mit ];
43 maintainers = with maintainers; [ hoverbear newam ];
44 };
45}