From: "Yann E. MORIN" <yann.morin.1998@free.fr>
To: Thomas Petazzoni <thomas.petazzoni@bootlin.com>
Cc: James Hilliard <james.hilliard1@gmail.com>,
Buildroot List <buildroot@buildroot.org>
Subject: Re: [Buildroot] [PATCH 6/7] support/scripts/gen-bootlin-toolchains: properly take into account !BR2_STATIC_LIBS for glibc toolchains
Date: Sun, 5 Jun 2022 22:28:03 +0200 [thread overview]
Message-ID: <20220605202803.GV427639@scaer> (raw)
In-Reply-To: <20220605202411.GU427639@scaer>
Thomas, All,
On 2022-06-05 22:24 +0200, Yann E. MORIN spake thusly:
> On 2022-06-05 21:42 +0200, Thomas Petazzoni spake thusly:
> > The Config.in options created for each toolchain were properly taking
> > into account the !BR2_STATIC_LIBS dependency of glibc
> > toolchains. However, this dependency was not taken into account into
> > the main BR2_TOOLCHAIN_EXTERNAL_BOOTLIN_ARCH_SUPPORTS
> > option. Consequently, if an architecture is only supported by glibc,
> > but BR2_STATIC_LIBS is enabled, the main "Bootlin toolchain" option
> > was visible... but with no selectable toolchain.
> >
> > We fix this by making sure that
> > BR2_TOOLCHAIN_EXTERNAL_BOOTLIN_ARCH_SUPPORTS is only true for all
> > architectures supported, taking into account the fact that some
> > architectures can only be supported if !BR2_STATIC_LIBS, when the only
> > available C library is glibc.
> >
> > Signed-off-by: Thomas Petazzoni <thomas.petazzoni@bootlin.com>
> > ---
> > support/scripts/gen-bootlin-toolchains | 5 ++++-
> > 1 file changed, 4 insertions(+), 1 deletion(-)
> >
> > diff --git a/support/scripts/gen-bootlin-toolchains b/support/scripts/gen-bootlin-toolchains
> > index f9dd9da9a8..97a744340a 100755
> > --- a/support/scripts/gen-bootlin-toolchains
> > +++ b/support/scripts/gen-bootlin-toolchains
> > @@ -482,7 +482,10 @@ def gen_config_in_options(toolchains, fpath):
> > f.write("config BR2_TOOLCHAIN_EXTERNAL_BOOTLIN_ARCH_SUPPORTS\n")
> > f.write("\tbool\n")
> > for arch, details in arches.items():
> > - f.write("\tdefault y if %s\n" % " && ".join(details['conditions']))
> > + conditions = details['conditions'].copy()
> > + if set([t.libc for t in toolchains if t.arch == arch]) == set(['glibc']):
>
> What about:
> if 'glibc' in [t.libc for t in toolchains if t.arch == arch]
Nah, that does not test that there is *only* glibc; forget it...
Regards,
Yann E. MORIN.
>
> > + conditions.append("!BR2_STATIC_LIBS")
> > + f.write("\tdefault y if %s\n" % " && ".join(conditions))
> > f.write("\n")
> >
> > f.write("if BR2_TOOLCHAIN_EXTERNAL_BOOTLIN\n\n")
> > --
> > 2.35.3
> >
>
> --
> .-----------------.--------------------.------------------.--------------------.
> | Yann E. MORIN | Real-Time Embedded | /"\ ASCII RIBBON | Erics' conspiracy: |
> | +33 662 376 056 | Software Designer | \ / CAMPAIGN | ___ |
> | +33 561 099 427 `------------.-------: X AGAINST | \e/ There is no |
> | http://ymorin.is-a-geek.org/ | _/*\_ | / \ HTML MAIL | v conspiracy. |
> '------------------------------^-------^------------------^--------------------'
> _______________________________________________
> buildroot mailing list
> buildroot@buildroot.org
> https://lists.buildroot.org/mailman/listinfo/buildroot
--
.-----------------.--------------------.------------------.--------------------.
| Yann E. MORIN | Real-Time Embedded | /"\ ASCII RIBBON | Erics' conspiracy: |
| +33 662 376 056 | Software Designer | \ / CAMPAIGN | ___ |
| +33 561 099 427 `------------.-------: X AGAINST | \e/ There is no |
| http://ymorin.is-a-geek.org/ | _/*\_ | / \ HTML MAIL | v conspiracy. |
'------------------------------^-------^------------------^--------------------'
_______________________________________________
buildroot mailing list
buildroot@buildroot.org
https://lists.buildroot.org/mailman/listinfo/buildroot
next prev parent reply other threads:[~2022-06-05 20:28 UTC|newest]
Thread overview: 16+ messages / expand[flat|nested] mbox.gz Atom feed top
2022-06-05 19:42 [Buildroot] [PATCH 0/7] Fix a number of toolchain dependency issues Thomas Petazzoni via buildroot
2022-06-05 19:42 ` [Buildroot] [PATCH 1/7] package/uclibc: introduce and use BR2_PACKAGE_UCLIBC_ARCH_SUPPORTS and BR2_PACKAGE_UCLIBC_SUPPORTS Thomas Petazzoni via buildroot
2022-06-05 19:42 ` [Buildroot] [PATCH 2/7] package/glibc: introduce and use BR2_PACKAGE_GLIBC_ARCH_SUPPORTS and BR2_PACKAGE_GLIBC_SUPPORTS Thomas Petazzoni via buildroot
2022-06-05 19:42 ` [Buildroot] [PATCH 3/7] package/musl: introduce and use BR2_PACKAGE_MUSL_ARCH_SUPPORTS and BR2_PACKAGE_MUSL_SUPPORTS Thomas Petazzoni via buildroot
2022-06-05 19:42 ` [Buildroot] [PATCH 4/7] Config.in: only allow BR2_STATIC_LIBS on supported libc/arch Thomas Petazzoni via buildroot
2022-06-05 19:42 ` [Buildroot] [PATCH 5/7] arch/Config.in.powerpc: disable some variants on ppc64le Thomas Petazzoni via buildroot
2022-06-06 9:45 ` Romain Naour
2022-06-07 2:41 ` Joel Stanley
2022-06-05 19:42 ` [Buildroot] [PATCH 6/7] support/scripts/gen-bootlin-toolchains: properly take into account !BR2_STATIC_LIBS for glibc toolchains Thomas Petazzoni via buildroot
2022-06-05 20:24 ` Yann E. MORIN
2022-06-05 20:28 ` Yann E. MORIN [this message]
2022-06-05 21:57 ` Thomas Petazzoni via buildroot
2022-06-05 21:56 ` Thomas Petazzoni via buildroot
2022-06-05 19:42 ` [Buildroot] [PATCH 7/7] toolchain/toolchain-external/toolchain-external-bootlin: regenerate with correct !BR2_STATIC_LIBS handling Thomas Petazzoni via buildroot
2022-06-06 10:24 ` [Buildroot] [PATCH 0/7] Fix a number of toolchain dependency issues Yann E. MORIN
2022-06-06 13:17 ` 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=20220605202803.GV427639@scaer \
--to=yann.morin.1998@free.fr \
--cc=buildroot@buildroot.org \
--cc=james.hilliard1@gmail.com \
--cc=thomas.petazzoni@bootlin.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