Skip to content

Commit

Permalink
Add Makefile for auto-formatting
Browse files Browse the repository at this point in the history
  • Loading branch information
alanjian85 committed May 15, 2024
1 parent bcda7b8 commit 83d6901
Showing 1 changed file with 17 additions and 0 deletions.
17 changes: 17 additions & 0 deletions Makefile
Original file line number Diff line number Diff line change
@@ -0,0 +1,17 @@
all: build/karg

clean:
@rm -rf build

fmt:
@clang-format -i $(shell find -not -path "./build/*" -name "*.[ch]")

build:
@mkdir build
@cmake -B build -D CMAKE_TOOLCHAIN_FILE=$(CMAKE_TOOLCHAIN_FILE) \
-D LIBC_INCLUDE=$(LIBC_INCLUDE) -D LUA_INCLUDE=$(LUA_INCLUDE)

FORCE:

build/karg: FORCE | build
@cmake --build build

0 comments on commit 83d6901

Please sign in to comment.