首页
学习
活动
专区
圈层
工具
发布
社区首页 >问答首页 >npm安装PDFkit失败

npm安装PDFkit失败
EN

Stack Overflow用户
提问于 2011-10-07 14:24:49
回答 1查看 1.9K关注 0票数 1

我试图使用推荐的命令安装PDFKit for node.js:

代码语言:javascript
复制
npm install pdfkit

但是,它在以下消息中失败:

@1.0.5预装/home/woody/node_modules/pdfkit/node_modules/zlib节点-waf干净的/ true;节点-waf配置生成

代码语言:javascript
复制
sh: node-waf: not found
sh: node-waf: not found
npm ERR! error installing zlib@1.0.5 Error: zlib@1.0.5 preinstall: `node-waf clean || true; node-waf configure build`
npm ERR! error installing zlib@1.0.5 `sh "-c" "node-waf clean || true; node-waf configure build"` failed with 127
npm ERR! error installing zlib@1.0.5     at ChildProcess.<anonymous> (/usr/lib/node_modules/npm/lib/utils/exec.js:49:20)
npm ERR! error installing zlib@1.0.5     at ChildProcess.emit (events.js:67:17)
npm ERR! error installing zlib@1.0.5     at ChildProcess.onexit (child_process.js:192:12)
npm ERR! error installing pdfkit@0.1.5 Error: zlib@1.0.5 preinstall: `node-waf clean || true; node-waf configure build`
npm ERR! error installing pdfkit@0.1.5 `sh "-c" "node-waf clean || true; node-waf configure build"` failed with 127
npm ERR! error installing pdfkit@0.1.5     at ChildProcess.<anonymous> (/usr/lib/node_modules/npm/lib/utils/exec.js:49:20)
npm ERR! error installing pdfkit@0.1.5     at ChildProcess.emit (events.js:67:17)
npm ERR! error installing pdfkit@0.1.5     at ChildProcess.onexit (child_process.js:192:12)
npm ERR! zlib@1.0.5 preinstall: `node-waf clean || true; node-waf configure build`
npm ERR! `sh "-c" "node-waf clean || true; node-waf configure build"` failed with 127
npm ERR! 
npm ERR! Failed at the zlib@1.0.5 preinstall script.
npm ERR! This is most likely a problem with the zlib package,
npm ERR! not with npm itself.
npm ERR! Tell the author that this fails on your system:
npm ERR!     node-waf clean || true; node-waf configure build
npm ERR! You can get their info via:
npm ERR!     npm owner ls zlib
npm ERR! There is likely additional logging output above.
npm ERR! 
npm ERR! System Linux 2.6.32-33-generic-pae
npm ERR! command "node" "/usr/bin/npm" "install" "pdfkit"
npm ERR! 
npm ERR! Additional logging details can be found in:
npm ERR!     /home/woody/npm-debug.log
npm not ok

我正在运行Ubuntu10.04.3 LTS

如果有人有什么帮助或建议,那就太好了-谢谢。

EN

回答 1

Stack Overflow用户

回答已采纳

发布于 2011-10-08 07:40:59

您需要安装nodejs软件包:

代码语言:javascript
复制
sudo apt-get install nodejs-dev
票数 4
EN
页面原文内容由Stack Overflow提供。腾讯云小微IT领域专用引擎提供翻译支持
原文链接:

https://stackoverflow.com/questions/7688634

复制
相关文章

相似问题

领券
问题归档专栏文章快讯文章归档关键词归档开发者手册归档开发者手册 Section 归档