#!/usr/bin/make -f # -*- makefile -*- # Debian build rules for dma, the DragonFly mail agent DDIR= $(CURDIR)/debian D= $(DDIR)/dma BUILDDEFS= DESTDIR=$D PREFIX=/usr CONFDIR=/etc CFLAGS:= $(shell dpkg-buildflags --get CFLAGS) CPPFLAGS:= $(shell dpkg-buildflags --get CPPFLAGS) LDFLAGS:= $(shell dpkg-buildflags --get LDFLAGS) CONFFILES= dma.conf auth.conf ifneq (,$(filter werror,$(DEB_BUILD_OPTIONS))) CFLAGS+= -Werror endif ifneq (,$(filter nostrip,$(DEB_BUILD_OPTIONS))) export STRIPFLAG= endif ifneq (,$(filter hardening,$(DEB_BUILD_OPTIONS))) export DEB_BUILD_HARDENING=1 else export DEB_BUILD_HARDENING=0 endif export CFLAGS CPPFLAGS LDFLAGS override_dh_auto_build: $(MAKE) -f Makefile ${BUILDDEFS} $(MAKE) -C $(DDIR)/migrate override_dh_auto_clean: $(MAKE) -f Makefile clean $(MAKE) -C $(DDIR)/migrate clean override_dh_auto_install: $(MAKE) -f Makefile ${BUILDDEFS} install install -o root -g mail -m 644 dma.conf $D/etc/dma install -o root -g mail -m 640 auth.conf $D/etc/dma override_dh_fixperms: dh_fixperms -Xusr/sbin/dma -Xusr/lib/dma-mbox-create -Xvar/spool/dma -Xetc/dma override_dh_installchangelogs: dh_installchangelogs -p dma dh_installchangelogs -p dma-migrate debian/migrate/NEWS %: dh $@