From 00fb5ea150c1f77d8282098db90f3afe78922ec2 Mon Sep 17 00:00:00 2001 From: Jascha Geerds Date: Fri, 18 Jul 2014 15:02:44 +0200 Subject: [PATCH 1/2] Add virtualenvwrapper and its dependencies --- pkgs/top-level/python-packages.nix | 59 ++++++++++++++++++++++++++++++ 1 file changed, 59 insertions(+) diff --git a/pkgs/top-level/python-packages.nix b/pkgs/top-level/python-packages.nix index fccad5c81de..10a96907ac0 100644 --- a/pkgs/top-level/python-packages.nix +++ b/pkgs/top-level/python-packages.nix @@ -5199,6 +5199,28 @@ rec { }; }; + pbr = buildPythonPackage rec { + name = "pbr-0.9.0"; + + src = fetchurl { + url = "https://pypi.python.org/packages/source/p/pbr/${name}.tar.gz"; + sha256 = "e5a57c434b1faa509a00bf458d2c7af965199d9cced3d05a547bff9880f7e8cb"; + }; + + # pip depend on $HOME setting + preConfigure = "export HOME=$TMPDIR"; + + doCheck = false; + + buildInputs = [ pip ]; + + meta = { + description = "Python Build Reasonableness"; + homepage = "http://docs.openstack.org/developer/pbr/"; + license = licenses.asl20; + }; + }; + pep8 = buildPythonPackage rec { name = "pep8-${version}"; version = "1.5.7"; @@ -7100,6 +7122,23 @@ rec { }; }; + stevedore = buildPythonPackage rec { + name = "stevedore-0.15"; + + src = fetchurl { + url = "http://pypi.python.org/packages/source/s/stevedore/${name}.tar.gz"; + sha256 = "bec9269cbfa58de4f0849ec79bb7d54eeeed9df8b5fbfa1637fbc68062822847"; + }; + + buildInputs = [ pbr pip ]; + + meta = { + description = "Manage dynamic plugins for Python applications"; + homepage = "https://pypi.python.org/pypi/stevedore"; + license = licenses.asl20; + }; + }; + pydns = buildPythonPackage rec { name = "pydns-2.3.6"; @@ -8058,6 +8097,26 @@ rec { }; }; + virtualenvwrapper = buildPythonPackage (rec { + name = "virtualenvwrapper-4.3"; + + src = fetchurl { + url = "https://pypi.python.org/packages/source/v/virtualenvwrapper/${name}.tar.gz"; + sha256 = "514cbc22218347bf7b54bdbe49e1a5f550d2d53b1ad2491c10e91ddf48fb528f"; + }; + + # pip depend on $HOME setting + preConfigure = "export HOME=$TMPDIR"; + + buildInputs = [ pbr pip stevedore virtualenv virtualenv-clone ]; + + meta = { + description = "Enhancements to virtualenv"; + homepage = "https://pypi.python.org/pypi/virtualenvwrapper"; + license = licenses.mit; + }; + }); + waitress = buildPythonPackage rec { name = "waitress-0.8.7"; From d3aba9b8664af07786023df3ceb57e1e86e4fa95 Mon Sep 17 00:00:00 2001 From: Jascha Geerds Date: Tue, 22 Jul 2014 23:34:24 +0200 Subject: [PATCH 2/2] Patch shell scripts --- pkgs/top-level/python-packages.nix | 7 ++++++- 1 file changed, 6 insertions(+), 1 deletion(-) diff --git a/pkgs/top-level/python-packages.nix b/pkgs/top-level/python-packages.nix index 10a96907ac0..c6f9aa4af22 100644 --- a/pkgs/top-level/python-packages.nix +++ b/pkgs/top-level/python-packages.nix @@ -8108,7 +8108,12 @@ rec { # pip depend on $HOME setting preConfigure = "export HOME=$TMPDIR"; - buildInputs = [ pbr pip stevedore virtualenv virtualenv-clone ]; + buildInputs = [ pbr pip stevedore virtualenv virtualenv-clone pkgs.which ]; + + patchPhase = '' + substituteInPlace "virtualenvwrapper.sh" --replace "which" "${pkgs.which}/bin/which" + substituteInPlace "virtualenvwrapper_lazy.sh" --replace "which" "${pkgs.which}/bin/which" + ''; meta = { description = "Enhancements to virtualenv";