forked from pipeseroni/pipes.sh
-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathMakefile
More file actions
48 lines (33 loc) · 933 Bytes
/
Makefile
File metadata and controls
48 lines (33 loc) · 933 Bytes
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
PREFIX=/usr/local
DESTDIR=
INSTDIR=$(DESTDIR)$(PREFIX)
INSTBIN=$(INSTDIR)/bin
INSTMAN=$(INSTDIR)/share/man/man6
SCRIPT=pipes.sh
MANPAGE=$(SCRIPT).6
all:
@echo did nothing. try targets: install, or uninstall.
.PHONY: all
# this target is intended for an HTML version of manpage to be displayed on
# GitHub Pages, so if there is a such named directory, it will also copy the
# generated HTML to the directory.
$(MANPAGE).html: $(MANPAGE)
TZ=UTC scripts/gen-man-html.sh '$^' '$@'
test -d gh-pages && cp -a $@ gh-pages/ || true
clean:
$(RM) $(MANPAGE).html
.PHONY: clean
test:
bats test
.PHONY: test
install:
test -d $(INSTDIR) || mkdir -p $(INSTDIR)
test -d $(INSTBIN) || mkdir -p $(INSTBIN)
test -d $(INSTMAN) || mkdir -p $(INSTMAN)
install -m 0755 $(SCRIPT) $(INSTBIN)
install -m 0644 $(MANPAGE) $(INSTMAN)
.PHONY: install
uninstall:
rm -f $(INSTBIN)/$(SCRIPT)
rm -f $(INSTMAN)/$(MANPAGE)
.PHONY: uninstall