diff options
| author | Ivan Trubach <mr.trubach@icloud.com> | 2024-06-04 07:13:46 +0300 |
|---|---|---|
| committer | Antoine du Hamel <duhamelantoine1995@gmail.com> | 2024-07-08 15:52:28 +0200 |
| commit | 69a5ce04aa9978538a13f4dfe935ef09fa910ac8 (patch) | |
| tree | b1b2dad752e0a44b52dca8047f085469f9266390 | |
| parent | nodejs_20: 20.12.2 -> 20.14.0 (#316258) (diff) | |
| download | nixpkgs-69a5ce04aa9978538a13f4dfe935ef09fa910ac8.tar.gz | |
nodejs: fix impure configure phase
When running configurePhase from impure build environment (i.e. nix
develop), default ./configure script was selecting wrong, impure Python
installation.
https://github.com/nodejs/node/blob/d57af10d1be390f4e33e6efe596133de9da36c86/configure#L7-L15
(cherry picked from commit f2f7ea87e8e97e20ea21b8125eda3d6845ebcdcb)
| -rw-r--r-- | pkgs/development/web/nodejs/nodejs.nix | 7 |
1 files changed, 5 insertions, 2 deletions
diff --git a/pkgs/development/web/nodejs/nodejs.nix b/pkgs/development/web/nodejs/nodejs.nix index 7f7f72c890e2..52899e5763d0 100644 --- a/pkgs/development/web/nodejs/nodejs.nix +++ b/pkgs/development/web/nodejs/nodejs.nix @@ -60,8 +60,6 @@ let NIX_CFLAGS_COMPILE = "-D__ENVIRONMENT_MAC_OS_X_VERSION_MIN_REQUIRED__=101300"; }; - CC_host = "cc"; - CXX_host = "c++"; depsBuildBuild = [ buildPackages.stdenv.cc openssl libuv zlib icu ]; # NB: technically, we do not need bash in build inputs since all scripts are @@ -106,6 +104,11 @@ let dontDisableStatic = true; + configureScript = writeScript "nodejs-configure" '' + export CC_host="$CC_FOR_BUILD" CXX_host="$CXX_FOR_BUILD" + exec ${python.executable} configure.py "$@" + ''; + enableParallelBuilding = true; # Don't allow enabling content addressed conversion as `nodejs` |
