Repository navigation
Closed
Description
ernestscomputer:musicomp ernest son$ npm install
> bufferutil@1.2.1 install /Users/ernest son/Desktop/PROJECTS/musicomp/node_modules/bufferutil
> node-gyp rebuild
CXX(target) Release/obj.target/bufferutil/src/bufferutil.o
clang: error: no such file or directory: 'son/.node-gyp/5.0.0/include/node'
clang: error: no such file or directory: 'son/.node-gyp/5.0.0/src'
clang: error: no such file or directory: 'son/.node-gyp/5.0.0/deps/uv/include'
clang: error: no such file or directory: 'son/.node-gyp/5.0.0/deps/v8/include'
make: *** [Release/obj.target/bufferutil/src/bufferutil.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:270:23)
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 Darwin 14.5.0
gyp ERR! command "/usr/local/Cellar/node/5.0.0/bin/node" "/usr/local/lib/node_modules/npm/node_modules/node-gyp/bin/node-gyp.js" "rebuild"
gyp ERR! cwd /Users/ernest son/Desktop/PROJECTS/musicomp/node_modules/bufferutil
gyp ERR! node -v v5.0.0
gyp ERR! node-gyp -v v3.0.3
gyp ERR! not ok
npm WARN install:bufferutil@1.2.1 bufferutil@1.2.1 install: `node-gyp rebuild`
npm WARN install:bufferutil@1.2.1 Exit status 1
> utf-8-validate@1.2.1 install /Users/ernest son/Desktop/PROJECTS/musicomp/node_modules/utf-8-validate
> node-gyp rebuild
CXX(target) Release/obj.target/validation/src/validation.o
clang: error: no such file or directory: 'son/.node-gyp/5.0.0/include/node'
clang: error: no such file or directory: 'son/.node-gyp/5.0.0/src'
clang: error: no such file or directory: 'son/.node-gyp/5.0.0/deps/uv/include'
clang: error: no such file or directory: 'son/.node-gyp/5.0.0/deps/v8/include'
make: *** [Release/obj.target/validation/src/validation.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:270:23)
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 Darwin 14.5.0
gyp ERR! command "/usr/local/Cellar/node/5.0.0/bin/node" "/usr/local/lib/node_modules/npm/node_modules/node-gyp/bin/node-gyp.js" "rebuild"
gyp ERR! cwd /Users/ernest son/Desktop/PROJECTS/musicomp/node_modules/utf-8-validate
gyp ERR! node -v v5.0.0
gyp ERR! node-gyp -v v3.0.3
gyp ERR! not ok
npm WARN install:utf-8-validate@1.2.1 utf-8-validate@1.2.1 install: `node-gyp rebuild`
npm WARN install:utf-8-validate@1.2.1 Exit status 1
Reacted by Legends, Ran Luo, emorling, Nick Schwaderer, Jitendra Pal, Volodymyr Vovk, Mukul, Vasiliy Yorkin, Josiel Faleiros Alves, Haitham Maya and 33 more
Metadata
Metadata
Assignees
Labels
No labels
Activity
brascosDad commentedon Nov 9, 2015
back story: in trying to uninstall iojs and reinstall node, I entered a world of shizzao but finally got node and npm installed successfully....I tried installing node-gyp globally to no avail...
bnoordhuis commentedon Nov 9, 2015
Delete your
$HOME/.node-gypdirectory and try again.Aside, many tools don't handle spaces in path names well (
/Users/ernest son/...).brascosDad commentedon Nov 9, 2015
sorry, when you say "$home" do you essentially mean usr/local/bin? that's what "which node-gyp" yields in term...or do you mean another location?
I did change my user name by eliminating space for "_". thanks for the heads up
bnoordhuis commentedon Nov 9, 2015
I mean the HOME environment variable. :-) node-gyp normally downloads the development tarballs to
$HOME/.node-gyp, i.e.,/home/username/.node-gypor/Users/username/.node-gyp.brascosDad commentedon Nov 9, 2015
thanks, i figured out what you meant....just tried npm install and it appears i still have rebuild issues. it looks as though my user rename didn't propogate..(?)
bnoordhuis commentedon Nov 9, 2015
Maybe you need to log out and log in again? It's also possible that
$HOME/.npmrchas some outdated variables.brascosDad commentedon Nov 9, 2015
so redelete $HOME/.node-gyp and also .npmrc? logout and try again? I already restarted after user name change...
bnoordhuis commentedon Nov 9, 2015
Maybe just edit your .npmrc in case it contains valuable things like tokens.
brascosDad commentedon Nov 9, 2015
i see a .rvmrc folder in $HOME, but no .npmrc.....and how exactly would I edit it (if I could find it)?
bnoordhuis commentedon Nov 9, 2015
If you don't have a .npmrc, don't worry about it. If you do, just vim will do; it's a text file.
brascosDad commentedon Nov 9, 2015
I don't have one...any other ideas? I think I've tried everything on our
list
On Mon, Nov 9, 2015 at 1:39 PM Ben Noordhuis notifications@github.com
wrote:
mmahalwy commentedon Nov 9, 2015
getting same problem here when trying to install
ember-clineoadventist commentedon Nov 10, 2015
same problem here with contextify.
brascosDad commentedon Nov 11, 2015
for me, the solution was fixing the space in my home folder (that was a whole other "can o' worms"). then 'npm install' worked like a charm. also, I suggest reaching out to the folks at npm if it truly is npm related. They're great!
midhunadarvin commentedon Nov 29, 2015
I also had the node-gyp rebuild error while installing utf-8-validate package through npm. Removing the space from my filepath worked for me.
225 remaining items
belvederef commentedon May 24, 2019
Nothing of what suggested above worked for me, however, I solved my issue switching to a different node version (e.g. using nvm).
kukoman commentedon May 24, 2019
mrpandat commentedon May 26, 2019
Switching from node
v12.3.1tov8.16.0withnvmsolved this for me.Thanks @belvederef 🎉
nbeers22 commentedon Jun 9, 2019
used nvm and downgraded to node v11.10.0, which solved my problem
woprandi commentedon Jun 12, 2019
I always have a problem to rebuild a old ember app despite a yarn.lock because of this package, unacceptable...
strarsis commentedon Jun 12, 2019
@woprandi: The system itself differs from the one where the bindings compilation worked,
so it fails, this shouldn't happen, but this package has this kind of issue.
You could try to install the app dependencies inside a VM/container that runs on an older *nix distribution (from which you know that it worked in the past) and hopefully it compiles.
pthornhi commentedon Jun 14, 2019
Only @punitnathani's solution worked for me. Downgrade from node@12.x.x
to
npm install -g node@11.10.0
Daisuke-sama commentedon Jun 16, 2019
For me as well @pthornhi . I had spent, probably, a few days for experiments...
shaikh-shahid commentedon Jun 18, 2019
Follow these steps to resolve the issue.
1: Make sure you have build-tools installed.
2: Update node-gyp
3: Delete package-lock.json and node modules folder and run npm install again.
4: Deleting ~/.node-gyp folder and run npm install again.
Source: https://codeforgeek.com/make-failed-with-exit-code-2/
mikkz commentedon Jun 20, 2019
For those who are using AMI 2, I resolve it using
sudo yum groupinstall "Development Tools"
Since my errors were
yankikucuk commentedon Jun 20, 2019
@pthornhi its worked for me.
MagicScorpion commentedon Jun 20, 2019
I am getting below error while installing btlejuice.
gyp ERR! build error
gyp ERR! stack Error:
makefailed with exit code: 2gyp ERR! stack at ChildProcess.onExit (/usr/share/node-gyp/lib/build.js:262:23)
gyp ERR! stack at ChildProcess.emit (events.js:189:13)
gyp ERR! stack at Process.ChildProcess._handle.onexit (internal/child_process.js:248:12)
gyp ERR! System Linux 4.19.0-kali4-amd64
gyp ERR! command "/usr/bin/node" "/usr/bin/node-gyp" "rebuild"
gyp ERR! cwd /usr/local/lib/node_modules/btlejuice/node_modules/bluetooth-hci-socket
gyp ERR! node -v v10.15.2
gyp ERR! node-gyp -v v3.8.0
gyp ERR! not ok
orwell1984 commentedon Jun 25, 2019
Gotta love hundreds of people checking in on a closed issue to no avail. Good maintainer ethics!
bzoz commentedon Jun 25, 2019
This page is for that specific issue from 3yrs ago, which was solved. It is not catch-all place for all node-gyp failures. If you have issues with building a node module: