Ruby on Rails on Snow Leopard
I finally tackled the (hopefully) last bit of my Snow Leopard upgrade today: getting Ruby (and Rails) ready to go. I’m working on an information visualization project and am using Ruby to write the app. Mike Gunderloy at A Fresh Cup has a great step by step guide (I started at step 19 since I was happy to upgrade in place):
As always happens when upgrading or installing, it seems, I did run into a few problems.
Errors and Workarounds
Problem: Git doesn’t want to install.
ld: warning: in /opt/local/lib/libiconv.dylib, file is not of required architecture
MacPorts is to blame. To uninstall MacPorts, use
sudo rm -rf
(Thanks, Simon Engledew)
Problem: MySQL gem doesn’t install.
ERROR: Failed to build gem native extension mysql
Make sure you installed the latest version of MySQL, the MySQL Preference Pane, and that you started the MySQL server before trying to install the gem. iCoreTech has directions for installing MySQL and MySQL gem on Snow Leopard.
HiveLogic has another method for installing Git on Snow Leopoard. I was having trouble with the package installers, and doing it “by hand” via HiveLogic’s instructions worked well.
My project uses RMagick. RMagick’s DMG installer wouldn’t work for me either. I was able to install RMagick from source using a script from OnRails.org.