For instructions on the GHC API up with GHC 6.8 or older please refer to GHC/As a library (up to 6.8)