Skip to content

Commit

Permalink
feat(makefile): add a Makefile in cpp (#13)
Browse files Browse the repository at this point in the history
Co-authored-by: Xwg <[email protected]>
  • Loading branch information
loloxwg and Xwg committed Jun 30, 2023
1 parent 1be72ef commit aa51024
Showing 1 changed file with 18 additions and 0 deletions.
18 changes: 18 additions & 0 deletions cpp/Makefile
Original file line number Diff line number Diff line change
@@ -0,0 +1,18 @@
.PHONY: build clean test format

TEST_THREADS ?= 4

build:
conan install . -if build --build=missing
conan build .

clean:
rm -rf build

test:
conan install . -if build --build=missing
conan build .
cd build && ctest . -j ${TEST_THREADS} --output-on-failure

format:
find ./src -type f ! -name "*.pb.h" -iname *.h -o -iname *.cpp | xargs clang-format -i

0 comments on commit aa51024

Please sign in to comment.