Currently a bogus $GHC_ENVIRONMENT can make cabal fail. Cabal itself could trigger this issue if it's called inside a cabal exec (though this is probably a terrible idea in the first place). Local and default environments instead do not cause any interference.
Should we always pass -package-env=- to ghc, or set $GHC_ENVIRONMENT to -?
I think yes:
- Cabal manages the set of packages it passes to ghc on its own, so why should it be affected by external environments?
- I don't see any use for passing an environment to cabal
- it can cause inscrutable errors
on the other hand:
- resetting a variable that may heve been explicitly set by the user does not sound good
Currently a bogus
$GHC_ENVIRONMENTcan make cabal fail. Cabal itself could trigger this issue if it's called inside acabal exec(though this is probably a terrible idea in the first place). Local and default environments instead do not cause any interference.Should we always pass
-package-env=-to ghc, or set$GHC_ENVIRONMENTto-?I think yes:
on the other hand: