Skip to content

Commit

Permalink
Merge pull request #19510 from grahamc/nodejs
Browse files Browse the repository at this point in the history
Nodejs: Upgrades for security patches
  • Loading branch information
grahamc committed Oct 14, 2016
2 parents 4771ccd + 91c4943 commit fcd4b7e
Show file tree
Hide file tree
Showing 4 changed files with 15 additions and 16 deletions.
5 changes: 3 additions & 2 deletions pkgs/development/web/nodejs/nodejs.nix
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,8 @@
, preBuild ? ""
, extraConfigFlags ? []
, extraBuildInputs ? []
, ...
, patches ? [],
...
}:

assert stdenv.system != "armv5tel-linux";
Expand Down Expand Up @@ -44,7 +45,7 @@ in stdenv.mkDerivation {
PATH=$out/bin:$PATH patchShebangs $out
'';

patches = stdenv.lib.optionals stdenv.isDarwin [ ./no-xcode.patch ];
patches = patches ++ stdenv.lib.optionals stdenv.isDarwin [ ./no-xcode.patch ];

buildInputs = extraBuildInputs
++ [ python which zlib libuv openssl ]
Expand Down
4 changes: 2 additions & 2 deletions pkgs/development/web/nodejs/v4.nix
Original file line number Diff line number Diff line change
Expand Up @@ -4,9 +4,9 @@
}@args:

import ./nodejs.nix (args // rec {
version = "4.4.6";
version = "4.6.0";
src = fetchurl {
url = "http://nodejs.org/dist/v${version}/node-v${version}.tar.xz";
sha256 = "0f6bbfbea525469c91932b1aac35e0810e6bcda96f1c720e42a433942ee66106";
sha256 = "1566q1kkv8j30fgqx8sm2h8323f38wwpa1hfb10gr6z46jyhv4a2";
};
})
12 changes: 9 additions & 3 deletions pkgs/development/web/nodejs/v6.nix
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
{ stdenv, fetchurl, openssl, python, zlib, libuv, v8, utillinux, http-parser
, pkgconfig, runCommand, which, libtool
, pkgconfig, runCommand, which, libtool, fetchpatch
, callPackage
, darwin ? null
}@args:
Expand All @@ -8,12 +8,18 @@ let
inherit (darwin.apple_sdk.frameworks) CoreServices ApplicationServices;

in import ./nodejs.nix (args // rec {
version = "6.7.0";
sha256 = "1r9vvnczjczqs29ja8gmbqgsfgkg0dph4qkaxb3yh7mb98r2ic6f";
version = "6.8.0";
sha256 = "13arzwki13688hr1lh871y06lrk019g4hkasmg11arm8j1dcwcpq";
extraBuildInputs = stdenv.lib.optionals stdenv.isDarwin
[ CoreServices ApplicationServices ];
preBuild = stdenv.lib.optionalString stdenv.isDarwin ''
sed -i -e "s|tr1/type_traits|type_traits|g" \
-e "s|std::tr1|std|" src/util.h
'';
patches = [
(fetchpatch {
url = "https://github.com/nodejs/node/commit/fc164acbbb700fd50ab9c04b47fc1b2687e9c0f4.patch";
sha256 = "1rms3n09622xmddn013yvf5c6p3s8w8s0d2h813zs8c1l15k4k1i";
})
];
})
10 changes: 1 addition & 9 deletions pkgs/top-level/all-packages.nix
Original file line number Diff line number Diff line change
Expand Up @@ -2307,7 +2307,7 @@ in
less = callPackage ../tools/misc/less { };

lf = callPackage ../tools/misc/lf {};

lhasa = callPackage ../tools/compression/lhasa {};

libcpuid = callPackage ../tools/misc/libcpuid { };
Expand Down Expand Up @@ -2419,10 +2419,6 @@ in
libtool = darwin.cctools;
};

nodejs-5_x = callPackage ../development/web/nodejs/v5.nix {
libtool = darwin.cctools;
};

nodejs-6_x = callPackage ../development/web/nodejs/v6.nix {
libtool = darwin.cctools;
};
Expand All @@ -2436,10 +2432,6 @@ in
nodejs = pkgs.nodejs-6_x;
};

nodePackages_5_x = callPackage ../development/node-packages/default-v5.nix {
nodejs = pkgs.nodejs-5_x;
};

nodePackages_4_x = callPackage ../development/node-packages/default-v4.nix {
nodejs = pkgs.nodejs-4_x;
};
Expand Down

0 comments on commit fcd4b7e

Please sign in to comment.