change makefile to use git-buildpackage for debian packaging
[monkeysphere.git] / packaging / debian / monkeysphere.prerm
1 #!/bin/sh -e
2
3 # prerm script for monkeysphere
4
5 # the only thing we're doing here is making sure that the local
6 # administrator is not trying to downgrade to a version below 0.23,
7 # since there was such a major reorganization of system data during
8 # the transition to 0.23.
9
10 # Author: Daniel Kahn Gillmor <dkg@fifthhorseman.net>
11 # Copyright 2009
12
13 set -e
14
15 case "$1" in
16     upgrade)
17         if dpkg --compare-versions "$2" lt 0.23 ; then
18             cat >&2 <<EOF
19
20 Downgrading the monkeysphere to a version earlier than 0.23 can have
21 BAD CONSEQUENCES, including potentially locking you out of the system.
22 Downgrading in this fashion is NOT SUPPORTED.
23
24 EOF
25
26             exit 1
27         fi
28     ;;
29 esac
30
31 # dh_installdeb will replace this with shell code automatically
32 # generated by other debhelper scripts.
33
34 #DEBHELPER#
35
36 exit 0