Closed federicobucchi closed 8 months ago
+1
+1
+1
+1
Okay, if you guys could read, you would notice that there are clear instructions on what to do in such circumstances:
npm ERR! Failed at the pty.js@0.2.4 install script.
npm ERR! This is most likely a problem with the pty.js 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 pty.js
npm ERR! There is likely additional logging output above.
Also, first link in google: http://stackoverflow.com/questions/24949902/errors-installing-pty-js-node
@petethepig should put it on documentation / README?
Well I am a bit confused here because I seem to be able to compile pty.js when I cd there and run make. Is there something I need to do with npm to force it to update.
/usr/local/lib/lib/node_modules/pty.js/$ make
node-gyp configure
gyp info it worked if it ends with ok
gyp info using node-gyp@1.0.2
gyp info using node@0.10.33 | darwin | x64
gyp info spawn python
gyp info spawn args [ '/usr/local/lib/node_modules/node-gyp/gyp/gyp_main.py',
gyp info spawn args 'binding.gyp',
gyp info spawn args '-f',
gyp info spawn args 'make',
gyp info spawn args '-I',
gyp info spawn args '/usr/local/lib/node_modules/pty.js/build/config.gypi',
gyp info spawn args '-I',
gyp info spawn args '/usr/local/lib/node_modules/node-gyp/addon.gypi',
gyp info spawn args '-I',
gyp info spawn args '/Users/vito-c/.node-gyp/0.10.33/common.gypi',
gyp info spawn args '-Dlibrary=shared_library',
gyp info spawn args '-Dvisibility=default',
gyp info spawn args '-Dnode_root_dir=/Users/vito-c/.node-gyp/0.10.33',
gyp info spawn args '-Dmodule_root_dir=/usr/local/lib/node_modules/pty.js',
gyp info spawn args '--depth=.',
gyp info spawn args '--no-parallel',
gyp info spawn args '--generator-output',
gyp info spawn args 'build',
gyp info spawn args '-Goutput_dir=.' ]
gyp info ok
node-gyp build
gyp info it worked if it ends with ok
gyp info using node-gyp@1.0.2
gyp info using node@0.10.33 | darwin | x64
gyp info spawn make
gyp info spawn args [ 'BUILDTYPE=Release', '-C', 'build' ]
make[2]: Nothing to be done for `all'.
gyp info ok
however installing devtools-terminal still fails
/usr/local/lib/lib/node_modules/pty.js/$ npm install -g devtools-terminal
Now I don't know much about npm/node but the interesting piece to me is right here
install /usr/local/lib/node_modules/devtools-terminal/node_modules/pty.js
It looks like it's trying to install pty.js into devtools-terminal/node_modules instead of using the one already compiled on my system? I'm going to open up a ticket on pty.js
I'm using homebrew to install node if that means anything
> pty.js@0.2.4 install /usr/local/lib/node_modules/devtools-terminal/node_modules/pty.js
> node-gyp rebuild
CXX(target) Release/obj.target/pty/src/unix/pty.o
../src/unix/pty.cc:487:10: error: use of undeclared identifier 'openpty'
return openpty(amaster, aslave, name, (termios *)termp, (winsize *)winp);
^
../src/unix/pty.cc:533:10: error: use of undeclared identifier 'forkpty'
return forkpty(amaster, name, (termios *)termp, (winsize *)winp);
^
2 errors generated.
make: *** [Release/obj.target/pty/src/unix/pty.o] Error 1
gyp ERR! build error
gyp ERR! stack Error: `make` failed with exit code: 2
gyp ERR! stack at ChildProcess.onExit (/usr/local/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:810:12)
gyp ERR! System Darwin 13.3.0
gyp ERR! command "node" "/usr/local/lib/node_modules/npm/node_modules/node-gyp/bin/node-gyp.js" "rebuild"
gyp ERR! cwd /usr/local/lib/node_modules/devtools-terminal/node_modules/pty.js
gyp ERR! node -v v0.10.33
gyp ERR! node-gyp -v v1.0.2
gyp ERR! not ok
> ws@0.4.32 install /usr/local/lib/node_modules/devtools-terminal/node_modules/socket.io/node_modules/socket.io-client/node_modules/ws
> (node-gyp rebuild 2> builderror.log) || (exit 0)
CXX(target) Release/obj.target/bufferutil/src/bufferutil.o
SOLINK_MODULE(target) Release/bufferutil.node
SOLINK_MODULE(target) Release/bufferutil.node: Finished
CXX(target) Release/obj.target/validation/src/validation.o
SOLINK_MODULE(target) Release/validation.node
SOLINK_MODULE(target) Release/validation.node: Finished
npm ERR! Darwin 13.3.0
npm ERR! argv "node" "/usr/local/bin/npm" "install" "-g" "devtools-terminal"
npm ERR! node v0.10.33
npm ERR! npm v2.1.7
npm ERR! code ELIFECYCLE
npm ERR! pty.js@0.2.4 install: `node-gyp rebuild`
npm ERR! Exit status 1
npm ERR!
npm ERR! Failed at the pty.js@0.2.4 install script.
npm ERR! This is most likely a problem with the pty.js 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 pty.js
npm ERR! There is likely additional logging output above.
npm ERR! Please include the following file with any support request:
npm ERR! /usr/local/lib/node_modules/pty.js/npm-debug.log
I can confirm that the answer http://stackoverflow.com/a/24981514 works.
After the command:
I get: