From: Arnout Vandecappelle <arnout@mind.be>
To: Thomas Petazzoni <thomas.petazzoni@bootlin.com>,
"Yann E. MORIN" <yann.morin.1998@free.fr>,
Romain Naour <romain.naour@gmail.com>,
Buildroot List <buildroot@buildroot.org>
Cc: Giulio Benetti <giulio.benetti@benettiengineering.com>,
Thomas De Schampheleire <thomas.de_schampheleire@nokia.com>
Subject: Re: [Buildroot] [PATCH v2 07/14] toolchain/toolchain-external: add BR2_TOOLCHAIN_EXTERNAL_HAS_NO_GDBSERVER option
Date: Tue, 14 Jun 2022 17:34:20 +0200 [thread overview]
Message-ID: <12178427-e595-be4e-5da5-d4cf1718b9e2@mind.be> (raw)
In-Reply-To: <20220608071027.3384469-8-thomas.petazzoni@bootlin.com>
On 08/06/2022 09:10, Thomas Petazzoni via buildroot wrote:
> Some external toolchains do not have gdbserver available, but the
> option BR2_TOOLCHAIN_EXTERNAL_GDB_SERVER_COPY is always visible. And
> when enabled, this option aborts with an error when gdbserver cannot
> be found:
>
> Could not find gdbserver in external toolchain
>
> Due to that, some random configurations fail to build when
> BR2_TOOLCHAIN_EXTERNAL_GDB_SERVER_COPY=y, for example with the Bootlin
> toolchains for Microblaze or OpenRISC (because there's no GDB support
> for those architectures).
>
> One solution could be to make "Could not find gdbserver in external
> toolchain" a warning instead of a hard error, but then nobody would
> notice about this issue, in cases where it should legitimately abort
> with a hard error.
>
> So, the clean solution would be to add a
> BR2_TOOLCHAIN_EXTERNAL_HAS_GDBSERVER. But that means all existing
> external toolchains would have to be modified to select this option.
>
> Instead, and as an exception, we chose to use inverted logic, and
> create an option that is the opposite:
> BR2_TOOLCHAIN_EXTERNAL_HAS_NO_GDBSERVER. By default, we assume
> external toolchains have gdbserver. If
> BR2_TOOLCHAIN_EXTERNAL_HAS_NO_GDBSERVER is enabled, we disallow the
> BR2_TOOLCHAIN_EXTERNAL_GDB_SERVER_COPY option.
>
> Note that the case of custom external toolchain does not matter: by
> definition they are not tested by the autobuilders, and by definition,
> we cannot now in menuconfig if the custom toolchain has or does not
> have gdbserver.
>
> This will help fixing:
>
> http://autobuild.buildroot.net/results/6315ef7b66ee4ae8f870c92186bc674d65f62f2c/
>
> Signed-off-by: Thomas Petazzoni <thomas.petazzoni@bootlin.com>
> ---
> Note: if you want me to go with the positive logic option
> BR2_TOOLCHAIN_EXTERNAL_HAS_GDBSERVER, I'll be happy to provide the
> patches.
> ---
> toolchain/toolchain-external/Config.in | 4 ++++
> 1 file changed, 4 insertions(+)
>
> diff --git a/toolchain/toolchain-external/Config.in b/toolchain/toolchain-external/Config.in
> index 2177e6a678..1a67e5645f 100644
> --- a/toolchain/toolchain-external/Config.in
> +++ b/toolchain/toolchain-external/Config.in
> @@ -155,9 +155,13 @@ source "toolchain/toolchain-external/toolchain-external-bootlin/Config.in.option
> # Custom toolchains
> source "toolchain/toolchain-external/toolchain-external-custom/Config.in.options"
>
> +config BR2_TOOLCHAIN_EXTERNAL_HAS_NO_GDBSERVER
> + bool
> +
> config BR2_TOOLCHAIN_EXTERNAL_GDB_SERVER_COPY
> bool "Copy gdb server to the Target"
> depends on BR2_TOOLCHAIN_EXTERNAL
> + depends on !BR2_TOOLCHAIN_EXTERNAL_HAS_NO_GDBSERVER
This could have been simplified to
depends on BR2_PACKAGE_GDB_ARCH_SUPPORTS
but this way is more flexible so better I guess.
Regards,
Arnout
> help
> Copy the gdbserver provided by the external toolchain to the
> target.
_______________________________________________
buildroot mailing list
buildroot@buildroot.org
https://lists.buildroot.org/mailman/listinfo/buildroot
next prev parent reply other threads:[~2022-06-14 15:34 UTC|newest]
Thread overview: 20+ messages / expand[flat|nested] mbox.gz Atom feed top
2022-06-08 7:10 [Buildroot] [PATCH v2 00/14] Another set of Bootlin toolchain integration improvements Thomas Petazzoni via buildroot
2022-06-08 7:10 ` [Buildroot] [PATCH v2 01/14] support/scripts/gen-bootlin-toolchains: fix RISC-V 64-bit toolchain description Thomas Petazzoni via buildroot
2022-06-08 7:10 ` [Buildroot] [PATCH v2 02/14] support/testing, toolchain/toolchain-external/toolchain-external-bootlin: regenerate with latest gen-bootlin-toolchains script Thomas Petazzoni via buildroot
2022-06-08 7:10 ` [Buildroot] [PATCH v2 03/14] support/scripts/gen-bootlin-toolchains: improve dependencies of ARM toolchains Thomas Petazzoni via buildroot
2022-06-08 7:10 ` [Buildroot] [PATCH v2 04/14] toolchain/toolchain-external/toolchain-external-bootlin: regenerate with BR2_ARM dependency Thomas Petazzoni via buildroot
2022-06-08 7:10 ` [Buildroot] [PATCH v2 05/14] support/scripts/gen-bootlin-toolchains: adjust dependencies of i686 toolchains Thomas Petazzoni via buildroot
2022-06-08 7:10 ` [Buildroot] [PATCH v2 06/14] toolchain/toolchain-external/toolchain-external-bootlin: regenerate after i686 toolchain dependency fixes Thomas Petazzoni via buildroot
2022-06-08 7:10 ` [Buildroot] [PATCH v2 07/14] toolchain/toolchain-external: add BR2_TOOLCHAIN_EXTERNAL_HAS_NO_GDBSERVER option Thomas Petazzoni via buildroot
2022-06-14 15:34 ` Arnout Vandecappelle [this message]
2022-06-14 15:58 ` Thomas Petazzoni via buildroot
2022-06-14 16:56 ` Arnout Vandecappelle
2022-06-14 21:41 ` Thomas Petazzoni via buildroot
2022-06-08 7:10 ` [Buildroot] [PATCH v2 08/14] support/scripts/gen-bootlin-toolchains: make use of BR2_TOOLCHAIN_EXTERNAL_HAS_NO_GDBSERVER Thomas Petazzoni via buildroot
2022-06-08 7:10 ` [Buildroot] [PATCH v2 09/14] toolchain/toolchain-external/toolchain-external-bootlin: regenerate with BR2_TOOLCHAIN_EXTERNAL_HAS_NO_GDBSERVER Thomas Petazzoni via buildroot
2022-06-08 7:10 ` [Buildroot] [PATCH v2 10/14] support/scripts/gen-bootlin-toolchains: check that toolchains exists for a certain arch Thomas Petazzoni via buildroot
2022-06-08 7:10 ` [Buildroot] [PATCH v2 11/14] support/scripts/gen-bootlin-toolchains: drop "mips64" architecture variant Thomas Petazzoni via buildroot
2022-06-08 7:10 ` [Buildroot] [PATCH v2 12/14] toolchain/toolchain-external/toolchain-external-bootlin: regenerate after mips64 toolchain removal Thomas Petazzoni via buildroot
2022-06-08 7:10 ` [Buildroot] [PATCH v2 13/14] support/scripts/gen-bootlin-toolchains: add support for ARMv7 big endian toolchain Thomas Petazzoni via buildroot
2022-06-08 7:10 ` [Buildroot] [PATCH v2 14/14] support/testing, toolchain/toolchain-external/toolchain-external-bootlin: regenerate with " Thomas Petazzoni via buildroot
2022-06-14 15:43 ` [Buildroot] [PATCH v2 00/14] Another set of Bootlin toolchain integration improvements Arnout Vandecappelle
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=12178427-e595-be4e-5da5-d4cf1718b9e2@mind.be \
--to=arnout@mind.be \
--cc=buildroot@buildroot.org \
--cc=giulio.benetti@benettiengineering.com \
--cc=romain.naour@gmail.com \
--cc=thomas.de_schampheleire@nokia.com \
--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