From 90d64cf1d4f424e787c913bf0cbe801ee10bb45c Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Tim=20K=C3=A4chele?= Date: Fri, 7 Nov 2025 22:50:25 +0100 Subject: [PATCH] Add compile flags makefile rule --- .gitignore | 3 +++ Makefile | 5 ++++- 2 files changed, 7 insertions(+), 1 deletion(-) diff --git a/.gitignore b/.gitignore index 0f7accbf7..dbb3303e3 100644 --- a/.gitignore +++ b/.gitignore @@ -156,3 +156,6 @@ docs/docs/public/c-reference # NPM **/node_modules/**/* + +# Clangd config +compile_flags.txt diff --git a/Makefile b/Makefile index 137f736d9..5a1413dfc 100644 --- a/Makefile +++ b/Makefile @@ -76,7 +76,7 @@ ifeq ($(os),Darwin) clang_tidy = $(llvm_path)/bin/clang-tidy endif -all: templates prism $(exec) $(lib_name) $(static_lib_name) test wasm +all: templates prism $(exec) $(lib_name) $(static_lib_name) test wasm clangd_config $(exec): $(objects) $(cc) $(objects) $(flags) $(ldflags) $(prism_ldflags) -o $(exec) @@ -122,5 +122,8 @@ lint: tidy: $(clang_tidy) $(project_files) -- $(flags) +clangd_config: + @echo "$(flags) $(test_cflags)" | tr ' ' '\n' | sort -u > compile_flags.txt + wasm: cd wasm && make