Skip to contentSkip to conversation

psplash: consider the situation of psplash not exist for systemd

PATCH New Chen Qi 1 participant 1 message Dec 1, 2022

lore
Share & tools
lore

Chen Qi

author
#0 lore raw

PATCH 1/1 psplash: consider the situation of psplash not exist for systemd

In current psplash framework, the psplash might not exist at all. For example, in case DSITRO is set to nodistro, the psplash does not exist.

In our psplash recipe, we have:
SPLASH_IMAGES = "file://psplash-poky-img.h;outsuffix=default" This variable is parsed to if psplash-poky-img.h exists, a package named psplash-default is created and is added to RDEPENDS:${PN}.

We can see that the psplash-poky-img.h resides in meta-poky, and in psplash_git.bbappend file in meta-poky, we have:
FILESEXTRAPATHS:prepend:poky := "${THISDIR}/files:" So this file is only available in case poky distro is used.

To fix this issue, add condition check in the corresponding systemd services.

---
 meta/recipes-core/psplash/files/psplash-start.service   | 1 +
 meta/recipes-core/psplash/files/psplash-systemd.service | 1 +
 2 files changed, 2 insertions(+)
meta/recipes-core/psplash/files/psplash-start.service +1 -0
index 36c2bb38e0..bec9368427 100644
@@ -2,6 +2,7 @@
 Description=Start psplash boot splash screen
 DefaultDependencies=no
 RequiresMountsFor=/run
+ConditionFileIsExecutable=/usr/bin/psplash
 
 [Service]
 Type=notify
meta/recipes-core/psplash/files/psplash-systemd.service +1 -0
index 082207f232..e93e3deb35 100644
@@ -4,6 +4,7 @@ DefaultDependencies=no
 After=psplash-start.service
 Requires=psplash-start.service
 RequiresMountsFor=/run
+ConditionFileIsExecutable=/usr/bin/psplash
 
 [Service]
 ExecStart=/usr/bin/psplash-systemd
Signature · 1 line
2.37.1