blob: 0701d9a48b2e659ed3ac95b711469294308f345e (
plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
|
From 9444ce03a27b8d423f8170cf75f56d48d8a0a659 Mon Sep 17 00:00:00 2001
From: =?UTF-8?q?Daniel=20N=C3=A9ri?= <dne+commits@rb67.eu>
Date: Mon, 11 Nov 2024 23:06:03 +0100
Subject: [PATCH] nvme-print: add fallback for non-standard locale category
MIME-Version: 1.0
Content-Type: text/plain; charset=UTF-8
Content-Transfer-Encoding: 8bit
LC_MEASUREMENT is a GNU (libc) extension - fall back to LC_ALL if it's
not defined.
Fixes build with musl libc
Signed-off-by: Daniel Néri <dne+commits@rb67.eu>
---
nvme-print.c | 4 ++++
1 file changed, 4 insertions(+)
--- a/nvme-print.c
+++ b/nvme-print.c
@@ -835,6 +835,10 @@ static bool is_fahrenheit_country(const
#define LC_MEASUREMENT LC_ALL
#endif
+#ifndef LC_MEASUREMENT
+#define LC_MEASUREMENT LC_ALL
+#endif
+
static bool is_temperature_fahrenheit(void)
{
const char *locale, *underscore;
|