1
0
Fork 0
mirror of https://gitlab.alpinelinux.org/alpine/aports.git synced 2025-07-23 03:05:48 +03:00
aports/community/ghc/0005-buildpath-abi-stability.patch
2023-02-04 18:34:50 +00:00

26 lines
1.3 KiB
Diff

Forwarded to https://gitlab.haskell.org/ghc/ghc/-/issues/10424
To-Do: Evaluate if this patch is actually still needed.
See: https://gitlab.haskell.org/ghc/ghc/-/issues/10424#note_453670
diff -upr ghc-9.4.3.orig/compiler/GHC/Iface/Recomp.hs ghc-9.4.3/compiler/GHC/Iface/Recomp.hs
--- ghc-9.4.3.orig/compiler/GHC/Iface/Recomp.hs 2022-11-09 17:50:53.003678568 +0100
+++ ghc-9.4.3/compiler/GHC/Iface/Recomp.hs 2022-11-09 17:53:50.484112012 +0100
@@ -1231,7 +1231,7 @@ addFingerprints hsc_env iface0
(mod_hash,
mi_src_hash iface0,
ann_fn (mkVarOcc "module"), -- See mkIfaceAnnCache
- mi_usages iface0,
+ usages,
sorted_deps,
mi_hpc iface0)
@@ -1266,6 +1266,8 @@ addFingerprints hsc_env iface0
(non_orph_rules, orph_rules) = mkOrphMap ifRuleOrph (mi_rules iface0)
(non_orph_fis, orph_fis) = mkOrphMap ifFamInstOrph (mi_fam_insts iface0)
ann_fn = mkIfaceAnnCache (mi_anns iface0)
+ -- Do not allow filenames to affect the interface
+ usages = [ case u of UsageFile _ fp _ -> UsageFile "" fp Nothing; _ -> u | u <- mi_usages iface0 ]
-- | Retrieve the orphan hashes 'mi_orphan_hash' for a list of modules
-- (in particular, the orphan modules which are transitively imported by the