aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorJan Sucan <jan@jansucan.com>2025-02-22 15:36:45 +0100
committerJán Sučan <jan@jansucan.com>2025-02-22 15:38:28 +0100
commit5bbe29d3b8e5c249bb6e05fa46afc5fda1e4c38b (patch)
tree42bea39ffa15c9f45398107302178e7ad7f537b4
parentaae2c5d151be25c1a480c2cbc2906412261f5674 (diff)
makefile: Define all phony targetsmaster
-rw-r--r--Makefile4
-rw-r--r--src/Makefile4
-rw-r--r--tests/Makefile2
3 files changed, 6 insertions, 4 deletions
diff --git a/Makefile b/Makefile
index 8014b02..d085432 100644
--- a/Makefile
+++ b/Makefile
@@ -1,10 +1,10 @@
include config.mk
+.PHONY: all test clean install uninstall
+
all:
$(MAKE) -C src all
-.PHONY: test clean
-
test: all
$(MAKE) -C tests
diff --git a/src/Makefile b/src/Makefile
index 34d7982..b371b09 100644
--- a/src/Makefile
+++ b/src/Makefile
@@ -1,5 +1,7 @@
include ../config.mk
+.PHONY: all clean
+
SOURCES=*.cpp
HEADERS=*.h
@@ -14,7 +16,5 @@ program_info.h:
echo "const std::string PROGRAM_NAME_STR {\"$(PROGRAM_NAME)\"};" >program_info.h
echo "const std::string PROGRAM_VERSION_STR {\"$(PROGRAM_VERSION)\"};" >>program_info.h
-.PHONY: clean
-
clean:
rm -f *.o *~ $(PROGRAM_NAME) program_info.h
diff --git a/tests/Makefile b/tests/Makefile
index f34fb0d..cc92441 100644
--- a/tests/Makefile
+++ b/tests/Makefile
@@ -1,5 +1,7 @@
PROGRAM_EXEC=../src/$(PROGRAM_NAME)
+.PHONY: all
+
all:
for t in [0-9]*.sh ; do \
echo $$t; \