2013-08-26 20:55:48 +01:00
|
|
|
{ pkgs, stdenv, nodejs, fetchurl, neededNatives, self, generated ? ./node-packages-generated.nix }:
|
2012-07-25 22:46:21 +01:00
|
|
|
|
2013-08-20 18:12:56 +01:00
|
|
|
{
|
2013-05-31 17:50:28 +01:00
|
|
|
nativeDeps = {
|
2013-07-27 18:33:18 +01:00
|
|
|
"node-expat"."*" = [ pkgs.expat ];
|
2013-09-04 18:29:15 +01:00
|
|
|
"rbytes"."*" = [ pkgs.openssl ];
|
2013-08-20 23:56:13 +01:00
|
|
|
"phantomjs"."~1.9" = [ pkgs.phantomjs ];
|
2013-05-31 17:50:28 +01:00
|
|
|
};
|
2013-05-29 16:22:18 +01:00
|
|
|
|
2013-05-31 17:50:28 +01:00
|
|
|
buildNodePackage = import ../development/web/nodejs/build-node-package.nix {
|
|
|
|
inherit stdenv nodejs neededNatives;
|
|
|
|
inherit (pkgs) runCommand;
|
|
|
|
};
|
2013-05-29 16:22:18 +01:00
|
|
|
|
2013-05-31 17:50:28 +01:00
|
|
|
patchLatest = srcAttrs:
|
|
|
|
let src = fetchurl srcAttrs; in pkgs.runCommand src.name {} ''
|
|
|
|
mkdir unpack
|
|
|
|
cd unpack
|
|
|
|
tar xf ${src}
|
|
|
|
mv */ package 2>/dev/null || true
|
|
|
|
sed -i -e "s/: \"latest\"/: \"*\"/" package/package.json
|
|
|
|
tar cf $out *
|
|
|
|
'';
|
2013-05-28 03:29:00 +01:00
|
|
|
|
2013-05-31 17:50:28 +01:00
|
|
|
/* Put manual packages below here (ideally eventually managed by npm2nix */
|
2013-08-26 20:55:48 +01:00
|
|
|
} // import generated { inherit self fetchurl; inherit (pkgs) lib; }
|