mail archive of the barebox mailing list
 help / color / mirror / Atom feed
From: Ahmad Fatoum <a.fatoum@pengutronix.de>
To: Sascha Hauer <sha@pengutronix.de>
Cc: BAREBOX <barebox@lists.infradead.org>
Subject: Re: [PATCH v2 1/2] MAKEALL: support direct options for KCONFIG_ADD
Date: Thu, 27 Mar 2025 11:37:37 +0100	[thread overview]
Message-ID: <ea7831f3-fe10-4145-8fd1-37c83f67d111@pengutronix.de> (raw)
In-Reply-To: <20250317113208.1863258-1-a.fatoum@pengutronix.de>

Hello Sascha,

On 3/17/25 12:32, Ahmad Fatoum wrote:
> KCONFIG_ADD currently expects a list of files to be merged.
> As MAKEALL is a bash script, let's make use of process substitution
> to create temporary files out of -k CONFIG_foo=bar options.

Please pick these two patches to the ci branch to workaround the build
breakage there.

Thanks,
Ahmad

> 
> Signed-off-by: Ahmad Fatoum <a.fatoum@pengutronix.de>
> ---
> v1 -> v2:
>   - fix Regex (Sascha)
> ---
>  MAKEALL | 14 +++++++++++---
>  1 file changed, 11 insertions(+), 3 deletions(-)
> 
> diff --git a/MAKEALL b/MAKEALL
> index 1966eedb4673..bc612b45561f 100755
> --- a/MAKEALL
> +++ b/MAKEALL
> @@ -56,7 +56,7 @@ usage() {
>  	echo "BUILDDIR    -O      build dir"
>  	echo "LOGDIR      -l      log dir"
>  	echo "REGEX       -e      regex"
> -	echo "KCONFIG_ADD -k      kconfig fragment"
> +	echo "KCONFIG_ADD -k      kconfig fragment or option"
>  	echo "TARGET      -t      Makefile target"
>  	echo "V           -v      verbosity"
>  	echo "INCREMENTAL -i"
> @@ -116,6 +116,11 @@ report() {
>  	fi
>  }
>  
> +merge_config() {
> +	with_logs_collected ./scripts/kconfig/merge_config.sh -m -O \
> +		${BUILDDIR} "$@"
> +}
> +
>  do_build_defconfig() {
>  	local arch=$1
>  	local defconfig=$2
> @@ -156,8 +161,11 @@ do_build_defconfig() {
>  	MAKE="${MAKE} $silent_flag CROSS_COMPILE=${cross_compile}"
>  	with_logs_collected ${MAKE} ${defconfig}
>  	for i in ${KCONFIG_ADD}; do
> -		with_logs_collected ./scripts/kconfig/merge_config.sh -m -O \
> -			${BUILDDIR} ${BUILDDIR}/.config $i
> +		if [[ $i =~ ^CONFIG_.*=.* ]]; then
> +			merge_config ${BUILDDIR}/.config <(echo $i)
> +		else
> +			merge_config ${BUILDDIR}/.config $i
> +		fi
>  	done
>  	with_logs_collected ${MAKE} $silent_flag olddefconfig
>  




      parent reply	other threads:[~2025-03-27 10:38 UTC|newest]

Thread overview: 4+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2025-03-17 11:32 Ahmad Fatoum
2025-03-17 11:32 ` [PATCH v2 2/2] MAKEALL: parse kconfig_add out of YAML files Ahmad Fatoum
2025-03-17 12:28 ` [PATCH v2 1/2] MAKEALL: support direct options for KCONFIG_ADD Sascha Hauer
2025-03-27 10:37 ` Ahmad Fatoum [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=ea7831f3-fe10-4145-8fd1-37c83f67d111@pengutronix.de \
    --to=a.fatoum@pengutronix.de \
    --cc=barebox@lists.infradead.org \
    --cc=sha@pengutronix.de \
    /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