[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[PULL 05/12] configure, meson: move CPU_CFLAGS out of QEMU_CFLAGS
From: |
Paolo Bonzini |
Subject: |
[PULL 05/12] configure, meson: move CPU_CFLAGS out of QEMU_CFLAGS |
Date: |
Tue, 5 Oct 2021 18:44:01 +0200 |
Flags that choose the target architecture, such as -m32 on x86, affect
all invocations of the compiler driver, for example including options
such as --print-search-dirs. To ensure that they are treated as such,
place them in the cross file in the [binaries] section instead of
including them in QEMU_CFLAGS.
Signed-off-by: Paolo Bonzini <pbonzini@redhat.com>
---
configure | 11 +++++------
1 file changed, 5 insertions(+), 6 deletions(-)
diff --git a/configure b/configure
index b0b1a1cc25..1d3f099498 100755
--- a/configure
+++ b/configure
@@ -142,11 +142,11 @@ lines: ${BASH_LINENO[*]}"
}
do_cc() {
- do_compiler "$cc" "$@"
+ do_compiler "$cc" $CPU_CFLAGS "$@"
}
do_cxx() {
- do_compiler "$cxx" "$@"
+ do_compiler "$cxx" $CPU_CFLAGS "$@"
}
# Append $2 to the variable named $1, with space separation
@@ -1688,7 +1688,6 @@ esac
eval "cross_cc_${cpu}=\$cc"
cross_cc_vars="$cross_cc_vars cross_cc_${cpu}"
-QEMU_CFLAGS="$CPU_CFLAGS $QEMU_CFLAGS"
# For user-mode emulation the host arch has to be one we explicitly
# support, even if we're using TCI.
@@ -5114,9 +5113,9 @@ if test "$skip_meson" = no; then
echo "c_link_args = [${LDFLAGS:+$(meson_quote $LDFLAGS)}]" >> $cross
echo "cpp_link_args = [${LDFLAGS:+$(meson_quote $LDFLAGS)}]" >> $cross
echo "[binaries]" >> $cross
- echo "c = [$(meson_quote $cc)]" >> $cross
- test -n "$cxx" && echo "cpp = [$(meson_quote $cxx)]" >> $cross
- test -n "$objcc" && echo "objc = [$(meson_quote $objcc)]" >> $cross
+ echo "c = [$(meson_quote $cc $CPU_CFLAGS)]" >> $cross
+ test -n "$cxx" && echo "cpp = [$(meson_quote $cxx $CPU_CFLAGS)]" >> $cross
+ test -n "$objcc" && echo "objc = [$(meson_quote $objcc $CPU_CFLAGS)]" >>
$cross
echo "ar = [$(meson_quote $ar)]" >> $cross
echo "nm = [$(meson_quote $nm)]" >> $cross
echo "pkgconfig = [$(meson_quote $pkg_config_exe)]" >> $cross
--
2.31.1
- [PULL 00/12] Misc changes for 2021-10-05, Paolo Bonzini, 2021/10/05
- [PULL 02/12] sev/i386: Introduce sev_add_kernel_loader_hashes for measured linux boot, Paolo Bonzini, 2021/10/05
- [PULL 04/12] hw/misc: applesmc: use host osk as default on macs, Paolo Bonzini, 2021/10/05
- [PULL 07/12] migration: add missing qemu_mutex_lock_iothread in migration_completion, Paolo Bonzini, 2021/10/05
- [PULL 01/12] i386: docs: Briefly describe KVM PV features, Paolo Bonzini, 2021/10/05
- [PULL 03/12] x86/sev: generate SEV kernel loader hashes in x86_load_linux, Paolo Bonzini, 2021/10/05
- [PULL 05/12] configure, meson: move CPU_CFLAGS out of QEMU_CFLAGS,
Paolo Bonzini <=
- [PULL 08/12] meson: bump submodule to 0.59.2, Paolo Bonzini, 2021/10/05
- [PULL 11/12] target/xtensa: list cores in a text file, Paolo Bonzini, 2021/10/05
- [PULL 10/12] hexagon: use env keyword argument to pass PYTHONPATH, Paolo Bonzini, 2021/10/05
- [PULL 09/12] meson: switch minimum meson version to 0.58.2, minimum recommended to 0.59.2, Paolo Bonzini, 2021/10/05
- [PULL 12/12] meson: show library versions in the summary, Paolo Bonzini, 2021/10/05