Add support for generating clang compilation database by default (#35629)

compilation db by default
This commit is contained in:
DevTekVE
2025-07-03 19:06:55 +02:00
committed by GitHub
parent e503e657bc
commit 2183b4ca7b
+1 -6
View File
@@ -39,10 +39,6 @@ AddOption('--clazy',
action='store_true',
help='build with clazy')
AddOption('--compile_db',
action='store_true',
help='build clang compilation database')
AddOption('--ccflags',
action='store',
type='string',
@@ -214,8 +210,7 @@ if arch == "Darwin":
darwin_rpath_link_flags = [f"-Wl,-rpath,{path}" for path in env["RPATH"]]
env["LINKFLAGS"] += darwin_rpath_link_flags
if GetOption('compile_db'):
env.CompilationDatabase('compile_commands.json')
env.CompilationDatabase('compile_commands.json')
# Setup cache dir
cache_dir = '/data/scons_cache' if AGNOS else '/tmp/scons_cache'