aboutsummaryrefslogtreecommitdiffstats
path: root/systemd/mandriva-boot-links
blob: 50ecc71c41c8217e595f9ac06816c9d63eb676ee (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
#!/bin/sh

uname_r=$(uname -r)

# Adjust symlinks as necessary in /boot to keep system services from
# spewing messages about mismatched System maps and so on.
if [ -L /boot/System.map -a -r /boot/System.map-$uname_r -a \
        ! /boot/System.map -ef /boot/System.map-$uname_r ] ; then
        ln -s -f System.map-$uname_r /boot/System.map
fi
if [ ! -e /boot/System.map -a -r /boot/System.map-$uname_r ] ; then
        ln -s -f System.map-$uname_r /boot/System.map
fi

# Adjust symlinks as necessary in /boot to have the default config
if [ -L /boot/config -a -r /boot/config-$uname_r ] ; then
        ln -sf config-$uname_r /boot/config
fi
if [ ! -e /boot/config -a -r /boot/config-$uname_r ] ; then
        ln -sf config-$uname_r /boot/config
fi