mail archive of the barebox mailing list
 help / color / mirror / Atom feed
From: Sascha Hauer <s.hauer@pengutronix.de>
To: Barebox List <barebox@lists.infradead.org>
Subject: [PATCH 01/10] MAKEALL: Configure before setting up CROSS_COMPILE
Date: Tue,  2 May 2023 09:39:16 +0200	[thread overview]
Message-ID: <20230502073925.266116-2-s.hauer@pengutronix.de> (raw)
In-Reply-To: <20230502073925.266116-1-s.hauer@pengutronix.de>

Do make defconfig before setting up CROSS_COMPILE. This will allow
us to select a ARM 32/64 bit toolchain from .config in the next step.

Signed-off-by: Sascha Hauer <s.hauer@pengutronix.de>
---
 MAKEALL | 19 ++++++++++---------
 1 file changed, 10 insertions(+), 9 deletions(-)

diff --git a/MAKEALL b/MAKEALL
index b4cf4c649b..ad95cfe040 100755
--- a/MAKEALL
+++ b/MAKEALL
@@ -98,6 +98,12 @@ do_build_target() {
 
 	tmp=$(echo "${target}" | tr - _)
 
+	MAKE="make -j${JOBS} ARCH=${arch} O=${BUILDDIR}"
+	${MAKE} ${target} 2>&1 > "${log_report}" | tee "${log_err}"
+
+	check_pipe_status
+	configure_result="$?"
+
 	cross_compile=$(eval echo '$CROSS_COMPILE_'${tmp})
 	cross_compile_set=$(eval echo '${CROSS_COMPILE_'${tmp}'+set}')
 	if [ "${cross_compile_set}" = "" ]
@@ -110,25 +116,20 @@ do_build_target() {
 		fi
 	fi
 
-	MAKE="make -j${JOBS} CROSS_COMPILE=${cross_compile} ARCH=${arch} O=${BUILDDIR}"
-	${MAKE} ${target} 2>&1 > "${log_report}" | tee "${log_err}"
-
-	check_pipe_status
-	result="$?"
-
 	printf "Configure: " | tee -a "${log_report}"
 
-	if [ "$result" = "0" ]; then
+	if [ "$configure_result" = "0" ]; then
 		printf "OK     \n" | tee -a "${log_report}"
 
+		MAKE="make -j${JOBS} CROSS_COMPILE=${cross_compile} ARCH=${arch} O=${BUILDDIR}"
 		${MAKE} -s 2>&1 >> "${log_report}" | tee -a "${log_err}"
 
 		check_pipe_status
-		result="$?"
+		compile_result="$?"
 
 		printf "Compile: " ${target} | tee -a "${log_report}"
 
-		if [ "$result" = "0" ]; then
+		if [ "$compile_result" = "0" ]; then
 			printf "OK     \n" | tee -a "${log_report}"
 			${cross_compile}size ${BUILDDIR}/barebox | tee -a "${log_report}"
 		else
-- 
2.39.2




  reply	other threads:[~2023-05-02  7:41 UTC|newest]

Thread overview: 11+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2023-05-02  7:39 [PATCH 00/10] MAKEALL updates Sascha Hauer
2023-05-02  7:39 ` Sascha Hauer [this message]
2023-05-02  7:39 ` [PATCH 02/10] MAKEALL: Select arm64 toolchain for 64bit ARM configs Sascha Hauer
2023-05-02  7:39 ` [PATCH 03/10] MAKEALL: order configs alphabetically Sascha Hauer
2023-05-02  7:39 ` [PATCH 04/10] MAKEALL: Do not print sizes Sascha Hauer
2023-05-02  7:39 ` [PATCH 05/10] MAKEALL: Do not trap Sascha Hauer
2023-05-02  7:39 ` [PATCH 06/10] MAKEALL: fix printing number of compiled configs Sascha Hauer
2023-05-02  7:39 ` [PATCH 07/10] MAKEALL: support Kconfig fragments Sascha Hauer
2023-05-02  7:39 ` [PATCH 08/10] MAKEALL: rename variables Sascha Hauer
2023-05-02  7:39 ` [PATCH 09/10] MAKEALL: separate errors and warnings Sascha Hauer
2023-05-02  7:39 ` [PATCH 10/10] MAKEALL: allow multiple defconfigs as arguments Sascha Hauer

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=20230502073925.266116-2-s.hauer@pengutronix.de \
    --to=s.hauer@pengutronix.de \
    --cc=barebox@lists.infradead.org \
    /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