summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorSimon Marlow <marlowsd@gmail.com>2010-02-17 13:32:50 +0000
committerSimon Marlow <marlowsd@gmail.com>2010-02-17 13:32:50 +0000
commitf3e080507db6130c983fc86485661e0f14fba565 (patch)
treeea357dc92734bf58c990bad9d26f09c0089468ca
parent2936ede28758713e2b32fad5749c622fdaaefd8e (diff)
downloadhaskell-f3e080507db6130c983fc86485661e0f14fba565.tar.gz
Fix a recompilation checking bug when a package dependency changes
We weren't forcing enough recompilationg when package dependencies changed, with the result that bumping a package version could lead to linking failures or other problems later. The problem/solutation are described on the wiki: http://hackage.haskell.org/trac/ghc/wiki/Commentary/Compiler/RecompilationAvoidance#Packageversionchanges
-rw-r--r--compiler/iface/MkIface.lhs7
1 files changed, 6 insertions, 1 deletions
diff --git a/compiler/iface/MkIface.lhs b/compiler/iface/MkIface.lhs
index 702a744d34..9263baec69 100644
--- a/compiler/iface/MkIface.lhs
+++ b/compiler/iface/MkIface.lhs
@@ -512,7 +512,12 @@ addFingerprints hsc_env mb_old_fingerprint iface0 new_decls
-- the export list hash doesn't depend on the fingerprints of
-- the Names it mentions, only the Names themselves, hence putNameLiterally.
export_hash <- computeFingerprint dflags putNameLiterally
- (mi_exports iface0, orphan_hash, dep_orphan_hashes)
+ (mi_exports iface0,
+ orphan_hash,
+ dep_orphan_hashes,
+ dep_pkgs (mi_deps iface0))
+ -- dep_pkgs: see "Package Version Changes" on
+ -- wiki/Commentary/Compiler/RecompilationAvoidance
-- put the declarations in a canonical order, sorted by OccName
let sorted_decls = eltsFM $ listToFM $