diff --git a/assets/oniro-logo-small.png b/assets/oniro-logo-small.png new file mode 100644 index 0000000000000000000000000000000000000000..6686503884c40e36519b5452c35ddb8b2ef71f84 Binary files /dev/null and b/assets/oniro-logo-small.png differ diff --git a/assets/oniro-logo-small.png.license b/assets/oniro-logo-small.png.license new file mode 100644 index 0000000000000000000000000000000000000000..98a0b3f4a5b8db268215a128c7d06e0a10897e73 --- /dev/null +++ b/assets/oniro-logo-small.png.license @@ -0,0 +1,3 @@ +# SPDX-FileCopyrightText: Huawei Inc. +# +# SPDX-License-Identifier: Apache-2.0 diff --git a/meta-ohos-core/recipes-core/psplash/psplash/0001-psplash-colors.h-color-change.patch b/meta-ohos-core/recipes-core/psplash/psplash/0001-psplash-colors.h-color-change.patch new file mode 100644 index 0000000000000000000000000000000000000000..f44cb5b2f67c2e46551633f4a2415ce77949fdc4 --- /dev/null +++ b/meta-ohos-core/recipes-core/psplash/psplash/0001-psplash-colors.h-color-change.patch @@ -0,0 +1,31 @@ +From e9a4653ac28d9d27ca2da1caab0997c1b957c8fc Mon Sep 17 00:00:00 2001 +From: Srikanth Krishnakar <Srikanth_Krishnakar@mentor.com> +Date: Thu, 13 Oct 2016 19:48:55 +0530 +Subject: [PATCH] plash-colors.h: color change + +Signed-off-by: Srikanth Krishnakar <Srikanth_Krishnakar@mentor.com> +[Adjusted color codes to our logo background. Stefan Schmidt] +Signed-off-by: Stefan Schmidt <stefan.schmidt@huawei.com> + +Upstream-Status: Inappropriate [configuration] + +--- + psplash-colors.h | 2 +- + 1 file changed, 1 insertion(+), 1 deletion(-) + +diff --git a/psplash-colors.h b/psplash-colors.h +index d701089..24a3a05 100644 +--- a/psplash-colors.h ++++ b/psplash-colors.h +@@ -20,7 +20,7 @@ + #define _HAVE_PSPLASH_COLORS_H + + /* This is the overall background color */ +-#define PSPLASH_BACKGROUND_COLOR 0xec,0xec,0xe1 ++#define PSPLASH_BACKGROUND_COLOR 0x0f,0x00,0x26 + + /* This is the color of any text output */ + #define PSPLASH_TEXT_COLOR 0x6d,0x6d,0x70 +-- +2.7.4 + diff --git a/meta-ohos-core/recipes-core/psplash/psplash/psplash-add-configure-options-to-disable-progress-bar.patch b/meta-ohos-core/recipes-core/psplash/psplash/psplash-add-configure-options-to-disable-progress-bar.patch new file mode 100644 index 0000000000000000000000000000000000000000..e53509d0dd5a343d417fdf78a68bccd6cb5aeaf8 --- /dev/null +++ b/meta-ohos-core/recipes-core/psplash/psplash/psplash-add-configure-options-to-disable-progress-bar.patch @@ -0,0 +1,117 @@ +From: "Pavel Zhukov" <pavel@zhukoff.net> +Date: Thu, 14 Oct 2021 09:02:17 +0200 +Subject: [yocto] [psplash][PATCH v2] Add configure options to disable progress bar + +Progress bar can overlap with products logos, added +--disable-progress-bar configure option to disable progress +bar completely without patching the code. +Default behaviour is to show progress bar + +Signed-off-by: Pavel Zhukov <pavel.zhukov@huawei.com> + +Upstream-Status: Submitted [https://lists.yoctoproject.org/g/yocto/topic/86307015] + +--- + configure.ac | 8 ++++++++ + psplash-config.h | 5 +++++ + psplash.c | 14 ++++++++++---- + 3 files changed, 23 insertions(+), 4 deletions(-) + +diff --git a/configure.ac b/configure.ac +index 2d836a1..2a7da91 100644 +--- a/configure.ac ++++ b/configure.ac +@@ -37,6 +37,14 @@ AS_IF([test x$disable_startup_msg = xtrue], [ + EXTRA_GCC_FLAGS="$EXTRA_GCC_FLAGS -DPSPLASH_DISABLE_STARTUP_MSG" + ]) + ++AC_ARG_ENABLE([progress-bar], ++ AS_HELP_STRING([--disable-progress-bar], [Disable progress bar]), ++ [disable_progress_bar=true], ++ [disable_progress_bar=false]) ++AS_IF([test x$disable_progress_bar = xtrue], [ ++ EXTRA_GCC_FLAGS="$EXTRA_GCC_FLAGS -DPSPLASH_DISABLE_PROGRESS_BAR" ++]) ++ + AC_ARG_ENABLE([img-fullscreen], + AS_HELP_STRING([--enable-img-fullscreen], [Enable the logo image in fullscreen mode)]), + [img_fullscreen=true], +diff --git a/psplash-config.h b/psplash-config.h +index 0ba8440..eb90ef3 100644 +--- a/psplash-config.h ++++ b/psplash-config.h +@@ -21,6 +21,11 @@ + #define PSPLASH_IMG_FULLSCREEN 0 + #endif + ++/* Bool indicated if the progress bar should be disabled */ ++#ifndef PSPLASH_DISABLE_PROGRESS_BAR ++#define PSPLASH_SHOW_PROGRESS_BAR 1 ++#endif ++ + /* Position of the image split from top edge, numerator of fraction */ + #define PSPLASH_IMG_SPLIT_NUMERATOR 5 + +diff --git a/psplash.c b/psplash.c +index 1a56629..ee1af6b 100644 +--- a/psplash.c ++++ b/psplash.c +@@ -61,6 +61,7 @@ psplash_draw_msg (PSplashFB *fb, const char *msg) + msg); + } + ++#ifdef PSPLASH_SHOW_PROGRESS_BAR + void + psplash_draw_progress (PSplashFB *fb, int value) + { +@@ -95,6 +96,7 @@ psplash_draw_progress (PSplashFB *fb, int value) + DBG("value: %i, width: %i, barwidth :%i\n", value, + width, barwidth); + } ++#endif /* PSPLASH_SHOW_PROGRESS_BAR */ + + static int + parse_command (PSplashFB *fb, char *string) +@@ -108,20 +110,22 @@ parse_command (PSplashFB *fb, char *string) + + command = strtok(string," "); + +- if (!strcmp(command,"PROGRESS")) ++ if (!strcmp(command,"MSG")) + { + char *arg = strtok(NULL, "\0"); + + if (arg) +- psplash_draw_progress (fb, atoi(arg)); ++ psplash_draw_msg (fb, arg); + } +- else if (!strcmp(command,"MSG")) ++ #ifdef PSPLASH_SHOW_PROGRESS_BAR ++ else if (!strcmp(command,"PROGRESS")) + { + char *arg = strtok(NULL, "\0"); + + if (arg) +- psplash_draw_msg (fb, arg); ++ psplash_draw_progress (fb, atoi(arg)); + } ++#endif + else if (!strcmp(command,"QUIT")) + { + return 1; +@@ -311,6 +315,7 @@ main (int argc, char** argv) + POKY_IMG_ROWSTRIDE, + POKY_IMG_RLE_PIXEL_DATA); + ++#ifdef PSPLASH_SHOW_PROGRESS_BAR + /* Draw progress bar border */ + psplash_fb_draw_image (fb, + (fb->width - BAR_IMG_WIDTH)/2, +@@ -322,6 +327,7 @@ main (int argc, char** argv) + BAR_IMG_RLE_PIXEL_DATA); + + psplash_draw_progress (fb, 0); ++#endif + + #ifdef PSPLASH_STARTUP_MSG + psplash_draw_msg (fb, PSPLASH_STARTUP_MSG); diff --git a/meta-ohos-core/recipes-core/psplash/psplash_%.bbappend b/meta-ohos-core/recipes-core/psplash/psplash_%.bbappend index e460d8f33b933dd2fb3adf521b71aeff72ba7947..e6b272b56fabf9c67fe3c981e8ce5d9e2321695f 100644 --- a/meta-ohos-core/recipes-core/psplash/psplash_%.bbappend +++ b/meta-ohos-core/recipes-core/psplash/psplash_%.bbappend @@ -3,4 +3,12 @@ # SPDX-License-Identifier: Apache-2.0 FILESEXTRAPATHS_prepend := "${ONIRO_COREBASE}/assets:" -SPLASH_IMAGES = "file://ostc-logo-small.png;outsuffix=default" +SPLASH_IMAGES = "file://oniro-logo-small.png;outsuffix=default" + +EXTRA_OECONF += "--enable-img-fullscreen --disable-startup-msg --disable-progress-bar" + +# Change background color and splash image with no progress bar +FILESEXTRAPATHS_prepend := "${THISDIR}/psplash:" +SRC_URI += "file://0001-psplash-colors.h-color-change.patch \ + file://psplash-add-configure-options-to-disable-progress-bar.patch \ + "