Compare commits
3 Commits
master
...
python-wip
Author | SHA1 | Date | |
---|---|---|---|
![]() |
9b9a21fd4f | ||
![]() |
0b3a49d78d | ||
![]() |
58f77b8219 |
|
@ -50,9 +50,6 @@ then throw "${name} not supported for interpreter ${python.executable}"
|
||||||
else
|
else
|
||||||
|
|
||||||
let
|
let
|
||||||
# use setuptools shim (so that setuptools is imported before distutils)
|
|
||||||
# pip does the same thing: https://github.com/pypa/pip/pull/3265
|
|
||||||
setuppy = ./run_setup.py;
|
|
||||||
# For backwards compatibility, let's use an alias
|
# For backwards compatibility, let's use an alias
|
||||||
doInstallCheck = doCheck;
|
doInstallCheck = doCheck;
|
||||||
in
|
in
|
||||||
|
@ -77,12 +74,9 @@ python.stdenv.mkDerivation (builtins.removeAttrs attrs ["disabled" "doCheck"] //
|
||||||
runHook postConfigure
|
runHook postConfigure
|
||||||
'';
|
'';
|
||||||
|
|
||||||
# we copy nix_run_setup.py over so it's executed relative to the root of the source
|
|
||||||
# many project make that assumption
|
|
||||||
buildPhase = attrs.buildPhase or ''
|
buildPhase = attrs.buildPhase or ''
|
||||||
runHook preBuild
|
runHook preBuild
|
||||||
cp ${setuppy} nix_run_setup.py
|
${python.interpreter} -m setuptools.launch setup.py ${lib.optionalString (setupPyBuildFlags != []) ("build_ext " + (lib.concatStringsSep " " setupPyBuildFlags))} bdist_wheel
|
||||||
${python.interpreter} nix_run_setup.py ${lib.optionalString (setupPyBuildFlags != []) ("build_ext " + (lib.concatStringsSep " " setupPyBuildFlags))} bdist_wheel
|
|
||||||
runHook postBuild
|
runHook postBuild
|
||||||
'';
|
'';
|
||||||
|
|
||||||
|
@ -105,14 +99,14 @@ python.stdenv.mkDerivation (builtins.removeAttrs attrs ["disabled" "doCheck"] //
|
||||||
|
|
||||||
installCheckPhase = attrs.checkPhase or ''
|
installCheckPhase = attrs.checkPhase or ''
|
||||||
runHook preCheck
|
runHook preCheck
|
||||||
${python.interpreter} nix_run_setup.py test
|
${python.interpreter} -m setuptools.launch setup.py test
|
||||||
runHook postCheck
|
runHook postCheck
|
||||||
'';
|
'';
|
||||||
|
|
||||||
postFixup = attrs.postFixup or ''
|
postFixup = attrs.postFixup or ''
|
||||||
wrapPythonPrograms
|
wrapPythonPrograms
|
||||||
|
|
||||||
# check if we have two packagegs with the same name in closure and fail
|
# check if we have two packages with the same name in closure and fail
|
||||||
# this shouldn't happen, something went wrong with dependencies specs
|
# this shouldn't happen, something went wrong with dependencies specs
|
||||||
${python.interpreter} ${./catch_conflicts.py}
|
${python.interpreter} ${./catch_conflicts.py}
|
||||||
'';
|
'';
|
||||||
|
@ -135,7 +129,7 @@ python.stdenv.mkDerivation (builtins.removeAttrs attrs ["disabled" "doCheck"] //
|
||||||
} // meta // {
|
} // meta // {
|
||||||
# add extra maintainer(s) to every package
|
# add extra maintainer(s) to every package
|
||||||
maintainers = (meta.maintainers or []) ++ [ chaoflow iElectric ];
|
maintainers = (meta.maintainers or []) ++ [ chaoflow iElectric ];
|
||||||
# a marker for release utilies to discover python packages
|
# a marker for release utilities to discover python packages
|
||||||
isBuildPythonPackage = python.meta.platforms;
|
isBuildPythonPackage = python.meta.platforms;
|
||||||
};
|
};
|
||||||
})
|
})
|
||||||
|
|
|
@ -1,6 +0,0 @@
|
||||||
import setuptools
|
|
||||||
import tokenize
|
|
||||||
|
|
||||||
__file__='setup.py';
|
|
||||||
|
|
||||||
exec(compile(getattr(tokenize, 'open', open)(__file__).read().replace('\\r\\n', '\\n'), __file__, 'exec'))
|
|
|
@ -4,11 +4,11 @@ stdenv.mkDerivation rec {
|
||||||
shortName = "setuptools-${version}";
|
shortName = "setuptools-${version}";
|
||||||
name = "${python.executable}-${shortName}";
|
name = "${python.executable}-${shortName}";
|
||||||
|
|
||||||
version = "19.4"; # 18.4 and up breaks python34Packages.characteristic and many others
|
version = "19.6";
|
||||||
|
|
||||||
src = fetchurl {
|
src = fetchurl {
|
||||||
url = "http://pypi.python.org/packages/source/s/setuptools/${shortName}.tar.gz";
|
url = "http://pypi.python.org/packages/source/s/setuptools/${shortName}.tar.gz";
|
||||||
sha256 = "214bf29933f47cf25e6faa569f710731728a07a19cae91ea64f826051f68a8cf";
|
sha256 = "1s8jd6lgaqjk5vbc3h5grvabzbzsvsk67f1651mcr3hs7isqvm7c";
|
||||||
};
|
};
|
||||||
|
|
||||||
buildInputs = [ python wrapPython ];
|
buildInputs = [ python wrapPython ];
|
||||||
|
|
|
@ -377,18 +377,18 @@ in modules // {
|
||||||
|
|
||||||
aiodns = buildPythonPackage rec {
|
aiodns = buildPythonPackage rec {
|
||||||
name = "aiodns-${version}";
|
name = "aiodns-${version}";
|
||||||
version = "1.0.0";
|
version = "1.0.1";
|
||||||
|
|
||||||
src = pkgs.fetchurl {
|
src = pkgs.fetchurl {
|
||||||
url = "https://pypi.python.org/packages/source/a/aiodns/${name}.tar.gz";
|
url = "https://pypi.python.org/packages/source/a/aiodns/${name}.tar.gz";
|
||||||
sha256 = "95140e4d2b67ee16dfbf357d9b54d7453b58f1732e81f869a1803a3ba3773b0d";
|
sha256 = "595b78b8d54115d937cf60d778c02dad76b6f789fd527dab308f99e5601e7f3d";
|
||||||
};
|
};
|
||||||
|
|
||||||
propagatedBuildInputs = with self; [ pycares ] ++ optional isPy33 asyncio ++ optional (isPy26 || isPy27 || isPyPy) trollius;
|
propagatedBuildInputs = with self; [ pycares ] ++ optional isPy33 asyncio ++ optional (isPy26 || isPy27 || isPyPy) trollius;
|
||||||
|
|
||||||
# Tests are not distributed
|
checkPhase = ''
|
||||||
# https://github.com/saghul/aiodns/issues/13
|
${python.interpreter} tests.py
|
||||||
doCheck = false;
|
'';
|
||||||
|
|
||||||
meta = {
|
meta = {
|
||||||
homepage = http://github.com/saghul/aiodns;
|
homepage = http://github.com/saghul/aiodns;
|
||||||
|
|
Loading…
Reference in New Issue
Block a user