diff options
author | lassulus <lassulus@lassul.us> | 2020-10-18 19:25:11 +0200 |
---|---|---|
committer | lassulus <lassulus@lassul.us> | 2020-10-18 19:25:11 +0200 |
commit | 5b29d7a435092aafcea15f588effbb6f45a6a56e (patch) | |
tree | 07340bc138d7bdea55bbb33e50fc2fa1b5387a57 /tv/5pkgs/rpi/433Utils/default.nix | |
parent | 9626d3cda953929e903b5a06595e98972cb08ffc (diff) | |
parent | b034f63f7a2e4361b32c33c0e1a980eecf1a5aa6 (diff) |
Merge remote-tracking branch 'ni/master'
Diffstat (limited to 'tv/5pkgs/rpi/433Utils/default.nix')
-rw-r--r-- | tv/5pkgs/rpi/433Utils/default.nix | 42 |
1 files changed, 42 insertions, 0 deletions
diff --git a/tv/5pkgs/rpi/433Utils/default.nix b/tv/5pkgs/rpi/433Utils/default.nix new file mode 100644 index 000000000..78be6de35 --- /dev/null +++ b/tv/5pkgs/rpi/433Utils/default.nix @@ -0,0 +1,42 @@ +{ fetchFromGitHub, stdenv +, wiringPi ? WiringPi.wiringPi +, wiringPiDev ? WiringPi.wiringPiDev +, WiringPi ? rpiPackages.WiringPi +, rpiPackages +}: + +stdenv.mkDerivation { + pname = "433Utils-RPi_utils"; + version = "2018-06-07"; + + src = fetchFromGitHub (stdenv.lib.importJSON ./src.json); + + patches = [ + ./rc-switch.protocols.patch + ./RPi_utils.codesend.codestring.patch + ]; + + buildPhase = '' + runHook postBuild + + make -C RPi_utils + + runHook preBuild + ''; + + buildInputs = [ + wiringPi + wiringPiDev + ]; + + installPhase = '' + runHook preInstall + + mkdir -p $out/bin + for name in send codesend RFSniffer; do + cp RPi_utils/$name $out/bin/ + done + + runHook postInstall + ''; +} |