From 7f92e3b6bfbb35b53ffcdb3ee56f87c7adb31433 Mon Sep 17 00:00:00 2001 From: Carter Sande Date: Wed, 4 Apr 2018 21:23:16 -0700 Subject: [PATCH] rpiboot-unstable: init at 2018-03-27 --- maintainers/maintainer-list.nix | 5 +++ pkgs/development/misc/rpiboot/unstable.nix | 36 ++++++++++++++++++++++ pkgs/top-level/all-packages.nix | 2 ++ 3 files changed, 43 insertions(+) create mode 100644 pkgs/development/misc/rpiboot/unstable.nix diff --git a/maintainers/maintainer-list.nix b/maintainers/maintainer-list.nix index e161599b899d..a39aa8b98829 100644 --- a/maintainers/maintainer-list.nix +++ b/maintainers/maintainer-list.nix @@ -695,6 +695,11 @@ github = "carlsverre"; name = "Carl Sverre"; }; + cartr = { + email = "carter.sande@duodecima.technology"; + github = "cartr"; + name = "Carter Sande"; + }; casey = { email = "casey@rodarmor.net"; github = "casey"; diff --git a/pkgs/development/misc/rpiboot/unstable.nix b/pkgs/development/misc/rpiboot/unstable.nix new file mode 100644 index 000000000000..c89d2f11e954 --- /dev/null +++ b/pkgs/development/misc/rpiboot/unstable.nix @@ -0,0 +1,36 @@ +{ stdenv, fetchFromGitHub, libusb1 }: + +let + version = "2018-03-27"; + name = "rpiboot-unstable-${version}"; +in stdenv.mkDerivation { + inherit name; + + src = fetchFromGitHub { + owner = "raspberrypi"; + repo = "usbboot"; + rev = "fb86716935f2e820333b037a2ff93a338ad9b695"; + sha256 = "163g7iw7kf6ra71adx6lf1xzf3kv20bppva15ljwn54jlah5mv98"; + }; + + nativeBuildInputs = [ libusb1 ]; + + patchPhase = '' + sed -i "s@/usr/@$out/@g" main.c + ''; + + installPhase = '' + mkdir -p $out/bin + mkdir -p $out/share/rpiboot + cp rpiboot $out/bin + cp -r msd $out/share/rpiboot + ''; + + meta = { + homepage = https://github.com/raspberrypi/usbboot; + description = "Utility to boot a Raspberry Pi CM/CM3/Zero over USB"; + maintainers = [ stdenv.lib.maintainers.cartr ]; + license = stdenv.lib.licenses.asl20; + platforms = stdenv.lib.platforms.unix; + }; +} diff --git a/pkgs/top-level/all-packages.nix b/pkgs/top-level/all-packages.nix index bcbdbae1e697..dcd0de9dea45 100644 --- a/pkgs/top-level/all-packages.nix +++ b/pkgs/top-level/all-packages.nix @@ -4649,6 +4649,8 @@ with pkgs; rpPPPoE = callPackage ../tools/networking/rp-pppoe { }; + rpiboot-unstable = callPackage ../development/misc/rpiboot/unstable.nix { }; + rpm = callPackage ../tools/package-management/rpm { }; rpm-ostree = callPackage ../tools/misc/rpm-ostree {