aboutsummaryrefslogtreecommitdiff
path: root/Makefile
diff options
context:
space:
mode:
Diffstat (limited to 'Makefile')
-rw-r--r--Makefile15
1 files changed, 15 insertions, 0 deletions
diff --git a/Makefile b/Makefile
new file mode 100644
index 0000000..e86f7fa
--- /dev/null
+++ b/Makefile
@@ -0,0 +1,15 @@
+CXX := g++
+CXXFLAGS := -g -O0 -Wall -Wextra -I.
+
+example/test: example/test.cc lib/thread_create.s lib/matcha.h
+ $(CXX) -o $@ $^ $(CXXFLAGS)
+
+fmt:
+ fd --type f '.+.h$$|.+.cc$$' --exec clang-format -i {}
+
+gdb: example/test
+ which cgdb && cgdb -x util.gdb -ex 'start' example/test \
+ || gdb -x util.gdb -ex 'start' example/test
+
+clean:
+ rm -f example/test