qemu-devel.nongnu.org archive mirror
 help / color / mirror / Atom feed
From: Paolo Bonzini <pbonzini@redhat.com>
To: Joelle van Dyne <j@getutm.app>, qemu-devel@nongnu.org
Subject: Re: [PATCH] meson: change buildtype when debug_info=no
Date: Thu, 29 Apr 2021 13:02:12 +0200	[thread overview]
Message-ID: <97f986cf-12a9-560c-2d45-8c80305be481@redhat.com> (raw)
In-Reply-To: <20210428195558.16960-1-j@getutm.app>

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" \
> 



      parent reply	other threads:[~2021-04-29 11:08 UTC|newest]

Thread overview: 5+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2021-04-28 19:55 [PATCH] meson: change buildtype when debug_info=no Joelle van Dyne
2021-04-29  5:07 ` Philippe Mathieu-Daudé
2021-04-29  7:33   ` Joelle van Dyne
2021-04-29  9:55     ` Philippe Mathieu-Daudé
2021-04-29 11:02 ` Paolo Bonzini [this message]

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=97f986cf-12a9-560c-2d45-8c80305be481@redhat.com \
    --to=pbonzini@redhat.com \
    --cc=j@getutm.app \
    --cc=qemu-devel@nongnu.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).