Fix dependencies for rails4 branch