* [PATCH] MAKEALL: add incremental build support
@ 2023-06-19 9:46 Ahmad Fatoum
2023-06-21 7:54 ` Sascha Hauer
0 siblings, 1 reply; 2+ messages in thread
From: Ahmad Fatoum @ 2023-06-19 9:46 UTC (permalink / raw)
To: barebox; +Cc: Ahmad Fatoum
MAKEALL always deletes the build directory, before starting. Add a
command line option to make this configurable.
Signed-off-by: Ahmad Fatoum <a.fatoum@pengutronix.de>
---
MAKEALL | 8 ++++++--
1 file changed, 6 insertions(+), 2 deletions(-)
diff --git a/MAKEALL b/MAKEALL
index a4e268d54cf8..f2e774cf88be 100755
--- a/MAKEALL
+++ b/MAKEALL
@@ -53,6 +53,7 @@ usage() {
echo "LOGDIR -l log dir"
echo "REGEX -e regex"
echo "KCONFIG_ADD -k kconfig fragment"
+ echo "INCREMENTAL -i"
echo ""
}
@@ -89,7 +90,7 @@ do_build_target() {
local log_report="${LOGDIR}/${target}/report.log"
local log_err="${LOGDIR}/${target}/errors.log"
- rm -rf "${BUILDDIR}"
+ [ "$INCREMENTAL" != "1" ] && rm -rf "${BUILDDIR}"
mkdir -p "${LOGDIR}/${target}"
printf "Building ${arch} ${target} \n" >&2 | tee -a "${log_report}"
@@ -196,7 +197,7 @@ do_build_all() {
return $build_target
}
-while getopts "hc:j:O:l:a:e:k:" Option
+while getopts "hc:j:O:l:a:e:k:i" Option
do
case $Option in
a )
@@ -220,6 +221,9 @@ case $Option in
k )
KCONFIG_ADD="${KCONFIG_ADD} ${OPTARG}"
;;
+ i )
+ INCREMENTAL=1
+ ;;
h )
usage
exit 0
--
2.39.2
^ permalink raw reply [flat|nested] 2+ messages in thread
* Re: [PATCH] MAKEALL: add incremental build support
2023-06-19 9:46 [PATCH] MAKEALL: add incremental build support Ahmad Fatoum
@ 2023-06-21 7:54 ` Sascha Hauer
0 siblings, 0 replies; 2+ messages in thread
From: Sascha Hauer @ 2023-06-21 7:54 UTC (permalink / raw)
To: Ahmad Fatoum; +Cc: barebox
On Mon, Jun 19, 2023 at 11:46:51AM +0200, Ahmad Fatoum wrote:
> MAKEALL always deletes the build directory, before starting. Add a
> command line option to make this configurable.
>
> Signed-off-by: Ahmad Fatoum <a.fatoum@pengutronix.de>
> ---
> MAKEALL | 8 ++++++--
> 1 file changed, 6 insertions(+), 2 deletions(-)
Applied, thanks
Sascha
>
> diff --git a/MAKEALL b/MAKEALL
> index a4e268d54cf8..f2e774cf88be 100755
> --- a/MAKEALL
> +++ b/MAKEALL
> @@ -53,6 +53,7 @@ usage() {
> echo "LOGDIR -l log dir"
> echo "REGEX -e regex"
> echo "KCONFIG_ADD -k kconfig fragment"
> + echo "INCREMENTAL -i"
> echo ""
> }
>
> @@ -89,7 +90,7 @@ do_build_target() {
> local log_report="${LOGDIR}/${target}/report.log"
> local log_err="${LOGDIR}/${target}/errors.log"
>
> - rm -rf "${BUILDDIR}"
> + [ "$INCREMENTAL" != "1" ] && rm -rf "${BUILDDIR}"
> mkdir -p "${LOGDIR}/${target}"
> printf "Building ${arch} ${target} \n" >&2 | tee -a "${log_report}"
>
> @@ -196,7 +197,7 @@ do_build_all() {
> return $build_target
> }
>
> -while getopts "hc:j:O:l:a:e:k:" Option
> +while getopts "hc:j:O:l:a:e:k:i" Option
> do
> case $Option in
> a )
> @@ -220,6 +221,9 @@ case $Option in
> k )
> KCONFIG_ADD="${KCONFIG_ADD} ${OPTARG}"
> ;;
> + i )
> + INCREMENTAL=1
> + ;;
> h )
> usage
> exit 0
> --
> 2.39.2
>
>
>
--
Pengutronix e.K. | |
Steuerwalder Str. 21 | http://www.pengutronix.de/ |
31137 Hildesheim, Germany | Phone: +49-5121-206917-0 |
Amtsgericht Hildesheim, HRA 2686 | Fax: +49-5121-206917-5555 |
^ permalink raw reply [flat|nested] 2+ messages in thread
end of thread, other threads:[~2023-06-21 7:55 UTC | newest]
Thread overview: 2+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2023-06-19 9:46 [PATCH] MAKEALL: add incremental build support Ahmad Fatoum
2023-06-21 7:54 ` Sascha Hauer
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox