Updated gemfile for rails 4.1 support. Patched a few oddities.