haskell/cabal — pull request #2119 by gelisam (2014-09-22 03:41:41+00:00)
Title: Generate object files for older versions of GHC

This works around [GHC bug #8942](https://ghc.haskell.org/trac/ghc/ticket/8942), for the versions of GHC which are affected by this bug.

Basically, ghci has been able to read .a files for a while, but under certain circumstances the .a file is read twice, causing ghci to exit with an error message. The workaround is to also generate .o files, like cabal 1.16 was doing.

Starting from GHC 7.8, ghci now requires .so files instead of .o or .a files. For those versions of GHC, the workaround is not needed, so we continue to skip .o files, like cabal 1.18 and above are doing.