node2nix
node2nix copied to clipboard
Libsass nightmare
Haven't found anything about libsass & node2nix, here is a problem:
$ nix build -f .
error: builder for '/nix/store/zrgyi4ayarp0qxhijzlwfjx2h1ys5qs6-node-dependencies-agola-web-0.1.0.drv' failed with exit code 1;
last 10 log lines:
> npm ERR! gyp ERR! command "/nix/store/sndm8q6yhr6a8yy9zdd1sxni3lc8pcmw-nodejs-18.8.0/bin/node" "/nix/store/hyj3limmjwrkjlfmn76ml7633nyzg2h7-node-dependencies-agola-web-0.1.0/agola-web/node_modules/node-gyp/bin/node-gyp.js" "rebuild" "--verbose" "--libsass_ext=" "
--libsass_cflags=" "--libsass_ldflags=" "--libsass_library="
> npm ERR! gyp ERR! cwd /nix/store/hyj3limmjwrkjlfmn76ml7633nyzg2h7-node-dependencies-agola-web-0.1.0/agola-web/node_modules/node-sass
> npm ERR! gyp ERR! node -v v18.8.0
> npm ERR! gyp ERR! node-gyp -v v3.8.0
> npm ERR! gyp ERR! not ok
> npm ERR! Build failed with error code: 1
>
> npm ERR! A complete log of this run can be found in:
> npm ERR! /build/.npm/_logs/2022-09-17T07_36_01_857Z-debug-0.log
>
For full logs, run 'nix log /nix/store/zrgyi4ayarp0qxhijzlwfjx2h1ys5qs6-node-dependencies-agola-web-0.1.0.drv'.
error: 1 dependencies of derivation '/nix/store/6fjjwbs3mn6sgwhrxcz4b4adhqrqyrxm-agola-web.drv' failed to build
error: 1 dependencies of derivation '/nix/store/9mjxszs7f09y78ikrcknbg9rfxlm80g0-agola.drv' failed to build
I have tried to alter node-sass package inside node-packages to look like this:
"node-sass-4.14.1" = {
name = "node-sass";
packageName = "node-sass";
version = "4.14.1";
src = fetchurl {
url = "https://registry.npmjs.org/node-sass/-/node-sass-4.14.1.tgz";
sha512 = "sjCuOlvGyCJS40R8BscF5vhVlQjNN069NtQ1gSxyK1u9iqvn6tf7O1R4GNowVZfiZUCRt5MmMs1xd+4V/7Yr0g==";
};
buildInputs = [pkgs.pkgconfig pkgs.libsass];
};
But no luck. So, how do you deal with this sass thing?
Have you considered switching to sass? It's pure JS, and the recommended implementation going forward. It can generally be installed in a nix environment with no special steps.
I am not a developer of software I am packaging