File: python2.1-unit.postinst

package info (click to toggle)
python-unit 1.4.1-3
  • links: PTS
  • area: main
  • in suites: woody
  • size: 300 kB
  • ctags: 368
  • sloc: python: 844; makefile: 75; sh: 42
file content (27 lines) | stat: -rw-r--r-- 597 bytes parent folder | download
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
#! /bin/sh -e
#
# postinst script for Debian python packages.
# Written 1998 by Gregor Hoffleit <flight@debian.org>.
#

VERSION=2.1
PACKAGE=python$VERSION-unit
DIRLIST="/usr/lib/python$VERSION/site-packages"

case "$1" in
    configure|abort-upgrade|abort-remove|abort-deconfigure)
        for i in $DIRLIST ; do
            python$VERSION -O /usr/lib/python$VERSION/compileall.py -q $i
            python$VERSION /usr/lib/python$VERSION/compileall.py -q $i
        done
    ;;

    *)
        echo "postinst called with unknown argument \`$1'" >&2
        exit 1
    ;;
esac

#DEBHELPER#

exit 0