waf: fixed cygwin build

This commit is contained in:
Andrew Tridgell 2024-05-27 14:35:34 +10:00
parent 6233bc0e10
commit 1ad0c069ae
2 changed files with 6 additions and 1 deletions

View File

@ -794,6 +794,8 @@ class sitl(Board):
if Utils.unversioned_sys_platform() == 'cygwin':
env.CXXFLAGS += ['-DCYGWIN_BUILD']
# can't do symbol checking on cygwin due to exception usage in system libraries
env.CHECK_SYMBOLS = False
if 'clang++' in cfg.env.COMPILER_CXX:
print("Disabling SLP for clang++")

View File

@ -150,7 +150,10 @@ def configure(cfg):
cfg.find_program('%s-ar' % cfg.env.TOOLCHAIN, var='AR', quiet=True)
cfg.load('compiler_cxx compiler_c')
cfg.find_program('%s-nm' % cfg.env.TOOLCHAIN, var='NM')
if sys.platform.startswith("cygwin"):
cfg.find_program('nm', var='NM')
else:
cfg.find_program('%s-nm' % cfg.env.TOOLCHAIN, var='NM')
if not cfg.options.disable_gccdeps:
cfg.load('gccdeps')