dnsmanager/mk/install.mk
2024-12-02 17:21:08 +01:00

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-dnsmanager-client: build-client
$(Q)install -D -m 555 ./bin/dnsmanager-client $(DESTDIR)$(BINDIR)/dnsmanager-client
install-binaries: install-dnsmanagerd install-dnsmanager-client
gz-man-dnsmanager-client:; $(Q)gzip -k --best ./man/dnsmanager-client.1
gz-man-dnsmanagerd:; $(Q)gzip -k --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-dnsmanager-client: gz-man-dnsmanager-client
$(Q)install -D -m 444 ./man/dnsmanager-client.1.gz $(DESTDIR)$(MANDIR)/man1/dnsmanager-client.1.gz
install-man: install-man-dnsmanagerd install-man-dnsmanager-client
install-dev-doc: doc ; install -D docs/ $(DESTDIR)$(DOCDIR)
# By default, dev documentation isn't installed.
install: install-binaries install-man #install-dev-doc