dnsmanager/mk/install.mk

27 lines
1.2 KiB
Makefile

# DESTDIR envvar is a way to install the application in a different root (for building packages for example).
PREFIX ?= /usr/local
BINDIR ?= $(PREFIX)/bin
SHAREDIR ?= $(PREFIX)/share
DOCDIR ?= $(SHAREDIR)/doc/dnsmanagerd
MANDIR ?= $(SHAREDIR)/man
install-dnsmanagerd: build-server
$(Q)install -D -m 555 ./bin/dnsmanagerd $(DESTDIR)$(BINDIR)/dnsmanagerd
install-dnsmanagerctl: build-client
$(Q)install -D -m 555 ./bin/dnsmanagerctl $(DESTDIR)$(BINDIR)/dnsmanagerctl
install-binaries: install-dnsmanagerd install-dnsmanagerctl
gz-man-dnsmanagerctl:; $(Q)gzip -k -f --best ./man/dnsmanagerctl.1
gz-man-dnsmanagerd:; $(Q)gzip -k -f --best ./man/dnsmanagerd.1
install-man-dnsmanagerd: gz-man-dnsmanagerd
$(Q)install -D -m 444 ./man/dnsmanagerd.1.gz $(DESTDIR)$(MANDIR)/man1/dnsmanagerd.1.gz
install-man-dnsmanagerctl: gz-man-dnsmanagerctl
$(Q)install -D -m 444 ./man/dnsmanagerctl.1.gz $(DESTDIR)$(MANDIR)/man1/dnsmanagerctl.1.gz
install-man: install-man-dnsmanagerd install-man-dnsmanagerctl
install-dev-doc: doc ; install -D docs/ $(DESTDIR)$(DOCDIR)
# By default, dev documentation isn't installed.
install: install-binaries install-man #install-dev-doc