qemu-devel
[Top][All Lists]
Advanced

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

Re: [PATCH] meson: change buildtype when debug_info=no


From: Paolo Bonzini
Subject: Re: [PATCH] meson: change buildtype when debug_info=no
Date: Thu, 29 Apr 2021 13:02:12 +0200
User-agent: Mozilla/5.0 (X11; Linux x86_64; rv:78.0) Gecko/20100101 Thunderbird/78.7.0

On 28/04/21 21:55, Joelle van Dyne wrote:
Meson defaults builds to 'debugoptimized' which adds '-g -O2'
to CFLAGS. If the user specifies '--disable-debug-info' we
should instead build with 'release' which does not emit any
debug info.

Signed-off-by: Joelle van Dyne <j@getutm.app>

This is not needed.  buildtype is a shortcut for the optimization and
debug options, we need not bother with it because configure sets the
individual options already:

        -Doptimization=$(if test "$debug" = yes; then echo 0; else echo 2; fi) \
        -Ddebug=$(if test "$debug_info" = yes; then echo true; else echo false; 
fi) \

Paolo

---
  configure | 1 +
  1 file changed, 1 insertion(+)

diff --git a/configure b/configure
index 4f374b4889..5c3568cbc3 100755
--- a/configure
+++ b/configure
@@ -6398,6 +6398,7 @@ NINJA=$ninja $meson setup \
          --sysconfdir "$sysconfdir" \
          --localedir "$localedir" \
          --localstatedir "$local_statedir" \
+        --buildtype $(if test "$debug_info" = yes; then echo "debugoptimized"; else echo 
"release"; fi) \
          -Ddocdir="$docdir" \
          -Dqemu_firmwarepath="$firmwarepath" \
          -Dqemu_suffix="$qemu_suffix" \





reply via email to

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