From: "J. Neuschäfer via buildroot" <buildroot@buildroot.org>
To: Arnout Vandecappelle <arnout@mind.be>
Cc: "Thomas Petazzoni" <thomas.petazzoni@bootlin.com>,
"J. Neuschäfer" <j.neuschaefer@gmx.net>,
"Yann E. MORIN" <yann.morin.1998@free.fr>,
buildroot@buildroot.org
Subject: Re: [Buildroot] [PATCH v3] Config.in: ban textrels on musl toolchains
Date: Wed, 17 Jul 2024 13:52:13 +0200 [thread overview]
Message-ID: <ZpewbZIQTIENQGmg@probook> (raw)
In-Reply-To: <50c04b02-5140-4c0c-b06d-e80eca7564af@mind.be>
On Mon, Jul 15, 2024 at 10:51:03AM +0200, Arnout Vandecappelle wrote:
> Hi J.,
>
> [BTW are you OK with me calling you "J."? It feels a bit weird...]
It's ok, as well as jn ("jay-enn"). which is also ok.
>
> On 04/07/2024 20:05, J. Neuschäfer via buildroot wrote:
[...]
> > +ifeq ($(BR2_LINK_ALLOW_TEXTREL),)
> > +TARGET_LDFLAGS += -z text
> > +endif
>
> After some discussion, we concluded that we don't see the point of making
> this a user-settable Config.in option. It should be completely in the
> Makefile.in, with a comment explaining why. So something like this
> (untested!):
>
> # musl's dynamic loader doesn't support DT_TEXTREL, which results in a runtime
> # crash if it gets used. The "-z text" linker option issues a build-time error
> # when DT_TEXREL is used, so we capture the problem earlier.
> ifeq ($(BR2_TOOLCHAIN_USES_MUSL)$(BR2_STATIC_LIBS),yy)
> TARGET_LDFLAGS += -#l,-z,text
> endif
>
> Note also that we use -Wl,-z,... everywhere else to pass the -z options to
> the linker. Maybe that's because older GCC don't understand -z. But anyway,
> to be consistent, let's do the same here.
>
> Can you test the above version and resubmit? Oh, and please also in the
> commit message give an example of how you can test it (e.g. by removing the
> micropyton patch and building micropyton under musl?)
Yep, will do!
Thanks again for your review.
jn
_______________________________________________
buildroot mailing list
buildroot@buildroot.org
https://lists.buildroot.org/mailman/listinfo/buildroot
prev parent reply other threads:[~2024-07-17 11:52 UTC|newest]
Thread overview: 4+ messages / expand[flat|nested] mbox.gz Atom feed top
2024-07-04 18:05 [Buildroot] [PATCH v3] Config.in: ban textrels on musl toolchains J. Neuschäfer via buildroot
2024-07-15 8:51 ` Arnout Vandecappelle via buildroot
2024-07-15 9:06 ` Thomas Petazzoni via buildroot
2024-07-17 11:52 ` J. Neuschäfer via buildroot [this message]
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=ZpewbZIQTIENQGmg@probook \
--to=buildroot@buildroot.org \
--cc=arnout@mind.be \
--cc=j.neuschaefer@gmx.net \
--cc=thomas.petazzoni@bootlin.com \
--cc=yann.morin.1998@free.fr \
/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