* [PATCH 1/3] scripts: Make building verbose for better failure analysis
@ 2018-04-12 14:48 Henning Schild
2018-04-12 14:48 ` [PATCH 2/3] scripts/isar-buildenv-internal: Remove unused variable Henning Schild
` (2 more replies)
0 siblings, 3 replies; 6+ messages in thread
From: Henning Schild @ 2018-04-12 14:48 UTC (permalink / raw)
To: isar-users; +Cc: Henning Schild
This will help understand what went wrong when looking at the CI logs
after a build failed. It can also help understanding builds that did not
fail.
Signed-off-by: Henning Schild <henning.schild@siemens.com>
---
scripts/ci_build.sh | 2 +-
scripts/vm_smoke_test | 2 ++
2 files changed, 3 insertions(+), 1 deletion(-)
diff --git a/scripts/ci_build.sh b/scripts/ci_build.sh
index f84fdcf..e941f8c 100755
--- a/scripts/ci_build.sh
+++ b/scripts/ci_build.sh
@@ -22,7 +22,7 @@ fi
source isar-init-build-env /build/$WORKSPACE/$GIT_COMMIT
# Start build for all possible configurations
-bitbake \
+bitbake -v \
multiconfig:qemuarm-wheezy:isar-image-base \
multiconfig:qemuarm-jessie:isar-image-base \
multiconfig:qemuarm-stretch:isar-image-base \
diff --git a/scripts/vm_smoke_test b/scripts/vm_smoke_test
index 60c78da..fde0e05 100755
--- a/scripts/vm_smoke_test
+++ b/scripts/vm_smoke_test
@@ -60,6 +60,8 @@ run_test () {
# Check kernel module
check_example_module
+ dump_boot_log
+
# Clean up test artifacts
rm $CONSOLE_OUTPUT
rm $PID_FILE
--
2.16.1
^ permalink raw reply [flat|nested] 6+ messages in thread
* [PATCH 2/3] scripts/isar-buildenv-internal: Remove unused variable
2018-04-12 14:48 [PATCH 1/3] scripts: Make building verbose for better failure analysis Henning Schild
@ 2018-04-12 14:48 ` Henning Schild
2018-04-23 6:03 ` Baurzhan Ismagulov
2018-04-12 14:48 ` [PATCH 3/3] scripts/start_vm: Deduplicate start_qemu Henning Schild
2018-04-23 6:03 ` [PATCH 1/3] scripts: Make building verbose for better failure analysis Baurzhan Ismagulov
2 siblings, 1 reply; 6+ messages in thread
From: Henning Schild @ 2018-04-12 14:48 UTC (permalink / raw)
To: isar-users; +Cc: Henning Schild
The variable BASEDIR is not used, probably a leftover. Remove it to keep
env clean.
Signed-off-by: Henning Schild <henning.schild@siemens.com>
---
scripts/isar-buildenv-internal | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/scripts/isar-buildenv-internal b/scripts/isar-buildenv-internal
index 94d7eb1..e1f7149 100755
--- a/scripts/isar-buildenv-internal
+++ b/scripts/isar-buildenv-internal
@@ -66,5 +66,5 @@ export PATH
BBPATH="${BUILDDIR}"
export BBPATH
-BB_ENV_EXTRAWHITE="BASEDIR BUILDDIR http_proxy https_proxy ftp_proxy no_proxy"
+BB_ENV_EXTRAWHITE="BUILDDIR http_proxy https_proxy ftp_proxy no_proxy"
export BB_ENV_EXTRAWHITE
--
2.16.1
^ permalink raw reply [flat|nested] 6+ messages in thread
* [PATCH 3/3] scripts/start_vm: Deduplicate start_qemu
2018-04-12 14:48 [PATCH 1/3] scripts: Make building verbose for better failure analysis Henning Schild
2018-04-12 14:48 ` [PATCH 2/3] scripts/isar-buildenv-internal: Remove unused variable Henning Schild
@ 2018-04-12 14:48 ` Henning Schild
2018-04-23 6:06 ` Baurzhan Ismagulov
2018-04-23 6:03 ` [PATCH 1/3] scripts: Make building verbose for better failure analysis Baurzhan Ismagulov
2 siblings, 1 reply; 6+ messages in thread
From: Henning Schild @ 2018-04-12 14:48 UTC (permalink / raw)
To: isar-users; +Cc: Henning Schild
Instead of echoing what we are about to execute, switch the shell to
verbose mode. But only toggle "x" if it was not seet already.
This simplifies the script and future changes will only have to touch
one spot.
Signed-off-by: Henning Schild <henning.schild@siemens.com>
---
scripts/start_vm | 22 ++++++----------------
1 file changed, 6 insertions(+), 16 deletions(-)
diff --git a/scripts/start_vm b/scripts/start_vm
index 4cb05ae..26274be 100755
--- a/scripts/start_vm
+++ b/scripts/start_vm
@@ -17,22 +17,11 @@ bb2sh() {
}
start_qemu() {
- root1=`echo $QEMU_ROOTFS_DEV \
- | sed 's,##ROOTFS_IMAGE##,$IMAGE_DIR/'"$ROOTFS_IMAGE"','`
- echo -e "IMAGE_DIR=$IMAGE_DIR; \\\\\n\
-qemu-system-$QEMU_ARCH \\\\\n\
- -m 1024M \\\\\n\
- -M $QEMU_MACHINE \\\\\n\
- $QCPU\\\\\n\
- -nographic \\\\\n\
- -kernel \$QKERNEL \\\\\n\
- -initrd \$QINITRD \\\\\n\
- -append \"console=$MACHINE_SERIAL root=/dev/$ROOTFS_DEV rw\" \\\\\n\
- $EXTRA_ARGS \\\\\n\
- $root1"
-
- root2=`echo $QEMU_ROOTFS_DEV \
+ root=`echo $QEMU_ROOTFS_DEV \
| sed 's,##ROOTFS_IMAGE##,'$IMAGE_DIR/$ROOTFS_IMAGE','`
+ local had_x
+ echo $- | grep -q x && had_x=1 || had_x=0
+ [ $had_x -eq 0 ] && set -x
qemu-system-$QEMU_ARCH \
-m 1024M \
-M $QEMU_MACHINE \
@@ -42,7 +31,8 @@ qemu-system-$QEMU_ARCH \\\\\n\
-initrd $QINITRD \
-append "console=$MACHINE_SERIAL root=/dev/$ROOTFS_DEV rw" \
$EXTRA_ARGS \
- $root2
+ $root
+ [ $had_x -eq 0 ] && set +x
}
show_help() {
--
2.16.1
^ permalink raw reply [flat|nested] 6+ messages in thread
* Re: [PATCH 1/3] scripts: Make building verbose for better failure analysis
2018-04-12 14:48 [PATCH 1/3] scripts: Make building verbose for better failure analysis Henning Schild
2018-04-12 14:48 ` [PATCH 2/3] scripts/isar-buildenv-internal: Remove unused variable Henning Schild
2018-04-12 14:48 ` [PATCH 3/3] scripts/start_vm: Deduplicate start_qemu Henning Schild
@ 2018-04-23 6:03 ` Baurzhan Ismagulov
2 siblings, 0 replies; 6+ messages in thread
From: Baurzhan Ismagulov @ 2018-04-23 6:03 UTC (permalink / raw)
To: isar-users
On Thu, Apr 12, 2018 at 04:48:55PM +0200, Henning Schild wrote:
> This will help understand what went wrong when looking at the CI logs
> after a build failed. It can also help understanding builds that did not
> fail.
Thanks, applied.
With kind regards,
Baurzhan.
^ permalink raw reply [flat|nested] 6+ messages in thread
* Re: [PATCH 2/3] scripts/isar-buildenv-internal: Remove unused variable
2018-04-12 14:48 ` [PATCH 2/3] scripts/isar-buildenv-internal: Remove unused variable Henning Schild
@ 2018-04-23 6:03 ` Baurzhan Ismagulov
0 siblings, 0 replies; 6+ messages in thread
From: Baurzhan Ismagulov @ 2018-04-23 6:03 UTC (permalink / raw)
To: isar-users
On Thu, Apr 12, 2018 at 04:48:56PM +0200, Henning Schild wrote:
> The variable BASEDIR is not used, probably a leftover. Remove it to keep
> env clean.
Thanks, applied.
With kind regards,
Baurzhan.
^ permalink raw reply [flat|nested] 6+ messages in thread
* Re: [PATCH 3/3] scripts/start_vm: Deduplicate start_qemu
2018-04-12 14:48 ` [PATCH 3/3] scripts/start_vm: Deduplicate start_qemu Henning Schild
@ 2018-04-23 6:06 ` Baurzhan Ismagulov
0 siblings, 0 replies; 6+ messages in thread
From: Baurzhan Ismagulov @ 2018-04-23 6:06 UTC (permalink / raw)
To: isar-users
On Thu, Apr 12, 2018 at 04:48:57PM +0200, Henning Schild wrote:
> Instead of echoing what we are about to execute, switch the shell to
> verbose mode. But only toggle "x" if it was not seet already.
>
> This simplifies the script and future changes will only have to touch
> one spot.
Thanks, applied.
In the future, I'd like to have something like do_and_log
qemu-system-$QEMU_ARCH args...
With kind regards,
Baurzhan.
^ permalink raw reply [flat|nested] 6+ messages in thread
end of thread, other threads:[~2018-04-23 6:06 UTC | newest]
Thread overview: 6+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2018-04-12 14:48 [PATCH 1/3] scripts: Make building verbose for better failure analysis Henning Schild
2018-04-12 14:48 ` [PATCH 2/3] scripts/isar-buildenv-internal: Remove unused variable Henning Schild
2018-04-23 6:03 ` Baurzhan Ismagulov
2018-04-12 14:48 ` [PATCH 3/3] scripts/start_vm: Deduplicate start_qemu Henning Schild
2018-04-23 6:06 ` Baurzhan Ismagulov
2018-04-23 6:03 ` [PATCH 1/3] scripts: Make building verbose for better failure analysis Baurzhan Ismagulov
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox