🔨 Fix ESP32 build (for xtensa32) (2) (#27570)

Followup to #27561
This commit is contained in:
ellensp 2024-12-06 12:20:25 +13:00 committed by GitHub
parent 4668b27158
commit a365163ff0
No known key found for this signature in database
GPG key ID: B5690EEEBB952194

View file

@ -87,7 +87,7 @@ def search_compiler(env):
if ppath.match(env['PROJECT_PACKAGES_DIR'] + "/**/bin"):
for gpath in ppath.glob(gcc_exe):
# Skip '*-elf-g++' (crosstool-NG) except for xtensa32
if not "xtensa32" not in str(gpath) and gpath.stem.endswith('-elf-g++'):
if not gpath.stem.endswith('-elf-g++') or "xtensa32" in str(gpath):
gccpath = str(gpath.resolve())
break
@ -95,7 +95,7 @@ def search_compiler(env):
for ppath in envpath:
for gpath in ppath.glob(gcc_exe):
# Skip macOS Clang
if gpath != 'usr/bin/g++' or env['PLATFORM'] != 'darwin':
if not (gpath == 'usr/bin/g++' and env['PLATFORM'] == 'darwin'):
gccpath = str(gpath.resolve())
break