Files
nixpkgs/pkgs/development/web/nodejs/nodejs.nix
kataokatsuki a976d21b1b nodejs: fix cross-compilation
configureScript interpolates python.interpreter, which resolves to the
hostPlatform interpreter. When cross-compiling, that binary cannot be executed
on the build platform:

  /nix/store/...-python3-aarch64-unknown-linux-musl-3.13.14/bin/python3.13:
  cannot execute binary file: Exec format error

python is also listed in nativeBuildInputs, where splicing substitutes the
buildPackages variant. The previous python.executable was a bare basename, so
it resolved to that build-platform interpreter through PATH.

Use python.pythonOnBuildForHost.interpreter, which refers to the same
derivation that nativeBuildInputs puts on PATH. For native builds the value is
unchanged.
2026-07-27 14:36:48 +09:00

26 KiB