From abafb64b6dcbdb0ca0943cd04373bd84353ce7ec Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Alex=20Benn=C3=A9e?= Date: Wed, 14 Sep 2022 16:59:38 +0100 Subject: [PATCH] configure: explicitly set cflags for --disable-pie MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit This is working around current limitation of Meson's handling of --disable-pie. Signed-off-by: Alex Bennée Cc: Paolo Bonzini Reviewed-by: Richard Henderson Message-Id: <20220914155950.804707-19-alex.bennee@linaro.org> --- configure | 3 +++ 1 file changed, 3 insertions(+) diff --git a/configure b/configure index 575dde1c1f..0bbf9d28af 100755 --- a/configure +++ b/configure @@ -1382,6 +1382,9 @@ elif test "$pie" = "no"; then if compile_prog "-Werror -fno-pie" "-no-pie"; then CONFIGURE_CFLAGS="-fno-pie $CONFIGURE_CFLAGS" CONFIGURE_LDFLAGS="-no-pie $CONFIGURE_LDFLAGS" + # Meson currently only handles pie as a boolean for now so if we have + # explicitly disabled PIE we need to extend our cflags because it wont. + QEMU_CFLAGS="-fno-pie -no-pie $QEMU_CFLAGS" fi elif compile_prog "-Werror -fPIE -DPIE" "-pie"; then CONFIGURE_CFLAGS="-fPIE -DPIE $CONFIGURE_CFLAGS"