From 23d81013dd77840570a4990ab72fb14b4597ce28 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?=C4=90o=C3=A0n=20Tr=E1=BA=A7n=20C=C3=B4ng=20Danh?= Date: Sat, 5 Oct 2024 10:41:26 +0700 Subject: [PATCH] mate-panel: fix strftime on musl Fix: #52494 --- .../mate-panel/patches/musl-strftime.patch | 40 +++++++++++++++++++ srcpkgs/mate-panel/template | 2 +- 2 files changed, 41 insertions(+), 1 deletion(-) create mode 100644 srcpkgs/mate-panel/patches/musl-strftime.patch diff --git a/srcpkgs/mate-panel/patches/musl-strftime.patch b/srcpkgs/mate-panel/patches/musl-strftime.patch new file mode 100644 index 00000000000..d13d62bcd24 --- /dev/null +++ b/srcpkgs/mate-panel/patches/musl-strftime.patch @@ -0,0 +1,40 @@ +--- a/applets/clock/clock-location-tile.c ++++ b/applets/clock/clock-location-tile.c +@@ -434,7 +434,7 @@ format_time (struct tm *now, + * weekday differs from the weekday at the location + * (the %A expands to the weekday). The %p expands to + * am/pm. */ +- format = _("%l:%M %p (%A)"); ++ format = _("%_I:%M %p (%A)"); + } + else { + /* Translators: This is a strftime format string. +@@ -451,7 +451,7 @@ format_time (struct tm *now, + * It is used to display the time in 12-hours format + * (eg, like in the US: 8:10 am). The %p expands to + * am/pm. */ +- format = _("%l:%M %p"); ++ format = _("%_I:%M %p"); + } + else { + /* Translators: This is a strftime format string. +@@ -497,7 +497,7 @@ convert_time_to_str (time_t now, ClockFo + * It is used to display the time in 12-hours format (eg, like + * in the US: 8:10 am). The %p expands to am/pm. + */ +- format = _("%l:%M %p"); ++ format = _("%_I:%M %p"); + } + else { + /* Translators: This is a strftime format string. +--- a/applets/clock/clock.c ++++ b/applets/clock/clock.c +@@ -458,7 +458,7 @@ get_updated_timeformat (ClockData *cd) + /* Translators: This is a strftime format string. + * It is used to display the time in 12-hours format (eg, like + * in the US: 8:10 am). The %p expands to am/pm. */ +- time_format = cd->showseconds ? _("%l:%M:%S %p") : _("%l:%M %p"); ++ time_format = cd->showseconds ? _("%_I:%M:%S %p") : _("%_I:%M %p"); + else + /* Translators: This is a strftime format string. + * It is used to display the time in 24-hours format (eg, like diff --git a/srcpkgs/mate-panel/template b/srcpkgs/mate-panel/template index eed9ba4a821..4ef96bb9daf 100644 --- a/srcpkgs/mate-panel/template +++ b/srcpkgs/mate-panel/template @@ -1,7 +1,7 @@ # Template file for 'mate-panel' pkgname=mate-panel version=1.28.2 -revision=1 +revision=2 build_style=gnu-configure build_helper="gir" configure_args="--disable-static --disable-schemas-compile