summary refs log tree commit diff
path: root/pkgs/development/web/nodejs/v16.nix
blob: 89b6c3e43631030ded6f5b0a46803ef00b647c83 (plain) (blame)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
{ callPackage, openssl, python3, fetchpatch, enableNpm ? true }:

let
  buildNodejs = callPackage ./nodejs.nix {
    inherit openssl;
    python = python3;
  };
in
  buildNodejs {
    inherit enableNpm;
    version = "16.16.0";
    sha256 = "sha256-FFFR7/Oyql6+czhACcUicag3QK5oepPJjGKM19UnNus=";
    patches = [
      ./disable-darwin-v8-system-instrumentation.patch
      # Fix npm silently fail without a HOME directory https://github.com/npm/cli/issues/4996
      (fetchpatch {
        url = "https://github.com/npm/cli/commit/9905d0e24c162c3f6cc006fa86b4c9d0205a4c6f.patch";
        sha256 = "sha256-RlabXWtjzTZ5OgrGf4pFkolonvTDIPlzPY1QcYDd28E=";
        includes = [ "deps/npm/lib/npm.js" "deps/npm/lib/utils/log-file.js" ];
        stripLen = 1;
        extraPrefix = "deps/npm/";
      })
    ];
  }