From patchwork Tue May 16 18:25:16 2023 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Bernd Kuhls X-Patchwork-Id: 91885 Received: from [127.0.0.1] by www.linuxtv.org with esmtp (Exim 4.92) (envelope-from ) id 1pyzNJ-005GYt-Tf; Tue, 16 May 2023 18:26:17 +0000 Received: from mailout04.t-online.de ([194.25.134.18]) by www.linuxtv.org with esmtps (TLS1.3:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.92) (envelope-from ) id 1pyzNH-005GYd-Ge for vdr@linuxtv.org; Tue, 16 May 2023 18:26:15 +0000 Received: from fwd81.dcpf.telekom.de (fwd81.aul.t-online.de [10.223.144.107]) by mailout04.t-online.de (Postfix) with SMTP id B4D06E6A9; Tue, 16 May 2023 20:25:21 +0200 (CEST) Received: from fli4l.lan.fli4l ([91.58.6.127]) by fwd81.t-online.de with (TLSv1.2:ECDHE-RSA-AES256-GCM-SHA384 encrypted) esmtp id 1pyzMO-4GWDsv0; Tue, 16 May 2023 20:25:20 +0200 Received: from bruckner.lan.fli4l ([192.168.1.1]:53826) by fli4l.lan.fli4l with esmtp (Exim 4.96) (envelope-from ) id 1pyzMO-0007vP-1U; Tue, 16 May 2023 20:25:20 +0200 From: Bernd Kuhls To: vdr@linuxtv.org Date: Tue, 16 May 2023 20:25:16 +0200 Message-Id: <20230516182517.999918-3-bernd.kuhls@t-online.de> X-Mailer: git-send-email 2.39.2 In-Reply-To: <20230516182517.999918-1-bernd.kuhls@t-online.de> References: <20230516182517.999918-1-bernd.kuhls@t-online.de> MIME-Version: 1.0 X-Spam-Score: -2.5 (--) X-TOI-EXPURGATEID: 150726::1684261520-D97F8DA8-FCF5E2FE/0/0 CLEAN NORMAL X-TOI-MSGID: 13452b36-1c67-4ce4-bcf4-10579f4a7d56 X-LSpam-Score: -2.6 (--) X-LSpam-Report: No, score=-2.6 required=5.0 tests=BAYES_00=-1.9, RCVD_IN_DNSWL_LOW=-0.7, RCVD_IN_MSPIKE_H3=0.001, RCVD_IN_MSPIKE_WL=0.001 autolearn=ham autolearn_force=no Subject: [vdr] [PATCH 3/4] i18n.c: _nl_msg_cat_cntr is an internal symbol of some intl implementation X-BeenThere: vdr@linuxtv.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: VDR Mailing List List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Reply-To: VDR Mailing List Cc: Thomas Petazzoni Errors-To: vdr-bounces@linuxtv.org Sender: "vdr" From: Thomas Petazzoni It is supported by glibc and uClibc (which both define __GLIBC__) but not musl (which doesn't define __GLIBC__). On musl, it doesn't do anything because musl has a basic NLS implementation. Even gettext-tiny defines _nl_msg_cat_cntr as a dummy symbol in its stub libintl-musl implementation. Signed-off-by: Thomas Petazzoni Signed-off-by: Bernd Kuhls --- i18n.c | 2 ++ 1 file changed, 2 insertions(+) diff --git a/i18n.c b/i18n.c index d77e82c1..e4bc54f2 100644 --- a/i18n.c +++ b/i18n.c @@ -124,8 +124,10 @@ static const char *SkipContext(const char *s) static void SetEnvLanguage(const char *Locale) { setenv("LANGUAGE", Locale, 1); +#if defined(__GLIBC__) extern int _nl_msg_cat_cntr; ++_nl_msg_cat_cntr; +#endif } static void SetLanguageNames(void)