configure: add --disable-tcg configure option

This lets you build without TCG (hardware accelerationor qtest only). When
this flag is passed to configure, it will automatically filter out the target
list to only those that support KVM or Xen or HAX.

Backports commit b3f6ea7e55e8228d6f84d5cee7cb11cae917ba95 from qemu
This commit is contained in:
Paolo Bonzini 2018-03-03 21:35:18 -05:00 committed by Lioncash
parent d70c141675
commit 4964bdcc29
No known key found for this signature in database
GPG key ID: 4E3C3CC1031BA9C7

14
qemu/configure vendored
View file

@ -174,6 +174,7 @@ solaris="no"
softmmu="yes"
aix="no"
pie=""
tcg="yes"
# parse CC options first
for opt do
@ -191,6 +192,10 @@ for opt do
--extra-ldflags=*) LDFLAGS="$optarg $LDFLAGS"
EXTRA_LDFLAGS="$optarg"
;;
--disable-tcg) tcg="no"
;;
--enable-tcg) tcg="yes"
;;
--enable-debug-info) debug_info="yes"
;;
--disable-debug-info) debug_info="no"
@ -1150,7 +1155,6 @@ echo "python $python"
echo "host CPU $cpu"
echo "host big endian $bigendian"
echo "target list $target_list"
echo "tcg debug enabled $debug_tcg"
echo "strip binaries $strip_opt"
echo "static build $static"
echo "mingw32 support $mingw32"
@ -1158,6 +1162,11 @@ if test -n "$sparc_cpu"; then
echo "Target Sparc Arch $sparc_cpu"
fi
echo "PIE $pie"
echo "TCG support $tcg"
if test "$tcg" = "yes" ; then
echo "TCG debug enabled $debug_tcg"
echo "TCG interpreter $tcg_interpreter"
fi
config_host_mak="config-host.mak"
@ -1217,9 +1226,12 @@ fi
if test "$bswap_h" = "yes" ; then
echo "CONFIG_MACHINE_BSWAP_H=y" >> $config_host_mak
fi
if test "$tcg" = "yes"; then
echo "CONFIG_TCG=y" >> $config_host_mak
if test "$tcg_interpreter" = "yes" ; then
echo "CONFIG_TCG_INTERPRETER=y" >> $config_host_mak
fi
fi
# XXX: suppress that
if [ "$bsd" = "yes" ] ; then