Blame SOURCES/0195-dracut.sh-always-copy-prelink-files-in-FIPS-mode.patch

712866
From bb232c88fa47ac8970d50dc97affe7cc65bc1ce9 Mon Sep 17 00:00:00 2001
712866
From: Harald Hoyer <harald@redhat.com>
712866
Date: Tue, 8 Jul 2014 11:50:04 +0200
712866
Subject: [PATCH] dracut.sh: always copy prelink files in FIPS mode
712866
712866
regardless of the the prelink={yes|no} switch
712866
712866
(cherry picked from commit 6cd7001b35c66a12787bc0943b9a7e83a3d443c0)
712866
---
712866
 dracut.sh | 26 ++++++++++++--------------
712866
 1 file changed, 12 insertions(+), 14 deletions(-)
712866
712866
diff --git a/dracut.sh b/dracut.sh
5c6c2a
index 705f090a..79974286 100755
712866
--- a/dracut.sh
712866
+++ b/dracut.sh
712866
@@ -1314,20 +1314,18 @@ if [[ $kernel_only != yes ]]; then
712866
     fi
712866
 fi
712866
 
712866
-if [[ $do_prelink == yes ]]; then
712866
-    PRELINK_BIN="$(command -v prelink)"
712866
-    if [[ $UID = 0 ]] && [[ $PRELINK_BIN ]]; then
712866
-        if [[ $DRACUT_FIPS_MODE ]]; then
712866
-            dinfo "*** Installing prelink files ***"
712866
-            inst_multiple -o prelink /etc/prelink.conf /etc/prelink.conf.d/*.conf /etc/prelink.cache
712866
-        else
712866
-            dinfo "*** Pre-linking files ***"
712866
-            inst_multiple -o prelink /etc/prelink.conf /etc/prelink.conf.d/*.conf
712866
-            chroot "$initdir" "$PRELINK_BIN" -a
712866
-            rm -f -- "$initdir/$PRELINK_BIN"
712866
-            rm -fr -- "$initdir"/etc/prelink.*
712866
-            dinfo "*** Pre-linking files done ***"
712866
-        fi
712866
+PRELINK_BIN="$(command -v prelink)"
712866
+if [[ $UID = 0 ]] && [[ $PRELINK_BIN ]]; then
712866
+    if [[ $DRACUT_FIPS_MODE ]]; then
712866
+        dinfo "*** Installing prelink files ***"
712866
+        inst_multiple -o prelink /etc/prelink.conf /etc/prelink.conf.d/*.conf /etc/prelink.cache
712866
+    elif [[ $do_prelink == yes ]]; then
712866
+        dinfo "*** Pre-linking files ***"
712866
+        inst_multiple -o prelink /etc/prelink.conf /etc/prelink.conf.d/*.conf
712866
+        chroot "$initdir" "$PRELINK_BIN" -a
712866
+        rm -f -- "$initdir/$PRELINK_BIN"
712866
+        rm -fr -- "$initdir"/etc/prelink.*
712866
+        dinfo "*** Pre-linking files done ***"
712866
     fi
712866
 fi
712866