!NhAsaYbbgmzHtXTPQJ:funklause.de

Nix NodeJS

210 Members
59 Servers

Load older messages


SenderMessageTime
14 Jul 2023
@lily:lily.flowersLily Foster

Just to confirm, does this do better for you Janne Heß?

diff --git a/pkgs/build-support/node/build-npm-package/hooks/default.nix b/pkgs/build-support/node/build-npm-package/hooks/default.nix
index c34709335ff..1e6d82dc8df 100644
--- a/pkgs/build-support/node/build-npm-package/hooks/default.nix
+++ b/pkgs/build-support/node/build-npm-package/hooks/default.nix
@@ -6,7 +6,7 @@
       name = "npm-config-hook";
       substitutions = {
         nodeSrc = srcOnly nodejs;
-        nodeGyp = "${buildPackages.nodejs}/lib/node_modules/npm/node_modules/node-gyp/bin/node-gyp.js";
+        nodeGyp = "${nodejs.__spliced.buildHost or buildPackages.nodejs}/lib/node_modules/npm/node_modules/node-gyp/bin/node-gyp.js";
 
         # Specify `diff`, `jq`, and `prefetch-npm-deps` by abspath to ensure that the user's build
         # inputs do not cause us to find the wrong binaries.
15:09:19
@janne.hess:helsinki-systems.de@janne.hess:helsinki-systems.detbh, I have no idea how __spliced works15:09:40
@janne.hess:helsinki-systems.de@janne.hess:helsinki-systems.debut probably?15:09:43
@lily:lily.flowersLily Foster
In reply to @janne.hess:helsinki-systems.de
tbh, I have no idea how __spliced works
Dark magic mostly. There's a reason a lot of people consider splicing to have been a bit of a mistake...
15:10:10
@janne.hess:helsinki-systems.de@janne.hess:helsinki-systems.deso I have to check spliceReal → mash → merge → value?15:10:55
@janne.hess:helsinki-systems.de@janne.hess:helsinki-systems.de * so I have to check spliceReal → mash → merge → value in splice.nix??15:11:01
@janne.hess:helsinki-systems.de@janne.hess:helsinki-systems.dewhat the…15:11:30
@lily:lily.flowersLily Foster
In reply to @janne.hess:helsinki-systems.de
but probably?
If that diff does work for your particular use-case, let me know and I may just go ahead and PR it, unless I or someone else comes up with something better
16:49:44
17 Jul 2023
@exelent:matrix.orgexelent joined the room.14:12:41
@exelent:matrix.orgexelent Hello guys, I want to install nodejs using home-manager to my new MBP M2, but nix always intend to build it from source, rather then download from a binary cache.
pkgs = inputs.nixpkgs.legacyPackages.aarch64-darwin;
this are the packages that I define. I also enabled cachix community cache cachix use nix-community
14:39:55
@adam:valkor.netadamcstephensWhat is your nixpkgs input url?15:46:35
@lily:lily.flowersLily Foster exelent: Is your home-manager config in a public repo so that we can look at it? 15:51:03
18 Jul 2023
@hexa:lossy.networkhexa gdamjan: any progress on the appservice-irc? 13:26:24
@gdamjan:spodeli.orggdamjanI didn't have the time to touch it14:38:57
@gdamjan:spodeli.orggdamjanI'm getting ready every day, but not enough slacking time at work :/14:39:24
@gdamjan:spodeli.orggdamjan my idea was to do a fetchYarnDeps for the deps, and do the build manually, based on what they do in the Dockerfile 14:40:56
@gdamjan:spodeli.orggdamjan so fetchYarnDeps gets all the deps, how does one clean-up non-production deps later? 18:23:10
@lily:lily.flowersLily Foster
In reply to @gdamjan:spodeli.org
so fetchYarnDeps gets all the deps, how does one clean-up non-production deps later?
Yarn does that during yarn install by default
18:27:35
@lily:lily.flowersLily FosterFor production*18:27:43
@gdamjan:spodeli.orggdamjanwhen does that happen18:28:05
@gdamjan:spodeli.orggdamjanugh, I just downloaded all the internet of deps :D18:28:21
@gdamjan:spodeli.orggdamjanincluding all the esbuilds for all architectures in the world18:28:51
@lily:lily.flowersLily Foster
In reply to @gdamjan:spodeli.org
when does that happen
Towards the end. I'd have to go double check exactly. Why, is it not doing it for you?
18:29:45
@gdamjan:spodeli.orggdamjanlast time I checked it wasn't18:30:15
@lily:lily.flowersLily FosterCan you share the derivation?18:32:34
@gdamjan:spodeli.orggdamjanlet me re-try, this was some time back trying to build matrix-appservice-irc18:39:30
@gdamjan:spodeli.orggdamjan well, I stumbled on another problem
https://github.com/matrix-org/matrix-appservice-irc/blob/develop/yarn.lock#L1309-L1327
it wants two different versions of ajv
nix only installs the older one
21:52:49
@gdamjan:spodeli.orggdamjanlet me try nixos-unstable21:54:06
@gdamjan:spodeli.orggdamjansame thing21:55:13
@gdamjan:spodeli.orggdamjan

on non-nix there will be 4 versions of ajv:

node_modules/har-validator/node_modules/ajv
node_modules/eslint/node_modules/ajv
node_modules/ajv
node_modules/@eslint/eslintrc/node_modules/ajv```
21:56:05

Show newer messages


Back to Room ListRoom Version: 6