build in rails 3.0, 3.1, 3.2, and 4.0