Cannot build KiCad on MacOS 15 due to obsolete 'CGDisplayCreateImage'

I have been trying to build KiCad from source (main, nightly and a merge request I am trying to help test) on MacOS 15.0.1 on Apple Silicon and have been unable to build, I beleive due to wxWidgets using an obsolete framework. I have been using KiCad-Mac-Build which should be able to build out of the box once all the dependencies are in place. Please see the log snippet below.

make[4]: Entering directory '/Users/osholt/Projects/KiCad-Dev/kicad-mac-builder/build/wxwidgets/src/wxwidgets'
/Users/osholt/Projects/KiCad-Dev/kicad-mac-builder/build/wxwidgets/src/wxwidgets/bk-deps clang++ -std=gnu++11 -mmacosx-version-min=15.0 -c -o monodll_carbon_dcscreen.o  -I/Users/osholt/Projects/KiCad-Dev/kicad-mac-builder/build/wxwidgets/src/wxwidgets/src/tiff/libtiff -I./src/tiff/libtiff -I./src/jpeg -I./src/png -I./src/zlib -I./3rdparty/pcre/src/wx -I./src/expat/expat/lib -I/Users/osholt/Projects/KiCad-Dev/kicad-mac-builder/build/wxwidgets/src/wxwidgets/lib/wx/include/osx_cocoa-unicode-3.2 -I./include -D__ASSERT_MACROS_DEFINE_VERSIONS_WITHOUT_UNDERSCORES=1 -D_FILE_OFFSET_BITS=64  -D__WXOSX_COCOA__      -DWXBUILDING -I./src/stc/scintilla/include -I./src/stc/scintilla/lexlib -I./src/stc/scintilla/src -D__WX__ -DSCI_LEXER -DNO_CXX11_REGEX -DLINK_LEXERS   -DwxUSE_BASE=1 -DWXMAKINGDLL -dynamic -fPIC -DPIC -Wall -Wundef -Wunused-parameter -Wno-ctor-dtor-privacy -Woverloaded-virtual -Wno-deprecated-declarations -g -O2 -fno-common  -fvisibility=hidden -fvisibility-inlines-hidden  -D__ASSERT_MACROS_DEFINE_VERSIONS_WITHOUT_UNDERSCORES=1  ./src/osx/carbon/dcscreen.cpp
./src/osx/carbon/dcscreen.cpp:73:13: **error: 'CGDisplayCreateImage' is unavailable: obsoleted in macOS 15.0 - Please use ScreenCaptureKit instead.
   73 |     image = CGDisplayCreateImage(kCGDirectMainDisplay);
      |             ^
/Applications/Xcode.app/Contents/Developer/Platforms/MacOSX.platform/Developer/SDKs/MacOSX.sdk/System/Library/Frameworks/CoreGraphics.framework/Headers/CGDirectDisplay.h:383:33: note: 'CGDisplayCreateImage' has been explicitly marked unavailable here**
  383 | CG_EXTERN CGImageRef __nullable CGDisplayCreateImage(CGDirectDisplayID displayID)
      |                                 ^
1 error generated.
make[4]: *** [Makefile:20448: monodll_carbon_dcscreen.o] Error 1
make[4]: Leaving directory '/Users/osholt/Projects/KiCad-Dev/kicad-mac-builder/build/wxwidgets/src/wxwidgets'
make[3]: *** [CMakeFiles/wxwidgets.dir/build.make:89: wxwidgets/src/wxwidgets-stamp/wxwidgets-build] Error 2
make[3]: Leaving directory '/Users/osholt/Projects/KiCad-Dev/kicad-mac-builder/build'
make[2]: *** [CMakeFiles/Makefile2:135: CMakeFiles/wxwidgets.dir/all] Error 2
make[2]: Leaving directory '/Users/osholt/Projects/KiCad-Dev/kicad-mac-builder/build'
make[1]: *** [CMakeFiles/Makefile2:442: CMakeFiles/package-kicad-nightly.dir/rule] Error 2
make[1]: Leaving directory '/Users/osholt/Projects/KiCad-Dev/kicad-mac-builder/build'
make: *** [Makefile:283: package-kicad-nightly] Error 2
Error while running make after rebuilding with a single job. Please report this issue if you cannot fix it after reading the README.
build.py argument summary:
app_notarization_id: None
apple_developer_password_keychain_name: None
apple_developer_username: None
arch: arm64
asc_provider: None
build_dir: /Users/osholt/Projects/KiCad-Dev/kicad-mac-builder/build
build_type: RelWithDebInfo
dmg_dir: None
dmg_notarization_id: None
docs_tarball_url: https://docs.kicad.org/kicad-doc-HEAD.tar.gz
extra_bundle_fix_dir: None
extra_kicad_cmake_args: None
extra_version: None
footprints_ref: origin/master
hardened_runtime: False
jobs: 1
kicad_git_url: https://gitlab.com/kicad/code/kicad.git
kicad_mac_builder_cmake_dir: /Users/osholt/Projects/KiCad-Dev/kicad-mac-builder/kicad-mac-builder
kicad_ref: origin/master
kicad_source_dir: None
macos_min_version: 15.0
packages3d_ref: origin/master
redistributable: True
release: False
release_name: None
retry_failed_build: True
signing_certificate_id: -
signing_identity: None
skip_docs_update: False
symbols_ref: origin/master
target: ['package-kicad-nightly']
templates_ref: origin/master
Traceback (most recent call last):
  File "/Users/osholt/Projects/KiCad-Dev/kicad-mac-builder/./build.py", line 365, in build
    subprocess.check_call(make_command, env=dict(os.environ, PATH=new_path))
  File "/Users/osholt/.pyenv/versions/3.11.3/lib/python3.11/subprocess.py", line 413, in check_call
    raise CalledProcessError(retcode, cmd)
subprocess.CalledProcessError: Command '['make', '-j12', 'package-kicad-nightly']' returned non-zero exit status 2.

During handling of the above exception, another exception occurred:

Traceback (most recent call last):
  File "/Users/osholt/Projects/KiCad-Dev/kicad-mac-builder/./build.py", line 462, in <module>
    main()
  File "/Users/osholt/Projects/KiCad-Dev/kicad-mac-builder/./build.py", line 458, in main
    build(parsed_args, new_path)
  File "/Users/osholt/Projects/KiCad-Dev/kicad-mac-builder/./build.py", line 376, in build
    subprocess.check_call(make_command, env=dict(os.environ, PATH=new_path))
  File "/Users/osholt/.pyenv/versions/3.11.3/lib/python3.11/subprocess.py", line 413, in check_call
    raise CalledProcessError(retcode, cmd)
subprocess.CalledProcessError: Command '['make', '-j1', 'package-kicad-nightly']' returned non-zero exit status 2.
Edited by Ian McInerney
To upload designs, you'll need to enable LFS and have an admin enable hashed storage. More information