[oe-commits] [openembedded-core] 16/30: busybox-inittab: minor formatting tweaks

git at git.openembedded.org git at git.openembedded.org
Mon Sep 16 08:55:04 UTC 2019


This is an automated email from the git hooks/post-receive script.

rpurdie pushed a commit to branch master-next
in repository openembedded-core.

commit d1955596080f8261efe3b21c5df005648ce207c9
Author: Andre McCurdy <armccurdy at gmail.com>
AuthorDate: Thu Sep 12 15:56:24 2019 -0700

    busybox-inittab: minor formatting tweaks
    
    Add an empty line to inittab before the line(s) which start getty.
    
    Also cleanup indent in recipe do_install().
    
    Signed-off-by: Andre McCurdy <armccurdy at gmail.com>
    Signed-off-by: Ross Burton <ross.burton at intel.com>
---
 meta/recipes-core/busybox/busybox-inittab_1.31.0.bb | 19 ++++++++++---------
 1 file changed, 10 insertions(+), 9 deletions(-)

diff --git a/meta/recipes-core/busybox/busybox-inittab_1.31.0.bb b/meta/recipes-core/busybox/busybox-inittab_1.31.0.bb
index c347daf..61fb8cb 100644
--- a/meta/recipes-core/busybox/busybox-inittab_1.31.0.bb
+++ b/meta/recipes-core/busybox/busybox-inittab_1.31.0.bb
@@ -13,15 +13,16 @@ do_compile() {
 }
 
 do_install() {
-    install -d ${D}${sysconfdir}
-    install -D -m 0644 ${WORKDIR}/inittab ${D}${sysconfdir}/inittab
-    tmp="${SERIAL_CONSOLES}"
-    for i in $tmp
-    do
-            j=`echo ${i} | sed s/\;/\ /g`
-            id=`echo ${i} | sed -e 's/^.*;//' -e 's/;.*//'`
-            echo "$id::respawn:${base_sbindir}/getty ${j}" >> ${D}${sysconfdir}/inittab
-    done
+	install -d ${D}${sysconfdir}
+	install -D -m 0644 ${WORKDIR}/inittab ${D}${sysconfdir}/inittab
+	tmp="${SERIAL_CONSOLES}"
+	[ -n "$tmp" ] && echo >> ${D}${sysconfdir}/inittab
+	for i in $tmp
+	do
+		j=`echo ${i} | sed s/\;/\ /g`
+		id=`echo ${i} | sed -e 's/^.*;//' -e 's/;.*//'`
+		echo "$id::respawn:${base_sbindir}/getty ${j}" >> ${D}${sysconfdir}/inittab
+	done
 }
 
 # SERIAL_CONSOLES is generally defined by the MACHINE .conf.

-- 
To stop receiving notification emails like this one, please contact
the administrator of this repository.


More information about the Openembedded-commits mailing list