diff mbox series

[=PATCH,v3,4/4] support/scripts/boot-qemu-image.py: don't fail if start-qemu.sh is missing

Message ID 20201115143609.2160080-4-romain.naour@gmail.com
State Superseded
Headers show
Series [=PATCH,v3,1/4] board/qemu/post-image.sh: rename IMAGE_DIR to BINARIES_DIR | expand

Commit Message

Romain Naour Nov. 15, 2020, 2:36 p.m. UTC
When boot-qemu-image.py script was added, we wanted to run
each qemu defconfig in gitlab, so we expect that all qemu
defconfig generate the script start-qemu.sh in images
directory.

Don't make it a hard requirement even if we prefer to be
able to do a runtime test for each qemu defconfig.

Signed-off-by: Romain Naour <romain.naour@gmail.com>
Cc: Yann E. MORIN <yann.morin.1998@free.fr>
---
 support/scripts/boot-qemu-image.py | 4 ++++
 1 file changed, 4 insertions(+)

Comments

Romain Naour Nov. 15, 2020, 2:41 p.m. UTC | #1
Hello,

This patch should be merged in master in order to avoid this failure in gitlab:

https://gitlab.com/buildroot.org/buildroot/-/jobs/849510085

The previous patches of this series is for next.

Best regards,
Romain

Le 15/11/2020 à 15:36, Romain Naour a écrit :
> When boot-qemu-image.py script was added, we wanted to run
> each qemu defconfig in gitlab, so we expect that all qemu
> defconfig generate the script start-qemu.sh in images
> directory.
> 
> Don't make it a hard requirement even if we prefer to be
> able to do a runtime test for each qemu defconfig.
> 
> Signed-off-by: Romain Naour <romain.naour@gmail.com>
> Cc: Yann E. MORIN <yann.morin.1998@free.fr>
> ---
>  support/scripts/boot-qemu-image.py | 4 ++++
>  1 file changed, 4 insertions(+)
> 
> diff --git a/support/scripts/boot-qemu-image.py b/support/scripts/boot-qemu-image.py
> index dbbba552ad..4066788c88 100755
> --- a/support/scripts/boot-qemu-image.py
> +++ b/support/scripts/boot-qemu-image.py
> @@ -18,6 +18,10 @@ def main():
>      if not sys.argv[1].startswith('qemu_'):
>          sys.exit(0)
>  
> +    if not os.path.exists('output/images/start-qemu.sh'):
> +        print('qemu-start.sh is missing, cannot test.')
> +        sys.exit(0)
> +
>      qemu_start = os.path.join(os.getcwd(), 'output/images/start-qemu.sh')
>  
>      child = pexpect.spawn(qemu_start, ['serial-only'],
>
diff mbox series

Patch

diff --git a/support/scripts/boot-qemu-image.py b/support/scripts/boot-qemu-image.py
index dbbba552ad..4066788c88 100755
--- a/support/scripts/boot-qemu-image.py
+++ b/support/scripts/boot-qemu-image.py
@@ -18,6 +18,10 @@  def main():
     if not sys.argv[1].startswith('qemu_'):
         sys.exit(0)
 
+    if not os.path.exists('output/images/start-qemu.sh'):
+        print('qemu-start.sh is missing, cannot test.')
+        sys.exit(0)
+
     qemu_start = os.path.join(os.getcwd(), 'output/images/start-qemu.sh')
 
     child = pexpect.spawn(qemu_start, ['serial-only'],