[Gem] Add Rails 4 support and reorganize Gemfile