Open frangio opened 4 years ago
Just checked, and installing the CLI as a dependency in a project works fine in node 12.7.0 with npm 6.10.0 in my Ubuntu 19.10. The issue must be in either an example project or a dev dependency.
Node: v12.14.1 npm: 6.13.4
npm i @openzeppelin/cli
includes following error, but apparently uses JS implementation so still installs Keccak bindings compilation fail. Pure JS implementation will be used.
keccak.target.mk:127: recipe for target 'Release/obj.target/keccak/src/addon.o' failed
make: *** [Release/obj.target/keccak/src/addon.o] Error 1
make: Leaving directory '/c/Users/andre/Documents/projects/forum/twelve/node_modules/solc-wrapper/node_modules/keccak/build'
gyp ERR! build error
gyp ERR! stack Error: `make` failed with exit code: 2
gyp ERR! stack at ChildProcess.onExit (/home/abcoathup/.nvm/versions/node/v12.14.1/lib/node_modules/npm/node_modules/node-gyp/lib/build.js:194:23)
gyp ERR! stack at ChildProcess.emit (events.js:223:5)
gyp ERR! stack at Process.ChildProcess._handle.onexit (internal/child_process.js:272:12)
gyp ERR! System Linux 4.4.0-18362-Microsoft
gyp ERR! command "/home/abcoathup/.nvm/versions/node/v12.14.1/bin/node" "/home/abcoathup/.nvm/versions/node/v12.14.1/lib/node_modules/npm/node_modules/node-gyp/bin/node-gyp.js" "rebuild"
gyp ERR! cwd /c/Users/andre/Documents/projects/forum/twelve/node_modules/solc-wrapper/node_modules/keccak
gyp ERR! node -v v12.14.1
gyp ERR! node-gyp -v v5.0.5
gyp ERR! not ok
npm ERR! code ELIFECYCLE
npm ERR! errno 1
npm ERR! keccak@1.4.0 rebuild: `node-gyp rebuild`
npm ERR! Exit status 1
npm ERR!
npm ERR! Failed at the keccak@1.4.0 rebuild script.
npm ERR! This is probably not a problem with npm. There is likely additional logging output above.
npm WARN Local package.json exists, but node_modules missing, did you mean to install?
npm ERR! A complete log of this run can be found in:
npm ERR! /home/abcoathup/.npm/_logs/2020-02-06T02_01_51_581Z-debug.log
Keccak bindings compilation fail. Pure JS implementation will be used.
Running
yarn install
at the root of the repo doesn't work if using Node 12, because of compilation errors in dependencies. I haven't checked if installing the CLI as a dependency also causes these errors. We thought this had been fixed in https://github.com/OpenZeppelin/openzeppelin-sdk/issues/926.