未找到v8-debug@0.4.6和node@4.4.5的预构建二进制文件

时间:2016-06-17 05:22:51

标签: node.js npm npm-install node-gyp

我无法进行完整的npm安装。每当我尝试时,我都会收到这样的信息:

node-pre-gyp ERR! Tried to download: https://node-inspector.s3.amazonaws.com/debug/v0.4.6/node-v46-linux-x64.tar.gz 
node-pre-gyp ERR! Pre-built binaries not found for v8-debug@0.4.6 and node@4.4.5 (node-v46 ABI) (falling back to source compile with node-gyp) 

我正在使用

node v4.4.5  
npm v2.2.5

我在node v6.2.1

上收到了类似的错误

完成消息:

dushyant@dushyant-3543:/mnt/f/git/existing$ npm install
npm WARN package.json angle@0.0.1 No repository field.
npm WARN package.json angle@0.0.1 No license field.


> v8-debug@0.4.6 preinstall /mnt/f/git/existing/node_modules/grunt-node-inspector/node_modules/node-inspector/node_modules/v8-debug
>  


> v8-profiler@5.2.12 preinstall /mnt/f/git/existing/node_modules/grunt-node-inspector/node_modules/node-inspector/node_modules/v8-profiler
>  


> ws@0.4.32 install /mnt/f/git/existing/node_modules/grunt-node-inspector/node_modules/node-inspector/node_modules/ws
> (node-gyp rebuild 2> builderror.log) || (exit 0)

make: Entering directory '/mnt/f/git/existing/node_modules/grunt-node-inspector/node_modules/node-inspector/node_modules/ws/build' CXX(target) Release/obj.target/bufferutil/src/bufferutil.o bufferutil.target.mk:92: recipe for target 'Release/obj.target/bufferutil/src/bufferutil.o' failed make: Leaving directory '/mnt/f/git/existing/node_modules/grunt-node-inspector/node_modules/node-inspector/node_modules/ws/build'

> v8-debug@0.4.6 install /mnt/f/git/existing/node_modules/grunt-node-inspector/node_modules/node-inspector/node_modules/v8-debug
> node-pre-gyp install --fallback-to-build

