File: postinst

package info (click to toggle)
yaboot 1.3.16-4
  • links: PTS
  • area: main
  • in suites: jessie, jessie-kfreebsd, wheezy
  • size: 1,508 kB
  • ctags: 3,009
  • sloc: ansic: 10,206; sh: 2,933; asm: 343; makefile: 241
file content (27 lines) | stat: -rw-r--r-- 844 bytes parent folder | download | duplicates (4)
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

set -e

# Backwards compatibility for old upgrades - ofboot.b is obsolete now.
if [ -f /etc/ofboot.b -a ! -f /boot/ofboot.b ] && \
	grep '^[[:space:]]*magicboot[[:space:]]*=[[:space:]]*/boot/ofboot.b' \
		/etc/yaboot.conf >/dev/null 2>/dev/null; then
	ln -s /etc/ofboot.b /boot/ofboot.b
elif [ -L /boot/ofboot.b -a ! -f /boot/ofboot.b ]; then
	rm -f /boot/ofboot.b
fi

if [ -f /usr/lib/yaboot/yaboot -a ! -f /boot/yaboot ] && \
	grep '^[[:space:]]*install[[:space:]]*=[[:space:]]*/boot/yaboot' \
		/etc/yaboot.conf >/dev/null 2>/dev/null; then
	ln -s /usr/lib/yaboot/yaboot /boot/yaboot
elif [ -L /boot/yaboot ]; then
	rm -f /boot/yaboot
fi

if [ "$DEBIAN_FRONTEND" != "noninteractive" ]; then
    echo "The bootblock is not automatically updated by installation of this package;"
    echo "run 'ybin' to update it."
fi

#DEBHELPER#