1{ lib
2, stdenv
3, rustPlatform
4, fetchFromGitHub
5, libusb1
6, libftdi
7, cargo-readme
8, pkg-config
9, AppKit
10}:
11
12rustPlatform.buildRustPackage rec {
13 pname = "humility";
14 version = "unstable-2022-09-15";
15
16 nativeBuildInputs = [ pkg-config cargo-readme ];
17 buildInputs = [ libusb1 libftdi ] ++ lib.optionals stdenv.isDarwin [
18 AppKit
19 ];
20
21 src = fetchFromGitHub {
22 owner = "oxidecomputer";
23 repo = pname;
24 rev = "d336c21c7b6da7f8203a9331c7657581de2bc6ad";
25 sha256 = "sha256-yW7QcxTWbL2YsV2bvfhbqQ2nawlPQbYxBfIGCWo28GY=";
26 };
27
28 cargoSha256 = "sha256-IurLI0ZQNpmiYwfcMZuxi7FWtSX+Ts7GYWFwUfD+Ji8=";
29
30 meta = with lib; {
31 description = "Debugger for Hubris";
32 homepage = "https://github.com/oxidecomputer/humility";
33 license = with licenses; [ mpl20 ];
34 maintainers = with maintainers; [ therishidesai ];
35 };
36}