Update gemspec to rails 4.0
Replace deprecated AR dynamic finders.