Ruby 1.9 compatibility

This should make deployment on modern systems easier, because they don't ship ruby 1.8 anymore.