diff options
author | Maxime Roussin-B?langer <maxime.roussinbelanger@gmail.com> | 2020-04-15 12:24:46 -0400 |
---|---|---|
committer | Richard Purdie <richard.purdie@linuxfoundation.org> | 2020-04-24 13:57:01 +0100 |
commit | 338a67951c375d907b36b87d4115ee5489df722e (patch) | |
tree | 0606f63041ade08f7a5f0ea15a6914a4ff3cc8f0 /meta/recipes-extended/timezone/tzdata.bb | |
parent | 406e7a085b0650bdba9f19633dadb7e6ff0149e5 (diff) | |
download | openembedded-core-contrib-338a67951c375d907b36b87d4115ee5489df722e.tar.gz |
tzdata: remove exit 0 from pkg_postinst
Documentation says that if you exit 0 in a pkg_postinst it will marked as
installed.
If you exit 0, before running postinst-intercepts defer_to_first_boot, the
pkg_postinst_ontarget script will not be present on target.
The "exit 0" in tzdata makes it difficult to have a bbappend with a
pkg_postinst_target step when you have `INSTALL_TIMEZONE_FILE = 0`
Signed-off-by: Maxime Roussin-BĂ©langer <maxime.roussinbelanger@gmail.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
Diffstat (limited to 'meta/recipes-extended/timezone/tzdata.bb')
-rw-r--r-- | meta/recipes-extended/timezone/tzdata.bb | 8 |
1 files changed, 2 insertions, 6 deletions
diff --git a/meta/recipes-extended/timezone/tzdata.bb b/meta/recipes-extended/timezone/tzdata.bb index 1e2d9bd1b9..1e2b440fb0 100644 --- a/meta/recipes-extended/timezone/tzdata.bb +++ b/meta/recipes-extended/timezone/tzdata.bb @@ -60,12 +60,8 @@ pkg_postinst_${PN} () { if [ -e ${src} ] ; then tz=$(sed -e 's:#.*::' -e 's:[[:space:]]*::g' -e '/^$/d' "${src}") fi - - if [ -z "${tz}" ] ; then - exit 0 - fi - - if [ ! -e "$D${datadir}/zoneinfo/${tz}" ] ; then + + if [ ! -z "${tz}" -a ! -e "$D${datadir}/zoneinfo/${tz}" ] ; then echo "You have an invalid TIMEZONE setting in ${src}" echo "Your ${etc_lt} has been reset to Universal; enjoy!" tz="Universal" |