Tag: node gyp

npm安装mongoose:错误与节点gyp错误

我在安装Mongodb(本地驱动程序)或Mongoose(需要并扩展它)时遇到了困难,并且在这里一直存在错误: 我已经尝试使用nvm将我的版本节点回滚到0.10.x,但没有这样做。 brianboyko@Boyko-Linux ~/boykofork $ npm install –save mongoose npm WARN package.json boykofork@1.0.0 No description npm WARN package.json boykofork@1.0.0 No README data / > kerberos@0.0.14 install /home/brianboyko/boykofork/node_modules/mongoose/node_modules/mongodb/node_modules/mongodb-core/node_modules/kerberos > (node-gyp rebuild) || (exit 0) make: Entering directory `/home/brianboyko/boykofork/node_modules/mongoose/node_modules/mongodb/node_modules/mongodb-core/node_modules/kerberos/build' CXX(target) Release/obj.target/kerberos/lib/kerberos.o CXX(target) Release/obj.target/kerberos/lib/worker.o CC(target) Release/obj.target/kerberos/lib/kerberosgss.o ../lib/kerberosgss.c:27:0: warning: ignoring #pragma clang diagnostic [-Wunknown-pragmas] #pragma clang diagnostic push ^ […]

用npm安装mmmagic时出错,node-gyp重build失败

我试图安装npm安装mmmagic,并继续得到这个错误。 我已经尝试了多个版本的mmmagic以及使用节点v0.10.40和节点v0.12.7,并重新安装node-gyp。 我清除了npmcaching,并多次销毁了node_module文件夹。 有任何想法吗? make: *** [Release/magic.node] Error 1 gyp ERR! build error gyp ERR! stack Error: `make` failed with exit code: 2 gyp ERR! stack at ChildProcess.onExit (/Users/XXXX/.nvm/v0.10.40/lib/node_modules/npm/node_modules/node-gyp/lib/build.js:267:23) gyp ERR! stack at ChildProcess.emit (events.js:98:17) gyp ERR! stack at Process.ChildProcess._handle.onexit (child_process.js:820:12) gyp ERR! System Darwin 15.0.0 gyp ERR! command "node" "/Users/XXXX/.nvm/v0.10.40/lib/node_modules/npm/node_modules/node-gyp/bin/node-gyp.js" "rebuild" gyp ERR! cwd […]

Yeoman / NPM错误:node-gyp失败

我尝试了Yeoman,但是当我运行“yo meanjs”命令时,它一直在卡住,它问我几个问题,然后说它正在运行npm install。 给它几分钟,它吐出下面的错误。 这一切工作正常我自己的电脑,但在我的工作笔记本电脑(我是一个pipe理员)我得到所有这些错误。 这里是模块和VS(MSBuild)安装。 安装程序 Visual Studio 2013专业版 Python 2.7.10 Ruby 2.2.3p173 节点版本4.2.1 模块 npm版本3.3.8 哟版本1.4.8 node-gyp 3.0.3 我在网上看了一下,但是大部分的信息都可以在类似的错误上find。 npm install –msvs_version = 2013 或者设置没有区别的pythonpath。 npm http 304 https://registry.npmjs.org/cookiejar npm http 304 https://registry.npmjs.org/reduce-component npm http 304 https://registry.npmjs.org/formidable npm http 304 https://registry.npmjs.org/extend npm http 304 https://registry.npmjs.org/methods npm http 304 https://registry.npmjs.org/readable-stream npm http request GET […]

Windows 10上的npm安装失败(node-gyp rebuild)

我正在尝试为使用nodejs和node-gyp的克隆项目执行npm安装。 经历了很多版本不匹配问题(特别是使用Visual Studio),并得到了重buildnode-gyp重build失败的一个点。 安装了Python 2.7,卸载了VS2013,并在Visual C ++ 2015中安装了VS2015社区版。使用SET GYP_MSVS_VERSION=2015将环境variablesGYP_MSVS_VERSION更改为SET GYP_MSVS_VERSION=2015 , npm config set msvs_version 2015 –global ,运行npm install -g –msvs_version=2015和得到以下错误。 在这一点上我没有做任何进一步的调整,并且已经尝试了5个小时以上! 我正在使用Cmder(以pipe理员身份运行),npm v3.6.0,节点v5.7.0和node-gyp v3.3.1(在v3.3.1运行node-gyp -v v3.3.1 node-gyp -v结果)。 我在Windows 10 x64上。 任何人有任何想法是什么导致这些错误? ..\src\WebWorkerThreads.cc(231): error C2660: 'v8::Isolate::New': function does not take 0 arguments [C:\Users \ramtin\AppData\Roaming\npm\node_modules\troop-node-enforcer\node_modules\webworker-threads\build\WebWorkerThr eads.vcxproj] ..\src\WebWorkerThreads.cc(540): warning C4996: 'node::FatalException': was declared deprecated [C:\Users\ramt in\AppData\Roaming\npm\node_modules\troop-node-enforcer\node_modules\webworker-threads\build\WebWorkerThreads. […]

问题与节点opus安装

我在安装Windows 10上的node-opus时遇到以下问题: Visual Studio 2015与Windows 10和Windows 8.1的SDK和工具+ C + +; npm v。3.8.5; python 2.7; 当我试图在我的项目中安装我的node-opus时,它说我build立了错误: > ref@1.3.2 install F:\node-js-app\bots\ContentBot\node_modules\ref > node-gyp rebuild F:\node-js-app\bots\ContentBot\node_modules\ref>if not defined npm_config_node_gyp (node "C:\Program Files\nodejs\node_m odules\npm\bin\node-gyp-bin\\..\..\node_modules\node-gyp\bin\node-gyp.js" rebuild ) else (node "" rebuild ) Building the projects in this solution one at a time. To enable parallel build, please add the "/m" […]

安装npm bluetooth-hci-socket时出错

我试图添加bluetooth-hci-socket到node.js作为pipe理员在Windows中 npm install bluetooth-hci-socket给我: 我的问题:在bluetooth-hci-socket@0.5.0安装失败是什么:'node-gyp rebuild'是什么意思? 如何修复它? 谢谢! 额外信息: 作为补贴,没有错误,我跑了: npm install –global –production windows-build-tools npm install -g node-gyp 并使用Zadig( https://www.youtube.com/watch?v=mL9B8wuEdms )更改了驱动程序设置

如何在AWS Lambda中使用rpath构build节点本机模块?

我试图在aws lambda函数中使用node-phash ,但是很快就会出现。 我已经在这里和在github上find了关于node-canvas库的指令,但仍然有一些麻烦。 我已经采取的步骤: 在Amazon Linux ec2实例上,我克隆了node-phash回购 我设置了一个env var来使用一个rpath ,如node-canvas演练所示: export LDFLAGS=-Wl,-rpath=/var/task/ 我确定了共同的代表: $ readelf -d pHashBinding.node | grep NEEDED 0x0000000000000001 (NEEDED) Shared library: [libstdc++.so.6] 0x0000000000000001 (NEEDED) Shared library: [libm.so.6] 0x0000000000000001 (NEEDED) Shared library: [libgcc_s.so.1] 0x0000000000000001 (NEEDED) Shared library: [libpthread.so.0] 0x0000000000000001 (NEEDED) Shared library: [libc.so.6] 然后,我复制并下载列出的文件,以包含在我的lambda zip文件中 我跑npm install ,表面上看起来很好 我确认了.node将会看到aws lambda根的代表: $ objdump […]

运行npm install时发生node-gyp错误

我是新来的节点,在这里有一点我的深度。 在Mac OS X和Centos 6上遇到这个错误。在我尝试的所有npm install xxx命令中发生。 任何build议如何解决这个错误非常赞赏。 类似npm安装给出node-gyp错误,但我没有空间在我的用户名,这是什么解决了他的问题。 npm install canvas > canvas@1.6.6 install /home/test1/ng2-webpack-demo/node_modules/canvas > node-gyp rebuild 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_lib.sh freetype' returned exit status 0 […]

如何将tesseract库包含在node-gyp构build过程中

我试图创build简单的节点插件与tesseract库作为依赖,但我是一个C ++初学者。 整个代码在: https : //github.com/q-nick/node-tesseract binding.cc: #include <node.h> #include <v8.h> // #include <tesseract/baseapi.h> // #include <leptonica/allheaders.h> void Method(const v8::FunctionCallbackInfo<v8::Value>& args) { v8::Isolate* isolate = args.GetIsolate(); args.GetReturnValue().Set(v8::String::NewFromUtf8(isolate, "world")); } void init(v8::Local<v8::Object> exports) { NODE_SET_METHOD(exports, "hello", Method); } NODE_MODULE(NODE_GYP_MODULE_NAME, init) binding.gyp: { "targets": [ { "target_name": "binding", "sources": [ "src/binding.cc" ], 'defines': [ 'V8_DEPRECATION_WARNINGS=1' ], 'include_dirs': […]

使用node-gyp将nodejs模块交叉编译到Windows

由于我的Windows 7 x64机器上的一些编译器问题,我必须在我的Linux ARM盒子上编译我所有的代码。 我如何交叉编译节点模块与节点gyp? 提前致谢。