2021-08-05 18:18:55 +01:00
|
|
|
{ stdenv
|
|
|
|
, lib
|
|
|
|
, fetchFromGitHub
|
|
|
|
, go-md2man
|
|
|
|
, installShellFiles
|
|
|
|
, libusb-compat-0_1
|
|
|
|
}:
|
2020-03-02 09:48:27 +00:00
|
|
|
|
|
|
|
stdenv.mkDerivation rec {
|
2019-08-13 22:52:01 +01:00
|
|
|
pname = "teensy-loader-cli";
|
2021-08-05 18:18:55 +01:00
|
|
|
version = "2.1+unstable=2021-04-10";
|
2020-03-02 09:48:27 +00:00
|
|
|
|
|
|
|
src = fetchFromGitHub {
|
|
|
|
owner = "PaulStoffregen";
|
|
|
|
repo = "teensy_loader_cli";
|
2021-08-05 18:18:55 +01:00
|
|
|
rev = "9dbbfa3b367b6c37e91e8a42dae3c6edfceccc4d";
|
|
|
|
sha256 = "lQ1XtaWPr6nvE8NArD1980QVOH6NggO3FlfsntUjY7s=";
|
2015-09-16 15:22:41 +01:00
|
|
|
};
|
|
|
|
|
2021-08-05 18:18:55 +01:00
|
|
|
nativeBuildInputs = [
|
|
|
|
go-md2man
|
|
|
|
installShellFiles
|
|
|
|
];
|
2015-09-16 15:22:41 +01:00
|
|
|
|
2021-08-05 18:18:55 +01:00
|
|
|
buildInputs = [
|
|
|
|
libusb-compat-0_1
|
|
|
|
];
|
2020-03-02 09:48:27 +00:00
|
|
|
|
2015-09-16 15:22:41 +01:00
|
|
|
installPhase = ''
|
2021-08-05 18:18:55 +01:00
|
|
|
runHook preInstall
|
|
|
|
|
2020-03-02 09:48:27 +00:00
|
|
|
install -Dm555 teensy_loader_cli $out/bin/teensy-loader-cli
|
|
|
|
install -Dm444 -t $out/share/doc/${pname} *.md *.txt
|
|
|
|
go-md2man -in README.md -out ${pname}.1
|
|
|
|
installManPage *.1
|
2021-08-05 18:18:55 +01:00
|
|
|
|
|
|
|
runHook postInstall
|
2015-09-16 15:22:41 +01:00
|
|
|
'';
|
|
|
|
|
2021-01-23 12:26:19 +00:00
|
|
|
meta = with lib; {
|
2015-09-16 15:22:41 +01:00
|
|
|
description = "Firmware uploader for the Teensy microcontroller boards";
|
2020-03-02 09:48:27 +00:00
|
|
|
homepage = "https://www.pjrc.com/teensy/";
|
2021-08-05 18:18:55 +01:00
|
|
|
license = licenses.gpl3Only;
|
2018-10-20 21:36:50 +01:00
|
|
|
platforms = platforms.unix;
|
2015-09-16 15:22:41 +01:00
|
|
|
};
|
|
|
|
}
|