summaryrefslogtreecommitdiff
path: root/Makefile
diff options
context:
space:
mode:
authorBent Bisballe Nyeng <deva@aasimon.org>2021-06-19 11:58:12 +0200
committerBent Bisballe Nyeng <deva@aasimon.org>2021-06-19 11:58:12 +0200
commit9fe6626a63718635cca6ce8920e1669d099d46a7 (patch)
treea63b415b0f8a9c2a97ab703234214b6fa7d61eb8 /Makefile
parenta2be8eba3aaf11a9a73092793d27d6d46b4270cd (diff)
Make self-aware (and recompile/re-launch as needed)
Diffstat (limited to 'Makefile')
-rw-r--r--Makefile8
1 files changed, 6 insertions, 2 deletions
diff --git a/Makefile b/Makefile
index af29818..507d841 100644
--- a/Makefile
+++ b/Makefile
@@ -1,10 +1,11 @@
-all: libcppbuild.a
+all: libcppbuild.a cppbuild
SRC = \
libcppbuild.cc \
task_cc.cc \
task_ld.cc \
task_ar.cc \
+ task_so.cc \
task.cc \
execute.cc \
@@ -18,5 +19,8 @@ CXXFLAGS = -g -O3 -std=c++17 -I.
libcppbuild.a: $(OBJ)
ar rcs $@ $(OBJ)
+cppbuild: cppbuild.cc libcppbuild.a
+ g++ $(CXXFLAGS) -pthread cppbuild.cc libcppbuild.a -o $@
+
clean:
- rm -f libcppbuild.a $(OBJ)
+ rm -f libcppbuild.a $(OBJ) cppbuild