From: Romain Naour <romain.naour@gmail.com>
To: buildroot@busybox.net
Subject: [Buildroot] [PATCH v3 5/7] package/diffutils: disable getopt_long replacement with glibc
Date: Sat, 23 Sep 2017 23:24:04 +0200 [thread overview]
Message-ID: <20170923212414.16744-6-romain.naour@gmail.com> (raw)
In-Reply-To: <20170923212414.16744-1-romain.naour@gmail.com>
Since glibc >= 2.26, don't try to use getopt_long replacement bundled
with diffutils. It will conflict with the one from glibc.
The getopt copy bundled in glibc has been updated with the one from gnulib.
After a lot of warnings...
Fixes:
xstrtol-error.c: In function 'xstrtol_error':
xstrtol-error.c:84:26: error: invalid use of undefined type 'struct rpl_option'
option = long_options[opt_idx].name;
^
xstrtol-error.c:84:26: error: dereferencing pointer to incomplete type 'const struct rpl_option'
[...]
xstrtol-error.c:92:1: error: conflicting types for 'xstrtol_fatal'
xstrtol_fatal (enum strtol_error err,
^~~~~~~~~~~~~
In file included from xstrtol-error.c:20:0:
xstrtol.h:69:16: note: previous declaration of 'xstrtol_fatal' was here
_Noreturn void xstrtol_fatal (enum strtol_error,
^~~~~~~~~~~~~
Signed-off-by: Romain Naour <romain.naour@gmail.com>
---
package/diffutils/diffutils.mk | 6 ++++++
1 file changed, 6 insertions(+)
diff --git a/package/diffutils/diffutils.mk b/package/diffutils/diffutils.mk
index 6e5b9b6..79785d6 100644
--- a/package/diffutils/diffutils.mk
+++ b/package/diffutils/diffutils.mk
@@ -11,6 +11,12 @@ DIFFUTILS_DEPENDENCIES = $(TARGET_NLS_DEPENDENCIES)
DIFFUTILS_LICENSE = GPL-3.0+
DIFFUTILS_LICENSE_FILES = COPYING
+# Since glibc >= 2.26, don't try to use getopt_long replacement bundled
+# with diffutils. It will conflict with the one from glibc.
+ifeq ($(BR2_TOOLCHAIN_USES_GLIBC),y)
+DIFFUTILS_CONF_ENV += gl_cv_func_getopt_gnu=yes
+endif
+
ifeq ($(BR2_PACKAGE_BUSYBOX),y)
DIFFUTILS_DEPENDENCIES += busybox
endif
--
2.9.5
next prev parent reply other threads:[~2017-09-23 21:24 UTC|newest]
Thread overview: 28+ messages / expand[flat|nested] mbox.gz Atom feed top
2017-09-23 21:23 [Buildroot] [PATCH v3 0/7] glibc: bump to 2.26 Romain Naour
2017-09-23 21:24 ` [Buildroot] [PATCH v3 1/7] package/gcc: fix build issue with glibc 2.26 Romain Naour
2017-09-27 20:29 ` Yann E. MORIN
2017-09-23 21:24 ` [Buildroot] [PATCH v3 2/7] " Romain Naour
2017-09-27 20:29 ` Yann E. MORIN
2017-09-23 21:24 ` [Buildroot] [PATCH v3 3/7] package/glibc: needs kernel headers >= 3.10 on powerpc64le Romain Naour
2017-09-27 20:32 ` Yann E. MORIN
2017-09-23 21:24 ` [Buildroot] [PATCH v3 4/7] package/gcc: enable float128 on powerpc64le with glibc >= 2.26 toolchains Romain Naour
2017-09-27 20:40 ` Yann E. MORIN
2017-09-27 21:14 ` Arnout Vandecappelle
2017-09-23 21:24 ` Romain Naour [this message]
2017-09-27 21:01 ` [Buildroot] [PATCH v3 5/7] package/diffutils: disable getopt_long replacement with glibc Yann E. MORIN
2017-09-23 21:24 ` [Buildroot] [PATCH v3 6/7] package/flex: disable reallocarray Romain Naour
2017-09-27 21:05 ` Yann E. MORIN
2017-09-27 21:11 ` Romain Naour
2017-09-23 21:24 ` [Buildroot] [PATCH v3 7/7] package/glibc: bump to 2.26 Romain Naour
2017-09-24 9:16 ` Bernd Kuhls
2017-09-23 21:24 ` [Buildroot] [PATCH v3 0/7] glibc: " Romain Naour
2017-09-23 21:28 ` Romain Naour
2017-09-23 21:24 ` [Buildroot] [PATCH v3 1/7] package/gcc: fix build issue with glibc 2.26 Romain Naour
2017-09-23 21:24 ` [Buildroot] [PATCH v3 2/7] " Romain Naour
2017-09-23 21:24 ` [Buildroot] [PATCH v3 3/7] package/glibc: needs kernel headers >= 3.10 on powerpc64le Romain Naour
2017-09-23 21:24 ` [Buildroot] [PATCH v3 4/7] package/gcc: enable float128 on powerpc64le with glibc >= 2.26 toolchains Romain Naour
2017-09-23 21:24 ` [Buildroot] [PATCH v3 5/7] package/diffutils: disable getopt_long replacement with glibc Romain Naour
2017-09-23 21:24 ` [Buildroot] [PATCH v3 6/7] package/flex: disable reallocarray Romain Naour
2017-09-23 21:24 ` [Buildroot] [PATCH v3 7/7] package/glibc: bump to 2.26 Romain Naour
2017-09-27 21:12 ` [Buildroot] [PATCH v3 0/7] glibc: " Arnout Vandecappelle
2017-10-16 16:25 ` Yann E. MORIN
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=20170923212414.16744-6-romain.naour@gmail.com \
--to=romain.naour@gmail.com \
--cc=buildroot@busybox.net \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox