ghc version 9.6.5 Fails to Build on macOS; Error ghc: can't find a package database
Summary
I'm the maintainer of ghc
for MacPorts, and just updated to version 9.6.5. The documented ghc
(hadrian
-based) build commands that work on previous versions fail with the latest ghc
version 9.6.5 Fails to Build on macOS, cabal
version 3.10.3.0.
The consistent build failure across macOS versions and architectures is:
:info:build # cabal-configure (for _build/stage0/libraries/mtl/setup-config)
:info:build dieVerbatim: user error (Error: hadrian:
:info:build '/opt/local/var/macports/build/_opt_local_ports_lang_ghc/ghc/work/.home/.cabal/bin/ghc'
:info:build exited with an error:
:info:build ghc: can't find a package database at
:info:build _build/stage0/libraries/ghc-boot-th/build/package.conf.inplace
:info:build )
Reference: https://github.com/macports/macports-ports/pull/23548
Steps to reproduce
Build ghc
using hadrian
with these document steps: https://gitlab.haskell.org/ghc/ghc/-/wikis/building/hadrian
Implemented in the Portfile.
Expected behavior
Successful ghc
build.
Environment
-
GHC version used: 9.6.5 Optional:
-
Operating System: macOS
-
System Architecture:
arm64
,x86_64