Nov 19 2009
∞
rvm / ree / nokogiri / gem bundler
(OSX 10.5… rvm installs REE with x86_64 architecture)
Recent steps I took to switch to rvm on my dev machine:
- Install rvm (http://rvm.beginrescueend.com/install/).
- Set up architecture flags (maybe optional — it seems like it installed x86_64 without this step) (http://rvm.beginrescueend.com/mysql/) (http://sick.snusnu.info/2009/11/04/installing-nokogiri-with-rvm-on-snow-leopard/).
- Switch to ree ruby: `rvm ree`.
- Install passenger: `gem install passenger` (NO sudo — remember this is rvm) and install the apache module as usual (http://www.modrails.com/install.html)
- In order for the mysql gem to install (remember since we’re x86_64), grab the x86_64 version of mysql 5.1 from http://dev.mysql.com/downloads/mysql/5.1.html#macosx-dmg.
- REBUILD everything macports for x86_64 :’( — this sucks. Mainly need `sudo port install libxml2 +universal` and `sudo port install libxslt +universal` and `sudo port install libiconv +universal` … that last one required me to uninstall and install a bunch of crap like gettext and readline… uggg…
- Set up the build options for nokogiri:
nokogiri: xml2-include: /opt/local/include/libxml2 xml2-lib: /opt/local/lib xslt-dir: /opt/local iconv-dir: /opt/local
- Finally, run `gem bundle` and watch the magic happen!
It’s late… this might not be too coherent.