summaryrefslogtreecommitdiffstats
path: root/pkgs/development/python-modules
diff options
context:
space:
mode:
authorVladimír Čunát <vcunat@gmail.com>2016-05-13 10:14:53 +0200
committerVladimír Čunát <vcunat@gmail.com>2016-05-13 10:14:53 +0200
commit3e387c3e005c87566b5403d24c86f71f4945a79b (patch)
tree6ddd883a2e405850093d1f19cd18bb9b712e7c01 /pkgs/development/python-modules
parentdf8958435e1fd0c6d55394e95d3d3d2e0edca474 (diff)
parent6c2fbfbd7720446821be2a506cefcd1e0ff3b42d (diff)
Merge branch 'staging'
Darwin isn't in a perfect state, in particular its bootstrap tools won't build which will block nixpkgs channel. But on the whole it seems acceptable.
Diffstat (limited to 'pkgs/development/python-modules')
-rw-r--r--pkgs/development/python-modules/generic/wrap.sh4
-rw-r--r--pkgs/development/python-modules/stringtemplate/default.nix19
2 files changed, 16 insertions, 7 deletions
diff --git a/pkgs/development/python-modules/generic/wrap.sh b/pkgs/development/python-modules/generic/wrap.sh
index fa6a4d0102f3..a67ea51f5a9b 100644
--- a/pkgs/development/python-modules/generic/wrap.sh
+++ b/pkgs/development/python-modules/generic/wrap.sh
@@ -28,8 +28,10 @@ wrapPythonProgramsIn() {
# Find all regular files in the output directory that are executable.
for f in $(find "$dir" -type f -perm -0100); do
# Rewrite "#! .../env python" to "#! /nix/store/.../python".
+ # Strip suffix, like "3" or "2.7m" -- we don't have any choice on which
+ # Python to use besides one in $python anyway.
if head -n1 "$f" | grep -q '#!.*/env.*\(python\|pypy\)'; then
- sed -i "$f" -e "1 s^.*/env[ ]*\(python\|pypy\)^#! $python^"
+ sed -i "$f" -e "1 s^.*/env[ ]*\(python\|pypy\)[^ ]*^#! $python^"
fi
# catch /python and /.python-wrapped
diff --git a/pkgs/development/python-modules/stringtemplate/default.nix b/pkgs/development/python-modules/stringtemplate/default.nix
index f70888f102fc..5e372535b8ec 100644
--- a/pkgs/development/python-modules/stringtemplate/default.nix
+++ b/pkgs/development/python-modules/stringtemplate/default.nix
@@ -3,15 +3,22 @@
stdenv.mkDerivation rec {
name = "PyStringTemplate-${version}";
version = "3.2b1";
- meta = {
- homepage = "http://www.stringtemplate.org/";
- description = "Text Templating Library";
- };
+
src = fetchurl {
url = "http://www.stringtemplate.org/download/${name}.tar.gz";
sha256 = "0lbib0l8c1q7i1j610rwcdagymr1idahrql4dkgnm5rzyg2vk3ml";
};
+
propagatedBuildInputs = [python antlr];
- buildPhase = "true";
- installPhase = "python setup.py install --prefix=$out --install-lib=$(toPythonPath $out) -O1";
+
+ dontBuild = true;
+
+ installPhase = ''
+ python setup.py install --prefix=$out --install-lib=$(toPythonPath $out) -O1
+ '';
+
+ meta = {
+ homepage = "http://www.stringtemplate.org/";
+ description = "Text Templating Library";
+ };
}