Ubuntu 14.04: Установка пакета `vega`` npmjs`

Мне нужно установить пакет vega из npmjs (см. здесь). Но $ sudo npm -g install vega выдает следующие ошибки. Любая помощь будет высоко оценена. Заранее спасибо за вашу помощь.

$ sudo apt-get install nodejs
$ sudo npm -g install npm

$ node --version
v0.10.33

$ nodejs --version
v0.10.33


$ sudo npm -g install vega

> canvas@1.1.3 install /usr/lib/node_modules/vega/node_modules/canvas
> node-gyp rebuild

gyp WARN EACCES user "root" does not have permission to access the dev dir "/home/yaseen/.node-gyp/0.10.33"
gyp WARN EACCES attempting to reinstall using temporary dev dir "/usr/lib/node_modules/vega/node_modules/canvas/.node-gyp"
Package cairo was not found in the pkg-config search path.
Perhaps you should add the directory containing `cairo.pc'
to the PKG_CONFIG_PATH environment variable
No package 'cairo' found
gyp: Call to './util/has_cairo_freetype.sh' returned exit status 0. while trying to load binding.gyp
gyp ERR! configure error 
gyp ERR! stack Error: `gyp` failed with exit code: 1
gyp ERR! stack     at ChildProcess.onCpExit (/usr/lib/node_modules/npm/node_modules/node-gyp/lib/configure.js:343:16)
gyp ERR! stack     at ChildProcess.emit (events.js:98:17)
gyp ERR! stack     at Process.ChildProcess._handle.onexit (child_process.js:810:12)
gyp ERR! System Linux 3.13.0-40-generic
gyp ERR! command "node" "/usr/lib/node_modules/npm/node_modules/node-gyp/bin/node-gyp.js" "rebuild"
gyp ERR! cwd /usr/lib/node_modules/vega/node_modules/canvas
gyp ERR! node -v v0.10.33
gyp ERR! node-gyp -v v1.0.2
gyp ERR! not ok 

> contextify@0.1.9 install /usr/lib/node_modules/vega/node_modules/d3/node_modules/jsdom/node_modules/contextify
> node-gyp rebuild

gyp WARN EACCES user "root" does not have permission to access the dev dir "/home/yaseen/.node-gyp/0.10.33"
gyp WARN EACCES attempting to reinstall using temporary dev dir "/usr/lib/node_modules/vega/node_modules/d3/node_modules/jsdom/node_modules/contextify/.node-gyp"
make: Entering directory `/usr/lib/node_modules/vega/node_modules/d3/node_modules/jsdom/node_modules/contextify/build'
  CXX(target) Release/obj.target/contextify/src/contextify.o
  SOLINK_MODULE(target) Release/obj.target/contextify.node
  SOLINK_MODULE(target) Release/obj.target/contextify.node: Finished
  COPY Release/contextify.node
make: Leaving directory `/usr/lib/node_modules/vega/node_modules/d3/node_modules/jsdom/node_modules/contextify/build'
npm ERR! Linux 3.13.0-40-generic
npm ERR! argv "node" "/usr/bin/npm" "-g" "install" "vega"
npm ERR! node v0.10.33
npm ERR! npm  v2.1.10
npm ERR! code ELIFECYCLE

npm ERR! canvas@1.1.3 install: `node-gyp rebuild`
npm ERR! Exit status 1
npm ERR! 
npm ERR! Failed at the canvas@1.1.3 install script 'node-gyp rebuild'.
npm ERR! This is most likely a problem with the canvas 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 their info via:
npm ERR!     npm owner ls canvas
npm ERR! There is likely additional logging output above.

npm ERR! Please include the following file with any support request:
npm ERR!     /home/yaseen/npm-debug.log
1
задан 3 December 2014 в 20:15

0 ответов

Другие вопросы по тегам:

Похожие вопросы: