qemu-devel.nongnu.org archive mirror
 help / color / mirror / Atom feed
From: "Philippe Mathieu-Daudé" <philmd@redhat.com>
To: Joelle van Dyne <j@getutm.app>, qemu-devel@nongnu.org
Cc: Paolo Bonzini <pbonzini@redhat.com>,
	Thomas Huth <thuth@redhat.com>,
	Peter Maydell <peter.maydell@linaro.org>
Subject: Re: [PATCH] meson: change buildtype when debug_info=no
Date: Thu, 29 Apr 2021 07:07:40 +0200	[thread overview]
Message-ID: <dd5fc80e-c08a-95a5-57e9-28a123196eff@redhat.com> (raw)
In-Reply-To: <20210428195558.16960-1-j@getutm.app>

On 4/28/21 9:55 PM, 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>
> ---
>  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) \

NAck. You are changing the default (which is 'debug') to 'release'.

This should be at least mentioned in the commit description, but
I don't think this is what we want here. 'release' enables -O3,
which is certainly not supported. The 'debug' profile is what we
have been and are testing.

I'd be OK if you had used "debugoptimized else debug".

The mainstream project would rather use 'debug'/'debugoptimized', or
'minsize', which are already tested. We might consider allowing forks
to use 'plain' profile eventually. But the 'release' type is an
unsupported landmine IMHO.

If you want to use something else, it should be an explicit argument
to ./configure, then you are on your own IMO.

Regards,

Phil.



  reply	other threads:[~2021-04-29  5: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é [this message]
2021-04-29  7:33   ` Joelle van Dyne
2021-04-29  9:55     ` Philippe Mathieu-Daudé
2021-04-29 11:02 ` Paolo Bonzini

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=dd5fc80e-c08a-95a5-57e9-28a123196eff@redhat.com \
    --to=philmd@redhat.com \
    --cc=j@getutm.app \
    --cc=pbonzini@redhat.com \
    --cc=peter.maydell@linaro.org \
    --cc=qemu-devel@nongnu.org \
    --cc=thuth@redhat.com \
    /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).