[Git][haskell-team/DHG_packages][experimental] 4 commits: ghc: Build rts package with -std=gnu17

Ilias Tsitsimpis (@iliastsi) gitlab at salsa.debian.org
Fri Sep 26 16:19:28 BST 2025



Ilias Tsitsimpis pushed to branch experimental at Debian Haskell Group / DHG_packages


Commits:
2f1f47d0 by Ilias Tsitsimpis at 2025-09-26T18:17:00+03:00
ghc: Build rts package with -std=gnu17

- - - - -
a7d1b04e by Ilias Tsitsimpis at 2025-09-26T18:17:21+03:00
ghc: Add hadrian bootstrap plan for GHC 9.6.6

- - - - -
ce10750d by Ilias Tsitsimpis at 2025-09-26T18:17:59+03:00
ghc: Backport patch to fix unregisterised builds

- - - - -
fdf5f47b by Ilias Tsitsimpis at 2025-09-26T18:18:15+03:00
Revert "ghc: re-enable registerised builds on i386"

This reverts commit 4a465cf3cb62a789ac6a64cb5c5ed2231dded811.

- - - - -


8 changed files:

- p/ghc/debian/changelog
- + p/ghc/debian/patches/hadrian-bootstrap-plan
- + p/ghc/debian/patches/hadrian-unreg-template-haskell
- p/ghc/debian/patches/series
- p/ghc/debian/rules
- − p/haskell-hadrian/debian/patches/hadrian-iserv
- p/haskell-hadrian/debian/patches/series
- + p/haskell-hadrian/debian/patches/unreg-template-haskell


Changes:

=====================================
p/ghc/debian/changelog
=====================================
@@ -2,6 +2,8 @@ ghc (9.10.3-1~exp1) experimental; urgency=medium
 
   * New upstream release
   * Update upstream signing key
+  * Fix unregisterised builds with GCC15
+  * Switch to unregistered build on i386 to avoid a baseline violation
 
  -- Ilias Tsitsimpis <iliastsi at debian.org>  Fri, 19 Sep 2025 17:54:59 +0300
 


