From 5c0da846af3f9a7d30e83a28e0ba68382d1125c9 Mon Sep 17 00:00:00 2001 From: Alex Biehl <alex.biehl@target.com> Date: Fri, 31 Aug 2018 14:26:58 +0200 Subject: [PATCH] Pass package dbs to abi hash calculation --- Cabal/Distribution/Simple/GHC.hs | 10 ++++++++-- 1 file changed, 8 insertions(+), 2 deletions(-) diff --git a/Cabal/Distribution/Simple/GHC.hs b/Cabal/Distribution/Simple/GHC.hs index 37a94ddc55..70521904ce 100644 --- a/Cabal/Distribution/Simple/GHC.hs +++ b/Cabal/Distribution/Simple/GHC.hs @@ -1573,11 +1573,17 @@ libAbiHash verbosity _pkg_descr lbi lib clbi = do ghcOptInputModules = toNubListR $ exposedModules lib } vanillaArgs = + -- due to a bug in GHC which tries to access the package database + -- in conjunction with data families, backpack and internal libraries + -- we may not modify the package database information. However, + -- we can't bootstrap GHC with this version of Cabal anymore + vanillaArgs0 + -- Package DBs unnecessary, and break ghc-cabal. See #3633 -- BUT, put at least the global database so that 7.4 doesn't -- break. - vanillaArgs0 { ghcOptPackageDBs = [GlobalPackageDB] - , ghcOptPackages = mempty } + -- vanillaArgs0 { ghcOptPackageDBs = [GlobalPackageDB] + -- , ghcOptPackages = mempty } sharedArgs = vanillaArgs `mappend` mempty { ghcOptDynLinkMode = toFlag GhcDynamicOnly, ghcOptFPic = toFlag True, -- GitLab