Internal error 2014080406

I can build the arm64 3.3.1 llvm compiler on macOS, but when I try to build it with a "Unicode" rtl, I get internal error 2014080406.

/usr/local/lib/fpc/3.3.1-llvm/ppca64 -tunicodertl -dFPC_USE_LIBC -Fi../inc -Fi../aarch64 -Fi../unix -Fi../bsd -Fi../bsd/aarch64 -Fi../darwin/aarch64 -FE. -FU../../rtl/units/aarch64-darwin-unicodertl -XR/Library/Developer/CommandLineTools/SDKs/MacOSX.sdk -Clv15.0 -dUSEWIDESTRING -daarch64  ../objpas/sysconst.pp
Free Pascal Compiler version 3.3.1 [2026/04/06] for aarch64
Copyright (c) 1993-2026 by Florian Klaempfl and others
Target OS: Darwin for AArch64
Compiling ../objpas/sysconst.pp
sysconst.pp(276) Fatal: Internal error 2014080406
Fatal: Compilation aborted
make[1]: *** [sysconst.ppu] Error 1
make: *** [darwin_all] Error 2

The commands given (with the regular llvm 3.3.1 ppca64 already built) are

setenv CLANGOPTION -Clv15.0
setenv XR /Applications/Xcode.app/Contents/Developer/Platforms/MacOSX.platform/Developer/SDKs/MacOSX.sdk

pushd rtl

make all FPC=/usr/local/lib/fpc/3.3.1-llvm/ppca64 CPU_TARGET=aarch64 OPT="-Clv15.0 -dUSEWIDESTRING" SUB_TARGET=unicodertl LLVM=1
sudo make install FPC=/usr/local/lib/fpc/3.3.1-llvm/ppca64 CPU_TARGET=aarch64 OPT="-Clv15.0 -dUSEWIDESTRING" SUB_TARGET=unicodertl LLVM=1

etcetera

Edited by Adriaan Van Os