aboutsummaryrefslogtreecommitdiff
path: root/Makefile
diff options
context:
space:
mode:
authorjohannst <johannes.stoelp@gmail.com>2020-09-22 23:48:09 +0200
committerjohannst <johannes.stoelp@gmail.com>2020-09-22 23:48:09 +0200
commit33f286000db35fe50639c237caa736deea304585 (patch)
treeddb74ebd1f626b200cbb5050545ded484dde4787 /Makefile
parent488d4c6237c3f713077fe93e2745ba5defde0aa5 (diff)
downloadmatcha-threads-33f286000db35fe50639c237caa736deea304585.tar.gz
matcha-threads-33f286000db35fe50639c237caa736deea304585.zip
split classes into separate files, add arch specific subdir
Diffstat (limited to 'Makefile')
-rw-r--r--Makefile13
1 files changed, 7 insertions, 6 deletions
diff --git a/Makefile b/Makefile
index ec64564..3f89456 100644
--- a/Makefile
+++ b/Makefile
@@ -6,7 +6,8 @@ CXX := g++
CXXFLAGS := -g -O0 -Wall -Wextra -I.
AR := ar
-lib/libmatcha.a: lib/matcha.o lib/thread_create.o lib/matcha.h
+lib/libmatcha.a: lib/compile_guard.o lib/thread.o lib/executor.o lib/arch/x86_64/thread_create.o lib/arch/x86_64/yield.o \
+ lib/thread.h lib/executor.h lib/arch/x86_64/asm.h
$(AR) rcs $@ $(filter %.o,$^)
%.o: %.cc
@@ -18,13 +19,13 @@ lib/libmatcha.a: lib/matcha.o lib/thread_create.o lib/matcha.h
fmt:
fd --type f '.+.h$$|.+.cc$$' --exec clang-format -i {}
-example/test: example/test.o lib/libmatcha.a
+example/demo1: example/demo1.o lib/libmatcha.a
$(CXX) -o $@ $^
-gdb: example/test
- which cgdb && cgdb -x util.gdb -ex 'start' example/test \
- || gdb -x util.gdb -ex 'start' example/test
+gdb: example/demo1
+ which cgdb && cgdb -x util.gdb -ex 'start' example/demo1 \
+ || gdb -x util.gdb -ex 'start' example/demo1
clean:
- rm -f example/test
+ rm -f example/demo1
rm -f **/*.o **/lib*.a