pm

barely a pack manager
git clone git://z3bra.org/pm
Log | Files | Refs | README | LICENSE

commit 6b12ca0f78ebb93d54b883bc2a49876af4d6ba0a
parent eb8831e065464bf61242657779cde4f6318ee4f7
Author: z3bra <willyatmailoodotorg>
Date:   Sat Jan 23 11:45:14 +0100

Cleanup makefile/config.mk

Diffstat:
config.mk | 6+++---
makefile | 30++++++++++++++----------------
2 files changed, 17 insertions(+), 19 deletions(-)
diff --git a/config.mk b/config.mk @@ -1,9 +1,9 @@ CC = cc -LD = $(CC) +LD = ${CC} PREFIX = /usr/local -MANPREFIX = $(PREFIX)/share/man +MANDIR = ${PREFIX}/man -CFLAGS = -Wall -Wextra -g +CFLAGS = -Wall -Wextra -pedantic LDFLAGS = -static LIBS = -larchive -lbz2 -lz diff --git a/makefile b/makefile @@ -1,25 +1,23 @@ include config.mk -BIN = pm - -all: $(BIN) +all: pm .c: $(CC) $(CFLAGS) $< $(LDFLAGS) $(LIBS) -o $@ clean: - rm -f $(BIN) + rm -f pm -install: $(BIN) +install: pm pm.1 pack.5 mkdir -p $(DESTDIR)$(PREFIX)/bin - mkdir -p $(DESTDIR)$(MANPREFIX)/man1 - mkdir -p $(DESTDIR)$(MANPREFIX)/man5 - cp $(BIN) $(DESTDIR)$(PREFIX)/bin/$(BIN) - cp $(BIN).1 $(DESTDIR)$(MANPREFIX)/man1/ - cp pack.5 $(DESTDIR)$(MANPREFIX)/man5/ - chmod 755 $(DESTDIR)$(PREFIX)/bin/$(BIN) + mkdir -p $(DESTDIR)$(MANDIR)/man1 + mkdir -p $(DESTDIR)$(MANDIR)/man5 + cp pm $(DESTDIR)$(PREFIX)/bin/pm + cp pm.1 $(DESTDIR)$(MANDIR)/man1/ + cp pack.5 $(DESTDIR)$(MANDIR)/man5/ + chmod 755 $(DESTDIR)$(PREFIX)/bin/pm -uninstall: $(BIN) - rm $(DESTDIR)$(PREFIX)/bin/$(BIN) - rm $(DESTDIR)$(MANPREFIX)/man1/$(BIN).1 - rm $(DESTDIR)$(MANPREFIX)/man5/pack.5- \ No newline at end of file +uninstall: + rm $(DESTDIR)$(PREFIX)/bin/pm + rm $(DESTDIR)$(MANDIR)/man1/pm.1 + rm $(DESTDIR)$(MANDIR)/man5/pack.5+ \ No newline at end of file