diff options
author | Bartosz Taudul <wolf@nereid.pl> | 2022-04-24 00:46:55 +0300 |
---|---|---|
committer | Bartosz Taudul <wolf@nereid.pl> | 2022-04-24 00:46:55 +0300 |
commit | 2dd61aba49de0f6513c858868625801544e8f031 (patch) | |
tree | bf1c47e4008bcd59e48ac0261d7eef07171c839c /library | |
parent | 67ab3acbd00a46604b2750b9f559500ce0f1ec27 (diff) |
Makefiles can now build clangd database.
Executing the "make db" will run the build process of the selected tool or
library through the bear wrapper (which has to be available in the system),
which will record the compilation parameters of each source file. This
database can be then used by VS Code to set the proper defines and find all
the required includes.
Note that database building is performed in context of the specific tool or
library. Not all tools have the same set of flags.
Diffstat (limited to 'library')
-rw-r--r-- | library/unix/Makefile | 6 |
1 files changed, 5 insertions, 1 deletions
diff --git a/library/unix/Makefile b/library/unix/Makefile index c70c51dd..a657b17b 100644 --- a/library/unix/Makefile +++ b/library/unix/Makefile @@ -9,4 +9,8 @@ release: clean: @+make -f build.mk clean -.PHONY: all clean debug release +db: clean + @bear -- $(MAKE) -f debug.mk all + @mv -f compile_commands.json ../../ + +.PHONY: all clean debug release db |