summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorMike Gilbert <floppym@gentoo.org>2021-08-23 11:35:43 -0400
committerMike Gilbert <floppym@gentoo.org>2021-08-23 11:35:43 -0400
commitdc85e1dfd2f04b32401ac1f63fc3e8133c749f78 (patch)
tree5744377a065d7d9c16e6ff2ea01ae93da6a19e72 /dev-libs/libgudev
parentdev-libs/icinga-php-library: install lib to correct dir (diff)
downloadgentoo-dc85e1dfd2f04b32401ac1f63fc3e8133c749f78.tar.gz
gentoo-dc85e1dfd2f04b32401ac1f63fc3e8133c749f78.tar.bz2
gentoo-dc85e1dfd2f04b32401ac1f63fc3e8133c749f78.zip
dev-libs/libgudev: skip test-double when fr_FR.UTF-8 is missing
Closes: https://bugs.gentoo.org/809359 Signed-off-by: Mike Gilbert <floppym@gentoo.org>
Diffstat (limited to 'dev-libs/libgudev')
-rw-r--r--dev-libs/libgudev/files/libgudev-test-double.patch30
-rw-r--r--dev-libs/libgudev/libgudev-237.ebuild5
2 files changed, 35 insertions, 0 deletions
diff --git a/dev-libs/libgudev/files/libgudev-test-double.patch b/dev-libs/libgudev/files/libgudev-test-double.patch
new file mode 100644
index 000000000000..5d0eb3dab18d
--- /dev/null
+++ b/dev-libs/libgudev/files/libgudev-test-double.patch
@@ -0,0 +1,30 @@
+From 6f0503b1930a0776ef45fa7bc87a87e9dc69dacf Mon Sep 17 00:00:00 2001
+From: Mike Gilbert <floppym@gentoo.org>
+Date: Sat, 21 Aug 2021 15:09:58 -0400
+Subject: [PATCH] Skip test-double if the fr_FR.UTF-8 locale is not available
+
+Bug: https://bugs.gentoo.org/809359
+---
+ tests/test-double.c | 6 +++++-
+ 1 file changed, 5 insertions(+), 1 deletion(-)
+
+diff --git a/tests/test-double.c b/tests/test-double.c
+index 0092d8b..7ba3abe 100644
+--- a/tests/test-double.c
++++ b/tests/test-double.c
+@@ -54,7 +54,11 @@ test_double (void)
+ int main(int argc, char **argv)
+ {
+ setlocale (LC_ALL, NULL);
+- setlocale (LC_NUMERIC, "fr_FR.UTF-8");
++ if (!setlocale (LC_NUMERIC, "fr_FR.UTF-8"))
++ /* Skip the test if fr_FR.UTF-8 is not available */
++ /* https://mesonbuild.com/Unit-tests.html#skipped-tests-and-hard-errors */
++ return 77;
++
+ g_test_init (&argc, &argv, NULL);
+
+ g_test_add_func ("/gudev/double", test_double);
+--
+2.33.0
+
diff --git a/dev-libs/libgudev/libgudev-237.ebuild b/dev-libs/libgudev/libgudev-237.ebuild
index 6f131f3140bd..ceaf1ef5e86c 100644
--- a/dev-libs/libgudev/libgudev-237.ebuild
+++ b/dev-libs/libgudev/libgudev-237.ebuild
@@ -28,6 +28,11 @@ BDEPEND="
virtual/pkgconfig
"
+PATCHES=(
+ # https://gitlab.gnome.org/GNOME/libgudev/-/merge_requests/19
+ "${FILESDIR}/libgudev-test-double.patch"
+)
+
multilib_src_configure() {
local emesonargs=(
$(meson_native_use_feature introspection)