diff options
author | Changqing Li <changqing.li@windriver.com> | 2025-04-28 15:11:24 +0800 |
---|---|---|
committer | Steve Sakoman <steve@sakoman.com> | 2025-05-14 08:33:40 -0700 |
commit | 35a23e15968c9f7b8b8958fd813e2672773fc506 (patch) | |
tree | 06fff5bc9803142adcfb2f227aad0acc4adf9511 /meta/recipes-core/initscripts | |
parent | 2fe0f26f452813774b4bec3d89383fc3eae53b76 (diff) | |
download | poky-35a23e15968c9f7b8b8958fd813e2672773fc506.tar.gz |
initscripts: add function log_success_msg/log_failure_msg/log_warning_msg
* add function log_success_msg/log_failure_msg/log_warning_msg, some
packages still use these functions, like mariadb, refer [1], without
these function, with sysV init manager, mariadb will report error:
root@qemux86-64:~# /etc/init.d/mysqld status
/etc/init.d/mysqld: line 383: log_success_msg: command not found
* remove RCONFLICTS with lsbinitscripts, LSB support already remove in
[2]
[1] https://github.com/MariaDB/server/blob/main/support-files/mysql.server.sh#L104
[2] https://git.openembedded.org/openembedded-core/commit/?id=fb064356af615d67d85b65942103bf943d84d290
[3] https://refspecs.linuxbase.org/LSB_4.0.0/LSB-Core-generic/LSB-Core-generic/iniscrptfunc.html
(From OE-Core rev: 1956cb8e04c586b555f51bc68b74ad5d5cf1a043)
Signed-off-by: Changqing Li <changqing.li@windriver.com>
Signed-off-by: Steve Sakoman <steve@sakoman.com>
Diffstat (limited to 'meta/recipes-core/initscripts')
-rwxr-xr-x | meta/recipes-core/initscripts/initscripts-1.0/functions | 21 | ||||
-rw-r--r-- | meta/recipes-core/initscripts/initscripts_1.0.bb | 1 |
2 files changed, 21 insertions, 1 deletions
diff --git a/meta/recipes-core/initscripts/initscripts-1.0/functions b/meta/recipes-core/initscripts/initscripts-1.0/functions index 35aebd4a55..7fc19c808b 100755 --- a/meta/recipes-core/initscripts/initscripts-1.0/functions +++ b/meta/recipes-core/initscripts/initscripts-1.0/functions | |||
@@ -92,3 +92,24 @@ passed() { | |||
92 | echo -n -e "${BRACKET}[${SUCCESS} PASS ${BRACKET}]${NORMAL}" | 92 | echo -n -e "${BRACKET}[${SUCCESS} PASS ${BRACKET}]${NORMAL}" |
93 | return $rc | 93 | return $rc |
94 | } | 94 | } |
95 | |||
96 | log_success_msg() | ||
97 | { | ||
98 | echo -n $@ | ||
99 | success | ||
100 | echo | ||
101 | } | ||
102 | |||
103 | log_failure_msg() | ||
104 | { | ||
105 | echo -n $@ | ||
106 | failure | ||
107 | echo | ||
108 | } | ||
109 | |||
110 | log_warning_msg() | ||
111 | { | ||
112 | echo -n $@ | ||
113 | warning | ||
114 | echo | ||
115 | } | ||
diff --git a/meta/recipes-core/initscripts/initscripts_1.0.bb b/meta/recipes-core/initscripts/initscripts_1.0.bb index 98693fa66e..0bc078c5eb 100644 --- a/meta/recipes-core/initscripts/initscripts_1.0.bb +++ b/meta/recipes-core/initscripts/initscripts_1.0.bb | |||
@@ -54,7 +54,6 @@ RDEPENDS:${PN} = "initd-functions \ | |||
54 | # Recommend pn-functions so that it will be a preferred default provider for initd-functions | 54 | # Recommend pn-functions so that it will be a preferred default provider for initd-functions |
55 | RRECOMMENDS:${PN} = "${PN}-functions" | 55 | RRECOMMENDS:${PN} = "${PN}-functions" |
56 | RPROVIDES:${PN}-functions = "initd-functions" | 56 | RPROVIDES:${PN}-functions = "initd-functions" |
57 | RCONFLICTS:${PN}-functions = "lsbinitscripts" | ||
58 | FILES:${PN}-functions = "${sysconfdir}/init.d/functions*" | 57 | FILES:${PN}-functions = "${sysconfdir}/init.d/functions*" |
59 | FILES:${PN}-sushell = "${base_sbindir}/sushell" | 58 | FILES:${PN}-sushell = "${base_sbindir}/sushell" |
60 | 59 | ||