summaryrefslogtreecommitdiff
path: root/Makefile.in
diff options
context:
space:
mode:
authorLukas Larsson <lukas@erlang.org>2020-07-08 17:18:53 +0200
committerLukas Larsson <lukas@erlang.org>2020-09-21 16:40:30 +0200
commit2340ac403aba8942334c9fcbefe7aa5bf58f2363 (patch)
tree21b80a7b30bf2184b328d1b81f06b6089006c08a /Makefile.in
parent7583e0ce26a041d13ae05a7a37210d397a3254d3 (diff)
downloaderlang-2340ac403aba8942334c9fcbefe7aa5bf58f2363.tar.gz
erts: Add support for building a compilation database
Diffstat (limited to 'Makefile.in')
-rw-r--r--Makefile.in4
1 files changed, 4 insertions, 0 deletions
diff --git a/Makefile.in b/Makefile.in
index 16bc7b1a3a..c1bf51664b 100644
--- a/Makefile.in
+++ b/Makefile.in
@@ -529,6 +529,10 @@ preloaded:
ERL_TOP=$(ERL_TOP) PATH=$(BOOT_PREFIX)"$${PATH}" \
$(MAKE) opt BUILD_ALL=true
+compdb:
+ (cd erts/emulator && ERL_TOP=$(ERL_TOP) TYPE=$(TYPE) $(MAKE) compdb)
+ sed -i -e '1s/^/[\n/' -e '$$s/,$$/\n]/' $(ERL_TOP)/compile_commands.json
+
dep depend:
$(make_verbose)
$(V_at)test X"$$ERTS_SKIP_DEPEND" = X"true" || (cd erts/emulator && PATH=$(BOOT_PREFIX)"$${PATH}" ERL_TOP=$(ERL_TOP) $(MAKE) generate)