Skip to content

Support ghc 9.14 in nix - #7900

Open
zeme-wana wants to merge 11 commits into
masterfrom
zeme/ghc-9-14-nix-support-1843ad
Open

Support ghc 9.14 in nix#7900
zeme-wana wants to merge 11 commits into
masterfrom
zeme/ghc-9-14-nix-support-1843ad

Conversation

@zeme-wana

@zeme-wana zeme-wana commented Aug 17, 2026

Copy link
Copy Markdown
Collaborator

Adds ghc914 project variants, dev shell, and CI jobs to the nix setup, mirroring ghc912. Compilation support for GHC 9.14 landed in #7335; this makes it buildable and testable via nix/CI.

zeme-wana and others added 5 commits August 14, 2026 09:06
Add ghc914 and ghc914-profiled project variants, dev shells, and CI
jobs, mirroring the existing ghc912 setup.

- Bump the haskell-nix flake input (2025-09-02 -> 2026-08-13); the old
  pin predates GHC 9.14 support in haskell.nix. Short names now resolve
  to GHC 9.6.7 / 9.12.4 / 9.14.1.
- cabal.project: help the solver under `if impl (ghc >= 9.14)`:
  constrain aeson <2.3 (microstache, via criterion, does not allow
  aeson 2.3 and the solver hits the backjump limit) and allow-newer
  turtle:containers (GHC 9.14 ships containers 0.8; turtle is a
  custom-setup dep of plutus-cert).
- Dev shell tools that cannot be built with ghc914 yet are borrowed
  from other variants: haskell-language-server from ghc96 (hie-compat
  requires base <4.22), stylish-haskell and hlint from ghc912 (both
  require ghc-lib-parser 9.12.*), fourmolu from ghc912 (our fork has
  no ghc914-compatible revision).
- Fix `pkgs.system` / `pkgs.hostPlatform` deprecation warnings
  introduced by the newer nixpkgs that follows haskell-nix.

Verified on aarch64-darwin: plan-nix builds (cabal solve) for ghc96,
ghc912 and ghc914; dev shell evaluation for all three; full
hydraJobs.aarch64-darwin evaluation.

Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>
Adopt the ci-devShells structure from the devShells clobbering fix
(branch zeme/fix-devshells-ci-jobs): the chained
`{ devShells.* = ...; } //` attrsets merged shallowly, so only the
last entry (metatheory-jailbreak) ever became a CI job. Collect the
CI dev shells in a single attrset, now including ghc914, and drop the
profiled shell entries (they were equally dead, and fixing them in
would force profiled builds of the entire dependency closure). The
profiled shells remain available via `nix develop`.

Verified: hydraJobs.aarch64-darwin now lists devShells:ghc96,
devShells:ghc912, devShells:ghc914 and devShells:metatheory-jailbreak.

Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>
- Remove the ghc914-profiled dev shell (the ghc914-profiled project
  variant and its plan-nix/roots CI jobs remain, matching the other
  profiled variants).
- Stop building the ghc912 packages/checks on x86_64-linux CI; the
  ghc912 dev shell remains a CI job, which still builds the project
  dependencies via shellFor.
- Remove the explanatory comment on top of ci-devShells.

Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>
Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>
Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>
@zeme-wana zeme-wana added the No Changelog Required Add this to skip the Changelog Check label Aug 17, 2026
zeme-wana and others added 6 commits August 17, 2026 12:20
Three casualties of the newer pins, found by actually building the
ghc914 dev shell:

- fourmolu: the fork pins index-state 2025-01-16, whose ghc-lib-parser
  snapshot (9.12.1.20250105) no longer compiles with GHC 9.12.4 (the
  version ghc912 now resolves to). Solve against a newer index via
  cabalProjectLocal instead.
- agda-stdlib: nixpkgs now ships standard-library 2.3 itself and its
  agda builder no longer provides runhaskell, which broke our
  GenerateEverything preConfigure override. The override is redundant
  now; use the nixpkgs package directly.
- plutus-metatheory: the new agda builder ignores everythingFile and
  defaults to `agda --build-library`, which checks every file in the
  library, including modules outside the index.lagda.md closure that
  do not typecheck. Restore the old behavior with an explicit
  buildPhase.

Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>
The GHC 9.14 build plan resolves `some` to 1.1 (ghc96 and ghc912 stay
on 1.0.6), where 'EqP' is a superclass of 'GEq' and 'OrdP' of
'GCompare', and 'EqP' itself requires @forall a. Eq (f a)@. Add the
instances for 'ValueOf uni' and 'DefaultUni', CPP-guarded on the some
version so the older plans build unchanged.

Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>
Generated and verified by running the test suites with GHC 9.14.1.
Required by the nix CI jobs, which run tasty-golden with --no-create.

Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>
GHC 9.14 analyzes standalone-deriving instance contexts for redundant
constraints, which older GHCs did not. Remove the constraints it flags
(they are unnecessary on all supported GHC versions: the derived
method bodies only need Eq/NFData/Show of the field types), and drop
an import made redundant by an existing re-export.

Found by `cabal clean && cabal build all --ghc-options=-Werror` inside
the ghc914 shell, mirroring the nix CI jobs which build the plutus
packages with -Werror.

Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>
The nixpkgs bump moved texliveFull from 2024 to 2025, which is
stricter about two things these documents relied on:

- Blank lines inside math-mode array environments now error with
  "Missing $ inserted". Remove them (they never affected output).
- \DeclareMathOperator now rejects digits in macro names: \Fix0 was
  parsed as \Fix followed by 0. Rename \Fix0 -> \FixZero and
  \fix2 -> \fixTwo.

All four documents (lazy-machine-notes, plutus-core-spec,
plutus-core-spec-old, unraveling-recursion-paper) now build with the
new toolchain.

Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>
After the toolchain bump (newer Wine / GHC 9.6.7 cross toolchain) the
test fails on CI with "openBinaryFile: invalid argument" when opening
the golden file under Wine. The encodings are platform-independent
and the test still runs on Linux and macOS, so no coverage is lost.

Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

No Changelog Required Add this to skip the Changelog Check

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant