Currently, under sysvinit, the psplash screen shows a graphic, a progress
bar, and a textual message just above the progress bar showing the user which
module is currently running during both bootup and shutdown. This way they can
see, roughly, how much time each module takes to run.

Add a knob, default off, so the user can choose whether or not to display the
textual message indicating the currently-running module.

This knob is added as a PACKAGECONFIG to sysvinit:
        verbose-psplash

Signed-off-by: Trevor Woerner <twoer...@gmail.com>
---
 meta/recipes-core/sysvinit/sysvinit/rc          | 4 +++-
 meta/recipes-core/sysvinit/sysvinit/rcS-default | 2 ++
 meta/recipes-core/sysvinit/sysvinit_2.97.bb     | 5 ++++-
 3 files changed, 9 insertions(+), 2 deletions(-)

diff --git a/meta/recipes-core/sysvinit/sysvinit/rc 
b/meta/recipes-core/sysvinit/sysvinit/rc
index c4a2f50f88..53a5ce31d2 100755
--- a/meta/recipes-core/sysvinit/sysvinit/rc
+++ b/meta/recipes-core/sysvinit/sysvinit/rc
@@ -160,7 +160,9 @@ startup() {
                        #
                        [ -f $previous_start ] && [ ! -f $stop ] && continue
                fi
-               psplash-write "MSG $(basename $i .sh | cut -c 4-)" || true
+               if [ x"${PSPLASH_VERBOSITY}" = x"yes" ]; then
+                       psplash-write "MSG $(basename $i .sh | cut -c 4-)" || 
true
+               fi
                case "$runlevel" in
                        0|6)
                                startup $i stop
diff --git a/meta/recipes-core/sysvinit/sysvinit/rcS-default 
b/meta/recipes-core/sysvinit/sysvinit/rcS-default
index e4e5782de5..d3a0f32d2a 100644
--- a/meta/recipes-core/sysvinit/sysvinit/rcS-default
+++ b/meta/recipes-core/sysvinit/sysvinit/rcS-default
@@ -32,3 +32,5 @@ ROOTFS_READ_ONLY=no
 INIT_SYSTEM=sysvinit
 # set psplash fifo directory
 PSPLASH_FIFO_DIR=/mnt
+# set the psplash verbosity (sysvinit)
+PSPLASH_VERBOSITY=#PSPLASH_V#
diff --git a/meta/recipes-core/sysvinit/sysvinit_2.97.bb 
b/meta/recipes-core/sysvinit/sysvinit_2.97.bb
index 98916f7f19..562b20327e 100644
--- a/meta/recipes-core/sysvinit/sysvinit_2.97.bb
+++ b/meta/recipes-core/sysvinit/sysvinit_2.97.bb
@@ -25,6 +25,8 @@ SRC_URI[sha256sum] = 
"2d5996857519bfd8634d2e1debabb3238fb38440f65fbfdc46420ee8bd
 
 S = "${WORKDIR}/sysvinit-${PV}"
 
+PACKAGECONFIG[verbose-psplash] = ",,"
+
 inherit update-alternatives features_check
 DEPENDS_append = " update-rc.d-native base-passwd virtual/crypt"
 do_package_setscene[depends] = "${MLPREFIX}base-passwd:do_populate_sysroot"
@@ -91,7 +93,8 @@ do_install () {
                install -d ${D}${sysconfdir}/rc$level.d
        done
 
-       install -m 0644    ${WORKDIR}/rcS-default       
${D}${sysconfdir}/default/rcS
+       sed -e 
's:#PSPLASH_V#:${@bb.utils.contains("PACKAGECONFIG","verbose-psplash","yes","no",
 d)}:g' ${WORKDIR}/rcS-default > ${D}${sysconfdir}/default/rcS
+       chmod 0644 ${D}${sysconfdir}/default/rcS
        install -m 0755    ${WORKDIR}/rc                ${D}${sysconfdir}/init.d
        install -m 0755    ${WORKDIR}/rcS               ${D}${sysconfdir}/init.d
        install -m 0755    ${WORKDIR}/bootlogd.init     
${D}${sysconfdir}/init.d/bootlogd
-- 
2.30.0.rc0

-=-=-=-=-=-=-=-=-=-=-=-
Links: You receive all messages sent to this group.
View/Reply Online (#146153): 
https://lists.openembedded.org/g/openembedded-core/message/146153
Mute This Topic: https://lists.openembedded.org/mt/79198304/21656
Group Owner: openembedded-core+ow...@lists.openembedded.org
Unsubscribe: https://lists.openembedded.org/g/openembedded-core/unsub 
[arch...@mail-archive.com]
-=-=-=-=-=-=-=-=-=-=-=-

Reply via email to