File: perl.postinst

package info (click to toggle)
perl 5.24.1-3+deb9u5
  • links: PTS, VCS
  • area: main
  • in suites: stretch
  • size: 103,716 kB
  • sloc: perl: 559,611; ansic: 293,886; sh: 67,316; pascal: 7,632; cpp: 3,895; makefile: 2,436; xml: 2,410; yacc: 989; sed: 6; lisp: 1
file content (28 lines) | stat: -rw-r--r-- 763 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
28
#!/bin/sh -e

if [ "$1" = configure ]
then
    # The 5.6.0 packages had /usr/share/doc/perl as a symlink to
    # perl-base, now the reverse.
    docs=/usr/share/doc
    if [ -L $docs/perl ] && [ ! -L $docs/perl-base ] && [ -d $docs/perl-base ]
    then
    rm -f $docs/perl
    mv $docs/perl-base $docs/perl
    ln -s perl $docs/perl-base
    fi

    # util-linux has an alternate rename
    update-alternatives --install /usr/bin/rename rename /usr/bin/prename 60 \
    --slave /usr/share/man/man1/rename.1.gz rename.1.gz \
        /usr/share/man/man1/prename.1.gz

    if which dpkg-trigger >/dev/null 2>&1 && \
       [ -n "$2" ] && \
       dpkg --compare-versions "$2" lt 5.24.0
    then
        dpkg-trigger --no-await perl-major-upgrade
    fi
fi

exit 0