Support GHC 7.4.x, some bugfixes