Skip to content

Commit

Permalink
pythonPackages.BlinkStick: move expression
Browse files Browse the repository at this point in the history
  • Loading branch information
Robert Schütz committed Feb 27, 2018
1 parent d509dd8 commit 250aa35
Show file tree
Hide file tree
Showing 2 changed files with 21 additions and 24 deletions.
20 changes: 20 additions & 0 deletions pkgs/development/python-modules/blinkstick/default.nix
Original file line number Diff line number Diff line change
@@ -0,0 +1,20 @@
{ lib, buildPythonPackage, fetchPypi, pyusb }:

buildPythonPackage rec {
pname = "BlinkStick";
version = "1.1.8";

src = fetchPypi {
inherit pname version;
sha256 = "3edf4b83a3fa1a7bd953b452b76542d54285ff6f1145b6e19f9b5438120fa408";
};

propagatedBuildInputs = [ pyusb ];

meta = with lib; {
description = "Python package to control BlinkStick USB devices";
homepage = https://pypi.python.org/pypi/BlinkStick/;
license = licenses.bsd3;
maintainers = with maintainers; [ np ];
};
}
25 changes: 1 addition & 24 deletions pkgs/top-level/python-packages.nix
Original file line number Diff line number Diff line change
Expand Up @@ -18738,30 +18738,7 @@ EOF

pyusb = callPackage ../development/python-modules/pyusb { libusb1 = pkgs.libusb1; };

BlinkStick = buildPythonPackage rec {
name = "BlinkStick-${version}";
version = "1.1.8";

src = pkgs.fetchurl {
url = "mirror://pypi/B/BlinkStick/${name}.tar.gz";
sha256 = "3edf4b83a3fa1a7bd953b452b76542d54285ff6f1145b6e19f9b5438120fa408";
};

# Requires pyusb 1.0.0b1.
# Likely current pyusb will work but we need to patch the hard requirement then.
broken = true;

patchPhase = "substituteInPlace setup.py --replace pyusb==1.0.0b1 pyusb==1.0.0";

propagatedBuildInputs = with self; [ pyusb ];

meta = {
description = "Python package to control BlinkStick USB devices";
homepage = https://pypi.python.org/pypi/BlinkStick/;
license = licenses.bsd3;
maintainers = with maintainers; [ np ];
};
};
BlinkStick = callPackage ../development/python-modules/blinkstick { };

usbtmc = callPackage ../development/python-modules/usbtmc {};

Expand Down

0 comments on commit 250aa35

Please sign in to comment.