=====================================
p/ghc/debian/patches/hadrian-bootstrap-plan
=====================================
@@ -0,0 +1,299 @@
+--- /dev/null
++++ b/hadrian/bootstrap/plan-bootstrap-9_6_6.json
+@@ -0,0 +1,296 @@
++{
++  "builtin": [
++    {
++      "package": "rts",
++      "version": "1.0.2"
++    },
++    {
++      "package": "ghc-prim",
++      "version": "0.10.0"
++    },
++    {
++      "package": "ghc-bignum",
++      "version": "1.3"
++    },
++    {
++      "package": "base",
++      "version": "4.18.2.1"
++    },
++    {
++      "package": "array",
++      "version": "0.5.6.0"
++    },
++    {
++      "package": "deepseq",
++      "version": "1.4.8.1"
++    },
++    {
++      "package": "ghc-boot-th",
++      "version": "9.6.6"
++    },
++    {
++      "package": "pretty",
++      "version": "1.1.3.6"
++    },
++    {
++      "package": "template-haskell",
++      "version": "2.20.0.0"
++    },
++    {
++      "package": "bytestring",
++      "version": "0.11.5.3"
++    },
++    {
++      "package": "containers",
++      "version": "0.6.7"
++    },
++    {
++      "package": "binary",
++      "version": "0.8.9.1"
++    },
++    {
++      "package": "transformers",
++      "version": "0.6.1.0"
++    },
++    {
++      "package": "mtl",
++      "version": "2.3.1"
++    },
++    {
++      "package": "stm",
++      "version": "2.5.1.0"
++    },
++    {
++      "package": "exceptions",
++      "version": "0.10.7"
++    },
++    {
++      "package": "filepath",
++      "version": "1.4.300.1"
++    },
++    {
++      "package": "time",
++      "version": "1.12.2"
++    },
++    {
++      "package": "unix",
++      "version": "2.8.4.0"
++    },
++    {
++      "package": "directory",
++      "version": "1.3.8.5"
++    },
++    {
++      "package": "text",
++      "version": "2.0.2"
++    },
++    {
++      "package": "parsec",
++      "version": "3.1.16.1"
++    },
++    {
++      "package": "Cabal-syntax",
++      "version": "3.10.3.0"
++    },
++    {
++      "package": "process",
++      "version": "1.6.19.0"
++    },
++    {
++      "package": "Cabal",
++      "version": "3.10.3.0"
++    }
++  ],
++  "dependencies": [
++    {
++      "cabal_sha256": "a694e88f9ec9fc79f0b03f233d3fea592b68f70a34aac2ddb5bcaecb6562e2fd",
++      "flags": [],
++      "package": "base16-bytestring",
++      "revision": 1,
++      "source": "hackage",
++      "src_sha256": "1d5a91143ef0e22157536093ec8e59d226a68220ec89378d5dcaeea86472c784",
++      "version": "1.0.2.0"
++    },
++    {
++      "cabal_sha256": "b938655b00cf204ce69abfff946021bed111d2609a9f7a9c22e28a1a202e9115",
++      "flags": [
++        "-llvm"
++      ],
++      "package": "clock",
++      "revision": 0,
++      "source": "hackage",
++      "src_sha256": "6ae9898afe788a5e334cd5fad5d18a3c2e8e59fa09aaf7b957dbb38a4767df2e",
++      "version": "0.8.4"
++    },
++    {
++      "cabal_sha256": "200d756a7b3bab7ca2bac6eb50ed8252f26de77ac8def490a3ad743f2933acbd",
++      "flags": [
++        "-exe",
++        "+use-cbits"
++      ],
++      "package": "cryptohash-sha256",
++      "revision": 4,
++      "source": "hackage",
++      "src_sha256": "73a7dc7163871a80837495039a099967b11f5c4fe70a118277842f7a713c6bf6",
++      "version": "0.11.102.1"
++    },
++    {
++      "cabal_sha256": "e3d3ce1dc7746b1132930e48c59fb5e8c51a09e92e0c031316be031067a273fb",
++      "flags": [],
++      "package": "extra",
++      "revision": 0,
++      "source": "hackage",
++      "src_sha256": "b6a909f8f0e4b8076a1653b4d34815a782f0a8c1e83d5267f4d00496471ef567",
++      "version": "1.7.14"
++    },
++    {
++      "cabal_sha256": "372c1733d83b90045eb29da9f010fed79bfef8771ce65eb126a1d83ecc54a9a2",
++      "flags": [],
++      "package": "filepattern",
++      "revision": 0,
++      "source": "hackage",
++      "src_sha256": "cc445d439ea2f65cac7604d3578aa2c3a62e5a91dc989f4ce5b3390db9e59636",
++      "version": "0.1.3"
++    },
++    {
++      "cabal_sha256": null,
++      "flags": [],
++      "package": "ghc-platform",
++      "revision": null,
++      "source": "local",
++      "src_sha256": null,
++      "version": "0.1.0.0"
++    },
++    {
++      "cabal_sha256": null,
++      "flags": [],
++      "package": "ghc-toolchain",
++      "revision": null,
++      "source": "local",
++      "src_sha256": null,
++      "version": "0.1.0.0"
++    },
++    {
++      "cabal_sha256": "f3bf68acfa0df7a064a378ef2cdcfeb55e6fb96100675f4c593556dcbf3d7194",
++      "flags": [
++        "+integer-gmp",
++        "-random-initial-seed"
++      ],
++      "package": "hashable",
++      "revision": 1,
++      "source": "hackage",
++      "src_sha256": "32efb16c2891786209b7cbe5c39df9b3a9ae51e836f1a54f646bc4602b7ab0f5",
++      "version": "1.4.3.0"
++    },
++    {
++      "cabal_sha256": "66b19fcd813b0e4db3e0bac541bd46606c3b13d3d081d9f9666f4be0f5ff14b8",
++      "flags": [],
++      "package": "heaps",
++      "revision": 0,
++      "source": "hackage",
++      "src_sha256": "89329df8b95ae99ef272e41e7a2d0fe2f1bb7eacfcc34bc01664414b33067cfd",
++      "version": "0.4"
++    },
++    {
++      "cabal_sha256": "f75cb4fa53c88c65794becdd48eb0d3b2b8abd89a3d5c19e87af91f5225c15e4",
++      "flags": [],
++      "package": "js-dgtable",
++      "revision": 0,
++      "source": "hackage",
++      "src_sha256": "e28dd65bee8083b17210134e22e01c6349dc33c3b7bd17705973cd014e9f20ac",
++      "version": "0.5.2"
++    },
++    {
++      "cabal_sha256": "4c1c447a9a2fba0adba6d30678302a30c32b9dfde9e7aa9e9156483e1545096d",
++      "flags": [],
++      "package": "js-flot",
++      "revision": 0,
++      "source": "hackage",
++      "src_sha256": "1ba2f2a6b8d85da76c41f526c98903cbb107f8642e506c072c1e7e3c20fe5e7a",
++      "version": "0.8.3"
++    },
++    {
++      "cabal_sha256": "59ab6c79159549ef94b584abce8e6d3b336014c2cce1337b59a8f637e2856df5",
++      "flags": [],
++      "package": "js-jquery",
++      "revision": 0,
++      "source": "hackage",
++      "src_sha256": "e0e0681f0da1130ede4e03a051630ea439c458cb97216cdb01771ebdbe44069b",
++      "version": "3.3.1"
++    },
++    {
++      "cabal_sha256": "d0ff45fa6e61f92af23611ceb8b9a6a04c236b50fb70c60e2ed3bfa532703670",
++      "flags": [],
++      "package": "primitive",
++      "revision": 1,
++      "source": "hackage",
++      "src_sha256": "5553c21b4a789f9b591eed69e598cc58484c274af29250e517b5a8bcc62b995f",
++      "version": "0.8.0.0"
++    },
++    {
++      "cabal_sha256": "caa9b4a92abf1496c7f6a3c0f4e357426a54880077cb9f04e260a8bfa034b77b",
++      "flags": [
++        "-optimised-mixer"
++      ],
++      "package": "splitmix",
++      "revision": 1,
++      "source": "hackage",
++      "src_sha256": "9df07a9611ef45f1b1258a0b412f4d02c920248f69d2e2ce8ccda328f7e13002",
++      "version": "0.1.0.5"
++    },
++    {
++      "cabal_sha256": "e7c1f881159d5cc788619c9ee8b8f340ba2ff0db571cdf3d1a1968ebc5108789",
++      "flags": [],
++      "package": "random",
++      "revision": 1,
++      "source": "hackage",
++      "src_sha256": "3e1272f7ed6a4d7bd1712b90143ec326fee9b225789222379fea20a9c90c9b76",
++      "version": "1.2.1.1"
++    },
++    {
++      "cabal_sha256": "1c28ca429e3960de0330908579a427ccacddd700cb84ec1969e2bbe576152add",
++      "flags": [
++        "-debug"
++      ],
++      "package": "unordered-containers",
++      "revision": 3,
++      "source": "hackage",
++      "src_sha256": "1b27bec5e0d522b27a6029ebf4c4a6d40acbc083c787008e32fb55c4b1d128d2",
++      "version": "0.2.19.1"
++    },
++    {
++      "cabal_sha256": "79416292186feeaf1f60e49ac5a1ffae9bf1b120e040a74bf0e81ca7f1d31d3f",
++      "flags": [],
++      "package": "utf8-string",
++      "revision": 0,
++      "source": "hackage",
++      "src_sha256": "ee48deada7600370728c4156cb002441de770d0121ae33a68139a9ed9c19b09a",
++      "version": "1.0.2"
++    },
++    {
++      "cabal_sha256": "3cb5814cce210b9756fa9246ff1b2a1e1b86be46fdc4c5e2baacdc5bf83ce5c3",
++      "flags": [
++        "-cloud",
++        "-embed-files",
++        "-portable"
++      ],
++      "package": "shake",
++      "revision": 1,
++      "source": "hackage",
++      "src_sha256": "352a56af12f70b50d564dcb61131555577281957ee196f1702a3723c0a3699d1",
++      "version": "0.19.7"
++    },
++    {
++      "cabal_sha256": null,
++      "flags": [
++        "-selftest",
++        "-threaded"
++      ],
++      "package": "hadrian",
++      "revision": null,
++      "source": "local",
++      "src_sha256": null,
++      "version": "0.1.0.0"
++    }
++  ]
++}


