[dpkg] 115/187: libcompat: Disable gettext support in getopt module

Reiner Herrmann reiner at reiner-h.de
Sun Nov 6 12:46:31 UTC 2016


This is an automated email from the git hooks/post-receive script.

deki-guest pushed a commit to branch master
in repository dpkg.

commit 322a17a9df9f4adfc029e3a40b185439b6acb224
Author: Guillem Jover <guillem at debian.org>
Date:   Sun Aug 28 02:24:56 2016 +0200

    libcompat: Disable gettext support in getopt module
    
    We do not carry translations for this module, and it makes it pull
    libintl for programs that might not use it otherwise.
---
 debian/changelog    |  3 +++
 lib/compat/getopt.c | 11 +++--------
 2 files changed, 6 insertions(+), 8 deletions(-)

diff --git a/debian/changelog b/debian/changelog
index f1b7ef1..bd4658d 100644
--- a/debian/changelog
+++ b/debian/changelog
@@ -59,6 +59,9 @@ dpkg (1.18.11) UNRELEASED; urgency=medium
     - Add <sys/sysmacros.h> on AIX for major() and minor().
     - Add missing <errno.h> in libcompat.
     - Include libcompat getopt module when we need getopt_long.
+    - Disable gettext support in libcompat getopt module. We do not carry
+      translations for this module, and it makes it pull libintl for programs
+      that might not use it otherwise.
   * Perl modules:
     - Obsolete Source-Version substvar in Dpkg::Substvars by emitting errors.
     - Rework keyring hooks in Dpkg::Vendor. Deprecate the keyrings hook, and
diff --git a/lib/compat/getopt.c b/lib/compat/getopt.c
index 0a3a47e..4c52b8b 100644
--- a/lib/compat/getopt.c
+++ b/lib/compat/getopt.c
@@ -87,15 +87,10 @@ USA.  */
 #define getpid() GetCurrentProcessId()
 #endif
 
+/* XXX: Disable intl support, because we do not carry the translations anyway
+ * and this pulls indirectly libintl, wich we do not want to impose. */
 #ifndef _
-/* This is for other GNU distributions with internationalized messages.
-   When compiling libc, the _ macro is predefined.  */
-#ifdef HAVE_LIBINTL_H
-# include <libintl.h>
-# define _(msgid)	gettext (msgid)
-#else
-# define _(msgid)	(msgid)
-#endif
+#define _(msgid)	(msgid)
 #endif
 
 /* This version of `getopt' appears to the caller like standard Unix `getopt'

-- 
Alioth's /usr/local/bin/git-commit-notice on /srv/git.debian.org/git/reproducible/dpkg.git



More information about the Reproducible-commits mailing list