Skip to content

Commit 0772eee

Browse files
committed
Only generate compile_commands.json if the script exists
1 parent 747410b commit 0772eee

File tree

1 file changed

+4
-0
lines changed

1 file changed

+4
-0
lines changed

Makefile

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -178,7 +178,11 @@ linux_menuconfig:
178178
.PHONY: linux
179179
linux $(KERNEL_IMAGE): $(LINUX_CONFIG) | $(CLANG_DIR)
180180
+ $(LINUX_MAKE)
181+
# Older versions of Linux don't have this script
182+
ifneq (,$(wildcard ./.env))
181183
$(LINUX_SRC)/scripts/clang-tools/gen_compile_commands.py -d $(LINUX_OUT)
184+
endif
185+
182186

183187
.PHONY: linux_modules
184188
linux_modules $(LINUX_OUT_MODULES_DEP): $(KERNEL_IMAGE)

0 commit comments

Comments
 (0)