Hi I am trying to install composer-cli using npm
but it is throwing error.
the log of the error is as below:
18988 error code ELIFECYCLE
18989 error errno 1
18990 error grpc#1.10.1 install: `node-pre-gyp install --fallback-to-build --library=static_library`
18990 error Exit status 1
18991 error Failed at the grpc#1.10.1 install script.
18991 error This is probably not a problem with npm. There is likely additional logging output above.
18992 verbose exit [ 1, true ]
I tried every possible way to fix this issue. but couldn't find any solution.
Please let me know how to fix the issue.
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:262:23)
gyp ERR! stack at ChildProcess.emit (events.js:182:13)
gyp ERR! stack at Process.ChildProcess._handle.onexit (internal/child_process.js:240:12)
gyp ERR! System Linux 4.15.0-34-generic
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" "--library=static_library" "--module=/home/dspl_user/.npm-global/lib/node_modules/composer-cli/node_modules/grpc/src/node/extension_binary/node-v64-linux-x64-glibc/grpc_node.node" "--module_name=grpc_node" "--module_path=/home/dspl_user/.npm-global/lib/node_modules/composer-cli/node_modules/grpc/src/node/extension_binary/node-v64-linux-x64-glibc"
gyp ERR! cwd /home/dspl_user/.npm-global/lib/node_modules/composer-cli/node_modules/grpc
gyp ERR! node -v v10.10.0
gyp ERR! node-gyp -v v3.8.0
gyp ERR! not ok
npm WARN optional SKIPPING OPTIONAL DEPENDENCY: fsevents#1.2.4 (node_modules/composer-cli/node_modules/fsevents):
npm WARN notsup SKIPPING OPTIONAL DEPENDENCY: Unsupported platform for fsevents#1.2.4: wanted {"os":"darwin","arch":"any"} (current: {"os":"linux","arch":"x64"})
npm ERR! code ELIFECYCLE
npm ERR! errno 1
npm ERR! grpc#1.10.1 install: `node-pre-gyp install --fallback-to-build --library=static_library`
npm ERR! Exit status 1
npm ERR!
npm ERR! Failed at the grpc#1.10.1 install script.
npm ERR! This is probably not a problem with npm. There is likely additional logging output above.
npm ERR! A complete log of this run can be found in:
npm ERR! /home/dspl_user/.npm/_logs/2018-09-27T13_11_13_477Z-debug.log
i resolved the same problem on my Ubuntu 18.04 machine by =>
Installing pre-requisites at https://hyperledger.github.io/composer/latest/installing/installing-prereqs.html
which says->
curl -O https://hyperledger.github.io/composer/latest/prereqs-ubuntu.sh
then
chmod u+x prereqs-ubuntu.sh
and at last =>
./prereqs-ubuntu.sh
then restart your terminal and try the installation =>
npm install -g composer-cli#0.20
without su or sudo. I hope this helps :):)
I think I had the same error as you. It's working for me now after switching to Node 8.9.0. It looks like you're using Node v10, which is not supported for hyperledger fabric.
Related
This question already has answers here:
npm failed to install time with make not found error
(5 answers)
Closed 3 years ago.
I'm setting up a npm package for a project in which there ngx-loader is going to be used. Here is the error while installing npm package.
prebuild-install WARN install No prebuilt binaries found (target=11.14.0 runtime=node arch=x64 platform=linux)
gyp ERR! build error
gyp ERR! stack Error: not found: make
gyp ERR! stack at getNotFoundError (/usr/lib/node_modules/npm/node_modules/which/which.js:13:12)
gyp ERR! stack at F (/usr/lib/node_modules/npm/node_modules/which/which.js:68:19)
gyp ERR! stack at E (/usr/lib/node_modules/npm/node_modules/which/which.js:80:29)
gyp ERR! stack at /usr/lib/node_modules/npm/node_modules/which/which.js:89:16
gyp ERR! stack at /usr/lib/node_modules/npm/node_modules/isexe/index.js:42:5
gyp ERR! stack at /usr/lib/node_modules/npm/node_modules/isexe/mode.js:8:5
gyp ERR! stack at FSReqCallback.oncomplete (fs.js:158:21)
gyp ERR! System Linux 4.18.0-18-generic
gyp ERR! command "/usr/bin/node" "/usr/lib/node_modules/npm/node_modules/node-gyp/bin/node-gyp.js" "rebuild"
gyp ERR! cwd /media/shubham/A/Angular/ngx-loading-bar-master/node_modules/iltorb
gyp ERR! node -v v11.14.0
gyp ERR! node-gyp -v v3.8.0
gyp ERR! not ok
npm WARN optional SKIPPING OPTIONAL DEPENDENCY: fsevents#1.2.4 (node_modules/fsevents):
npm WARN notsup SKIPPING OPTIONAL DEPENDENCY: Unsupported platform for fsevents#1.2.4: wanted {"os":"darwin","arch":"any"} (current: {"os":"linux","arch":"x64"})
npm ERR! code ELIFECYCLE
npm ERR! errno 1
npm ERR! iltorb#1.3.10 install: `detect-libc prebuild-install || node-gyp rebuild`
npm ERR! Exit status 1
npm ERR!
npm ERR! Failed at the iltorb#1.3.10 install script.
npm ERR! This is probably not a problem with npm. There is likely additional logging output above.
I expect npm package to be installed.
Looks like this is the problem: this is from their npm page
You will also need to install
On Unix
python (v2.7 recommended, v3.x.x is not supported)
make A proper C/C++ compiler toolchain, like GCC
I get an issue when installing node-sass :
gyp verb download contents checksum {"node-v10.2.1-headers.tar.gz":"3700814861e61288d7dd1c4115f40acac0cbd0abbdd4bfd650d4ae85cc02ecce"}
gyp verb validating download checksum for node-v10.2.1-headers.tar.gz (3700814861e61288d7dd1c4115f40acac0cbd0abbdd4bfd650d4ae85cc02ecce == 3700814861e61288d7dd1c4115f40acac0cbd0abbdd4bfd650d4ae85cc02ecce)
gyp verb get node dir target node version installed: 10.2.1
gyp verb build dir attempting to create "build" dir: /var/www/****/node_modules/node-sass/build
gyp ERR! configure error
gyp ERR! stack Error: EACCES: permission denied, mkdir '/var/www/****/node_modules/node-sass/build'
gyp ERR! System Linux 4.4.0-116-generic
gyp ERR! command "/usr/local/bin/node" "/var/www/****/node_modules/node-gyp/bin/node-gyp.js" "rebuild" "--verbose" "--libsass_ext=" "--libsass_cflags=" "--libsass_ldflags=" "--libsass_library="
gyp ERR! cwd /var/www/****/node_modules/node-sass
gyp ERR! node -v v10.2.1
gyp ERR! node-gyp -v v3.6.2
gyp ERR! not ok
Build failed with error code: 1
npm WARN gestiaweb#1.0.0 No repository field.
npm WARN optional SKIPPING OPTIONAL DEPENDENCY: fsevents#1.2.4 (node_modules/fsevents):
npm WARN notsup SKIPPING OPTIONAL DEPENDENCY: Unsupported platform for fsevents#1.2.4: wanted {"os":"darwin","arch":"any"} (current: {"os":"linux","arch":"x64"})
npm ERR! code ELIFECYCLE
npm ERR! errno 1
npm ERR! node-sass#4.9.0 postinstall: `node scripts/build.js`
npm ERR! Exit status 1
npm ERR!
npm ERR! Failed at the node-sass#4.9.0 postinstall script.
npm ERR! This is probably not a problem with npm. There is likely additional logging output above.
npm ERR! A complete log of this run can be found in:
npm ERR! /home/****/.npm/_logs/2018-06-01T14_24_13_534Z-debug.log
Environment : Ubuntu (lastest)
NodeJS version : v10.2.1
Npm version : 5.6.0
gyp ERR! stack Error: EACCES: permission denied,
Its says permission denied. Try run with sudo
sudo npm i node-sass
It looks like there is a permissions issue. Can you install other packages?
If not make sure the user you are running the npm i node-gyp command has permissions to write to the appropriate directory.
chmod +w <path>/node_modules
In this case there seemed to be a permission issue with the user's node install
Solution:
sudo su && npm i node-sass
I'm new to node and a bit out of my depth here. Experiencing this error on both Mac OS X and Centos 6. Happens in all the npm install xxx commands I've tried. Any suggestions on how to get around this error much appreciated.
Similar to npm install gives node-gyp error but I do not have spaces in my username which is what solved his issue.
npm install canvas
> canvas#1.6.6 install /home/test1/ng2-webpack-demo/node_modules/canvas
> node-gyp rebuild
Package cairo was not found in the pkg-config search path.
Perhaps you should add the directory containing `cairo.pc'
to the PKG_CONFIG_PATH environment variable
No package 'cairo' found
gyp: Call to './util/has_lib.sh freetype' returned exit status 0 while in
binding.gyp. while trying to load binding.gyp
gyp ERR! configure error
gyp ERR! stack Error: `gyp` failed with exit code: 1
gyp ERR! stack at ChildProcess.onCpExit
(/usr/lib/node_modules/npm/node_modules/node-gyp/lib/configure.js:336:16)
gyp ERR! stack at emitTwo (events.js:106:13)
gyp ERR! stack at ChildProcess.emit (events.js:191:7)
gyp ERR! stack at Process.ChildProcess._handle.onexit
(internal/child_process.js:215:12)
gyp ERR! System Linux 2.6.32-642.4.2.el6.x86_64
gyp ERR! command "/usr/bin/node" "/usr/lib/node_modules/npm/node_modules/node-
gyp/bin/node-gyp.js" "rebuild"
gyp ERR! cwd /home/test1/ng2-webpack-demo/node_modules/canvas
gyp ERR! node -v v6.11.1
gyp ERR! node-gyp -v v3.6.2
gyp ERR! not ok
npm WARN #angular/animations#4.3.6 requires a peer of #angular/core#4.3.6 but
none was installed.
npm WARN #angular/material#2.0.0-beta.8 requires a peer of #angular/cdk#2.0.0-
beta.8 but none was installed.
npm WARN #angular/material#2.0.0-beta.8 requires a peer of
#angular/core#^4.0.0 but none was installed.
npm WARN #angular/material#2.0.0-beta.8 requires a peer of
#angular/common#^4.0.0 but none was installed.
npm WARN #ngtools/webpack#1.2.10 requires a peer of #angular/tsc-
wrapped#^0.5.0 but none was installed.
npm WARN optional SKIPPING OPTIONAL DEPENDENCY: fsevents#1.1.2
(node_modules/fsevents):
npm WARN notsup SKIPPING OPTIONAL DEPENDENCY: Unsupported platform for
fsevents#1.1.2: wanted {"os":"darwin","arch":"any"} (current:
{"os":"linux","arch":"x64"})
npm ERR! code ELIFECYCLE
npm ERR! errno 1
npm ERR! canvas#1.6.6 install: `node-gyp rebuild`
npm ERR! Exit status 1
npm ERR!
npm ERR! Failed at the canvas#1.6.6 install script.
npm ERR! This is probably not a problem with npm. There is likely additional
logging output above.
npm ERR! A complete log of this run can be found in:
npm ERR! /home/test1/.npm/_logs/2017-08-29T15_54_58_848Z-debug.log
This is a known canvas issue, probably caused by missing native libs.
Try this see if it helps:
sudo npm uninstall -g node-gyp
sudo npm install -g node-gyp
brew install pkg-config cairo libpng jpeg giflib
npm i canvas
Source: https://github.com/Automattic/node-canvas/issues/913#issuecomment-368042394
I've same error the reason was that I don't have clang compiler installed.
My solution to this was to install build-essential package
sudo apt-get install build-essential
I'm using Ubuntu 20.1 release
I am trying to create a Google Cloud Function that generates an image from text.
I've used this Canvas node module
(had to install these dependencies on Mac to run it locally)
brew install pkg-config cairo pango libpng jpeg giflib
My package.json looks like this:
"dependencies": {
"canvas": "^1.6.5"
}
While trying to deploy it as a Function to Google cloud I am getting this error (seems like there are missing dependencies on the remote container)
Copying file:///var/folders/rq/jqlbr35d6gg3_bjhwgzdjm3m0000gn/T/tmpsuL8lN/fun.zip [Content-Type=application/zip]...
- [1 files][ 722.0 B/ 722.0 B]
Operation completed over 1 objects/722.0 B.
Waiting for operation to finish...failed.
Deploying function (may take a while - up to 2 minutes)...failed.
ERROR: (gcloud.beta.functions.deploy) OperationError: code=3, message=Build failed: exit status 1
> canvas#1.6.5 install /workspace/node_modules/canvas
> node-gyp rebuild
./util/has_lib.sh: 31: ./util/has_lib.sh: pkg-config: not found
gyp: Call to './util/has_lib.sh freetype' returned exit status 0 while in binding.gyp. while trying to load binding.gyp
gyp ERR! configure error
gyp ERR! stack Error: `gyp` failed with exit code: 1
gyp ERR! stack at ChildProcess.onCpExit (/nodejs/lib/node_modules/npm/node_modules/node-gyp/lib/configure.js:305:16)
gyp ERR! stack at emitTwo (events.js:106:13)
gyp ERR! stack at ChildProcess.emit (events.js:191:7)
gyp ERR! stack at Process.ChildProcess._handle.onexit (internal/child_process.js:215:12)
gyp ERR! System Linux 4.4.0-78-generic
gyp ERR! command "/nodejs/bin/node" "/nodejs/lib/node_modules/npm/node_modules/node-gyp/bin/node-gyp.js" "rebuild"
gyp ERR! cwd /workspace/node_modules/canvas
gyp ERR! node -v v6.9.1
gyp ERR! node-gyp -v v3.4.0
gyp ERR! not ok
npm WARN img#1.0.0 No description
npm WARN img#1.0.0 No repository field.
npm ERR! Linux 4.4.0-78-generic
npm ERR! argv "/nodejs/bin/node" "/nodejs/bin/npm" "--global-style" "--production" "--fetch-retries=5" "--fetch-retry-factor=2" "--fetch-retry-mintimeout=1000" "install" "/workspace"
npm ERR! node v6.9.1
npm ERR! npm v3.10.8
npm ERR! code ELIFECYCLE
npm ERR! canvas#1.6.5 install: `node-gyp rebuild`
npm ERR! Exit status 1
npm ERR!
npm ERR! Failed at the canvas#1.6.5 install script 'node-gyp rebuild'.
npm ERR! Make sure you have the latest version of node.js and npm installed.
npm ERR! If you do, this is most likely a problem with the canvas 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 information on how to open an issue for this project with:
npm ERR! npm bugs canvas
npm ERR! Or if that isn't available, you can get their info via:
npm ERR! npm owner ls canvas
npm ERR! There is likely additional logging output above.
npm ERR! Please include the following file with any support request:
npm ERR! /workspace/npm-debug.log
On Ubuntu 16.04, I was able to clear up a similar problem by following the instructions here to install dependencies: https://www.npmjs.com/package/canvas
I've searched around for a couple of days trying to resolve this issue, and although people have had issues installing bcrypt with NPM, they don't appear to be like mine. For those of you finding this via Google, I suggest you also take a look at this post.
Now I get the following error, as do others, when installing bcrypt:
> bcrypt#0.8.7 install /home/william/bonsai/brain/src/hyperdev/node_modules/bcrypt
> node-gyp rebuild
/bin/sh: 1: node: not found
gyp: Call to 'node -e "require('nan')"' returned exit status 127 while in binding.gyp. while trying to load binding.gyp
gyp ERR! configure error
gyp ERR! stack Error: `gyp` failed with exit code: 1
gyp ERR! stack at ChildProcess.onCpExit (/usr/share/node-gyp/lib/configure.js:354: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 4.4.0-28-generic
gyp ERR! command "/usr/bin/nodejs" "/usr/bin/node-gyp" "rebuild"
gyp ERR! cwd /home/william/bonsai/brain/src/hyperdev/node_modules/bcrypt
gyp ERR! node -v v4.2.6
gyp ERR! node-gyp -v v3.0.3
gyp ERR! not ok
hyperdev# /home/william/bonsai/brain/src/hyperdev
└── touch#1.0.0 extraneous
npm ERR! Linux 4.4.0-28-generic
npm ERR! argv "/usr/bin/nodejs" "/usr/bin/npm" "install" "bcrypt"
npm ERR! node v4.2.6
npm ERR! npm v3.5.2
npm ERR! code ELIFECYCLE
npm ERR! bcrypt#0.8.7 install: `node-gyp rebuild`
npm ERR! Exit status 1
npm ERR!
npm ERR! Failed at the bcrypt#0.8.7 install script 'node-gyp rebuild'.
npm ERR! Make sure you have the latest version of node.js and npm installed.
npm ERR! If you do, this is most likely a problem with the bcrypt 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 information on how to open an issue for this project with:
npm ERR! npm bugs bcrypt
npm ERR! Or if that isn't available, you can get their info via:
npm ERR! npm owner ls bcrypt
npm ERR! There is likely additional logging output above.
npm ERR! Please include the following file with any support request:
npm ERR! /home/william/bonsai/brain/src/hyperdev/npm-debug.log
I have all of bcrypt's dependencies installed, so I am genuinely unsure of how to proceed. Here is the npm debug log needed.
I think this is a known bug in Meteor.
I use debian8.6-64bit.
I remove accounts-password and npm-bcrypt, and then I do
meteor add npm-bcrypt
meteor npm install -g node-gyp
meteor npm install --save bcrypt
meteor npm install --save babel-runtime
meteor add accounts-password
Finally, I fix the bug. I'm not sure of its effectiveness, if you change order of command.