5 [ "$DEBIAN_SCRIPT_DEBUG" ] && set -vx
12 abort-upgrade|abort-remove|abort-deconfigure)
17 echo "postinst called with unknown argument \`$1'" >&2
22 libdir="/usr/lib/jvm/java-6-sun/jre"
24 if [ -x /usr/sbin/chpax ]; then
26 elif [ -x /sbin/chpax ]; then
28 elif uname -r | grep -q grsec; then
29 # no chpax found in default places
30 echo "Warning: Grsecurity kernel detected but no chpax found."
31 echo "Your java applications might not work until you run"
33 echo "chpax -rs $libdir/bin/java"
37 echo "chpax -rs $libdir/bin/\*"
41 if [ ! -x $libdir/bin/java ]; then
42 echo "java not found in $libdir/bin. _Very_ strange."
46 if uname -r | grep -q grsec; then
48 ! $chpax -v $libdir/bin/java | egrep -q "flags for $libdir/bin/java \(...r.s\)"; then
49 $chpax -rs $libdir/bin/java