Reputation: 149
I've to work for a project on Mac. But i've some problems for install nodejs. When i make node -v on the terminal it's ok but when i wan't to use the command npm that doesn't work, i've this error:
npm -v dyld: lazy symbol binding failed: Symbol not found: __ZSt16__ostream_insertIcSt11char_traitsIcEERSt13basic_ostreamIT_T0_ES6_PKS3_l Referenced from: /usr/local/bin/node Expected in: /usr/lib/libstdc++.6.dylib
dyld: Symbol not found: __ZSt16__ostream_insertIcSt11char_traitsIcEERSt13basic_ostreamIT_T0_ES6_PKS3_l Referenced from: /usr/local/bin/node Expected in: /usr/lib/libstdc++.6.dylib
Trace/BPT trap
So if anyone can help because i really don't know how to fix the problem...
Thank's
Upvotes: 2
Views: 1373
Reputation: 525
@Kreepz - I recently had some machine problems, had to use an old machine, and ran into the same issues. Fear not, there is a solution!
Before we get started, please make sure you have Xcode installed on the machine. The version needed is 3.1.4 - which can be downloaded for free by registering with Apple and searching for it in Apple's dev tools here
Secondly, to save us ALOT of headaches, we're going to use brew to install node. That said, OS X 10.5.x does not support homebrew, but it does support tigerbrew.
To install tigerbrew, enter the following from your command line:
ruby -e "$(curl -fsSkL raw.github.com/mistydemeo/tigerbrew/go/install)"
Next, run the following to make sure brew is up to speed:
brew doctor
After running brew doctor
you'll need to pay attention to the output closely. It's going to let you know about issues that must be resolved in your system. Address them and run brew doctor
again until things look good.
Then, we'll need to make sure we can compile everything without hiccups. Before installing node, run the following:
brew install gcc48
Woop woop! Now what's next? You guessed it - let's install node:
brew install node
Now, that last command is going to take a while. If it fails, run brew doctor
again and make sure all the warnings and errors are resolved. If you're still having issues, check the tigerbrew troubleshooting page here.
I hope that this helps you or anyone else looking at this! Good luck!
Upvotes: 2