From 7ab915fe4cc14583df29d27c2ebe9be602d7df74 Mon Sep 17 00:00:00 2001 From: Kory Maincent Date: Thu, 7 Oct 2021 11:31:01 +0200 Subject: [PATCH] package/psplash: add support to psplash personalized png image Add an configuration to use personalized png image. If the configuration is empty we keep the psplash default image. Signed-off-by: Kory Maincent [Arnout: use ifneq condition instead of $(if ...)] Signed-off-by: Arnout Vandecappelle (Essensium/Mind) --- package/psplash/Config.in | 10 ++++++++++ package/psplash/psplash.mk | 10 ++++++++++ 2 files changed, 20 insertions(+) diff --git a/package/psplash/Config.in b/package/psplash/Config.in index 5053ebacf7..da99b264e0 100644 --- a/package/psplash/Config.in +++ b/package/psplash/Config.in @@ -27,5 +27,15 @@ config BR2_PACKAGE_PSPLASH http://git.yoctoproject.org/cgit/cgit.cgi/psplash/ +if BR2_PACKAGE_PSPLASH + +config BR2_PACKAGE_PSPLASH_IMAGE + string "psplash image" + help + Use a personalized png image as boot splash. + Let it empty if you want to keep the psplash default image. + +endif + comment "psplash needs a toolchain w/ wchar" depends on !BR2_USE_WCHAR diff --git a/package/psplash/psplash.mk b/package/psplash/psplash.mk index a0f01869b4..199509ecd6 100644 --- a/package/psplash/psplash.mk +++ b/package/psplash/psplash.mk @@ -18,6 +18,16 @@ else PSPLASH_CONF_OPTS += --without-systemd endif +PSPLASH_IMAGE = $(call qstrip,$(BR2_PACKAGE_PSPLASH_IMAGE)) + +ifneq ($(PSPLASH_IMAGE),) +define PSPLASH_COPY_IMAGE + cp $(PSPLASH_IMAGE) $(@D)/base-images/psplash-poky.png +endef + +PSPLASH_POST_EXTRACT_HOOKS += PSPLASH_COPY_IMAGE +endif + define PSPLASH_INSTALL_INIT_SYSTEMD $(INSTALL) -D -m 644 package/psplash/psplash-start.service \ $(TARGET_DIR)/usr/lib/systemd/system/psplash-start.service