]> code.ossystems Code Review - openembedded-core.git/commitdiff
image.bbclass: replace rootfs with /dev/root
authorChen Qi <Qi.Chen@windriver.com>
Thu, 27 Mar 2014 02:29:07 +0000 (10:29 +0800)
committerRichard Purdie <richard.purdie@linuxfoundation.org>
Thu, 27 Mar 2014 09:41:04 +0000 (09:41 +0000)
Replace 'rootfs' with '/dev/root' in read_only_rootfs_hook function
to match the latest change in fstab file from the base-files recipe.

The related commit is as follows.

commit e8bc7a136a81a0d8df2d32dfba0920c1b2835141
    base-files: use /dev/root in /etc/fstab for systemd support

Signed-off-by: Chen Qi <Qi.Chen@windriver.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
meta/classes/image.bbclass

index b0639ae33febb706287ea57ed74d7dfbfa7dfc2f..29309f55cb0c39ef1444a0b683abd0d86e69cd6e 100644 (file)
@@ -175,7 +175,7 @@ do_rootfs[umask] = "022"
 read_only_rootfs_hook () {
        if ${@base_contains("DISTRO_FEATURES", "sysvinit", "true", "false", d)}; then
                # Tweak the mount option and fs_passno for rootfs in fstab
-               sed -i -e '/^[#[:space:]]*rootfs/{s/defaults/ro/;s/\([[:space:]]*[[:digit:]]\)\([[:space:]]*\)[[:digit:]]$/\1\20/}' ${IMAGE_ROOTFS}/etc/fstab
+               sed -i -e '/^[#[:space:]]*\/dev\/root/{s/defaults/ro/;s/\([[:space:]]*[[:digit:]]\)\([[:space:]]*\)[[:digit:]]$/\1\20/}' ${IMAGE_ROOTFS}/etc/fstab
                # Change the value of ROOTFS_READ_ONLY in /etc/default/rcS to yes
                if [ -e ${IMAGE_ROOTFS}/etc/default/rcS ]; then
                        sed -i 's/ROOTFS_READ_ONLY=no/ROOTFS_READ_ONLY=yes/' ${IMAGE_ROOTFS}/etc/default/rcS