mirror of
https://github.com/RIOT-OS/RIOT.git
synced 2024-12-29 04:50:03 +01:00
dist/tools/compile_commands: fix clangd mode with ESP32
In clangd mode drop a number of compiler flags not supported by LLVM.
This commit is contained in:
parent
9827e573c0
commit
e90975da6f
24
dist/tools/compile_commands/compile_commands.py
vendored
24
dist/tools/compile_commands/compile_commands.py
vendored
@ -318,11 +318,21 @@ if __name__ == '__main__':
|
||||
if _args.clangd:
|
||||
_args.add_built_in_includes = True
|
||||
_args.add_libstdcxx_includes = True
|
||||
_args.filter_out = ['-mno-thumb-interwork',
|
||||
# Only even included for versions of GCC that support it
|
||||
'-misa-spec=2.2',
|
||||
'-malign-data=natural',
|
||||
# Only supported starting with clang 11
|
||||
'-msmall-data-limit=8',
|
||||
]
|
||||
flags = [
|
||||
'-mno-thumb-interwork',
|
||||
# Only even included for versions of GCC that
|
||||
# support it
|
||||
'-misa-spec=2.2',
|
||||
'-malign-data=natural',
|
||||
# Only supported starting with clang 11
|
||||
'-msmall-data-limit=8',
|
||||
# not supported by clang, see
|
||||
# https://gcc.gnu.org/onlinedocs/gcc-10.2.0/gcc/Xtensa-Options.html
|
||||
'-mtext-section-literals',
|
||||
'-fstrict-volatile-bitfields',
|
||||
# it's called -mlong-calls in LLVM, but we don't need it for clangd
|
||||
# as we do not generate code anyway
|
||||
'-mlongcalls',
|
||||
]
|
||||
_args.filter_out.extend(flags)
|
||||
generate_compile_commands(_args)
|
||||
|
Loading…
Reference in New Issue
Block a user