node-pre-gyp ERR! Tried to download: https://node-inspector.s3.amazonaws.com/debug/v0.4.6/node-v46-linux-x64.tar.gz node-pre-gyp ERR! Pre-built binaries not found for v8-debug@0.4.6 and node@4.4.5 (node-v46 ABI) (falling back to source compile with node-gyp)  make: Entering directory '/mnt/f/git/existing/node_modules/grunt-node-inspector/node_modules/node-inspector/node_modules/v8-debug/build' CXX(target) Release/obj.target/debug/src/debug.o In file included from ../src/debug.cc:2:0: ../node_modules/nan/nan.h:261:25: error: redefinition of ‘template<class T> v8::Local<T>
_NanEnsureLocal(v8::Local<T>)’  NAN_INLINE v8::Local<T> _NanEnsureLocal(v8::Local<T> val) {
                         ^ ../node_modules/nan/nan.h:256:25: note: ‘template<class T> v8::Local<T> _NanEnsureLocal(v8::Handle<T>)’ previously declared here  NAN_INLINE v8::Local<T>
_NanEnsureLocal(v8::Handle<T> val) {
                         ^ ../node_modules/nan/nan.h:661:13: error: ‘node::smalloc’ has not been declared
     , node::smalloc::FreeCallback callback
             ^ ../node_modules/nan/nan.h:661:35: error: expected ‘,’ or ‘...’ before ‘callback’
     , node::smalloc::FreeCallback callback
                                   ^ ../node_modules/nan/nan.h: In function ‘v8::Local<v8::Object> NanNewBufferHandle(char*, size_t, int)’: ../node_modules/nan/nan.h:665:50: error: ‘callback’ was not declared in this scope
         v8::Isolate::GetCurrent(), data, length, callback, hint);
                                                  ^ ../node_modules/nan/nan.h:665:60: error: ‘hint’ was not declared in this scope
         v8::Isolate::GetCurrent(), data, length, callback, hint);
                                                            ^ ../node_modules/nan/nan.h: In function ‘v8::Local<v8::Object> NanNewBufferHandle(const char*, uint32_t)’: ../node_modules/nan/nan.h:672:67: error: no matching function for call to ‘New(v8::Isolate*, const char*&, uint32_t&)’
     return node::Buffer::New(v8::Isolate::GetCurrent(), data, size);
                                                                   ^ In file included from ../node_modules/nan/nan.h:25:0,
                 from ../src/debug.cc:2: /home/dushyant/.node-gyp/4.4.5/include/node/node_buffer.h:31:40: note: candidate: v8::MaybeLocal<v8::Object> node::Buffer::New(v8::Isolate*, v8::Local<v8::String>, node::encoding) <near match>  NODE_EXTERN v8::MaybeLocal<v8::Object> New(v8::Isolate* isolate,
                                        ^ /home/dushyant/.node-gyp/4.4.5/include/node/node_buffer.h:31:40: note: conversion of argument 3 would be ill-formed: In file included from ../src/debug.cc:2:0: ../node_modules/nan/nan.h:672:67: error: invalid conversion from ‘uint32_t {aka unsigned int}’ to ‘node::encoding’ [-fpermissive]
     return node::Buffer::New(v8::Isolate::GetCurrent(), data, size);
                                                                   ^ In file included from ../node_modules/nan/nan.h:25:0,
                 from ../src/debug.cc:2: /home/dushyant/.node-gyp/4.4.5/include/node/node_buffer.h:43:40: note: candidate: v8::MaybeLocal<v8::Object> node::Buffer::New(v8::Isolate*, char*, size_t) <near match>  NODE_EXTERN v8::MaybeLocal<v8::Object> New(v8::Isolate* isolate,
                                        ^ /home/dushyant/.node-gyp/4.4.5/include/node/node_buffer.h:43:40: note: conversion of argument 2 would be ill-formed: In file included from ../src/debug.cc:2:0: ../node_modules/nan/nan.h:672:67: error: invalid conversion from ‘const char*’ to ‘char*’ [-fpermissive]
     return node::Buffer::New(v8::Isolate::GetCurrent(), data, size);
                                                                   ^ ../node_modules/nan/nan.h: In function ‘v8::Local<v8::Object> NanNewBufferHandle(uint32_t)’: ../node_modules/nan/nan.h:676:29: error: could not convert ‘node::Buffer::New(v8::Isolate::GetCurrent(), ((size_t)size))’ from ‘v8::MaybeLocal<v8::Object>’ to ‘v8::Local<v8::Object>’
     return node::Buffer::New(v8::Isolate::GetCurrent(), size);
                             ^ ../node_modules/nan/nan.h: In function ‘v8::Local<v8::Object> NanBufferUse(char*, uint32_t)’: ../node_modules/nan/nan.h:683:12: error: ‘Use’ is not a member of ‘node::Buffer’
     return node::Buffer::Use(v8::Isolate::GetCurrent(), data, size);
            ^ ../src/debug.cc: In static member function ‘static void nodex::Debug::InternalConstructorName(const v8::FunctionCallbackInfo<v8::Value>&)’: ../src/debug.cc:194:23: warning: ISO C++ forbids converting a string constant to ‘char*’ [-Wwrite-strings]
           result_type = "";
                       ^ debug.target.mk:90: recipe for target 'Release/obj.target/debug/src/debug.o' failed make: *** [Release/obj.target/debug/src/debug.o] Error 1 make: Leaving directory '/mnt/f/git/existing/node_modules/grunt-node-inspector/node_modules/node-inspector/node_modules/v8-debug/build' gyp ERR! build error  gyp ERR! stack Error: `make` failed with exit code: 2 gyp ERR! stack     at ChildProcess.onExit (/usr/lib/node_modules/npm/node_modules/node-gyp/lib/build.js:276:23) gyp ERR! stack     at emitTwo (events.js:87:13) gyp ERR! stack     at ChildProcess.emit (events.js:172:7) gyp ERR! stack     at Process.ChildProcess._handle.onexit (internal/child_process.js:200:12) gyp ERR! System Linux 4.4.0-24-generic gyp ERR! command "/usr/bin/nodejs" "/usr/lib/node_modules/npm/node_modules/node-gyp/bin/node-gyp.js" "build" "--fallback-to-build" "--module=/mnt/f/git/existing/node_modules/grunt-node-inspector/node_modules/node-inspector/node_modules/v8-debug/build/debug/v0.4.6/node-v46-linux-x64/debug.node" "--module_name=debug" "--module_path=/mnt/f/git/existing/node_modules/grunt-node-inspector/node_modules/node-inspector/node_modules/v8-debug/build/debug/v0.4.6/node-v46-linux-x64" gyp ERR! cwd /mnt/f/git/existing/node_modules/grunt-node-inspector/node_modules/node-inspector/node_modules/v8-debug gyp ERR! node -v v4.4.5 gyp ERR! node-gyp -v v3.3.1 gyp ERR! not ok  node-pre-gyp ERR! build error  node-pre-gyp ERR! stack Error: Failed to execute '/usr/bin/nodejs /usr/lib/node_modules/npm/node_modules/node-gyp/bin/node-gyp.js build
--fallback-to-build --module=/mnt/f/git/existing/node_modules/grunt-node-inspector/node_modules/node-inspector/node_modules/v8-debug/build/debug/v0.4.6/node-v46-linux-x64/debug.node
--module_name=debug --module_path=/mnt/f/git/existing/node_modules/grunt-node-inspector/node_modules/node-inspector/node_modules/v8-debug/build/debug/v0.4.6/node-v46-linux-x64' (1) node-pre-gyp ERR! stack     at ChildProcess.<anonymous> (/mnt/f/git/existing/node_modules/grunt-node-inspector/node_modules/node-inspector/node_modules/v8-debug/node_modules/node-pre-gyp/lib/util/compile.js:83:29) node-pre-gyp ERR! stack     at emitTwo (events.js:87:13) node-pre-gyp ERR! stack     at ChildProcess.emit (events.js:172:7) node-pre-gyp ERR! stack     at maybeClose (internal/child_process.js:827:16) node-pre-gyp ERR! stack     at Process.ChildProcess._handle.onexit (internal/child_process.js:211:5) node-pre-gyp ERR! System Linux
4.4.0-24-generic node-pre-gyp ERR! command "/usr/bin/nodejs" "/mnt/f/git/existing/node_modules/grunt-node-inspector/node_modules/node-inspector/node_modules/v8-debug/node_modules/.bin/node-pre-gyp" "install" "--fallback-to-build" node-pre-gyp ERR! cwd /mnt/f/git/existing/node_modules/grunt-node-inspector/node_modules/node-inspector/node_modules/v8-debug node-pre-gyp ERR! node -v v4.4.5 node-pre-gyp ERR! node-pre-gyp -v v0.6.28 node-pre-gyp ERR! not ok  Failed to execute '/usr/bin/nodejs /usr/lib/node_modules/npm/node_modules/node-gyp/bin/node-gyp.js build
--fallback-to-build --module=/mnt/f/git/existing/node_modules/grunt-node-inspector/node_modules/node-inspector/node_modules/v8-debug/build/debug/v0.4.6/node-v46-linux-x64/debug.node
--module_name=debug --module_path=/mnt/f/git/existing/node_modules/grunt-node-inspector/node_modules/node-inspector/node_modules/v8-debug/build/debug/v0.4.6/node-v46-linux-x64' (1)

> v8-profiler@5.2.12 install /mnt/f/git/existing/node_modules/grunt-node-inspector/node_modules/node-inspector/node_modules/v8-profiler
> node-pre-gyp install --fallback-to-build

node-pre-gyp ERR! Tried to download: https://node-inspector.s3.amazonaws.com/profiler/v5.2.12/node-v46-linux-x64.tar.gz  node-pre-gyp ERR! Pre-built binaries not found for v8-profiler@5.2.12 and node@4.4.5 (node-v46 ABI) (falling back to source compile with node-gyp)  make: Entering directory '/mnt/f/git/existing/node_modules/grunt-node-inspector/node_modules/node-inspector/node_modules/v8-profiler/build'   CXX(target) Release/obj.target/profiler/src/profiler.o   CXX(target) Release/obj.target/profiler/src/cpu_profiler.o   CXX(target) Release/obj.target/profiler/src/cpu_profile.o   CXX(target) Release/obj.target/profiler/src/cpu_profile_node.o   CXX(target) Release/obj.target/profiler/src/heap_profiler.o   CXX(target) Release/obj.target/profiler/src/heap_snapshot.o   CXX(target) Release/obj.target/profiler/src/heap_output_stream.o   CXX(target) Release/obj.target/profiler/src/heap_graph_node.o   CXX(target) Release/obj.target/profiler/src/heap_graph_edge.o   SOLINK_MODULE(target) Release/obj.target/profiler.node   COPY Release/profiler.node   COPY /mnt/f/git/existing/node_modules/grunt-node-inspector/node_modules/node-inspector/node_modules/v8-profiler/build/profiler/v5.2.12/node-v46-linux-x64/profiler.node TOUCH Release/obj.target/action_after_build.stamp make: Leaving directory '/mnt/f/git/existing/node_modules/grunt-node-inspector/node_modules/node-inspector/node_modules/v8-profiler/build' npm ERR! Linux 4.4.0-24-generic npm ERR! argv "/usr/bin/nodejs" "/usr/bin/npm" "install" npm ERR! node v4.4.5 npm ERR! npm  v2.15.5 npm ERR! code ELIFECYCLE

npm ERR! v8-debug@0.4.6 install: `node-pre-gyp install
--fallback-to-build` npm ERR! Exit status 1 npm ERR!  npm ERR! Failed at the v8-debug@0.4.6 install script 'node-pre-gyp install
--fallback-to-build'. npm ERR! This is most likely a problem with the v8-debug package, npm ERR! not with npm itself. npm ERR! Tell the author that this fails on your system: npm ERR!     node-pre-gyp install --fallback-to-build npm ERR! You can get information on how to open an issue for this project with: npm ERR!     npm bugs v8-debug npm ERR! Or if that isn't available, you can get their info via: npm ERR!  npm ERR!     npm owner ls v8-debug npm ERR! There is likely additional logging output above.

npm ERR! Please include the following file with any support request: npm ERR!     /mnt/f/git/existing/npm-debug.log

1 个答案:

答案 0 :(得分:1)

您似乎正在安装node-inspector。 它与node -v的版本相关。

当我使用7.6.0时遇到同样的问题,但我降级到6.9.5。我成功安装了node-inspector。

同样的问题,node-inspector install failed issue

如提及如何降级,您可以执行以下操作,

  1. 结帐nodejs project
  2. sudo ./configure
  3. sudo make
  4. sudo make install
  5. 然后你var response = [[1234]]; var responseStr = response.toString(); console.log(responseStr);,你可以看到你想要的节点的当前版本。