mirror of
https://github.com/NixOS/nixpkgs.git
synced 2026-09-30 20:00:10 +00:00
This commit was created by a combination of scripts and tools: - an ast-grep script to prefix things in meta with `lib.`, - a modified nixf-diagnose / nixf combination to remove unused `with lib;`, and - regular nixfmt. Co-authored-by: Wolfgang Walther <walther@technowledgy.de>
34 lines
808 B
Nix
34 lines
808 B
Nix
{
|
|
lib,
|
|
stdenv,
|
|
libusb1,
|
|
}:
|
|
|
|
stdenv.mkDerivation rec {
|
|
pname = "fxload";
|
|
version = libusb1.version;
|
|
dontUnpack = true;
|
|
dontBuild = true;
|
|
dontConfigure = true;
|
|
dontInstall = true;
|
|
dontPatch = true;
|
|
dontPatchELF = true;
|
|
|
|
# fxload binary exist inside the `examples/bin` directory of `libusb1`
|
|
postFixup = ''
|
|
mkdir -p $out/bin
|
|
ln -s ${passthru.libusb}/examples/bin/fxload $out/bin/fxload
|
|
'';
|
|
|
|
passthru.libusb = libusb1.override { withExamples = true; };
|
|
|
|
meta = {
|
|
homepage = "https://github.com/libusb/libusb";
|
|
description = "Tool to upload firmware to into an21, fx, fx2, fx2lp and fx3 ez-usb devices";
|
|
mainProgram = "fxload";
|
|
license = lib.licenses.gpl2Only;
|
|
platforms = lib.platforms.linux;
|
|
maintainers = with lib.maintainers; [ logger ];
|
|
};
|
|
}
|