SVN: geninitrd/trunk/geninitrd

glen glen at pld-linux.org
Thu Oct 25 18:31:44 CEST 2007


Author: glen
Date: Thu Oct 25 18:31:44 2007
New Revision: 8874

Modified:
   geninitrd/trunk/geninitrd
Log:
- install all shared libs to /lib
- install /var/lib/multipath/bindings for dm-multipath if present

Modified: geninitrd/trunk/geninitrd
==============================================================================
--- geninitrd/trunk/geninitrd	(original)
+++ geninitrd/trunk/geninitrd	Thu Oct 25 18:31:44 2007
@@ -328,10 +328,9 @@
 
 	local lib libs=$(ldd "$@" | awk '/statically|linux-gate\.so/{next} NF == 2 {print $1} /=/{print $3}' | sort -u)
 	for lib in $libs; do
-		local libdir=/$(echo "$lib" | cut -d/ -f2)/
-		if [ ! -f "$MNTIMAGE$libdir${lib##*/}" ]; then
-			inst_d $libdir
-			inst_exec $lib $libdir
+		if [ ! -f "$MNTIMAGE/lib/${lib##*/}" ]; then
+			inst_d /lib
+			inst_exec $lib /lib
 		fi
 	done
 }
@@ -1234,7 +1233,6 @@
 #! /bin/sh
 mount -t proc none /proc
 if [ "$(awk ' /debuginitrd/  { print "yes"; } ' /proc/cmdline)" = "yes" ]; then
-	export DEBUG=yes
 	set -x
 fi
 umount /proc
@@ -1354,12 +1352,17 @@
 
 initrd_gen_multipath() {
 	inst_d /proc /sys /sbin /lib/udev /etc
+	ln -s lib $MNTIMAGE/lib64
 	inst_exec /sbin/kpartx /sbin
 	inst_exec /sbin/multipath /sbin
 	# for udev callouts
 	inst_exec /sbin/scsi_id /lib/udev
 	inst_exec /sbin/mpath* /sbin
 	inst /etc/multipath.conf /etc
+	if [ -f /var/lib/multipath/bindings ]; then
+		inst_d /var/lib/multipath
+		inst /var/lib/multipath/bindings /var/lib/multipath
+	fi
 
 	cat <<-'EOF' >> "$s"
 	mount -t proc none /proc


More information about the pld-cvs-commit mailing list