From: Luis Machado <luis.machado@linaro.org>
To: Alan Modra <amodra@gmail.com>, Tom Tromey <tom@tromey.com>,
Alan Modra via Binutils <binutils@sourceware.org>,
gdb-patches@sourceware.org
Cc: "Thomas Weißschuh" <thomas@t-8ch.de>
Subject: Re: [PATCH] Add startswith function and use it instead of CONST_STRNEQ.
Date: Tue, 30 Mar 2021 08:58:21 -0300 [thread overview]
Message-ID: <b976b345-8b01-d6f1-9535-0b0e3d784eb6@linaro.org> (raw)
In-Reply-To: <cde6b380-0d7e-1cb8-3c8b-88f11d4acada@linaro.org>
Hi Alan, Tom,
On 3/26/21 8:44 AM, Luis Machado wrote:
> On 3/25/21 7:31 PM, Mike Frysinger wrote:
>> On 25 Mar 2021 16:47, Luis Machado wrote:
>>> On 3/25/21 8:54 AM, Alan Modra wrote:
>>>> On Thu, Mar 25, 2021 at 07:53:04AM -0300, Luis Machado wrote:
>>>>> On 3/22/21 7:56 PM, Alan Modra wrote:
>>>>>> On Mon, Mar 22, 2021 at 01:13:00PM -0300, Luis Machado wrote:
>>>>>>> Just FTR, I'm seeing breakage in sim/aarch64 and sim/arm. Both are
>>>>>>> complaining about "-Werror=implicit-function-declaration"
>>>>>>> regarding strncmp
>>>>>>> and strlen.
>>>>>>>
>>>>>>> Is this the breakage you're talking about? Just so I know what to
>>>>>>> expect
>>>>>>> when it gets fixed.
>>>>>>
>>>>>> Yes.
>>>>>>
>>>>>
>>>>> Thanks. Are there plans to address this or should I come up with a
>>>>> patch?
>>>>
>>>> I posted a patch here
>>>> https://sourceware.org/pipermail/binutils/2021-March/115863.html
>>>> It's been tested with gdb, sim and binutils builds.
>>>>
>>>> Tom offered to solve the problem himself, so I'm waiting on that or
>>>> for someone in the gdb camp to review my patch. Since I messed this
>>>> up in the first place by taking a comment by Tom as a go-ahead rather
>>>> than first posting a patch for proper review by gdb maintainers, I'm
>>>> being a little cautious in committing the above patch.
>>>>
>>>
>>> I applied the above patch to today's master binutils-gdb and gave
>>> configure's --enable-targets=all a try, but I ran into the following:
>>>
>>> In file included from ../../../repos/binutils-gdb/bfd/archive.c:135:
>>> ./bfd.h:568:1: error: redefinition of ‘startswith’
>>> 568 | startswith (const char *str, const char *prefix)
>>> | ^~~~~~~~~~
>>> In file included from ../../../repos/binutils-gdb/bfd/sysdep.h:122,
>>> from ../../../repos/binutils-gdb/bfd/archive.c:134:
>>> ../../../repos/binutils-gdb/bfd/../include/str-util.h:23:1: note:
>>> previous definition of ‘startswith’ was here
>>> 23 | startswith (const char *str, const char *prefix)
>>> | ^~~~~~~~~~
>>
>> Alan's patch didn't include the regenerated bfd.h inputs, so you'll
>> have to do that on your side.
>> -mike
>>
>
> Oops. Regenerated now. I gave it a try again and it worked OK.
Given this has been broken for a little while, and given Alan's patch
fixes the problem for arm/aarch64 sims (from what I tested), can we push
this for now and get it addressed in some other way later, if someone
wants it?
I think someone's hit this on riscv as well.
next prev parent reply other threads:[~2021-03-30 11:58 UTC|newest]
Thread overview: 41+ messages / expand[flat|nested] mbox.gz Atom feed top
2021-03-18 14:20 [PATCH] [RFC] Come up with startswith function Martin Liška
2021-03-18 14:54 ` Tom Tromey
2021-03-18 15:26 ` Martin Liška
2021-03-18 18:00 ` Tom Tromey
2021-03-18 18:29 ` Hans-Peter Nilsson
2021-03-19 6:37 ` Alan Modra
2021-03-19 12:44 ` [PATCH] Add startswith function and use it instead of CONST_STRNEQ Martin Liška
2021-03-19 17:55 ` Hans-Peter Nilsson
2021-03-20 7:00 ` Alan Modra
2021-03-20 18:58 ` Tom Tromey
2021-03-21 13:12 ` Alan Modra
2021-03-22 2:13 ` Tom Tromey
2021-03-22 12:06 ` Alan Modra
2021-03-22 16:13 ` Luis Machado
2021-03-22 22:56 ` Alan Modra
2021-03-25 10:53 ` Luis Machado
2021-03-25 11:54 ` Alan Modra
2021-03-25 12:05 ` Luis Machado
2021-03-25 19:47 ` Luis Machado
2021-03-25 22:31 ` Mike Frysinger
2021-03-26 11:44 ` Luis Machado
2021-03-30 11:58 ` Luis Machado [this message]
2021-03-31 13:12 ` Martin Liška
2021-03-31 13:44 ` Luis Machado
2021-03-22 16:42 ` Martin Liška
2021-03-23 0:02 ` Alan Modra
2021-03-23 4:49 ` Mike Frysinger
2021-03-24 8:19 ` [PATCH 0/5] Start using startswith instead of strncmp Martin Liska
2021-03-18 14:16 ` [PATCH 2/5] Use startswith more for strncmp function calls Martin Liska
2021-03-22 11:12 ` [PATCH 1/5] Replace const_strneq with startswith Martin Liska
2021-03-22 12:33 ` [PATCH 3/5] Use startswith in gas subfolder Martin Liska
2021-03-22 13:56 ` [PATCH 4/5] Remove strneq macro and use startswith Martin Liska
2021-03-23 9:02 ` [PATCH 5/5] Use startswith in gdb subfolder Martin Liska
2021-03-31 20:26 ` Tom Tromey
2021-04-01 5:21 ` [PATCH 0/5] Start using startswith instead of strncmp Martin Liška
2021-04-01 12:47 ` Alan Modra
2021-04-01 13:03 ` Martin Liška
2021-03-31 20:18 ` [PATCH] Add startswith function and use it instead of CONST_STRNEQ Tom Tromey
2021-03-22 6:57 ` Mike Frysinger
2021-03-21 13:19 ` Alan Modra
2021-03-22 10:04 ` Martin Liška
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=b976b345-8b01-d6f1-9535-0b0e3d784eb6@linaro.org \
--to=luis.machado@linaro.org \
--cc=amodra@gmail.com \
--cc=binutils@sourceware.org \
--cc=gdb-patches@sourceware.org \
--cc=thomas@t-8ch.de \
--cc=tom@tromey.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).