blob: 266656db062f2f2cd0aeae1c25cb3ec090763413 (
plain)
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
32
33
34
35
36
|
#! /bin/sh
set -e
if [ "$1" = configure ]; then
files=$(dpkg -L lib@PVER@-dbg@HOST_QUAL@ | sed -n '/^\/usr\/lib\/@PVER@\/.*\.py$/p')
if [ -n "$files" ]; then
/usr/bin/@PVER@ -E -S /usr/lib/@PVER@/py_compile.py $files
if grep -sq '^byte-compile[^#]*optimize' /etc/python/debian_config; then
/usr/bin/@PVER@ -E -S -O /usr/lib/@PVER@/py_compile.py $files
fi
else
echo >&2 "@PVER@-dbg: can't get files for byte-compilation"
fi
if [ -d /usr/include/@PVER@_d ] && [ ! -h /usr/include/@PVER@_d ]; then
if rmdir /usr/include/@PVER@_d 2> /dev/null; then
ln -sf @PVER@dmu /usr/include/@PVER@_d
else
echo >&2 "WARNING: non-empty directory on upgrade: /usr/include/@PVER@_d"
ls -l /usr/include/@PVER@_d
fi
fi
if [ -d /usr/lib/@PVER@/config_d ] && [ ! -h /usr/lib/@PVER@/config_d ]; then
if rmdir /usr/lib/@PVER@/config_d 2> /dev/null; then
ln -sf config-dmu /usr/lib/@PVER@/config_d
else
echo >&2 "WARNING: non-empty directory on upgrade: /usr/lib/@PVER@/config_d"
ls -l /usr/lib/@PVER@/config_d
fi
fi
fi
#DEBHELPER#
exit 0
|