0

When I install geoip (https://github.com/kuno/GeoIP)

sudo npm install geoip (-g)

I have this error back

gyp ERR! build error 
gyp ERR! stack Error: `make` failed with exit code: 2
gyp ERR! stack     at ChildProcess.onExit (/root/local/lib/node_modules/npm/node_modules/node-gyp/lib/build.js:267:23)
gyp ERR! stack     at ChildProcess.EventEmitter.emit (events.js:98:17)
gyp ERR! stack     at Process.ChildProcess._handle.onexit (child_process.js:789:12)
gyp ERR! System Linux 3.2.0-24-virtual
gyp ERR! command "node" "/root/local/lib/node_modules/npm/node_modules/node-gyp/bin/node-    gyp.js" "rebuild"
gyp ERR! cwd /var/www/test.com/node_modules/geoip
gyp ERR! node -v v0.10.18
gyp ERR! node-gyp -v v0.10.9
gyp ERR! not ok 
npm ERR! weird error 1
npm ERR! not ok code 0

Anyone has the same problem?
This happen remotely on Ubuntu 12.04. In local on OSX it works.

4

1 回答 1

2

安装失败,因为它没有找到zlip.h文件。请在执行命令前执行此npm install geoip命令

sudo apt-get install zlib1g-dev
于 2013-09-17T10:09:00.417 回答