Build fixes for GHC HEAD