2011-03-29 17:02:15 +02:00
|
|
|
{ stdenv, fetchurl, python, wrapPython }:
|
|
|
|
|
|
|
|
stdenv.mkDerivation rec {
|
|
|
|
name = "setuptools-0.6c11";
|
2009-05-24 00:54:11 +02:00
|
|
|
|
|
|
|
src = fetchurl {
|
|
|
|
url = "http://pypi.python.org/packages/source/s/setuptools/${name}.tar.gz";
|
2009-12-25 15:17:57 +01:00
|
|
|
sha256 = "1lx1hwxkhipyh206bgl90ddnfcnb68bzcvyawczbf833fadyl3v3";
|
2009-05-24 00:54:11 +02:00
|
|
|
};
|
|
|
|
|
2011-03-29 17:02:15 +02:00
|
|
|
buildInputs = [ python wrapPython ];
|
2009-05-24 00:54:11 +02:00
|
|
|
|
2011-03-29 17:02:15 +02:00
|
|
|
buildPhase = "python setup.py build --build-base $out";
|
2009-05-24 00:54:11 +02:00
|
|
|
|
2011-03-29 17:02:15 +02:00
|
|
|
installPhase =
|
|
|
|
''
|
|
|
|
dst=$out/lib/${python.libPrefix}/site-packages
|
|
|
|
mkdir -p $dst
|
|
|
|
PYTHONPATH=$dst:$PYTHONPATH
|
|
|
|
python setup.py install --prefix=$out
|
2012-02-26 18:23:02 +01:00
|
|
|
# remove generic files, leave setuptools.pth
|
|
|
|
rm $dst/site.py*
|
|
|
|
rm $dst/easy-install.pth
|
2011-03-29 17:02:15 +02:00
|
|
|
wrapPythonPrograms
|
|
|
|
'';
|
2009-05-24 00:54:11 +02:00
|
|
|
|
2011-03-29 17:02:15 +02:00
|
|
|
doCheck = false; # doesn't work with Python 2.7
|
2009-05-24 14:20:08 +02:00
|
|
|
|
2011-03-29 17:02:15 +02:00
|
|
|
checkPhase = "python setup.py test";
|
2009-05-24 00:54:11 +02:00
|
|
|
|
|
|
|
meta = {
|
|
|
|
description = "Utilities to facilitate the installation of Python packages";
|
|
|
|
homepage = http://pypi.python.org/pypi/setuptools;
|
|
|
|
licenses = [ "PSF" "ZPL" ];
|
2009-05-24 14:20:08 +02:00
|
|
|
};
|
2009-05-24 00:54:11 +02:00
|
|
|
}
|