#!/usr/bin/make -f # -*- mode: makefile; coding: utf-8 -*- DEB_HOST_ARCH_OS := $(shell dpkg-architecture -qDEB_HOST_ARCH_OS) %: dh $@ --with autoreconf DEB_CONFIGURE_EXTRA_FLAGS := \ --disable-shared \ --without-libcrack \ --without-audit \ --with-libpam \ --enable-shadowgrp \ --enable-man \ --disable-account-tools-setuid \ --with-group-name-max-length=32 \ --without-acl \ --without-attr \ --without-tcb ifneq ($(DEB_BUILD_GNU_TYPE),$(DEB_HOST_GNU_TYPE)) DEB_CONFIGURE_EXTRA_FLAGS += --host=$(DEB_HOST_GNU_TYPE) endif ifeq (illumos,$(DEB_HOST_ARCH_OS)) DEB_CONFIGURE_EXTRA_FLAGS += --enable-utmpx DEB_CONFIGURE_EXTRA_FLAGS += --exec-prefix=/usr endif override_dh_auto_configure: dh_auto_configure -- $(DEB_CONFIGURE_EXTRA_FLAGS) override_dh_install: dh_install ifeq (hurd,$(DEB_HOST_ARCH_OS)) install -d debian/passwd/etc install -c -m 644 debian/login.defs debian/passwd/etc/login.defs else install -d debian/login/etc install -c -m 644 debian/login.defs debian/login/etc/login.defs endif install -c -m 444 debian/securetty.$(DEB_HOST_ARCH_OS) debian/login/etc/securetty install -c -m 644 debian/useradd.default debian/passwd/etc/default/useradd install -d debian/passwd/sbin install -c -m 555 debian/shadowconfig.sh debian/passwd/sbin/shadowconfig override_dh_installpam: dh_installpam -p login dh_installpam -p login --name=su dh_installpam -p passwd --name=passwd dh_installpam -p passwd --name=chfn dh_installpam -p passwd --name=chsh dh_installpam -p passwd --name=chpasswd dh_installpam -p passwd --name=newusers override_dh_fixperms: dh_fixperms chmod u+s debian/login/usr/bin/su chmod u+s debian/login/usr/bin/newgrp chmod u+s debian/passwd/usr/bin/chfn chmod u+s debian/passwd/usr/bin/chsh chmod u+s debian/passwd/usr/bin/gpasswd chmod u+s debian/passwd/usr/bin/passwd chgrp shadow debian/passwd/usr/bin/chage chgrp shadow debian/passwd/usr/bin/expiry chmod g+s debian/passwd/usr/bin/chage chmod g+s debian/passwd/usr/bin/expiry