summaryrefslogtreecommitdiff
path: root/debian/sendmail-bin.preinst.in
blob: b245a3bb9d9b7f26662b767cdbfbb0835b558f00 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
#!/bin/sh
set -e;

# do we have debconf?
if [ -f /usr/share/debconf/confmodule ]; then
	DEBCONF=true;
	. /usr/share/debconf/confmodule;
else
	DEBCONF='';
	fi;

if [ "$1" = "upgrade" ]; then
    	# DPKG doesn't overwrite directories with symlinks...
		rm -rf @libdir@/sendmail 2>/dev/null || true;

		# Prevent cronjob from running during upgrade...
		if [ -f /etc/cron.d/sendmail ]; then
			echo "#preinst" > @sysconfdir@/cron.d/sendmail;
			fi;
fi

#DEBHELPER#