dracut/0073-30usrmove-usrmove-convert.sh-rename-duplicate-librar.patch
2012-01-26 15:48:52 +01:00

31 lines
1008 B
Diff

From 5ebad51b8461d501613f86bcc46fdda4eddbdaf9 Mon Sep 17 00:00:00 2001
From: Harald Hoyer <harald@redhat.com>
Date: Thu, 26 Jan 2012 15:37:50 +0100
Subject: [PATCH] 30usrmove/usrmove-convert.sh: rename duplicate libraries
ldconfig does not ignore the duplicate leftover libs with a .usrmove~
suffix, so we rename ".so" to "_so".
---
modules.d/30usrmove/usrmove-convert.sh | 8 ++++++++
1 files changed, 8 insertions(+), 0 deletions(-)
diff --git a/modules.d/30usrmove/usrmove-convert.sh b/modules.d/30usrmove/usrmove-convert.sh
index 8a623b3..cb93993 100755
--- a/modules.d/30usrmove/usrmove-convert.sh
+++ b/modules.d/30usrmove/usrmove-convert.sh
@@ -141,6 +141,14 @@ for dir in bin sbin lib lib64; do
&& rm -rf "$ROOT/${dir}.usrmove-old~" || :
done
+for dir in lib lib64; do
+ [[ -d "$ROOT/$dir" ]] || continue
+ for lib in "$ROOT"/usr/${dir}/lib*.so*.usrmove~; do
+ [[ -f $lib ]] || continue
+ mv $lib ${lib/.so/_so}
+ done
+done
+
set +e
echo "Run ldconfig."