[Git][ghc/ghc][ghc-9.12] 2 commits: hackage-doc-tarball: Allow ghc-boot-th to be uploaded to hackage

Ben Gamari (@bgamari) gitlab at gitlab.haskell.org
Mon Feb 3 23:45:30 UTC 2025



Ben Gamari pushed to branch ghc-9.12 at Glasgow Haskell Compiler / GHC


Commits:
49f934d3 by Zubin Duggal at 2025-01-29T08:59:12-05:00
hackage-doc-tarball: Allow ghc-boot-th to be uploaded to hackage

It can't refer to files outside its source directory, so patch that part out.
This is OK because those files are only used while bootstrapping.

Also add ghci to the list of packages to be uploaded

Fixes #25687

(cherry picked from commit fd297671f81fc262b700471cfc6cd05d34254b6e)

- - - - -
c3657b33 by Ben Gamari at 2025-01-30T14:07:53-05:00
upload-ghc-libs: Drop more references to ghc-internal from ghc-boot-th

Fixes #25687

- - - - -


1 changed file:

- .gitlab/rel_eng/upload_ghc_libs.py


Changes:

=====================================
.gitlab/rel_eng/upload_ghc_libs.py
=====================================
@@ -93,6 +93,25 @@ def prep_ghc():
     build_copy_file(PACKAGES['ghc'], 'GHC/Platform/Constants.hs')
     build_copy_file(PACKAGES['ghc'], 'GHC/Settings/Config.hs')
 
+def prep_ghc_boot_th():
+    # Drop references to `ghc-internal` from `hs-source-dirs` as Hackage rejects
+    # out-of-sdist references and this packages is only uploaded for documentation
+    # purposes.
+    modify_file(PACKAGES['ghc-boot-th'], 'ghc-boot-th.cabal',
+                lambda s: s.replace('../ghc-internal/src', '')
+                           .replace('GHC.Internal.TH.Lib.Map', '')
+                           .replace('GHC.Internal.TH.PprLib', '')
+                           .replace('GHC.Internal.TH.Ppr', '')
+                           .replace('GHC.Internal.TH.Lib,', '')
+                           .replace('GHC.Internal.TH.Lib', '')
+                           .replace('GHC.Internal.TH.Lift,', '')
+                           .replace('GHC.Internal.TH.Quote,', '')
+                           .replace('GHC.Internal.TH.Syntax', '')
+                           .replace('GHC.Internal.ForeignSrcLang', '')
+                           .replace('GHC.Internal.LanguageExtensions', '')
+                           .replace('GHC.Internal.Lexeme', '')
+                )
+
 PACKAGES = {
     pkg.name: pkg
     for pkg in [
@@ -105,9 +124,10 @@ PACKAGES = {
         Package('template-haskell', Path("libraries/template-haskell"), no_prep),
         Package('ghc-heap', Path("libraries/ghc-heap"), no_prep),
         Package('ghc-boot', Path("libraries/ghc-boot"), prep_ghc_boot),
-        Package('ghc-boot-th', Path("libraries/ghc-boot-th"), no_prep),
+        Package('ghc-boot-th', Path("libraries/ghc-boot-th"), prep_ghc_boot_th),
         Package('ghc-compact', Path("libraries/ghc-compact"), no_prep),
         Package('ghc', Path("compiler"), prep_ghc),
+        Package('ghci', Path("libraries/ghci"), no_prep),
     ]
 }
 # Dict[str, Package]



View it on GitLab: https://gitlab.haskell.org/ghc/ghc/-/compare/d3633636f652bdafc71538c28d27e580ca2ef89f...c3657b3347133b52cff99f250ac8cdfb45732c6e

-- 
View it on GitLab: https://gitlab.haskell.org/ghc/ghc/-/compare/d3633636f652bdafc71538c28d27e580ca2ef89f...c3657b3347133b52cff99f250ac8cdfb45732c6e
You're receiving this email because of your account on gitlab.haskell.org.


-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://mail.haskell.org/pipermail/ghc-commits/attachments/20250203/e0ee79d9/attachment-0001.html>


More information about the ghc-commits mailing list