me.stub!(:code!)

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:

  1. Install rvm (http://rvm.beginrescueend.com/install/).
  2. 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/).
  3. Switch to ree ruby: `rvm ree`.
  4. Install passenger: `gem install passenger` (NO sudo — remember this is rvm) and install the apache module as usual (http://www.modrails.com/install.html)
  5. 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.
  6. 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…
  7. 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
  8. Finally, run `gem bundle` and watch the magic happen!

It’s late… this might not be too coherent.

Comments (View)
blog comments powered by Disqus
Page 1 of 1