Check for file from real_init=FILE rather than /sbin/init (bug #437080)
authorDustin Frisch <dustin.frisch@gmail.com>
Wed, 3 Oct 2012 16:20:16 +0000 (18:20 +0200)
committerSebastian Pipping <sebastian@pipping.org>
Wed, 3 Oct 2012 16:21:09 +0000 (18:21 +0200)
ChangeLog
defaults/linuxrc

index 47a81ea237319a9ae1ff69cf0858486a2c26e3c5..d4530803c38ec32bbd001d0d393fd98707d63d77 100644 (file)
--- a/ChangeLog
+++ b/ChangeLog
@@ -5,6 +5,10 @@
 # Distributed under the GPL v2
 # $Id$
 
+  03 Oct 2012; Dustin Frisch <dustin.frisch@gmail.com> defaults/linuxrc:
+  With boot parameter real_init=/foo look for ${NEW_ROOT}/foo, not
+  ${NEW_ROOT}/sbin/init (bug #437080)
+
   23 Sep 2012; Sebastian Pipping <sping@gentoo.org> gen_initramfs.sh:
   Append e2fsck and mke2fs to initramfs. Original patch by Rick Farina
 
index 4a12c21cddd682cf6b19dddc72f0623c705d17c7..d6766b883517b8c25c3fee07c7d6f4235748d843 100755 (executable)
@@ -623,7 +623,7 @@ do
                # else not a good root and start over.
                if [ "$?" = '0' ]
                then
-                       if [ -d ${NEW_ROOT}/dev -a -x ${NEW_ROOT}/sbin/init ] || [ "${REAL_ROOT}" = "/dev/nfs" ]
+                       if [ -d ${NEW_ROOT}/dev -a -x "${NEW_ROOT}${REAL_INIT:-/sbin/init}" ] || [ "${REAL_ROOT}" = "/dev/nfs" ]
                        then
                                break
                        else