Restrict base versions.

unsafePerformIO was removed from base in 4.7 and was already deprecated
in 4.6. By bumping the cabal version and restricting base version we are
able to change the import reliably.

An alternative solution would be to keep the base <5 constraint and use
CPP to make the import.

This is necessary to get this package and packages that depend on it (such as `derive`) to work with GHC 7.9 which uses base 4.7.