use same build strategy for rails 4 as for rails 3