infra: --shutdown the unkown-pragmas warning

Apply the flag even if the sanitizer is toggled on.
This commit is contained in:
Hermet Park 2024-10-04 02:31:46 +09:00
parent 5813e7e09f
commit 3563546a65

View file

@ -17,9 +17,10 @@ if cc.get_id() == 'clang-cl'
if simd_type == 'neon-arm' if simd_type == 'neon-arm'
compiler_flags += ['/clang:-mfpu=neon'] compiler_flags += ['/clang:-mfpu=neon']
endif endif
compiler_flags += ['/clang:-Wno-unknown-pragmas']
if get_option('b_sanitize') == 'none' if get_option('b_sanitize') == 'none'
override_options += ['cpp_eh=none','cpp_rtti=false'] override_options += ['cpp_eh=none','cpp_rtti=false']
compiler_flags += ['/clang:-fno-math-errno', '/clang:-Woverloaded-virtual', '/clang:-Wno-unknown-pragmas', compiler_flags += ['/clang:-fno-math-errno', '/clang:-Woverloaded-virtual',
'/clang:-fno-stack-protector', '/clang:-fno-unwind-tables' , '/clang:-fno-stack-protector', '/clang:-fno-unwind-tables' ,
'/clang:-fno-asynchronous-unwind-tables'] '/clang:-fno-asynchronous-unwind-tables']
endif endif
@ -30,10 +31,10 @@ elif (cc.get_id() != 'msvc')
if simd_type == 'neon-arm' if simd_type == 'neon-arm'
compiler_flags += ['-mfpu=neon'] compiler_flags += ['-mfpu=neon']
endif endif
compiler_flags += ['-Wno-unknown-pragmas']
if get_option('b_sanitize') == 'none' if get_option('b_sanitize') == 'none'
compiler_flags += ['-fno-exceptions', '-fno-rtti', '-fno-stack-protector', '-fno-math-errno', compiler_flags += ['-fno-exceptions', '-fno-rtti', '-fno-stack-protector', '-fno-math-errno',
'-fno-unwind-tables' , '-fno-asynchronous-unwind-tables', '-fno-unwind-tables' , '-fno-asynchronous-unwind-tables', '-Woverloaded-virtual']
'-Woverloaded-virtual', '-Wno-unknown-pragmas']
endif endif
endif endif