diff options
author | Cameron Katri <me@cameronkatri.com> | 2021-03-31 08:44:31 -0400 |
---|---|---|
committer | Cameron Katri <me@cameronkatri.com> | 2021-03-31 08:44:31 -0400 |
commit | 81fec145b9975521418e33a45812437a4b409f8b (patch) | |
tree | 3b2273f3e69ca3b4f651805987ce481245a875a2 /Makefile | |
parent | 070c02351eb61ec65f5d694adce91aca5e1b8487 (diff) | |
download | bsd-progress-81fec145b9975521418e33a45812437a4b409f8b.tar.gz bsd-progress-81fec145b9975521418e33a45812437a4b409f8b.tar.zst bsd-progress-81fec145b9975521418e33a45812437a4b409f8b.zip |
New upstream version 9.99.81
Diffstat (limited to 'Makefile')
-rw-r--r-- | Makefile | 31 |
1 files changed, 31 insertions, 0 deletions
diff --git a/Makefile b/Makefile new file mode 100644 index 0000000..cc9c47d --- /dev/null +++ b/Makefile @@ -0,0 +1,31 @@ +# $NetBSD: Makefile,v 1.2 2003/01/22 02:56:30 lukem Exp $ + +PROG= progress +SRCS= progress.c progressbar.c strsuftoll.c + + +CPPFLAGS +=-Iinclude -DSTANDALONE_PROGRESS +UNAME ?= $(shell uname) +PREFIX ?= /usr +PROG_PREFIX ?= bsd- + +ifeq ($(UNAME), Linux) +ifeq ($(shell pkg-config libbsd-overlay && echo 1),1) + CPPFLAGS+=$(shell pkg-config libbsd-overlay --cflags) + LDFLAGS+=$(shell pkg-config libbsd-overlay --libs) +endif # ($(shell pkg-config libbsd-overlay && echo 1),1) +endif # ($(UNAME), Linux) + +all: $(PROG) + +$(PROG): $(SRCS:%.c=%.o) + $(CC) $(LDFLAGS) -o $@ $^ + +install: $(PROG) progress.1 + install -Dm755 $(PROG) $(DESTDIR)$(PREFIX)/bin/$(PROG_PREFIX)$(PROG) + install -Dm644 progress.1 $(DESTDIR)$(PREFIX)/share/man/man1/$(PROG_PREFIX)progress.1 + +clean: + rm -f *.o $(PROG) + +.PHONY: all install clean |