PREFIX  ?= /usr
BINDIR  ?= $(PREFIX)/bin
SBINDIR  ?= $(PREFIX)/sbin
DOCDIR  ?= $(PREFIX)/doc/qmail-utils
SYSCONFDIR ?= /etc


INSTFILES = arregla-queue-qmail mtrack qbonkns qfixq rcptcreate strack trash-clean
DOCFILES = README.morercptto qbonkns.txt qfixq.txt

all: $(INSTFILES)

install-docs:
	install -d $(DESTDIR)/$(DOCDIR)
	cd docs; install -v -g root -o root -m 0644 $(DOCFILES) $(DESTDIR)$(DOCDIR)

install: all install-docs

	install -d $(DESTDIR)/$(SBINDIR)
	install -d $(DESTDIR)/$(BINDIR)
	install -v -g root -o root -m 0755 $(INSTFILES) $(DESTDIR)/$(BINDIR)

