[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: [Qemu-devel] [PATCH 0/3] tests/tcg: disentangle makefiles
From: |
Paolo Bonzini |
Subject: |
Re: [Qemu-devel] [PATCH 0/3] tests/tcg: disentangle makefiles |
Date: |
Wed, 7 Aug 2019 16:30:10 +0200 |
User-agent: |
Mozilla/5.0 (X11; Linux x86_64; rv:60.0) Gecko/20100101 Thunderbird/60.8.0 |
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
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)
+
# temporary config to build submodules
for rom in seabios vgabios ; do
config_mak=roms/$rom/config.mak