forked from bonsai/harakit
Merge branch 'manpage-install'
This commit is contained in:
commit
9093b06166
5
Makefile
5
Makefile
@ -17,6 +17,8 @@
|
|||||||
DESTDIR ?= dist
|
DESTDIR ?= dist
|
||||||
PREFIX ?= /usr/local
|
PREFIX ?= /usr/local
|
||||||
|
|
||||||
|
MANDIR != [ $(PREFIX) = / ] && printf '/usr/share/man\n' \
|
||||||
|
|| printf '/share/man\n'
|
||||||
SYSEXITS != printf '\043include <sysexits.h>\n' | cpp -M - | sed 's/ /\n/g' \
|
SYSEXITS != printf '\043include <sysexits.h>\n' | cpp -M - | sed 's/ /\n/g' \
|
||||||
| sed -n 's/sysexits\.h//p' || printf 'include\n'
|
| sed -n 's/sysexits\.h//p' || printf 'include\n'
|
||||||
|
|
||||||
@ -42,7 +44,7 @@ clean:
|
|||||||
dist: all
|
dist: all
|
||||||
mkdir -p $(DESTDIR)/$(PREFIX)/bin $(DESTDIR)/$(PREFIX)/share/man/man1
|
mkdir -p $(DESTDIR)/$(PREFIX)/bin $(DESTDIR)/$(PREFIX)/share/man/man1
|
||||||
cp build/bin/* $(DESTDIR)/$(PREFIX)/bin
|
cp build/bin/* $(DESTDIR)/$(PREFIX)/bin
|
||||||
cp docs/*.1 $(DESTDIR)/$(PREFIX)/share/man/man1
|
cp docs/*.1 $(DESTDIR)/$(PREFIX)/$(MANDIR)/man1
|
||||||
|
|
||||||
.PHONY: install
|
.PHONY: install
|
||||||
install: dist
|
install: dist
|
||||||
@ -102,7 +104,6 @@ mm: build/bin/mm
|
|||||||
build/bin/mm: src/mm.c build
|
build/bin/mm: src/mm.c build
|
||||||
$(CC) $(CFLAGS) -o $@ src/mm.c
|
$(CC) $(CFLAGS) -o $@ src/mm.c
|
||||||
|
|
||||||
|
|
||||||
.PHONY: npc
|
.PHONY: npc
|
||||||
npc: build/bin/npc
|
npc: build/bin/npc
|
||||||
build/bin/npc: src/npc.c build
|
build/bin/npc: src/npc.c build
|
||||||
|
Loading…
Reference in New Issue
Block a user