forked from mirrors/nixpkgs
Restoring builderDefs functionality in setuptools
svn path=/nixpkgs/trunk/; revision=15697
This commit is contained in:
parent
ed69e9ed94
commit
f4e6e80bcf
|
@ -1,21 +1,34 @@
|
|||
{ fetchurl, stdenv, python, makeWrapper }:
|
||||
a :
|
||||
let
|
||||
fetchurl = a.fetchurl;
|
||||
|
||||
stdenv.mkDerivation rec {
|
||||
name = "setuptools-0.6c9";
|
||||
version = a.lib.getAttr ["version"] "0.6c9" a;
|
||||
buildInputs = with a; [
|
||||
python makeWrapper
|
||||
];
|
||||
in
|
||||
rec {
|
||||
name = "setuptools-" + version;
|
||||
|
||||
src = fetchurl {
|
||||
url = "http://pypi.python.org/packages/source/s/setuptools/${name}.tar.gz";
|
||||
sha256 = "1n5k6hf9nn69fnprgsnr9hdxzj2j6ir76qcy9d4b2v0v62bh86g6";
|
||||
};
|
||||
|
||||
buildInputs = [ python makeWrapper ];
|
||||
inherit buildInputs;
|
||||
configureFlags = [];
|
||||
|
||||
doCheck = true;
|
||||
|
||||
buildPhase = "python setup.py build --build-base $out";
|
||||
checkPhase = "python setup.py test";
|
||||
doMakeCheck = a.fullDepEntry (''
|
||||
python setup.py test
|
||||
'') ["minInit" "doUnpack" "addInputs" "doBuild"];
|
||||
|
||||
installPhase = ''
|
||||
doBuild = a.fullDepEntry(''
|
||||
python setup.py build --build-base $out
|
||||
'') ["addInputs" "doUnpack"];
|
||||
|
||||
doInstall = a.fullDepEntry(''
|
||||
ensureDir "$out/lib/python2.5/site-packages"
|
||||
|
||||
PYTHONPATH="$out/lib/python2.5/site-packages:$PYTHONPATH" \
|
||||
|
@ -27,7 +40,9 @@ stdenv.mkDerivation rec {
|
|||
--prefix PYTHONPATH ":" \
|
||||
"$out/lib/python2.5/site-packages"
|
||||
done
|
||||
'';
|
||||
'') ["doBuild"];
|
||||
|
||||
phaseNames = ["doBuild" "doInstall"];
|
||||
|
||||
meta = {
|
||||
description = "Utilities to facilitate the installation of Python packages";
|
||||
|
|
|
@ -4316,8 +4316,8 @@ let
|
|||
inherit fetchurl stdenv python makeWrapper;
|
||||
};
|
||||
|
||||
setuptools = import ../development/python-modules/setuptools {
|
||||
inherit fetchurl stdenv python makeWrapper;
|
||||
setuptools = builderDefsPackage (import ../development/python-modules/setuptools) {
|
||||
inherit python makeWrapper;
|
||||
};
|
||||
|
||||
simplejson = import ../development/python-modules/simplejson {
|
||||
|
|
Loading…
Reference in a new issue