Cmake 3.30.2 bootstrap failure on MacOS with gcc and old Xcode SDK

I’m trying to bootstrap Cmake 3.30.2 on a MacOS (14.6.1) Apple silicon system using gcc (13.3.0), but with a wrinkle: the gcc compiler was built against an old Xcode SDK (11.1) so that I can use it on older MacOS systems.

This seems to cause problems with the bootstrap, involving header files from the Xcode SDK. Here’s a snippet of output:

g++        -DCMAKE_BOOTSTRAP    -DCMake_HAVE_CXX_MAKE_UNIQUE=1 -DCMake_HAVE_CXX_FILESYSTEM=1   -I/opt/sdk2-tmp/build/cmake-3.30.2/build/Bootstrap.cmk   -I/opt/sdk2-tmp/build/cmake-3.30.2/Source   -I/opt/sdk2-tmp/build/cmake-3.30.2/Source/LexerParser   -I/opt/sdk2-tmp/build/cmake-3.30.2/Utilities/std   -I/opt/sdk2-tmp/build/cmake-3.30.2/Utilities  -c /opt/sdk2-tmp/build/cmake-3.30.2/Source/cmFindProgramCommand.cxx -o cmFindProgramCommand.o
In file included from /Applications/mesasdk/bin/../sysroot/usr/include/dispatch/dispatch.h:63,
                 from /Applications/mesasdk/bin/../sysroot/System/Library/Frameworks/CoreFoundation.framework/Headers/CFStream.h:20,
                 from /Applications/mesasdk/bin/../sysroot/System/Library/Frameworks/CoreFoundation.framework/Headers/CFPropertyList.h:18,
                 from /Applications/mesasdk/bin/../sysroot/System/Library/Frameworks/CoreFoundation.framework/Headers/CoreFoundation.h:76,
                 from /opt/sdk2-tmp/build/cmake-3.30.2/Source/cmFindProgramCommand.cxx:21:
/Applications/mesasdk/bin/../sysroot/usr/include/os/object.h:278:1: error: 'OS_ASSUME_PTR_ABI_SINGLE_BEGIN' does not name a type; did you mean 'DISPATCH_ASSUME_ABI_SINGLE_BEGIN'?
  278 | OS_OBJECT_ASSUME_ABI_SINGLE_BEGIN
      | ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
/Applications/mesasdk/bin/../sysroot/usr/include/os/object.h:327:1: error: 'OS_ASSUME_PTR_ABI_SINGLE_END' does not name a type; did you mean 'OS_OBJECT_ASSUME_ABI_SINGLE_END'?
  327 | OS_OBJECT_ASSUME_ABI_SINGLE_END
      | ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
In file included from /Applications/mesasdk/bin/../sysroot/usr/include/os/workgroup.h:29,
                 from /Applications/mesasdk/bin/../sysroot/usr/include/dispatch/dispatch.h:64:
/Applications/mesasdk/bin/../sysroot/usr/include/os/workgroup_base.h:65:1: error: 'OS_ASSUME_PTR_ABI_SINGLE_BEGIN' does not name a type; did you mean 'DISPATCH_ASSUME_ABI_SINGLE_BEGIN'?
   65 | OS_WORKGROUP_ASSUME_ABI_SINGLE_BEGIN
      | ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
/Applications/mesasdk/bin/../sysroot/usr/include/os/workgroup_base.h:83:1: error: 'OS_ASSUME_PTR_ABI_SINGLE_END' does not name a type; did you mean 'OS_OBJECT_ASSUME_ABI_SINGLE_END'?
   83 | OS_WORKGROUP_ASSUME_ABI_SINGLE_END
      | ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
/Applications/mesasdk/bin/../sysroot/usr/include/os/workgroup_interval.h:32:1: error: 'OS_ASSUME_PTR_ABI_SINGLE_BEGIN' does not name a type; did you mean 'DISPATCH_ASSUME_ABI_SINGLE_BEGIN'?
   32 | OS_WORKGROUP_ASSUME_ABI_SINGLE_BEGIN
      | ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
/Applications/mesasdk/bin/../sysroot/usr/include/os/workgroup_interval.h:42:1: error: 'os_workgroup_t' does not name a type
   42 | OS_WORKGROUP_SUBCLASS_DECL(os_workgroup_interval, os_workgroup, WorkGroupInterval);
      | ^~~~~~~~~~~~~~~~~~~~~~~~~~

(there are many more errors)

Would appreciate some guidance here!