dracut.sh: always copy prelink files in FIPS mode

regardless of the the prelink={yes|no} switch

(cherry picked from commit 6cd7001b35)
Harald Hoyer 2014-07-08 11:50:04 +02:00
parent 0c81abbe79
commit bb232c88fa
1 changed files with 12 additions and 14 deletions

View File

@ -1314,20 +1314,18 @@ if [[ $kernel_only != yes ]]; then
fi
fi

if [[ $do_prelink == yes ]]; then
PRELINK_BIN="$(command -v prelink)"
if [[ $UID = 0 ]] && [[ $PRELINK_BIN ]]; then
if [[ $DRACUT_FIPS_MODE ]]; then
dinfo "*** Installing prelink files ***"
inst_multiple -o prelink /etc/prelink.conf /etc/prelink.conf.d/*.conf /etc/prelink.cache
else
dinfo "*** Pre-linking files ***"
inst_multiple -o prelink /etc/prelink.conf /etc/prelink.conf.d/*.conf
chroot "$initdir" "$PRELINK_BIN" -a
rm -f -- "$initdir/$PRELINK_BIN"
rm -fr -- "$initdir"/etc/prelink.*
dinfo "*** Pre-linking files done ***"
fi
PRELINK_BIN="$(command -v prelink)"
if [[ $UID = 0 ]] && [[ $PRELINK_BIN ]]; then
if [[ $DRACUT_FIPS_MODE ]]; then
dinfo "*** Installing prelink files ***"
inst_multiple -o prelink /etc/prelink.conf /etc/prelink.conf.d/*.conf /etc/prelink.cache
elif [[ $do_prelink == yes ]]; then
dinfo "*** Pre-linking files ***"
inst_multiple -o prelink /etc/prelink.conf /etc/prelink.conf.d/*.conf
chroot "$initdir" "$PRELINK_BIN" -a
rm -f -- "$initdir/$PRELINK_BIN"
rm -fr -- "$initdir"/etc/prelink.*
dinfo "*** Pre-linking files done ***"
fi
fi