Opened 4 weeks ago
Last modified 4 weeks ago
#74440 assigned defect
cmake @3.31.12 +universal: x86_64 configuration cannot load CLT 27 libxcrun on ARM64
| Reported by: | JeffreyRacine (Jeffrey S. Racine) | Owned by: | mascguy (Christopher Nielsen) |
|---|---|---|---|
| Priority: | Normal | Milestone: | |
| Component: | ports | Version: | 2.12.6 |
| Keywords: | goldengate arm64 universal | Cc: | |
| Port: | cmake |
Description
On macOS 27.0 Golden Gate (26A428), ARM64, with MacPorts 2.12.6 and Xcode/CLT 27, building CMake 3.31.12 +universal fails in the Intel configuration path when MacPorts selects Command Line Tools. Rosetta is installed and working.
The Intel-invoked Apple tool shim cannot load:
/Library/Developer/CommandLineTools/usr/lib/libxcrun.dylib
The diagnostic reports:
fat file, but missing compatible architecture (have 'arm64,arm64e', need 'x86_64')
This occurs inside CMake's compiler probe, so the outer error misleadingly
reports that /usr/bin/clang cannot compile a simple test program.
A controlled comparison used the same Intel CMake bootstrap:
- With DEVELOPER_DIR selecting CLT, C/C++ configuration failed with the missing x86_64 libxcrun slice.
- With full Xcode selected, whose libxcrun also contains x86_64, C/C++ configuration and builds succeeded. Both ARM64 and Intel test executables were built and run.
A subsequent MacPorts source build of CMake with its saved +universal variant
and the command-scoped use_xcode=yes option completed successfully. Both
installed CMake architecture slices passed version checks.
The full Xcode selection must reach the build environment; the system's xcode-select setting by itself was insufficient in this case. Please consider requiring/selecting full Xcode for the affected universal build, or another tool invocation that avoids executing a CLT shim under Intel. I have not validated a general repair for other ports or older macOS versions.
The attached toolchain-comparison.txt contains the failed CLT configure log and successful full-Xcode ARM64/x86_64 build logs. Personal scratch paths have been replaced with <scratch>.
Attachments (1)
Change History (2)
Changed 4 weeks ago by JeffreyRacine (Jeffrey S. Racine)
| Attachment: | toolchain-comparison.txt added |
|---|
comment:1 Changed 4 weeks ago by jmroot (Joshua Root)
| Owner: | set to mascguy |
|---|---|
| Status: | new → assigned |

Sanitized controlled comparison: CLT libxcrun architecture failure and successful full-Xcode ARM64/x86_64 C/C++ builds using the same Intel CMake bootstrap.