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

Version 7.7.0 fails to install bcrypt with yarn #349

Closed
JrSchild opened this issue Mar 2, 2017 · 4 comments
Closed

Version 7.7.0 fails to install bcrypt with yarn #349

JrSchild opened this issue Mar 2, 2017 · 4 comments

Comments

@JrSchild
Copy link

JrSchild commented Mar 2, 2017

The CONTRIBUTING link in the README is broken. Anyway, The following Dockerfile fails to compile bcrypt when building.

FROM node:7.7.0
RUN yarn add bcrypt

Whereas it works when using version 7.6.0. The entire error message from gyp is too long, but here's the end:

make: Entering directory '/node_modules/bcrypt/build'
  CXX(target) Release/obj.target/bcrypt_lib/src/blowfish.o
  CXX(target) Release/obj.target/bcrypt_lib/src/bcrypt.o
  CXX(target) Release/obj.target/bcrypt_lib/src/bcrypt_node.o
In file included from ../../nan/nan.h:47:0,
                 from ../src/bcrypt_node.cc:1:
/root/.node-gyp/7.7.0/include/node/node.h:44:33: fatal error: tracing/trace_event.h: No such file or directory
 #include "tracing/trace_event.h"
                                 ^
compilation terminated.
bcrypt_lib.target.mk:96: recipe for target 'Release/obj.target/bcrypt_lib/src/bcrypt_node.o' failed
make: Leaving directory '/node_modules/bcrypt/build'
make: *** [Release/obj.target/bcrypt_lib/src/bcrypt_node.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:276:23)
gyp ERR! stack     at emitTwo (events.js:106:13)
gyp ERR! stack     at ChildProcess.emit (events.js:194:7)
gyp ERR! stack     at Process.ChildProcess._handle.onexit (internal/child_process.js:215:12)
gyp ERR! System Linux 4.9.6-moby
gyp ERR! command "/usr/local/bin/node" "/usr/local/lib/node_modules/npm/node_modules/node-gyp/bin/node-gyp.js" "build" "--fallback-to-build" "--module=/node_modules/bcrypt/lib/binding/bcrypt_lib.node" "--module_name=bcrypt_lib" "--module_path=/node_modules/bcrypt/lib/binding"
gyp ERR! cwd /node_modules/bcrypt
gyp ERR! node -v v7.7.0
gyp ERR! node-gyp -v v3.5.0
gyp ERR! not ok
node-pre-gyp ERR! build error
node-pre-gyp ERR! stack Error: Failed to execute '/usr/local/bin/node /usr/local/lib/node_modules/npm/node_modules/node-gyp/bin/node-gyp.js build --fallback-to-build --module=/node_modules/bcrypt/lib/binding/bcrypt_lib.node --module_name=bcrypt_lib --module_path=/node_modules/bcrypt/lib/binding' (1)
node-pre-gyp ERR! stack     at ChildProcess.<anonymous> (/node_modules/node-pre-gyp/lib/util/compile.js:83:29)
node-pre-gyp ERR! stack     at emitTwo (events.js:106:13)
node-pre-gyp ERR! stack     at ChildProcess.emit (events.js:194:7)
node-pre-gyp ERR! stack     at maybeClose (internal/child_process.js:899:16)
node-pre-gyp ERR! stack     at Process.ChildProcess._handle.onexit (internal/child_process.js:226:5)
node-pre-gyp ERR! System Linux 4.9.6-moby
node-pre-gyp ERR! command "/usr/local/bin/node" "/node_modules/bcrypt/node_modules/.bin/node-pre-gyp" "install" "--fallback-to-build"
node-pre-gyp ERR! cwd /node_modules/bcrypt
node-pre-gyp ERR! node -v v7.7.0
node-pre-gyp ERR! node-pre-gyp -v v0.6.32
node-pre-gyp ERR! not ok
Failed to execute '/usr/local/bin/node /usr/local/lib/node_modules/npm/node_modules/node-gyp/bin/node-gyp.js build --fallback-to-build --module=/node_modules/bcrypt/lib/binding/bcrypt_lib.node --module_name=bcrypt_lib --module_path=/node_modules/bcrypt/lib/binding' (1)
info Visit https://yarnpkg.com/en/docs/cli/add for documentation about this command.
The command '/bin/sh -c yarn add bcrypt' returned a non-zero code: 1
@Starefossen
Copy link
Member

Starefossen commented Mar 2, 2017

Thanks for the heads up about the CONTRIBUTING link not working. There is a thread going on about ~~~this~~~ a similar issue in #346 btw.

@chorrell
Copy link
Contributor

chorrell commented Mar 2, 2017

I believe you are hitting an issue specifically with Node.js 7.7.0 which is resolved in v7.7.1.

In the release notes for v7.7.1: https://nodejs.org/en/blog/release/v7.7.1/

There's a note about "add missing src/tracing header files" which looks like the source of this:

fatal error: tracing/trace_event.h: No such file or directory
 #include "tracing/trace_event.h"

v7.7.1 should be landing in the Docker Hub pretty soon:

docker-library/official-images#2712

@chorrell
Copy link
Contributor

chorrell commented Mar 2, 2017

v7.7.1 should be available now

@JrSchild
Copy link
Author

JrSchild commented Mar 2, 2017

Thank you. That was fast! Confirmed that it's working.

@JrSchild JrSchild closed this as completed Mar 2, 2017
brew added a commit to okfn/opendatasurvey that referenced this issue Mar 3, 2017
brew added a commit to okfn/opendatasurvey that referenced this issue Mar 3, 2017
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

3 participants