本文介绍了在pkg-config搜索路径中找不到软件包cairo。节点j.s安装画布问题的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧! 问题描述 29岁程序员,3月因学历无情被辞! 我在安装节点安装画布模块时遇到问题。似乎是与cairo的东西我得到这个错误...I am having a problem installing installing the canvas module in node..It seems to be something with cairo I am getting this error...npm http GET https://registry.npmjs.org/canvasnpm http 304 https://registry.npmjs.org/canvasnpm http GET https://registry.npmjs.org/nannpm http 304 https://registry.npmjs.org/nan> [email protected] install /Users/plimb/Desktop/motion-therapy/node_modules/canvas> node-gyp rebuildPackage 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 variableNo package 'cairo' foundgyp: Call to './util/has_cairo_freetype.sh' returned exit status 0. while trying to load binding.gypgyp ERR! configure errorgyp ERR! stack Error: `gyp` failed with exit code: 1gyp ERR! stack at ChildProcess.onCpExit (/usr/local/lib/node_modules/npm/node_modules/node-gyp/lib/configure.js:424:16)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 Darwin 13.0.0gyp ERR! command "node" "/usr/local/lib/node_modules/npm/node_modules/node-gyp/bin/node-gyp.js" "rebuild"gyp ERR! cwd /Users/plimb/Desktop/motion-therapy/node_modules/canvasgyp ERR! node -v v0.10.21gyp ERR! node-gyp -v v0.10.10gyp ERR! not oknpm ERR! weird error 1npm ERR! not ok code 0I'm not sure what it all means! Would appreciate any help!For example how to a mkdir cairo pc in the pkg_config_path environment variable?推荐答案有同样的问题, @ Epistemex的链接帮助我对其进行了疑难解答。Had the same problem and @Epistemex's link helped me troubleshoot it. ...您需要安装 libcairo2-dev , libjpeg-dev 和 libgif-dev 包...sudo apt-get install libcairo2-dev libjpeg-dev libgif-dev 这篇关于在pkg-config搜索路径中找不到软件包cairo。节点j.s安装画布问题的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持! 上岸,阿里云!
05-31 23:12