* Newer kernels change the format of /proc/mounts slightly when rootfs is
mounted over NFS.
* Old style:
/dev/root / nfs <options> 0 0
* New style:
<server>:<mount> / nfs <options> 0 0
* The regexp in grep can be simplified and rolled into one, but may become
less strict...
Signed-off-by: Denys Dmytriyenko <denys@ti.com>
Acked-by: Khem Raj <raj.khem@gmail.com>
--- /dev/null
+diff -uNr busybox-1.13.2.orig/examples/udhcp/simple.script busybox-1.13.2/examples/udhcp/simple.script
+--- busybox-1.13.2.orig/examples/udhcp/simple.script 2011-02-23 00:30:32.000000000 -0500
++++ busybox-1.13.2/examples/udhcp/simple.script 2011-02-23 17:05:37.873381763 -0500
+@@ -10,7 +10,12 @@
+
+ # return 0 if root is mounted on a network filesystem
+ root_is_nfs() {
++ # old style mounts
+ grep -qe '^/dev/root.*\(nfs\|smbfs\|ncp\|coda\) .*' /proc/mounts
++ if ! $? ; then
++ # new style mounts
++ grep -qe '^.*:.* / \(nfs\|smbfs\|ncp\|coda\) .*' /proc/mounts
++ fi
+ }
+
+ case "$1" in
--- /dev/null
+diff -uNr busybox-1.13.2.orig/examples/udhcp/simple.script busybox-1.13.2/examples/udhcp/simple.script
+--- busybox-1.13.2.orig/examples/udhcp/simple.script 2011-02-23 00:30:32.000000000 -0500
++++ busybox-1.13.2/examples/udhcp/simple.script 2011-02-23 17:05:37.873381763 -0500
+@@ -10,7 +10,12 @@
+
+ # return 0 if root is mounted on a network filesystem
+ root_is_nfs() {
++ # old style mounts
+ grep -qe '^/dev/root.*\(nfs\|smbfs\|ncp\|coda\) .*' /proc/mounts
++ if ! $? ; then
++ # new style mounts
++ grep -qe '^.*:.* / \(nfs\|smbfs\|ncp\|coda\) .*' /proc/mounts
++ fi
+ }
+
+ case "$1" in
require busybox_1.1x.inc
-PR = "${INC_PR}.3"
+PR = "${INC_PR}.4"
SRC_URI += "\
file://busybox-1.13.2-awk.patch \
require busybox_1.1x.inc
-PR = "${INC_PR}.0"
+PR = "${INC_PR}.1"
SRC_URI += " \
http://busybox.net/downloads/fixes-1.18.3/busybox-1.18.3-buildsys.patch;name=patch01 \
file://fdisk_nios2.patch \
file://udhcpscript.patch \
file://udhcpc-fix-nfsroot.patch \
+ file://udhcpc-new-nfsroot.patch \
file://B921600.patch \
file://get_header_tar.patch \
file://busybox-appletlib-dependency.patch \