diff --git a/.gitignore b/.gitignore index 416ea9f..bcba568 100644 --- a/.gitignore +++ b/.gitignore @@ -1,6 +1,8 @@ # Objects. .scons-cache/ *.os +*.obj + # SConstruct .sconf_temp @@ -12,3 +14,7 @@ # Editors .vscode/ + +# Clangd +.cache/ +compile_commands.json \ No newline at end of file diff --git a/SConstruct b/SConstruct index 8222b88..de4cce2 100644 --- a/SConstruct +++ b/SConstruct @@ -5,6 +5,10 @@ from pathlib import Path # TODO: Do not copy environment after godot-cpp/test is updated . env = SConscript("godot-cpp/SConstruct") +env.Tool('compilation_db') +cdb = env.CompilationDatabase('compile_commands.json') +Alias('cdb', cdb) + # Add source files. env.Append(CPPPATH=["src/"]) sources = Glob("src/*.cpp")