=====================================
p/ghc/debian/patches/hadrian-unreg-template-haskell
=====================================
@@ -0,0 +1,20 @@
+commit 702f7964373d9ffb1d550ee714bd723d8bb0c1a3
+Author: Matthew Pickering <matthewtpickering at gmail.com>
+Date:   Mon Apr 29 12:13:00 2024 +0100
+
+    Make interface files and object files depend on inplace .conf file
+    
+    A potential fix for #24737
+
+--- a/hadrian/src/Rules/Compile.hs
++++ b/hadrian/src/Rules/Compile.hs
+@@ -218,6 +218,9 @@
+   ctxPath <- contextPath ctx
+   (src, deps) <- lookupDependencies (ctxPath -/- ".dependencies") objpath
+   need (src:deps)
++  -- The .conf file is needed when template-haskell is implicitly added as a dependency
++  -- when a module in the template-haskell package is compiled. (See #24737)
++  when  (isLibrary (C.package ctx)) (need . (:[]) =<< pkgConfFile ctx)
+ 
+   -- The .dependencies file lists indicating inputs. ghc will
+   -- generally read more *.hi and *.hi-boot files (direct inputs).


=====================================
p/ghc/debian/patches/series
=====================================
@@ -18,3 +18,5 @@ llvm-newer-version
 alpha-fix-ieee_set_fp_control-invocation.patch
 # 0004-llvmGen-Pass-mcmodel-medium-option-to-LLVM-backend-on-LoongArch.patch
 # 0005-Pass-the-mcmodel-medium-parameter-to-CC-via-GHC.patch
+hadrian-bootstrap-plan
+hadrian-unreg-template-haskell


=====================================
p/ghc/debian/rules
=====================================
@@ -70,7 +70,11 @@ ifneq (,$(filter armel armhf, $(DEB_HOST_ARCH)))
   EXTRA_INSTALL_CONFIGURE_FLAGS += --enable-ld-override
 endif
 
-ifneq (,$(filter powerpcspe x32, $(DEB_HOST_ARCH)))
+# From GHC 8.10 and later, native code generator support for legacy x87
+# floating point coprocessor has been removed. GHC now only support floating
+# point via SSE2. This causes a baseline violation on Debian for i386 where
+# there is no SSE support. Fallback to unregisterised builds on i386.
+ifneq (,$(filter i386 powerpcspe x32, $(DEB_HOST_ARCH)))
   EXTRA_CONFIGURE_FLAGS += --enable-unregisterised
 endif
 
@@ -115,6 +119,13 @@ ifneq (,$(filter parallel=%,$(DEB_BUILD_OPTIONS)))
   NUMJOBS = $(patsubst parallel=%,%,$(filter parallel=%,$(DEB_BUILD_OPTIONS)))
 endif
 
+# The rts module fails to compile with GCC15 (unregisterised builds)
+# because GCC15 defaults to gnu23 standard, which doesn't support
+# function declaration without a prototype.
+# Use gnu17 standard instead.
+# See https://gitlab.haskell.org/ghc/ghc/-/issues/24897
+EXTRA_HADRIAN_FLAGS += "*.rts.ghc.hs.opts += -optc-std=gnu17"
+
 # Use system libffi
 EXTRA_CONFIGURE_FLAGS += --with-system-libffi
 


=====================================
p/haskell-hadrian/debian/patches/hadrian-iserv deleted
=====================================
@@ -1,18 +0,0 @@
-Description: Fix installation patch for iserv/unlit
-Author: Ilias Tsitsimpis <iliastsi at debian.org>
-Bug: https://gitlab.haskell.org/ghc/ghc/-/issues/22557
-Bug: https://gitlab.haskell.org/ghc/ghc/-/issues/22697
-
-Index: b/hadrian/src/Packages.hs
-===================================================================
---- a/hadrian/src/Packages.hs
-+++ b/hadrian/src/Packages.hs
-@@ -197,7 +197,7 @@ programPath context at Context {..} = do
-     -- See: https://github.com/snowleopard/hadrian/issues/570
-     -- Likewise for @iserv@ and @unlit at .
-     name <- programName context
--    path <- if package `elem` [iserv, touchy, unlit]
-+    path <- if package `elem` [touchy, unlit]
-               then stageLibPath stage <&> (-/- "bin")
-               else stageBinPath stage
-     return $ path -/- name <.> exe


=====================================
p/haskell-hadrian/debian/patches/series
=====================================
@@ -1,2 +1,3 @@
 hadrian-haddock-opts
 enable-interpreter
+unreg-template-haskell


=====================================
p/haskell-hadrian/debian/patches/unreg-template-haskell
=====================================
@@ -0,0 +1,20 @@
+commit 702f7964373d9ffb1d550ee714bd723d8bb0c1a3
+Author: Matthew Pickering <matthewtpickering at gmail.com>
+Date:   Mon Apr 29 12:13:00 2024 +0100
+
+    Make interface files and object files depend on inplace .conf file
+    
+    A potential fix for #24737
+
+--- a/hadrian/src/Rules/Compile.hs
++++ b/hadrian/src/Rules/Compile.hs
+@@ -218,6 +218,9 @@
+   ctxPath <- contextPath ctx
+   (src, deps) <- lookupDependencies (ctxPath -/- ".dependencies") objpath
+   need (src:deps)
++  -- The .conf file is needed when template-haskell is implicitly added as a dependency
++  -- when a module in the template-haskell package is compiled. (See #24737)
++  when  (isLibrary (C.package ctx)) (need . (:[]) =<< pkgConfFile ctx)
+ 
+   -- The .dependencies file lists indicating inputs. ghc will
+   -- generally read more *.hi and *.hi-boot files (direct inputs).



View it on GitLab: https://salsa.debian.org/haskell-team/DHG_packages/-/compare/260ace2159d5a610e554de3090d77c36121a364e...fdf5f47b84ec3af6869a3a75b825e2668a29f075

-- 
View it on GitLab: https://salsa.debian.org/haskell-team/DHG_packages/-/compare/260ace2159d5a610e554de3090d77c36121a364e...fdf5f47b84ec3af6869a3a75b825e2668a29f075
You're receiving this email because of your account on salsa.debian.org.


-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://alioth-lists.debian.net/pipermail/pkg-haskell-commits/attachments/20250926/6f41955e/attachment-0001.htm>


More information about the Pkg-haskell-commits mailing list