From: Tom Tromey <tom@tromey.com>
To: Tsukasa OI <research_trasio@irq.a4lg.com>
Cc: Tom Tromey <tom@tromey.com>, gdb-patches@sourceware.org
Subject: Re: [PATCH] sim, sim/m32c, sim/rl78: Use getopt_long
Date: Tue, 25 Oct 2022 10:54:41 -0600 [thread overview]
Message-ID: <87y1t3c08e.fsf@tromey.com> (raw)
In-Reply-To: <2024f524-35e3-cdc6-8098-a220daf30c23@irq.a4lg.com> (Tsukasa OI's message of "Mon, 24 Oct 2022 16:51:00 +0900")
> Glibc (2.25 or before; not too old to drop support) includes <getopt.h>
> from <unistd.h> but this causes <unistd.h> to include Binutils/GCC's
> include/getopt.h. It means, using the filename "getopt.h" in an include
> path (-I) itself is a risk. The only reason it didn't cause a problem
> is most of Binutils/GCC components used getopt_long and
> getopt_long_only, not plain getopt.
What exactly was the problem?
It seems to me that we'd want to use the libiberty getopt.h, because
we're also linking against the linking getopt.
Tom
next prev parent reply other threads:[~2022-10-25 16:54 UTC|newest]
Thread overview: 14+ messages / expand[flat|nested] mbox.gz Atom feed top
[not found] <3b7e769f-b5e9-4049-786f-d00d997f0280@irq.a4lg.com>
2022-10-18 17:13 ` Tsukasa OI
2022-10-21 16:27 ` Tom Tromey
2022-10-24 7:51 ` Tsukasa OI
2022-10-25 5:53 ` Tsukasa OI
2022-10-25 16:54 ` Tom Tromey [this message]
2022-10-25 17:17 ` Tsukasa OI
2022-10-25 19:42 ` Tom Tromey
2022-10-25 6:27 ` [PATCH v2] sim, sim/{m32c,ppc,rl78}: " Tsukasa OI
2022-10-26 8:59 ` Mike Frysinger
2022-10-26 10:57 ` Tsukasa OI
2022-10-26 16:01 ` Mike Frysinger
2022-10-27 1:29 ` Tsukasa OI
2022-10-26 10:59 ` [PATCH v3] " Tsukasa OI
2022-10-27 1:23 ` [PATCH v4] " Tsukasa OI
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=87y1t3c08e.fsf@tromey.com \
--to=tom@tromey.com \
--cc=gdb-patches@sourceware.org \
--cc=research_trasio@irq.a4lg.com \
/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;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).