Refine the GHCI macro into HAVE[_{INTERNAL, EXTERNAL}]_INTERPRETER
As discussed in #16331 (closed), the GHCI macro, defined through 'ghci' flags
in ghc.cabal.in
, ghc-bin.cabal.in
and ghci.cabal.in
, is supposed to indicate
whether GHC is built with support for an internal interpreter, that runs in
the same process. It is however overloaded in a few places to mean
"there is an interpreter available", regardless of whether it's an internal
or external interpreter.
For the sake of clarity and with the hope of more easily being able to build stage 1 GHCs with external interpreter support, this patch splits the previous GHCI macro into 3 different ones:
-
HAVE_INTERNAL_INTERPRETER
: GHC is built with an internal interpreter -
HAVE_EXTERNAL_INTERPRETER
: GHC is built with support for external interpreters -
HAVE_INTERPRETER
:HAVE_INTERNAL_INTERPRETER || HAVE_EXTERNAL_INTERPRETER