Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Rebuild failed! #84

Closed
sbrl opened this issue Aug 19, 2016 · 5 comments
Closed

Rebuild failed! #84

sbrl opened this issue Aug 19, 2016 · 5 comments

Comments

@sbrl
Copy link
Contributor

sbrl commented Aug 19, 2016

I just got this error the other day. It first said

Some installed packages could not be loaded because they contain native modules that were compiled for an earlier version of Atom.

...but if I hit Rebuild Packages, it fails with this error:

In file included from ../src/unix/pty.cc:20:0:
../node_modules/nan/nan.h:592:20: error: variable or field ‘AddGCEpilogueCallback’ declared void
       v8::Isolate::GCEpilogueCallback callback
                    ^
../node_modules/nan/nan.h:592:7: error: ‘GCEpilogueCallback’ is not a member of ‘v8::Isolate’
       v8::Isolate::GCEpilogueCallback callback
       ^
../node_modules/nan/nan.h:593:18: error: expected primary-expression before ‘gc_type_filter’
     , v8::GCType gc_type_filter = v8::kGCTypeAll) {
                  ^
../node_modules/nan/nan.h:598:20: error: variable or field ‘RemoveGCEpilogueCallback’ declared void
       v8::Isolate::GCEpilogueCallback callback) {
                    ^
../node_modules/nan/nan.h:598:7: error: ‘GCEpilogueCallback’ is not a member of ‘v8::Isolate’
       v8::Isolate::GCEpilogueCallback callback) {
       ^
../node_modules/nan/nan.h:603:20: error: variable or field ‘AddGCPrologueCallback’ declared void
       v8::Isolate::GCPrologueCallback callback
                    ^
../node_modules/nan/nan.h:603:7: error: ‘GCPrologueCallback’ is not a member of ‘v8::Isolate’
       v8::Isolate::GCPrologueCallback callback
       ^
../node_modules/nan/nan.h:604:18: error: expected primary-expression before ‘gc_type_filter’
     , v8::GCType gc_type_filter = v8::kGCTypeAll) {
                  ^
../node_modules/nan/nan.h:609:20: error: variable or field ‘RemoveGCPrologueCallback’ declared void
       v8::Isolate::GCPrologueCallback callback) {
                    ^
../node_modules/nan/nan.h:609:7: error: ‘GCPrologueCallback’ is not a member of ‘v8::Isolate’
       v8::Isolate::GCPrologueCallback callback) {
       ^
../src/unix/pty.cc: In function ‘Nan::NAN_METHOD_RETURN_TYPE PtyFork(Nan::NAN_METHOD_ARGS_TYPE)’:
../src/unix/pty.cc:222:34: warning: ignoring return value of ‘int chdir(const char*)’, declared with attribute warn_unused_result [-Wunused-result]
       if (strlen(cwd)) chdir(cwd);
                                  ^
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 (/opt/atom/resources/app/apm/node_modules/npm/node_modules/node-gyp/lib/build.js:269: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 Linux 4.2.0-16-generic
gyp ERR! command "node" "/opt/atom/resources/app/apm/node_modules/npm/node_modules/node-gyp/bin/node-gyp.js" "rebuild"
gyp ERR! cwd /home/sbrl/.atom/packages/termrk/node_modules/pty.js
gyp ERR! node -v v0.10.40
gyp ERR! node-gyp -v v2.0.2
gyp ERR! not ok 

npm ERR! Linux 4.2.0-16-generic
npm ERR! argv "/opt/atom/resources/app/apm/bin/node" "/opt/atom/resources/app/apm/node_modules/npm/bin/npm-cli.js" "--globalconfig" "/home/sbrl/.atom/.apm/.apmrc" "--userconfig" "/home/sbrl/.atom/.apmrc" "rebuild" "--target=0.37.8" "--arch=x64"
npm ERR! node v0.10.40
npm ERR! npm  v2.13.3
npm ERR! code ELIFECYCLE
npm ERR! [email protected] install: `node-gyp rebuild`
npm ERR! Exit status 1
npm ERR! 
npm ERR! Failed at the [email protected] install script 'node-gyp rebuild'.
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!     /home/sbrl/.atom/packages/termrk/npm-debug.log
@romgrk
Copy link
Owner

romgrk commented Aug 19, 2016

As mentionned in the log, this is an issue with the pty.js module. I'd recommend opening an issue there. Though before make sure you have everything installed properly (Frameworks, compiler, etc)

(Sorry for the brevity of this answer, I get many of this type of issues these days)

@romgrk romgrk closed this as completed Aug 19, 2016
@romgrk
Copy link
Owner

romgrk commented Aug 19, 2016

Note: I see in the logs that the pty.js version is 0.3.0. If you are willing to solve it by yourself you could try with [email protected].
Basically the apm command-line tool works exactly like npm does. See apm dev -h. Run apm dev Termrk. Modify package.json to use pty.js (maybe the 0.2.7-1 version).

@sbrl
Copy link
Contributor Author

sbrl commented Aug 20, 2016

Frameworks? Compilers? Ummm.....

I think I'll try and find an alternative extension.

@ghost
Copy link

ghost commented Aug 30, 2016

Hi @romgrk I've just encountered the same issue and it seems to have been solved in pty.js version 0.3.1 [1]. I got this package to rebuild by simply bumping the version in the package.json and running apm install. As there is now an official release that includes it, it might be beneficial to update the dependency here as well.

[1] chjj/pty.js#164

@romgrk
Copy link
Owner

romgrk commented Sep 1, 2016

Thanks @Gert-dev for the useful feedback :)
I have never been able to reproduce this issue, but as it pops up frequently these days, I've updated [email protected] aa6c9c0, and deployed a patch as version 0.2.6.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants