2023-01-20 10:41:00 +00:00
|
|
|
{ lib
|
|
|
|
, stdenv
|
|
|
|
, libusb1
|
|
|
|
}:
|
2020-04-24 23:36:52 +00:00
|
|
|
|
2021-09-26 12:46:18 +00:00
|
|
|
stdenv.mkDerivation rec {
|
|
|
|
pname = "fxload";
|
2023-01-20 10:41:00 +00:00
|
|
|
version = libusb1.version;
|
|
|
|
dontUnpack = true;
|
|
|
|
dontBuild = true;
|
|
|
|
dontConfigure = true;
|
|
|
|
dontInstall = true;
|
|
|
|
dontPatch = true;
|
|
|
|
dontPatchELF = true;
|
2020-04-24 23:36:52 +00:00
|
|
|
|
2023-01-20 10:41:00 +00:00
|
|
|
# fxload binary exist inside the `examples/bin` directory of `libusb1`
|
|
|
|
postFixup = ''
|
2023-02-02 18:25:31 +00:00
|
|
|
mkdir -p $out/bin
|
|
|
|
ln -s ${passthru.libusb}/examples/bin/fxload $out/bin/fxload
|
2020-04-24 23:36:52 +00:00
|
|
|
'';
|
|
|
|
|
2023-01-20 10:41:00 +00:00
|
|
|
passthru.libusb = libusb1.override { withExamples = true; };
|
|
|
|
|
2021-01-15 22:18:51 +00:00
|
|
|
meta = with lib; {
|
2023-01-20 10:41:00 +00:00
|
|
|
homepage = "https://github.com/libusb/libusb";
|
|
|
|
description = "Tool to upload firmware to into an21, fx, fx2, fx2lp and fx3 ez-usb devices";
|
|
|
|
license = licenses.gpl2Only;
|
2020-04-24 23:36:52 +00:00
|
|
|
platforms = platforms.linux;
|
2023-01-20 10:41:00 +00:00
|
|
|
maintainers = with maintainers; [ realsnick ];
|
2020-04-24 23:36:52 +00:00
|
|
|
};
|
|
|
|
}
|