File: JB-bin.prerm.in

package info (click to toggle)
sun-java6 6-26-0lenny1
  • links: PTS, VCS
  • area: non-free
  • in suites: lenny
  • size: 167,260 kB
  • ctags: 111
  • sloc: sh: 649,491; makefile: 802
file content (31 lines) | stat: -rw-r--r-- 718 bytes parent folder | download | duplicates (2)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
#!/bin/sh -e

basedir=/@basedir@
basediralias=/@basediralias@
jar_packs='@jre_packs@'
jre_tools='@jre_tools@'

for i in $jar_packs; do
    jar=$(echo $i | sed 's/\.pack$/.jar/')
    rm -f $basedir/$jar
done

rm -f $basedir/jre/lib/@archdir@/client/classes.jsa

if [ "$1" = "remove" ] || [ "$1" = "deconfigure" ]; then
    for i in $jre_tools; do
	update-alternatives --remove $i $basediralias/jre/bin/$i
    done

    if which update-binfmts >/dev/null; then
	# try to remove and ignore the error
	if [ -e /var/lib/binfmts/@basename@ ]; then
	    update-binfmts --package @basename@ \
		--remove jar /usr/bin/jexec || true
	fi
    fi

    update-alternatives --remove jexec $basediralias/jre/lib/jexec
fi

#DEBHELPER#