From 190f522242b2e91eb3213e828a26886aa7847f3a Mon Sep 17 00:00:00 2001 From: Julian Hurst Date: Tue, 3 Dec 2024 18:47:51 +0100 Subject: Refactor and add tests Folders need to have 'sensible' names for hare test to detect them. --- Makefile | 27 +++++++++++++++++++++++++++ 1 file changed, 27 insertions(+) create mode 100644 Makefile (limited to 'Makefile') diff --git a/Makefile b/Makefile new file mode 100644 index 0000000..539e5f0 --- /dev/null +++ b/Makefile @@ -0,0 +1,27 @@ +.POSIX: +.SUFFIXES: +HARE=hare +HAREFLAGS= + +DESTDIR= +PREFIX=/usr/local +BINDIR=$(PREFIX)/bin + +all: example-cmd + +example-cmd: + $(HARE) build $(HAREFLAGS) -o $@ cmd/$@/ + +check: + $(HARE) test $(HAREFLAGS) + +clean: + rm -f example-cmd + +install: + install -Dm755 example-cmd $(DESTDIR)$(BINDIR)/example-cmd + +uninstall: + rm -f $(DESTDIR)$(BINDIR)/example-cmd + +.PHONY: all check clean install uninstall -- cgit v1.2.3