File: atm-tools.postinst

package info (click to toggle)
linux-atm 1%3A2.5.1-1.5
  • links: PTS
  • area: main
  • in suites: jessie, jessie-kfreebsd, wheezy
  • size: 7,512 kB
  • ctags: 4,814
  • sloc: ansic: 36,137; sh: 9,573; yacc: 1,193; lex: 556; makefile: 325; perl: 186; awk: 1
file content (30 lines) | stat: -rw-r--r-- 643 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
29
30
#!/bin/sh -e

upgrade_quirks() {
  [ "$2" ] || return 0

  dpkg --compare-versions $2 lt 1:2.5.1-1.3 || return 0

  if [ -f /lib/init/rw/sendsigs.omit.d/atmarpd ]; then
    mv /lib/init/rw/sendsigs.omit.d/atmarpd /run/sendsigs.omit.d/atmarpd
  fi
  rm -f /etc/rc0.d/K*atm /etc/rc6.d/K*atm

  # replaced by a symlink in 1:2.5.1-1.3, but dpkg fails to do it on upgrades
  if [ -d /usr/share/doc/atm-tools -a ! -L /usr/share/doc/atm-tools ] ; then
    rmdir /usr/share/doc/atm-tools
    ln -s /usr/share/doc/libatm1 /usr/share/doc/atm-tools
  fi

  return 0
}

case "$1" in
    configure)
    upgrade_quirks "$@"
    ;;
esac

#DEBHELPER#

exit 0