From 4deb439d2eea2660cf60fc6639581e43fcb5aa77 Mon Sep 17 00:00:00 2001 From: Vincent Ambo Date: Sat, 25 Apr 2020 17:57:33 +0100 Subject: feat(third_party/python): Package broadlink infrared library --- third_party/default.nix | 1 + third_party/python/broadlink.nix | 22 ++++++++++++++++++++++ 2 files changed, 23 insertions(+) create mode 100644 third_party/python/broadlink.nix (limited to 'third_party') diff --git a/third_party/default.nix b/third_party/default.nix index f62c1251f469..909ff0a5b94c 100644 --- a/third_party/default.nix +++ b/third_party/default.nix @@ -87,6 +87,7 @@ let pkgconfig pounce protobuf + python3 python3Packages remarshal rink diff --git a/third_party/python/broadlink.nix b/third_party/python/broadlink.nix new file mode 100644 index 000000000000..75db1ef2b7af --- /dev/null +++ b/third_party/python/broadlink.nix @@ -0,0 +1,22 @@ +# Python package for controlling the Broadlink RM Pro Infrared +# controller. +# +# https://github.com/mjg59/python-broadlink +{ pkgs, lib, ... }: + +let + inherit (pkgs) fetchFromGitHub; + inherit (pkgs.python3Packages) buildPythonPackage cryptography; +in buildPythonPackage (lib.fix (self: { + pname = "python-broadlink"; + version = "0.13.2"; + + src = fetchFromGitHub { + owner = "mjg59"; + repo = "python-broadlink"; + rev = self.version; + sha256 = "0dwqzx294sjdc8dg1sd3z6mhll0zzsb8k0lzs63nyhm2nc9pyv6j"; + }; + + propagatedBuildInputs = [ cryptography ]; +})) -- cgit 1.4.1