oboeru

a collection of simple, scriptable flashcard programs
git clone anongit@rnpnr.xyz:oboeru.git
Log | Files | Refs | Feed | README | LICENSE

Commit: 752c483204700cae1592000c47d8313a0585e730
Parent: daf8b21c6e1a0c4f8a3f5d9cc11596033704da9b
Author: Randy Palamar
Date:   Thu, 19 Aug 2021 15:27:05 -0600

simplify Makefile

Diffstat:
MMakefile | 20++++++++------------
1 file changed, 8 insertions(+), 12 deletions(-)

diff --git a/Makefile b/Makefile @@ -4,7 +4,9 @@ include config.mk OBOERU_SRC = oboeru.c util.c OBOERU_OBJ = $(OBOERU_SRC:.c=.o) -default: oboeru oboerudata oboeruhttp +BINS = oboeru oboerudata oboeruhttp + +default: $(BINS) config.h: cp config.def.h $@ @@ -22,19 +24,13 @@ oboerudata: oboerudata.go oboeruhttp: oboeruhttp.go go build -ldflags "$(GOLDFLAGS)" $@.go -install: oboeru oboerudata oboeruhttp +install: $(BINS) mkdir -p $(PREFIX)/bin - cp oboeru $(PREFIX)/bin - cp oboerudata $(PREFIX)/bin - cp oboeruhttp $(PREFIX)/bin - chmod 755 $(PREFIX)/bin/oboeru - chmod 755 $(PREFIX)/bin/oboerudata - chmod 755 $(PREFIX)/bin/oboeruhttp + cp $(BINS) $(PREFIX)/bin + chmod 755 $(BINS:%=$(PREFIX)/bin/%) uninstall: - rm $(PREFIX)/bin/oboeru - rm $(PREFIX)/bin/oboerudata - rm $(PREFIX)/bin/oboeruhttp + rm $(BINS:%=$(PREFIX)/bin/%) clean: - rm *.o oboeru oboerudata oboeruhttp + rm *.o $(BINS)