trying to install bcrypt into node project + node set up issues
OP managed to fix this for themselves with:
sudo xcode-select -switch /Applications/Xcode.app/Contents/Developer/
but graciously accepted my answer anyway.
Original answer below:
There are two distinct problems here. One is that your node
is slightly out of date and your npm
is substantially out of date.
You're using OSX, so there are a number of popular ways to manage different node versions. Here's a guide on updating node https://github.com/npm/npm/wiki/Troubleshooting#updating-node-on-osx
Then you'll want to update to the latest npm
:
npm install -g npm@latest
Finally, it looks like although you have XCode installed, something is still awry. You report that this command yields
$ xcode-select --print-path
/Library/Developer/CommandLineTools
On my system, which is OSX/Yosemite and can build native addon modules, I see
$ xcode-select --print-path
/Applications/Xcode.app/Contents/Developer
You may need to switch your xcode path to a different directory. For starters, though, please update to the current node
and npm
tools and try the installation again; if it still fails, the least dangerous next thing to try is
xcode-select --install
If none of that fixes things, let me know and I'll try to help further.
I was having a similar issue but with a different package.
node-gyp rebuild
No receipt for 'com.apple.pkg.CLTools_Executables' found at '/'.
No receipt for 'com.apple.pkg.DeveloperToolsCLILeo' found at '/'.
No receipt for 'com.apple.pkg.DeveloperToolsCLI' found at '/'.
gyp: No Xcode or CLT version detected!
gyp ERR! configure error
Running macOS Catalina 10.15.2
, I tried the following:
$ xcode-select --install
xcode-select: error: command line tools are already installed,
use "Software Update" to install updates
Fixed it by doing the following:
$ [sudo] xcode-select --reset
Hope this helps someone in the future.
EDIT
If someone is still running into issues, there's a thread on GitHub
that has other solutions worth trying:
- github.com/schnerd/d3-scale-cluster/issues