Repository navigation
Bootstrap job fails on macos-latest (GHC 9.12.4) due to linker error with SDK TBD files #12465
Copy link
Copy link
Closed
Description
Describe the bug
Bootstrap sources saved to /Users/runner/work/cabal/cabal/bootstrap-sources.tar.gz
Use these with the command:
bootstrap.py -w /Users/runner/.ghcup/ghc/9.12.4/bin/ghc-9.12.4 -s /Users/runner/work/cabal/cabal/bootstrap-sources.tar.gz
[1 of 2] Compiling Main ( Setup.hs, /Users/runner/work/cabal/cabal/_build/dists/alex-3.5.4.2/setup/Main.o )
[2 of 2] Linking /Users/runner/work/cabal/cabal/_build/dists/alex-3.5.4.2/setup/Setup
ld: multiple errors: tapi error: malformed file
/Library/Developer/CommandLineTools/SDKs/MacOSX27.0.sdk/usr/lib/libSystem.B.tbd:4:20: error:
error: unknown architecture
arm64e.x1-macos, arm64e.x1-maccatalyst ]
^~~~~~~~~~~~~~~
in '/Library/Developer/CommandLineTools/SDKs/MacOSX.sdk/usr/lib/libm.tbd'; tapi error: malformed file
|
4 | arm64e.x1-macos, arm64e.x1-maccatalyst ]
| ^
/Library/Developer/CommandLineTools/SDKs/MacOSX27.0.sdk/usr/lib/libiconv.2.tbd:4:20: error:
error: unknown architecture
arm64e.x1-macos, arm64e.x1-maccatalyst ]
^~~~~~~~~~~~~~~
in '/Library/Developer/CommandLineTools/SDKs/MacOSX.sdk/usr/lib/libiconv.tbd'; tapi error: malformed file
|
4 | arm64e.x1-macos, arm64e.x1-maccatalyst ]
| ^
/Library/Developer/CommandLineTools/SDKs/MacOSX27.0.sdk/usr/lib/libffi.tbd:4:20: error:
error: unknown architecture
arm64e.x1-macos, arm64e.x1-maccatalyst ]
^~~~~~~~~~~~~~~
in '/Library/Developer/CommandLineTools/SDKs/MacOSX.sdk/usr/lib/libffi.tbd'; tapi error: malformed file
|
4 | arm64e.x1-macos, arm64e.x1-maccatalyst ]
| ^
/Library/Developer/CommandLineTools/SDKs/MacOSX27.0.sdk/usr/lib/libSystem.B.tbd:4:20: error:
error: unknown architecture
arm64e.x1-macos, arm64e.x1-maccatalyst ]
^~~~~~~~~~~~~~~
in '/Library/Developer/CommandLineTools/SDKs/MacOSX.sdk/usr/lib/libSystem.tbd'
|
4 | arm64e.x1-macos, arm64e.x1-maccatalyst ]
| ^
clang: error: linker command failed with exit code 1 (use -v to see invocation)
ghc-9.12.4: Uncaught exception ghc-9.12.4-6f4d:GHC.Utils.Panic.GhcException:
`gcc' failed in phase `Linker'. (Exit code: 1)
While handling `gcc' failed in phase `Linker'. (Exit code: 1)
HasCallStack backtrace:
throwIO, called at libraries/exceptions/src/Control/Monad/Catch.hs:347:12 in exceptions-0.10.12-3ae7:Control.Monad.Catch
throwM, called at libraries/exceptions/src/Control/Monad/Catch.hs:872:84 in exceptions-0.10.12-3ae7:Control.Monad.Catch
onException, called at compiler/GHC/Driver/Make.hs:2992:23 in ghc-9.12.4-6f4d:GHC.Driver.Make
DO NOT use this script if you have another recent cabal-install available.
This script is intended only for bootstrapping cabal-install on new
architectures.
To Reproduce
Steps to reproduce the behavior: https://github.com/haskell/cabal/actions/runs/38614163097/job/116848009687?pr=12460
Expected behavior
Bootstrap script successfully compiles dependencies (alex) and finishes cabal-install bootstrap.
System information
- Operating system: macos-latest runner
- GHC version: 9.12.4
- cabal version: 3.18.1.0
Reactions are currently unavailable
Activity
zlonast commentedon Oct 16, 2026
Same problem: actions/runner-images#14940
CI: run macOS jobs on macos-15 until actions/runner-images#14940 is f…
ulysses4ever commentedon Oct 16, 2026
I’m not sure if this should be left open or not. After all #12468 is just a stop gap.
andreasabel commentedon Oct 17, 2026
@ulysses4ever Thanks for the investigation and communication.
On the Agda side, I am considering to use one of these workarounds (once I confirm them):
sudo xcode-select -s /Library/Developer/CommandLineToolsUse Command Line Tools linker in test-macos actonlang/acton#3283SDKROOT=$(xcrun --sdk macosx --show-sdk-path)fix: use the active Xcode SDK on macOS carpentry-org/setup-carp#1Update: I could only confirm the first workaround: https://github.com/andreasabel/gha-test/actions/runs/39004738788/workflow#L36