Merge remote-tracking branch 'origin/master' into stdenv-updates

This commit is contained in:
Eelco Dolstra
2013-01-17 14:19:14 +01:00
120 changed files with 2870 additions and 471 deletions

View File

@@ -3,7 +3,7 @@
(http://pypi.python.org/pypi/setuptools/), which represents a large
number of Python packages nowadays. */
{ python, setuptools, wrapPython, lib, offlineDistutils, setuptoolsSite }:
{ python, setuptools, wrapPython, lib, offlineDistutils, recursivePthLoader }:
{ name, namePrefix ? "python-"
@@ -23,7 +23,7 @@
''
easy_install --always-unzip --prefix="$out" .
''
, preConfigure ? "true"
, buildPhase ? "true"
@@ -48,16 +48,14 @@ python.stdenv.mkDerivation (attrs // {
name = namePrefix + name;
# checkPhase after installPhase to run tests on installed packages
phases = "unpackPhase patchPhase configurePhase buildPhase installPhase checkPhase fixupPhase distPhase";
buildInputs = [ python wrapPython setuptools ] ++ buildInputs ++ pythonPath;
# setuptoolsSite is responsible for loading pth files
propagatedBuildInputs = propagatedBuildInputs ++ [ setuptoolsSite ];
propagatedBuildInputs = propagatedBuildInputs ++ [ recursivePthLoader ];
buildInputStrings = map toString buildInputs;
pythonPath = [ setuptools] ++ pythonPath;
pythonPath = [ setuptools ] ++ pythonPath;
preConfigure = ''
PYTHONPATH="${offlineDistutils}/lib/${python.libPrefix}/site-packages:$PYTHONPATH"
@@ -83,9 +81,7 @@ python.stdenv.mkDerivation (attrs // {
# Remove any site.py files generated by easy_install as these
# cause collisions. If pth files are to be processed a
# corresponding site.py needs to be included in the PYTHONPATH.
#
# leave them until we have a better solution: see #209
#rm -f "$out/lib/${python.libPrefix}"/site-packages/site.py*
rm -f "$out/lib/${python.libPrefix}"/site-packages/site.py*
${postInstall}
'';