From 7e9f24a7d2a880c03f5c4545d3115d8c3f4bc4ce Mon Sep 17 00:00:00 2001 From: Roland Bauerschmidt Date: Mon, 8 Apr 2002 08:49:42 +0000 Subject: Added first version of debian packaging files. --- debian/fuse-python.postinst | 31 +++++++++++++++++++++++++++++++ 1 file changed, 31 insertions(+) create mode 100644 debian/fuse-python.postinst (limited to 'debian/fuse-python.postinst') diff --git a/debian/fuse-python.postinst b/debian/fuse-python.postinst new file mode 100644 index 0000000..8afbe69 --- /dev/null +++ b/debian/fuse-python.postinst @@ -0,0 +1,31 @@ +#! /bin/sh -e +# +# postinst script for Debian python packages. +# Written 1998 by Gregor Hoffleit . +# Modified 2001 by Matthias Klose + +PACKAGE=`basename $0 .postinst` +PV=`dpkg --listfiles $PACKAGE | sed -n -e '/^\/usr\/lib\/python.*\//{ + s,/usr/lib/python\([0-9][0-9.]*\)/.*,\1,p + q +}'` +PYTHON=python$PV +DIRLIST="/usr/lib/python$PV/site-packages/extension" + +case "$1" in + configure|abort-upgrade|abort-remove|abort-deconfigure) + for i in $DIRLIST ; do + /usr/bin/$PYTHON -O /usr/lib/python$PV/compileall.py -q $i + /usr/bin/$PYTHON /usr/lib/python$PV/compileall.py -q $i + done + ;; + + *) + echo "postinst called with unknown argument \`$1'" >&2 + exit 1 + ;; +esac + +#DEBHELPER# + +exit 0 -- cgit v1.2.3