Skip to content

Commit

Permalink
tweak Makefile
Browse files Browse the repository at this point in the history
  • Loading branch information
escondida committed Apr 7, 2020
1 parent 4a6ebfc commit a52c0f7
Showing 1 changed file with 4 additions and 3 deletions.
7 changes: 4 additions & 3 deletions Makefile
Original file line number Diff line number Diff line change
@@ -1,5 +1,6 @@
CC ?= cc
PREFIX ?= /usr/local
BINDIR ?= $(PREFIX)/bin
DATADIR ?= $(PREFIX)/share
DOCDIR ?= $(DATADIR)/doc
MANDIR ?= $(DATADIR)/man
Expand Down Expand Up @@ -57,9 +58,9 @@ CFLAGS += \

LDFLAGS += -Wl,-z,relro,-z,now,--build-id -pie

all: $(TARGS)
all: flags $(TARGS)

ddate: flags $(OBJS)
ddate: $(OBJS)
@echo $(CC) -o $@ $^
@$(CC) $(CFLAGS) $(LDFLAGS) -o $@ $^

Expand All @@ -76,7 +77,7 @@ flags:

-include $(DEPS)

install: all
install: $(TARGS)
install -D ddate $(DESTDIR)$(BINDIR)/ddate
install -D -m 644 slogans $(DESTDIR)$(DATADIR)/ddate/slogans
install -D -m 644 doc/ddate.1 $(DESTDIR)$(MANDIR)/man1/ddate.1
Expand Down

0 comments on commit a52c0f7

Please sign in to comment.