Python: improve cross-compilation

This changeset allows for cross-compilation of Python packages. Packages
built with buildPythonPackage are not allowed to refer to the build
machine. Executables that have shebangs will refer to the host.
This commit is contained in:
Frederik Rietdijk
2019-01-02 20:09:44 +01:00
parent 613498af97
commit f665828fa3
14 changed files with 68 additions and 41 deletions

View File

@@ -10,17 +10,16 @@
, ensureNewerSourcesForZipFilesHook
, toPythonModule
, namePrefix
, bootstrapped-pip
, flit
, writeScript
, update-python-libraries
}:
let
setuptools-specific = import ./build-python-package-setuptools.nix { inherit lib python bootstrapped-pip; };
setuptools-specific = import ./build-python-package-setuptools.nix { inherit lib python; };
flit-specific = import ./build-python-package-flit.nix { inherit python flit; };
wheel-specific = import ./build-python-package-wheel.nix { };
common = import ./build-python-package-common.nix { inherit python bootstrapped-pip; };
common = import ./build-python-package-common.nix { inherit python; };
mkPythonDerivation = import ./mk-python-derivation.nix {
inherit lib config python wrapPython setuptools unzip ensureNewerSourcesForZipFilesHook;
inherit toPythonModule namePrefix writeScript update-python-libraries;