···142143The `buildPythonPackage` mainly does four things:
144145-* In the [`buildPhase`](#build-phase), it calls `${python.pythonForBuild.interpreter} setup.py bdist_wheel` to
146 build a wheel binary zipfile.
147* In the [`installPhase`](#ssec-install-phase), it installs the wheel file using `pip install *.whl`.
148* In the [`postFixup`](#var-stdenv-postFixup) phase, the `wrapPythonPrograms` bash function is called to
···1682As workaround install it as an extra `preInstall` step:
16831684```shell
1685-${python.pythonForBuild.interpreter} setup.py install_data --install-dir=$out --root=$out
1686sed -i '/ = data\_files/d' setup.py
1687```
1688
···142143The `buildPythonPackage` mainly does four things:
144145+* In the [`buildPhase`](#build-phase), it calls `${python.pythonOnBuildForHost.interpreter} setup.py bdist_wheel` to
146 build a wheel binary zipfile.
147* In the [`installPhase`](#ssec-install-phase), it installs the wheel file using `pip install *.whl`.
148* In the [`postFixup`](#var-stdenv-postFixup) phase, the `wrapPythonPrograms` bash function is called to
···1682As workaround install it as an extra `preInstall` step:
16831684```shell
1685+${python.pythonOnBuildForHost.interpreter} setup.py install_data --install-dir=$out --root=$out
1686sed -i '/ = data\_files/d' setup.py
1687```
1688
+1-1
nixos/modules/programs/fish.nix
···268 ''
269 mkdir -p $out
270 if [ -d $package/share/man ]; then
271- find $package/share/man -type f | xargs ${pkgs.python3.pythonForBuild.interpreter} ${patchedGenerator}/create_manpage_completions.py --directory $out >/dev/null
272 fi
273 '';
274 in
···268 ''
269 mkdir -p $out
270 if [ -d $package/share/man ]; then
271+ find $package/share/man -type f | xargs ${pkgs.python3.pythonOnBuildForHost.interpreter} ${patchedGenerator}/create_manpage_completions.py --directory $out >/dev/null
272 fi
273 '';
274 in
···1-{ pythonForBuild, runCommand }: {
2 dont-propagate-conflicting-deps = let
3 # customize a package so that its store paths differs
4 mkConflict = pkg: pkg.overrideAttrs { some_modification = true; };
···16 '';
17 in
18 # this build must never triger conflicts
19- pythonForBuild.pkgs.buildPythonPackage {
20 pname = "dont-propagate-conflicting-deps";
21 version = "0.0.0";
22 src = projectSource;
···24 propagatedBuildInputs = [
25 # At least one dependency of `build` should be included here to
26 # keep the test meaningful
27- (mkConflict pythonForBuild.pkgs.tomli)
28 # setuptools is also needed to build the example project
29- pythonForBuild.pkgs.setuptools
30 ];
31 };
32}
···1+{ pythonOnBuildForHost, runCommand }: {
2 dont-propagate-conflicting-deps = let
3 # customize a package so that its store paths differs
4 mkConflict = pkg: pkg.overrideAttrs { some_modification = true; };
···16 '';
17 in
18 # this build must never triger conflicts
19+ pythonOnBuildForHost.pkgs.buildPythonPackage {
20 pname = "dont-propagate-conflicting-deps";
21 version = "0.0.0";
22 src = projectSource;
···24 propagatedBuildInputs = [
25 # At least one dependency of `build` should be included here to
26 # keep the test meaningful
27+ (mkConflict pythonOnBuildForHost.pkgs.tomli)
28 # setuptools is also needed to build the example project
29+ pythonOnBuildForHost.pkgs.setuptools
30 ];
31 };
32}
···37 '';
3839 preBuild = ''
40- ${python.pythonForBuild.interpreter} setup.py build_cython
41 '';
4243 # On Darwin, the test requires macFUSE to be installed outside of Nix.
···37 '';
3839 preBuild = ''
40+ ${python.pythonOnBuildForHost.interpreter} setup.py build_cython
41 '';
4243 # On Darwin, the test requires macFUSE to be installed outside of Nix.
···46 # This is only used for figuring out what version of Python is in
47 # use, and related stuff like figuring out what the install prefix
48 # should be, but it does need to be able to execute Python code.
49- "-Dpython=${python.pythonForBuild.interpreter}"
50 ];
5152 meta = with lib; {
···46 # This is only used for figuring out what version of Python is in
47 # use, and related stuff like figuring out what the install prefix
48 # should be, but it does need to be able to execute Python code.
49+ "-Dpython=${python.pythonOnBuildForHost.interpreter}"
50 ];
5152 meta = with lib; {
···30 # for the package to function. Therefore override of buildPhase was
31 # necessary.
32 buildPhase = ''
33- ${python.pythonForBuild.interpreter} setup.py build_ext --inplace
34- ${python.pythonForBuild.interpreter} setup.py bdist_wheel
35 '';
3637 nativeCheckInputs = [
···30 # for the package to function. Therefore override of buildPhase was
31 # necessary.
32 buildPhase = ''
33+ ${python.pythonOnBuildForHost.interpreter} setup.py build_ext --inplace
34+ ${python.pythonOnBuildForHost.interpreter} setup.py bdist_wheel
35 '';
3637 nativeCheckInputs = [
+1-1
pkgs/development/python-modules/pygobject/3.nix
···57 # This is only used for figuring out what version of Python is in
58 # use, and related stuff like figuring out what the install prefix
59 # should be, but it does need to be able to execute Python code.
60- "-Dpython=${python.pythonForBuild.interpreter}"
61 ];
6263 passthru = {
···57 # This is only used for figuring out what version of Python is in
58 # use, and related stuff like figuring out what the install prefix
59 # should be, but it does need to be able to execute Python code.
60+ "-Dpython=${python.pythonOnBuildForHost.interpreter}"
61 ];
6263 passthru = {
···42 # This is only used for figuring out what version of Python is in
43 # use, and related stuff like figuring out what the install prefix
44 # should be, but it does need to be able to execute Python code.
45- "-Dpython=${python.pythonForBuild.interpreter}"
46 ];
4748 meta = with lib; {
···42 # This is only used for figuring out what version of Python is in
43 # use, and related stuff like figuring out what the install prefix
44 # should be, but it does need to be able to execute Python code.
45+ "-Dpython=${python.pythonOnBuildForHost.interpreter}"
46 ];
4748 meta = with lib; {
···29 ];
3031 buildPhase = ''
32- ${python.pythonForBuild.interpreter} bootstrap.py
33- ${python.pythonForBuild.interpreter} setup.py sdist --formats=gztar
3435 # Here we untar the sdist and retar it in order to control the timestamps
36 # of all the files included
···29 ];
3031 buildPhase = ''
32+ ${python.pythonOnBuildForHost.interpreter} bootstrap.py
33+ ${python.pythonOnBuildForHost.interpreter} setup.py sdist --formats=gztar
3435 # Here we untar the sdist and retar it in order to control the timestamps
36 # of all the files included
···53 wrapGAppsNoGuiHook
54 python3.pkgs.wrapPython
55 # checkInput but cheked for during the configuring
56- (python3.pythonForBuild.withPackages (ps: with ps; [
57 pygobject3
58 dbus-python
59 python-dbusmock
···53 wrapGAppsNoGuiHook
54 python3.pkgs.wrapPython
55 # checkInput but cheked for during the configuring
56+ (python3.pythonOnBuildForHost.withPackages (ps: with ps; [
57 pygobject3
58 dbus-python
59 python-dbusmock
···103 # cython modules are not installed for some reasons
104 (
105 cd TTS/tts/utils/monotonic_align
106- ${python.pythonForBuild.interpreter} setup.py install --prefix=$out
107 )
108 '';
109
···103 # cython modules are not installed for some reasons
104 (
105 cd TTS/tts/utils/monotonic_align
106+ ${python.pythonOnBuildForHost.interpreter} setup.py install --prefix=$out
107 )
108 '';
109