From: Thomas Huth <thuth@redhat.com>
To: Gerd Hoffmann <kraxel@redhat.com>, qemu-devel@nongnu.org
Cc: "Stefan Hajnoczi" <stefanha@redhat.com>,
"Kevin Wolf" <kwolf@redhat.com>,
"Philippe Mathieu-Daudé" <f4bug@amsat.org>,
"Peter Maydell" <peter.maydell@linaro.org>
Subject: Re: [Qemu-devel] [PATCH v2] build: try improve handling of clang warnings
Date: Fri, 9 Mar 2018 15:08:05 +0100 [thread overview]
Message-ID: <6df623d1-d171-a208-dde4-0a6a7d0d9426@redhat.com> (raw)
In-Reply-To: <20180309135945.20436-1-kraxel@redhat.com>
On 09.03.2018 14:59, Gerd Hoffmann wrote:
> This patch disables the pragma diagnostic -Wunused-but-set-variable for
> clang in util/coroutine-ucontext.c.
>
> This in turn allows us to remove it from the configure check, so the
> CONFIG_PRAGMA_DIAGNOSTIC_AVAILABLE will succeed for clang.
>
> With that in place clang builds (linux) will use -Werror by default,
> which breaks the build due to warning about unaligned struct members.
>
> Just turning off this warning isn't a good idea as it indicates
> portability problems. So make it a warning again, using
> -Wno-error=address-of-packed-member. That way it doesn't break the
> build but still shows up in the logs.
>
> Now clang builds qemu without errors. Well, almost. There are some
> left in the rdma code. Leaving that to the rdma people. All others can
> use --disable-rdma to workarounds this.
>
> Cc: Philippe Mathieu-Daudé <f4bug@amsat.org>
> Cc: Thomas Huth <thuth@redhat.com>
> Cc: Peter Maydell <peter.maydell@linaro.org>
> Signed-off-by: Gerd Hoffmann <kraxel@redhat.com>
> ---
> configure | 2 +-
> util/coroutine-ucontext.c | 4 ++--
> 2 files changed, 3 insertions(+), 3 deletions(-)
Reviewed-by: Thomas Huth <thuth@redhat.com>
next prev parent reply other threads:[~2018-03-09 14:08 UTC|newest]
Thread overview: 3+ messages / expand[flat|nested] mbox.gz Atom feed top
2018-03-09 13:59 [Qemu-devel] [PATCH v2] build: try improve handling of clang warnings Gerd Hoffmann
2018-03-09 14:08 ` Thomas Huth [this message]
2018-03-09 15:45 ` Philippe Mathieu-Daudé
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=6df623d1-d171-a208-dde4-0a6a7d0d9426@redhat.com \
--to=thuth@redhat.com \
--cc=f4bug@amsat.org \
--cc=kraxel@redhat.com \
--cc=kwolf@redhat.com \
--cc=peter.maydell@linaro.org \
--cc=qemu-devel@nongnu.org \
--cc=stefanha@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).