bnoordhuis / node-buffertools

working with node.js buffers made easy
ISC License
205 stars 35 forks source link

Seems broken in npm 4.1 #69

Closed rom1504 closed 8 years ago

rom1504 commented 9 years ago
> buffertools@2.1.3 install /tmp/a/node_modules/buffertools
> node-gyp rebuild

Usage: gyp_main.py [options ...] [build_file ...]

gyp_main.py: error: no such option: --no-parallel
gyp ERR! configure error 
gyp ERR! stack Error: `gyp` failed with exit code: 2
gyp ERR! stack     at ChildProcess.onCpExit (/opt/node-v4.1.1-linux-x64/lib/node_modules/npm/node_modules/node-gyp/lib/configure.js:355:16)
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 3.19.0-30-generic
gyp ERR! command "/opt/node-v4.1.1-linux-x64/bin/node" "/opt/node-v4.1.1-linux-x64/lib/node_modules/npm/node_modules/node-gyp/bin/node-gyp.js" "rebuild"
gyp ERR! cwd /tmp/a/node_modules/buffertools
gyp ERR! node -v v4.1.1
gyp ERR! node-gyp -v v3.0.3
gyp ERR! not ok 
npm ERR! Linux 3.19.0-30-generic
npm ERR! argv "/opt/node-v4.1.1-linux-x64/bin/node" "/opt/node-v4.1.1-linux-x64/bin/npm" "install" "buffertools"
npm ERR! node v4.1.1
npm ERR! npm  v2.14.4
npm ERR! code ELIFECYCLE

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

npm ERR! Please include the following file with any support request:                                                         
npm ERR!     /tmp/a/npm-debug.log
bnoordhuis commented 9 years ago

Not really a buffertools issue, more of a gyp and node-gyp issue.

Do you have a gyp package installed through your distro's package manager? That can conflict with node-gyp's copy.

rom1504 commented 8 years ago

On a system with no initial node/npm/gyp installation (and with no ~/.npm and no ~/.node-gyp) I'm still getting:

npm install buffertools
-
> buffertools@2.1.3 install /tmp/a/node_modules/buffertools
> node-gyp rebuild

make: entrant dans le répertoire « /tmp/a/node_modules/buffertools/build »
  CXX(target) Release/obj.target/buffertools/buffertools.o
In file included from $HOME/.node-gyp/4.2.0/include/node/node.h:42:0,
                 from ../buffertools.cc:17:
$HOME/.node-gyp/4.2.0/include/node/v8.h:336:1: erreur: expected unqualified-id before ‘using’
$HOME/.node-gyp/4.2.0/include/node/v8.h:469:1: erreur: expected unqualified-id before ‘using’
$HOME/.node-gyp/4.2.0/include/node/v8.h:852:1: erreur: expected unqualified-id before ‘using’
../buffertools.cc:32:11: erreur: ‘v8::Handle’ has not been declared
../buffertools.cc:492:21: erreur: variable or field ‘RegisterModule’ declared void
../buffertools.cc:492:21: erreur: ‘Handle’ was not declared in this scope
../buffertools.cc:492:34: erreur: expected primary-expression before ‘>’ token
../buffertools.cc:492:36: erreur: ‘target’ was not declared in this scope
../buffertools.cc:506:1: erreur: ‘RegisterModule’ was not declared in this scope
make: *** [Release/obj.target/buffertools/buffertools.o] Erreur 1
make: quittant le répertoire « /tmp/a/node_modules/buffertools/build »
gyp ERR! build error 
gyp ERR! stack Error: `make` failed with exit code: 2
gyp ERR! stack     at ChildProcess.onExit ($HOME/local/opt/node-v4.2.0-linux-x64/lib/node_modules/npm/node_modules/node-gyp/lib/build.js:270: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 3.2.0-91-generic
gyp ERR! command "$HOME/local/opt/node-v4.2.0-linux-x64/bin/node" "$HOME/local/opt/node-v4.2.0-linux-x64/lib/node_modules/npm/node_modules/node-gyp/bin/node-gyp.js" "rebuild"
gyp ERR! cwd /tmp/a/node_modules/buffertools
gyp ERR! node -v v4.2.0
gyp ERR! node-gyp -v v3.0.3
gyp ERR! not ok 
npm ERR! Linux 3.2.0-91-generic
npm ERR! argv "$HOME/local/opt/node-v4.2.0-linux-x64/bin/node" "$HOME/local/opt/node-v4.2.0-linux-x64/bin/npm" "install" "buffertools"
npm ERR! node v4.2.0
npm ERR! npm  v2.14.7
npm ERR! code ELIFECYCLE

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

npm ERR! Please include the following file with any support request:                                                                                                                                                                                                  
npm ERR!     /tmp/a/npm-debug.log

Now I guess it might be a node-gyp issue yeah.

https://github.com/nodejs/node-gyp/issues/736

bnoordhuis commented 8 years ago

Make sure you use a C++11-capable compiler: g++ >= 4.8.2 or clang++ >= 3.4.

rom1504 commented 8 years ago

Ah yeah that does it. Thanks !