set -e
	update-alternatives --install /usr/sbin/halt halt /usr/bin/systemctl 300
	update-alternatives --install /usr/sbin/reboot reboot /usr/bin/systemctl 300
	update-alternatives --install /usr/sbin/shutdown shutdown /usr/bin/systemctl 300
	update-alternatives --install /usr/sbin/poweroff poweroff /usr/bin/systemctl 300
	update-alternatives --install /usr/sbin/runlevel runlevel /usr/bin/systemctl 300
	update-alternatives --install /etc/resolv.conf resolv-conf /etc/resolv-conf.systemd 50
	if true; then
		sed -e '/^hosts:/s/\s*\<myhostname\>//' \
			-e 's/\(^hosts:.*\)\(\<files\>\)\(.*\)\(\<dns\>\)\(.*\)/\1\2 myhostname \3\4\5/' \
			-i $D/etc/nsswitch.conf
	fi
	if true; then
		sed -e 's#\(^passwd:.*\)#\1 systemd#' \
			-e 's#\(^group:.*\)#\1 systemd#' \
			-e 's#\(^shadow:.*\)#\1 systemd#' \
			-i $D/etc/nsswitch.conf
	fi
