y-a-v-a / node-gd

🎨 GD graphics library (libgd) C++ bindings for Node.js.

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

Install fails on Ubuntu machine

Sunlis opened this issue · comments

I had no issues installing this package in my local Ubuntu VM (running Ubuntu 16.04), but for some reason, when trying to install on my server (also Ubuntu 16.04) it fails. I've installed libgd2-dev, as stated in the README.

Running npm install node-gd gives the classic, wonderfully-useless error:

npm ERR! Linux 4.8.0-56-generic
npm ERR! argv "/usr/bin/nodejs" "/usr/bin/npm" "install" "node-gd"
npm ERR! node v4.2.6
npm ERR! npm  v3.5.2
npm ERR! file sh
npm ERR! code ELIFECYCLE
npm ERR! errno ENOENT
npm ERR! syscall spawn
npm ERR! node-gd@1.5.0 install: `node-gyp rebuild`
npm ERR! spawn ENOENT
npm ERR! 
npm ERR! spawn ENOENT
npm ERR! 
npm ERR! Failed at the node-gd@1.5.0 install script 'node-gyp rebuild'.
npm ERR! Make sure you have the latest version of node.js and npm installed.
npm ERR! If you do, this is most likely a problem with the node-gd package,
npm ERR! not with npm itself.
npm ERR! Tell the author that this fails on your system:
npm ERR!     node-gyp rebuild
npm ERR! You can get information on how to open an issue for this project with:
npm ERR!     npm bugs node-gd
npm ERR! Or if that isn't available, you can get their info via:
npm ERR!     npm owner ls node-gd
npm ERR! There is likely additional logging output above.
npm ERR! Please include the following file with any support request:
npm ERR!     /home/seandohring/space_bot/npm-debug.log

npm-debug.log can be found here

Solved this by upgrading node. I was running an old version (4.x.x). Upgraded to 6.11.1 and install worked first try.