0

I'm trying to install node-sass or gulp-sass on my Raspberry Pi, I have these errors :

npm WARN deprecated npmconf@2.1.2: this package has been reintegrated into npm and is now out of date with respect to npm
npm WARN deprecated lodash.padright@3.1.1: This package has been renamed. Use lodash.padend@^4.0.0.
npm WARN deprecated lodash.padleft@3.1.1: This package has been renamed. Use lodash.padstart@^4.0.0.

> node-sass@3.4.2 install /var/www/drupal8/node_modules/node-sass
> node scripts/install.js

Cannot download "https://github.com/sass/node-sass/releases/download/v3.4.2/linux-arm-46_binding.node":

HTTP error 404 Not Found

Hint: If github.com is not accessible in your location
      try setting a proxy via HTTP_PROXY, e.g.

      export HTTP_PROXY=http://example.com:1234

or configure npm proxy via

      npm config set proxy http://example.com:8080

> node-sass@3.4.2 postinstall /var/www/drupal8/node_modules/node-sass
> node scripts/build.js

Building: /usr/local/bin/node /var/www/drupal8/node_modules/node-gyp/bin/node-gyp.js rebuild --verbose --libsass_ext= --libsass_cflags= --libsass_ldflags= --libsass_library=

I've tried this solution : https://www.raspberrypi.org/forums/viewtopic.php?f=66&t=117076, but does not work.

Thanks,

Christian Stewart
  • 15,217
  • 20
  • 82
  • 139
Xad31
  • 1
  • 2

2 Answers2

0

So what's happening here is that there's not a precompiled version of node-sass for arm, the architecture of your device.

It then tries to compile the module using scripts/build.js.

You haven't included any errors to suggest why this might fail. What I'd recommend doing is making sure you have build-essential installed on your system (via apt or whatever package manager you have).

Christian Stewart
  • 15,217
  • 20
  • 82
  • 139
0

I had this same problem, with node 5.x version, I downgrade to version 4 following the instructions below and installed node-sass successfully

Download Node.js source Raspberry Pi Model A, B, B+ and Compute Module

wget https://nodejs.org/dist/v4.0.0/node-v4.0.0-linux-armv6l.tar.gz 
tar -xvf node-v4.0.0-linux-armv6l.tar.gz 
cd node-v4.0.0-linux-armv6l

Raspberry Pi 2 Model B

wget https://nodejs.org/dist/v4.0.0/node-v4.0.0-linux-armv7l.tar.gz 
tar -xvf node-v4.0.0-linux-armv7l.tar.gz 
cd node-v4.0.0-linux-armv7l

Copy to /usr/local

sudo cp -R * /usr/local/
Rui Sebastião
  • 855
  • 1
  • 18
  • 36