New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
nodePackages.dat :init at 13.13.1 #75832
Conversation
This pull request has been mentioned on NixOS Discourse. There might be relevant details there: https://discourse.nixos.org/t/nodepackages-dat-init-at-13-13-1/5135/1 |
I think you add an entry in |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
If I were you I'd avoid committing the changes to node-packages-v10.nix
and node-packages-v12.nix
since you're not trying to modify those package sets.
@@ -2,7 +2,7 @@ | |||
|
|||
{pkgs ? import <nixpkgs> { | |||
inherit system; | |||
}, system ? builtins.currentSystem, nodejs ? pkgs."nodejs-13_x"}: | |||
}, system ? builtins.currentSystem, nodejs ? pkgs."nodejs-8_x"}: |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This looks wrong
@@ -363,7 +363,7 @@ let | |||
|
|||
npm ${forceOfflineFlag} --nodedir=${nodeSources} ${npmFlags} ${stdenv.lib.optionalString production "--production"} rebuild | |||
|
|||
if [ "''${dontNpmInstall-}" != "1" ] | |||
if [ "$dontNpmInstall" != "1" ] |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This will produce an error if $dontNpmInstall
is unset and set -u
is enabled (which I think it is by default for stdenv packages, not sure about node packages).
Even with @lilyball 's suggestion I still get the following error:
|
BTW if you wrap your long outputs in a <details><summary>Description goes here</summary>
markdown contents goes here
</details> (the blank lines are to ensure block-level markdown inside the tag is parsed) This renders like Description goes hereecho "this is your contents" |
The error is coming from |
Even with
|
Curious, when I try to build
If I try to build As for the error I printed, looking at this file there's two different In any case, given how this works, declaring the |
My latest attempt is with the following diff (note: I removed diff --git a/pkgs/development/node-packages/default-v13.nix b/pkgs/development/node-packages/default-v13.nix
index a5bc1c8e1ad..93c45ffa4ce 100644
--- a/pkgs/development/node-packages/default-v13.nix
+++ b/pkgs/development/node-packages/default-v13.nix
@@ -13,7 +13,7 @@ nodePackages // {
wrapProgram "$out/bin/node2nix" --prefix PATH : ${stdenv.lib.makeBinPath [ pkgs.nix ]}
'';
};
- sodium-native = nodePackages.sodium-native.override {
- buildInputs = [ nodePackages.node-gyp-build pkgs.libtool ];
+ dat = nodePackages.dat.override {
+ nativeBuildInputs = [ nodePackages.node-gyp-build ];
};
}
diff --git a/pkgs/development/node-packages/node-packages-v13.json b/pkgs/development/node-packages/node-packages-v13.json
index f4947938390..a6576f47328 100644
--- a/pkgs/development/node-packages/node-packages-v13.json
+++ b/pkgs/development/node-packages/node-packages-v13.json
@@ -1,5 +1,5 @@
[
"node2nix",
- "dat" ,
- "sodium-native"
+ "dat",
+ "node-gyp-build"
]
diff --git a/pkgs/development/node-packages/node-packages-v13.nix b/pkgs/development/node-packages/node-packages-v13.nix
index a11eacd0fde..fc3939164f7 100644
--- a/pkgs/development/node-packages/node-packages-v13.nix
+++ b/pkgs/development/node-packages/node-packages-v13.nix
@@ -5269,23 +5269,18 @@ in
bypassCache = true;
reconstructLock = true;
};
- sodium-native = nodeEnv.buildNodePackage {
- name = "sodium-native";
- packageName = "sodium-native";
- version = "2.4.6";
+ node-gyp-build = nodeEnv.buildNodePackage {
+ name = "node-gyp-build";
+ packageName = "node-gyp-build";
+ version = "4.2.0";
src = fetchurl {
- url = "https://registry.npmjs.org/sodium-native/-/sodium-native-2.4.6.tgz";
- sha512 = "Ro9lhTjot8M01nwKLXiqLSmjR7B8o+Wg4HmJUjEShw/q6XPlNMzjPkA1VJKaMH8SO8fJ/sggAKVwreTaFszS2Q==";
+ url = "https://registry.npmjs.org/node-gyp-build/-/node-gyp-build-4.2.0.tgz";
+ sha512 = "4oiumOLhCDU9Rronz8PZ5S4IvT39H5+JEv/hps9V8s7RSLhsac0TCP78ulnHXOo8X1wdpPiTayGlM1jr4IbnaQ==";
};
- dependencies = [
- sources."ini-1.3.5"
- sources."nan-2.14.0"
- sources."node-gyp-build-4.2.0"
- ];
buildInputs = globalBuildInputs;
meta = {
- description = "Low level bindings for libsodium";
- homepage = https://github.com/sodium-friends/sodium-native;
+ description = "Build tool and bindings loader for node-gyp that supports prebuilds";
+ homepage = https://github.com/prebuild/node-gyp-build;
license = "MIT";
};
production = true; For some reason this produces compilation errors. I don't know if Full log
|
cc @svanderburg |
Apparently if I install dat via npm -g I get no troubles and |
Apparently dat was already in nixpkgs in node-packages-v10.json,but it does not compile |
Motivation for this change
Things done
Buld fails with the following error:
sandbox
innix.conf
on non-NixOS linux)nix-shell -p nix-review --run "nix-review wip"
./result/bin/
)nix path-info -S
before and after)Notify maintainers
cc @