2024-11-30 12:02:01 +01:00
|
|
|
# DESTDIR envvar is a way to install the application in a different root (for building packages for example).
|
2024-12-01 21:43:52 +01:00
|
|
|
PREFIX ?= /usr/local
|
2024-11-30 12:02:01 +01:00
|
|
|
BINDIR ?= $(PREFIX)/bin
|
|
|
|
SHAREDIR ?= $(PREFIX)/share
|
|
|
|
DOCDIR ?= $(SHAREDIR)/doc/authd
|
|
|
|
MANDIR ?= $(SHAREDIR)/man
|
|
|
|
|
2024-12-01 00:42:38 +01:00
|
|
|
install-authd: build-server ; install -D -m 555 ./bin/authd $(DESTDIR)$(BINDIR)/authd
|
|
|
|
install-authc: build-client ; install -D -m 555 ./bin/authc $(DESTDIR)$(BINDIR)/authc
|
2024-11-30 12:02:01 +01:00
|
|
|
install-binaries: install-authd install-authc
|
|
|
|
|
2024-12-02 17:18:16 +01:00
|
|
|
gz-man-authd:; gzip -k --best ./man/authd.1
|
|
|
|
gz-man-authc:; gzip -k --best ./man/authc.1
|
2024-12-01 21:43:52 +01:00
|
|
|
|
2024-12-02 17:18:16 +01:00
|
|
|
install-man-authd: gz-man-authd ; install -D -m 444 ./man/authd.1.gz $(DESTDIR)$(MANDIR)/man1/authd.1.gz
|
|
|
|
install-man-authc: gz-man-authc ; install -D -m 444 ./man/authc.1.gz $(DESTDIR)$(MANDIR)/man1/authc.1.gz
|
2024-11-30 12:02:01 +01:00
|
|
|
install-man: install-man-authd install-man-authc
|
|
|
|
|
|
|
|
doc:; crystal docs
|
2024-12-01 00:42:38 +01:00
|
|
|
install-dev-doc: doc ; install -D docs/ $(DESTDIR)$(DOCDIR)
|
2024-11-30 12:02:01 +01:00
|
|
|
|
|
|
|
# By default, dev documentation isn't installed.
|
|
|
|
install: install-binaries install-man #install-dev-doc
|