diff options
Diffstat (limited to 'pkgs/development/python-modules/bootstrap/build/default.nix')
| -rw-r--r-- | pkgs/development/python-modules/bootstrap/build/default.nix | 68 |
1 files changed, 37 insertions, 31 deletions
diff --git a/pkgs/development/python-modules/bootstrap/build/default.nix b/pkgs/development/python-modules/bootstrap/build/default.nix index f4e49bd65605..2101ee06c6bb 100644 --- a/pkgs/development/python-modules/bootstrap/build/default.nix +++ b/pkgs/development/python-modules/bootstrap/build/default.nix @@ -1,46 +1,52 @@ -{ lib -, stdenv -, python -, build -, flit-core -, installer -, packaging -, pyproject-hooks -, tomli -, makeWrapper +{ + lib, + stdenv, + python, + build, + flit-core, + installer, + packaging, + pyproject-hooks, + tomli, + makeWrapper, }: let - buildBootstrapPythonModule = basePackage: attrs: stdenv.mkDerivation ({ - pname = "${python.libPrefix}-bootstrap-${basePackage.pname}"; - inherit (basePackage) version src meta; + buildBootstrapPythonModule = + basePackage: attrs: + stdenv.mkDerivation ( + { + pname = "${python.libPrefix}-bootstrap-${basePackage.pname}"; + inherit (basePackage) version src meta; - nativeBuildInputs = [ makeWrapper ]; + nativeBuildInputs = [ makeWrapper ]; - buildPhase = '' - runHook preBuild + buildPhase = '' + runHook preBuild - PYTHONPATH="${flit-core}/${python.sitePackages}" \ - ${python.interpreter} -m flit_core.wheel + PYTHONPATH="${flit-core}/${python.sitePackages}" \ + ${python.interpreter} -m flit_core.wheel - runHook postBuild - ''; + runHook postBuild + ''; - installPhase = '' - runHook preInstall + installPhase = '' + runHook preInstall - PYTHONPATH="${installer}/${python.sitePackages}" \ - ${python.interpreter} -m installer \ - --destdir "$out" --prefix "" dist/*.whl + PYTHONPATH="${installer}/${python.sitePackages}" \ + ${python.interpreter} -m installer \ + --destdir "$out" --prefix "" dist/*.whl - runHook postInstall - ''; - } // attrs); + runHook postInstall + ''; + } + // attrs + ); - bootstrap-packaging = buildBootstrapPythonModule packaging {}; + bootstrap-packaging = buildBootstrapPythonModule packaging { }; - bootstrap-pyproject-hooks = buildBootstrapPythonModule pyproject-hooks {}; + bootstrap-pyproject-hooks = buildBootstrapPythonModule pyproject-hooks { }; - bootstrap-tomli = buildBootstrapPythonModule tomli {}; + bootstrap-tomli = buildBootstrapPythonModule tomli { }; sitePkgs = python.sitePackages; in |
