diff options
| author | Jinfeng Wang <jinfeng.wang.cn@windriver.com> | 2024-11-18 15:07:22 +0800 |
|---|---|---|
| committer | Steve Sakoman <steve@sakoman.com> | 2024-12-02 06:23:20 -0800 |
| commit | f9ff43bbf13bf33b9e1fba4ac9ced65847df755f (patch) | |
| tree | ffe53a6693a19d4630bb4e1fa83e946d3b4b2ecd | |
| parent | 74473524acb9ec3831ad8dd3d4e58bfce233b28b (diff) | |
| download | poky-f9ff43bbf13bf33b9e1fba4ac9ced65847df755f.tar.gz | |
tzdata&tzcode-native: upgrade 2024a -> 2024b
(From OE-Core rev: 5aa73ec35a3c65df62f17bc8196a35f28fd3522e)
Signed-off-by: Jinfeng Wang <jinfeng.wang.cn@windriver.com>
Signed-off-by: Steve Sakoman <steve@sakoman.com>
(cherry picked from commit c8d3edb2562ea4d980186e78b4abb5a94b1d7b22)
Signed-off-by: Steve Sakoman <steve@sakoman.com>
5 files changed, 206 insertions, 3 deletions
diff --git a/meta/recipes-core/glib-2.0/glib-2.0/gdatetime-test-fail-0001.patch b/meta/recipes-core/glib-2.0/glib-2.0/gdatetime-test-fail-0001.patch new file mode 100644 index 0000000000..1997f88f12 --- /dev/null +++ b/meta/recipes-core/glib-2.0/glib-2.0/gdatetime-test-fail-0001.patch | |||
| @@ -0,0 +1,72 @@ | |||
| 1 | From 39af934b11ec7bb8f943ba963919816266a3316e Mon Sep 17 00:00:00 2001 | ||
| 2 | From: "Rebecca N. Palmer" <rebecca_palmer@zoho.com> | ||
| 3 | Date: Fri, 11 Oct 2024 09:38:52 +0100 | ||
| 4 | Subject: [PATCH 1/3] gdatetime test: Do not assume PST8PDT was always exactly | ||
| 5 | -8/-7 | ||
| 6 | |||
| 7 | In newer tzdata, it is an alias for America/Los_Angeles, which has a | ||
| 8 | slightly different meaning: DST did not exist there before 1883. As a | ||
| 9 | result, we can no longer hard-code the knowledge that interval 0 is | ||
| 10 | standard time and interval 1 is summer time, and instead we need to look | ||
| 11 | up the correct intervals from known timestamps. | ||
| 12 | |||
| 13 | Resolves: https://gitlab.gnome.org/GNOME/glib/-/issues/3502 | ||
| 14 | Bug-Debian: https://bugs.debian.org/1084190 | ||
| 15 | [smcv: expand commit message, fix whitespace] | ||
| 16 | Signed-off-by: Simon McVittie <smcv@debian.org> | ||
| 17 | |||
| 18 | Upstream-Status: Backport | ||
| 19 | [https://github.com/GNOME/glib/commit/c0619f08e6c608fd6464d2f0c6970ef0bbfb9ecf] | ||
| 20 | |||
| 21 | Signed-off-by: Jinfeng Wang <jinfeng.wang.cn@windriver.com> | ||
| 22 | --- | ||
| 23 | glib/tests/gdatetime.c | 22 ++++++++++++++++------ | ||
| 24 | 1 file changed, 16 insertions(+), 6 deletions(-) | ||
| 25 | |||
| 26 | diff --git a/glib/tests/gdatetime.c b/glib/tests/gdatetime.c | ||
| 27 | index 141263b66..cfe00906d 100644 | ||
| 28 | --- a/glib/tests/gdatetime.c | ||
| 29 | +++ b/glib/tests/gdatetime.c | ||
| 30 | @@ -2625,6 +2625,7 @@ test_posix_parse (void) | ||
| 31 | { | ||
| 32 | GTimeZone *tz; | ||
| 33 | GDateTime *gdt1, *gdt2; | ||
| 34 | + gint i1, i2; | ||
| 35 | |||
| 36 | /* Check that an unknown zone name falls back to UTC. */ | ||
| 37 | G_GNUC_BEGIN_IGNORE_DEPRECATIONS | ||
| 38 | @@ -2648,16 +2649,25 @@ test_posix_parse (void) | ||
| 39 | |||
| 40 | /* This fails rules_from_identifier on Unix (though not on Windows) | ||
| 41 | * but passes anyway because PST8PDT is a zone name. | ||
| 42 | + * | ||
| 43 | + * Intervals i1 and i2 (rather than 0 and 1) are needed because in | ||
| 44 | + * recent tzdata, PST8PDT may be an alias for America/Los_Angeles, | ||
| 45 | + * and hence be aware that DST has not always existed. | ||
| 46 | + * https://bugs.debian.org/1084190 | ||
| 47 | */ | ||
| 48 | tz = g_time_zone_new_identifier ("PST8PDT"); | ||
| 49 | g_assert_nonnull (tz); | ||
| 50 | g_assert_cmpstr (g_time_zone_get_identifier (tz), ==, "PST8PDT"); | ||
| 51 | - g_assert_cmpstr (g_time_zone_get_abbreviation (tz, 0), ==, "PST"); | ||
| 52 | - g_assert_cmpint (g_time_zone_get_offset (tz, 0), ==, - 8 * 3600); | ||
| 53 | - g_assert (!g_time_zone_is_dst (tz, 0)); | ||
| 54 | - g_assert_cmpstr (g_time_zone_get_abbreviation (tz, 1), ==, "PDT"); | ||
| 55 | - g_assert_cmpint (g_time_zone_get_offset (tz, 1), ==,- 7 * 3600); | ||
| 56 | - g_assert (g_time_zone_is_dst (tz, 1)); | ||
| 57 | + /* a date in winter = non-DST */ | ||
| 58 | + i1 = g_time_zone_find_interval (tz, G_TIME_TYPE_STANDARD, 0); | ||
| 59 | + /* approximately 6 months in seconds, i.e. a date in summer = DST */ | ||
| 60 | + i2 = g_time_zone_find_interval (tz, G_TIME_TYPE_DAYLIGHT, 15000000); | ||
| 61 | + g_assert_cmpstr (g_time_zone_get_abbreviation (tz, i1), ==, "PST"); | ||
| 62 | + g_assert_cmpint (g_time_zone_get_offset (tz, i1), ==, - 8 * 3600); | ||
| 63 | + g_assert (!g_time_zone_is_dst (tz, i1)); | ||
| 64 | + g_assert_cmpstr (g_time_zone_get_abbreviation (tz, i2), ==, "PDT"); | ||
| 65 | + g_assert_cmpint (g_time_zone_get_offset (tz, i2), ==,- 7 * 3600); | ||
| 66 | + g_assert (g_time_zone_is_dst (tz, i2)); | ||
| 67 | g_time_zone_unref (tz); | ||
| 68 | |||
| 69 | tz = g_time_zone_new_identifier ("PST8PDT6:32:15"); | ||
| 70 | -- | ||
| 71 | 2.34.1 | ||
| 72 | |||
diff --git a/meta/recipes-core/glib-2.0/glib-2.0/gdatetime-test-fail-0002.patch b/meta/recipes-core/glib-2.0/glib-2.0/gdatetime-test-fail-0002.patch new file mode 100644 index 0000000000..b3d11b5076 --- /dev/null +++ b/meta/recipes-core/glib-2.0/glib-2.0/gdatetime-test-fail-0002.patch | |||
| @@ -0,0 +1,65 @@ | |||
| 1 | From 27eb6eb01d5752c201dd2ec02f656463d12ebee0 Mon Sep 17 00:00:00 2001 | ||
| 2 | From: Simon McVittie <smcv@debian.org> | ||
| 3 | Date: Fri, 18 Oct 2024 11:03:19 +0100 | ||
| 4 | Subject: [PATCH 2/3] gdatetime test: Try to make PST8PDT test more obviously | ||
| 5 | correct | ||
| 6 | |||
| 7 | Instead of using timestamp 0 as a magic number (in this case interpreted | ||
| 8 | as 1970-01-01T00:00:00-08:00), calculate a timestamp from a recent | ||
| 9 | year/month/day in winter, in this case 2024-01-01T00:00:00-08:00. | ||
| 10 | |||
| 11 | Similarly, instead of using a timestamp 15 million seconds later | ||
| 12 | (1970-06-23T15:40:00-07:00), calculate a timestamp from a recent | ||
| 13 | year/month/day in summer, in this case 2024-07-01T00:00:00-07:00. | ||
| 14 | |||
| 15 | Signed-off-by: Simon McVittie <smcv@debian.org> | ||
| 16 | |||
| 17 | Upstream-Status: Backport | ||
| 18 | [https://github.com/GNOME/glib/commit/30e9cfa5733003cd1079e0e9e8a4bff1a191171a] | ||
| 19 | |||
| 20 | Signed-off-by: Jinfeng Wang <jinfeng.wang.cn@windriver.com> | ||
| 21 | --- | ||
| 22 | glib/tests/gdatetime.c | 15 +++++++-------- | ||
| 23 | 1 file changed, 7 insertions(+), 8 deletions(-) | ||
| 24 | |||
| 25 | diff --git a/glib/tests/gdatetime.c b/glib/tests/gdatetime.c | ||
| 26 | index cfe00906d..22aa5112a 100644 | ||
| 27 | --- a/glib/tests/gdatetime.c | ||
| 28 | +++ b/glib/tests/gdatetime.c | ||
| 29 | @@ -2649,19 +2649,16 @@ test_posix_parse (void) | ||
| 30 | |||
| 31 | /* This fails rules_from_identifier on Unix (though not on Windows) | ||
| 32 | * but passes anyway because PST8PDT is a zone name. | ||
| 33 | - * | ||
| 34 | - * Intervals i1 and i2 (rather than 0 and 1) are needed because in | ||
| 35 | - * recent tzdata, PST8PDT may be an alias for America/Los_Angeles, | ||
| 36 | - * and hence be aware that DST has not always existed. | ||
| 37 | - * https://bugs.debian.org/1084190 | ||
| 38 | */ | ||
| 39 | tz = g_time_zone_new_identifier ("PST8PDT"); | ||
| 40 | g_assert_nonnull (tz); | ||
| 41 | g_assert_cmpstr (g_time_zone_get_identifier (tz), ==, "PST8PDT"); | ||
| 42 | /* a date in winter = non-DST */ | ||
| 43 | - i1 = g_time_zone_find_interval (tz, G_TIME_TYPE_STANDARD, 0); | ||
| 44 | - /* approximately 6 months in seconds, i.e. a date in summer = DST */ | ||
| 45 | - i2 = g_time_zone_find_interval (tz, G_TIME_TYPE_DAYLIGHT, 15000000); | ||
| 46 | + gdt1 = g_date_time_new (tz, 2024, 1, 1, 0, 0, 0); | ||
| 47 | + i1 = g_time_zone_find_interval (tz, G_TIME_TYPE_STANDARD, g_date_time_to_unix (gdt1)); | ||
| 48 | + /* a date in summer = DST */ | ||
| 49 | + gdt2 = g_date_time_new (tz, 2024, 7, 1, 0, 0, 0); | ||
| 50 | + i2 = g_time_zone_find_interval (tz, G_TIME_TYPE_DAYLIGHT, g_date_time_to_unix (gdt2)); | ||
| 51 | g_assert_cmpstr (g_time_zone_get_abbreviation (tz, i1), ==, "PST"); | ||
| 52 | g_assert_cmpint (g_time_zone_get_offset (tz, i1), ==, - 8 * 3600); | ||
| 53 | g_assert (!g_time_zone_is_dst (tz, i1)); | ||
| 54 | @@ -2669,6 +2666,8 @@ test_posix_parse (void) | ||
| 55 | g_assert_cmpint (g_time_zone_get_offset (tz, i2), ==,- 7 * 3600); | ||
| 56 | g_assert (g_time_zone_is_dst (tz, i2)); | ||
| 57 | g_time_zone_unref (tz); | ||
| 58 | + g_date_time_unref (gdt1); | ||
| 59 | + g_date_time_unref (gdt2); | ||
| 60 | |||
| 61 | tz = g_time_zone_new_identifier ("PST8PDT6:32:15"); | ||
| 62 | #ifdef G_OS_WIN32 | ||
| 63 | -- | ||
| 64 | 2.34.1 | ||
| 65 | |||
diff --git a/meta/recipes-core/glib-2.0/glib-2.0/gdatetime-test-fail-0003.patch b/meta/recipes-core/glib-2.0/glib-2.0/gdatetime-test-fail-0003.patch new file mode 100644 index 0000000000..b9afad15c5 --- /dev/null +++ b/meta/recipes-core/glib-2.0/glib-2.0/gdatetime-test-fail-0003.patch | |||
| @@ -0,0 +1,63 @@ | |||
| 1 | From 9dd5e9f49620f13a3eaf2b862b7aa3c680953f01 Mon Sep 17 00:00:00 2001 | ||
| 2 | From: Simon McVittie <smcv@debian.org> | ||
| 3 | Date: Fri, 18 Oct 2024 11:23:42 +0100 | ||
| 4 | Subject: [PATCH 3/3] gdatetime test: Fall back if legacy System V PST8PDT is | ||
| 5 | not available | ||
| 6 | |||
| 7 | On recent versions of Debian, PST8PDT is part of the tzdata-legacy | ||
| 8 | package, which is not always installed and might disappear in future. | ||
| 9 | Successfully tested with and without tzdata-legacy on Debian unstable. | ||
| 10 | |||
| 11 | Signed-off-by: Simon McVittie <smcv@debian.org> | ||
| 12 | |||
| 13 | Upstream-Status: Backport | ||
| 14 | [https://github.com/GNOME/glib/commit/fe2699369f79981dcf913af4cfd98b342b84a9c1] | ||
| 15 | |||
| 16 | Signed-off-by: Jinfeng Wang <jinfeng.wang.cn@windriver.com> | ||
| 17 | --- | ||
| 18 | glib/tests/gdatetime.c | 19 +++++++++++++++++-- | ||
| 19 | 1 file changed, 17 insertions(+), 2 deletions(-) | ||
| 20 | |||
| 21 | diff --git a/glib/tests/gdatetime.c b/glib/tests/gdatetime.c | ||
| 22 | index 22aa5112a..4e963b171 100644 | ||
| 23 | --- a/glib/tests/gdatetime.c | ||
| 24 | +++ b/glib/tests/gdatetime.c | ||
| 25 | @@ -2626,6 +2626,7 @@ test_posix_parse (void) | ||
| 26 | GTimeZone *tz; | ||
| 27 | GDateTime *gdt1, *gdt2; | ||
| 28 | gint i1, i2; | ||
| 29 | + const char *expect_id; | ||
| 30 | |||
| 31 | /* Check that an unknown zone name falls back to UTC. */ | ||
| 32 | G_GNUC_BEGIN_IGNORE_DEPRECATIONS | ||
| 33 | @@ -2648,11 +2649,25 @@ test_posix_parse (void) | ||
| 34 | g_time_zone_unref (tz); | ||
| 35 | |||
| 36 | /* This fails rules_from_identifier on Unix (though not on Windows) | ||
| 37 | - * but passes anyway because PST8PDT is a zone name. | ||
| 38 | + * but can pass anyway because PST8PDT is a legacy System V zone name. | ||
| 39 | */ | ||
| 40 | tz = g_time_zone_new_identifier ("PST8PDT"); | ||
| 41 | + expect_id = "PST8PDT"; | ||
| 42 | + | ||
| 43 | +#ifndef G_OS_WIN32 | ||
| 44 | + /* PST8PDT is in tzdata's "backward" set, packaged as tzdata-legacy and | ||
| 45 | + * not always present in some OSs; fall back to the equivalent geographical | ||
| 46 | + * name if the "backward" time zones are absent. */ | ||
| 47 | + if (tz == NULL) | ||
| 48 | + { | ||
| 49 | + g_test_message ("Legacy PST8PDT time zone not available, falling back"); | ||
| 50 | + tz = g_time_zone_new_identifier ("America/Los_Angeles"); | ||
| 51 | + expect_id = "America/Los_Angeles"; | ||
| 52 | + } | ||
| 53 | +#endif | ||
| 54 | + | ||
| 55 | g_assert_nonnull (tz); | ||
| 56 | - g_assert_cmpstr (g_time_zone_get_identifier (tz), ==, "PST8PDT"); | ||
| 57 | + g_assert_cmpstr (g_time_zone_get_identifier (tz), ==, expect_id); | ||
| 58 | /* a date in winter = non-DST */ | ||
| 59 | gdt1 = g_date_time_new (tz, 2024, 1, 1, 0, 0, 0); | ||
| 60 | i1 = g_time_zone_find_interval (tz, G_TIME_TYPE_STANDARD, g_date_time_to_unix (gdt1)); | ||
| 61 | -- | ||
| 62 | 2.34.1 | ||
| 63 | |||
diff --git a/meta/recipes-core/glib-2.0/glib-2.0_2.72.3.bb b/meta/recipes-core/glib-2.0/glib-2.0_2.72.3.bb index 8007de0613..b8c75eaa49 100644 --- a/meta/recipes-core/glib-2.0/glib-2.0_2.72.3.bb +++ b/meta/recipes-core/glib-2.0/glib-2.0_2.72.3.bb | |||
| @@ -51,6 +51,9 @@ SRC_URI = "${GNOME_MIRROR}/glib/${SHRT_VER}/glib-${PV}.tar.xz \ | |||
| 51 | file://CVE-2024-34397_18.patch \ | 51 | file://CVE-2024-34397_18.patch \ |
| 52 | file://0001-gvariant-serialiser-Convert-endianness-of-offsets.patch \ | 52 | file://0001-gvariant-serialiser-Convert-endianness-of-offsets.patch \ |
| 53 | file://CVE-2024-52533.patch \ | 53 | file://CVE-2024-52533.patch \ |
| 54 | file://gdatetime-test-fail-0001.patch \ | ||
| 55 | file://gdatetime-test-fail-0002.patch \ | ||
| 56 | file://gdatetime-test-fail-0003.patch \ | ||
| 54 | " | 57 | " |
| 55 | SRC_URI:append:class-native = " file://relocate-modules.patch" | 58 | SRC_URI:append:class-native = " file://relocate-modules.patch" |
| 56 | 59 | ||
diff --git a/meta/recipes-extended/timezone/timezone.inc b/meta/recipes-extended/timezone/timezone.inc index 4734adcc08..adf095280f 100644 --- a/meta/recipes-extended/timezone/timezone.inc +++ b/meta/recipes-extended/timezone/timezone.inc | |||
| @@ -6,7 +6,7 @@ SECTION = "base" | |||
| 6 | LICENSE = "PD & BSD-3-Clause" | 6 | LICENSE = "PD & BSD-3-Clause" |
| 7 | LIC_FILES_CHKSUM = "file://LICENSE;md5=c679c9d6b02bc2757b3eaf8f53c43fba" | 7 | LIC_FILES_CHKSUM = "file://LICENSE;md5=c679c9d6b02bc2757b3eaf8f53c43fba" |
| 8 | 8 | ||
| 9 | PV = "2024a" | 9 | PV = "2024b" |
| 10 | 10 | ||
| 11 | SRC_URI =" http://www.iana.org/time-zones/repository/releases/tzcode${PV}.tar.gz;name=tzcode;subdir=tz \ | 11 | SRC_URI =" http://www.iana.org/time-zones/repository/releases/tzcode${PV}.tar.gz;name=tzcode;subdir=tz \ |
| 12 | http://www.iana.org/time-zones/repository/releases/tzdata${PV}.tar.gz;name=tzdata;subdir=tz \ | 12 | http://www.iana.org/time-zones/repository/releases/tzdata${PV}.tar.gz;name=tzdata;subdir=tz \ |
| @@ -16,5 +16,5 @@ S = "${WORKDIR}/tz" | |||
| 16 | 16 | ||
| 17 | UPSTREAM_CHECK_URI = "http://www.iana.org/time-zones" | 17 | UPSTREAM_CHECK_URI = "http://www.iana.org/time-zones" |
| 18 | 18 | ||
| 19 | SRC_URI[tzcode.sha256sum] = "80072894adff5a458f1d143e16e4ca1d8b2a122c9c5399da482cb68cba6a1ff8" | 19 | SRC_URI[tzcode.sha256sum] = "5e438fc449624906af16a18ff4573739f0cda9862e5ec28d3bcb19cbaed0f672" |
| 20 | SRC_URI[tzdata.sha256sum] = "0d0434459acbd2059a7a8da1f3304a84a86591f6ed69c6248fffa502b6edffe3" | 20 | SRC_URI[tzdata.sha256sum] = "70e754db126a8d0db3d16d6b4cb5f7ec1e04d5f261255e4558a67fe92d39e550" |
