qemu-devel
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: [Qemu-devel] [PATCH 0/3] tests/tcg: disentangle makefiles


From: Alex Bennée
Subject: Re: [Qemu-devel] [PATCH 0/3] tests/tcg: disentangle makefiles
Date: Wed, 07 Aug 2019 17:38:35 +0100
User-agent: mu4e 1.3.4; emacs 27.0.50

Paolo Bonzini <address@hidden> writes:

> On 07/08/19 15:33, Eric Blake wrote:
>> On 8/7/19 8:06 AM, Paolo Bonzini wrote:
>>> On 07/08/19 14:40, Alex Bennée wrote:
>>>>
>>>> Paolo Bonzini <address@hidden> writes:
>>>>
>>>>> The tests/tcg rely a lot on per-target informations from
>>>>> the QEMU makefiles, but most of the definitions in there
>>>>> aren't really relevant to TCG tests.
>>>>>
>>>>> This series is just a cleanup, but it could also be
>>>>> a useful start in making it possible to compile tests/tcg
>>>>> out of QEMU's tree, and/or making it a submodule, and/or
>>>>> unifying the system emulation tests with kvm-unit-tests.
>>>>
>>>> Hmm something is throwing off configure and making it use my login shell
>>>> instead of /bin/sh:
>>>>
>>>>   libpmem support   no
>>>>   libudev           yes
>>>>   default devices   yes
>>>>   ~/lsrc/qemu.git/tests/tcg/configure.sh (line 63): 'case' builtin not 
>>>> inside of switch block
>>>>     case $arch in
>>>>     ^
>>>>   <W> fish: Error while reading file 
>>>> /home/alex/lsrc/qemu.git/tests/tcg/configure.sh
>>>
>>> It's the ${SHELL} you found in patch 3.  The disadvantage of relying on
>>> #! is that some people have bash in /usr/bin/bash rather than /bin/bash.
>>>  But we already assume /bin/bash elsewhere so I can drop it.
>>
>> Rather, we use '#!/usr/bin/env bash' to find bash anywhere.
>
> Nevermind - this script is pure Bourne shell.  The only fix needed
> should be

I thought we wanted to use pure POSIX shell and not rely on bash-ism's
creeping in?

>
> diff --git a/configure b/configure
> index eeeda8760a..f216f3f9d9 100755
> --- a/configure
> +++ b/configure
> @@ -6468,12 +6468,6 @@ if ! $python -c 'import sys; sys.exit(sys.version_info 
> < (3,0))'; then
>    echo "warning: Python 3 will be required for building future versions of 
> QEMU" >&2
>  fi
>
> -(for i in $cross_cc_vars; do
> -  export $i
> -done
> -export target_list source_path
> -${SHELL-/bin/sh} $source_path/tests/tcg/configure.sh)
> -
>  config_host_mak="config-host.mak"
>
>  echo "# Automatically generated by configure - do not modify" 
> >config-all-disas.mak
> @@ -7844,6 +7838,12 @@ for f in $LINKS ; do
>      fi
>  done
>
> +(for i in $cross_cc_vars; do
> +  export $i
> +done
> +export target_list source_path
> +$source_path/tests/tcg/configure.sh)
> +

I also had chmod +x the script.

>  # temporary config to build submodules
>  for rom in seabios vgabios ; do
>      config_mak=roms/$rom/config.mak


--
Alex Bennée



reply via email to

[Prev in Thread] Current Thread [Next in Thread]