From: "Daniel P. Berrange" <berrange@redhat.com>
To: Alistair Francis <alistair.francis@xilinx.com>
Cc: "qemu-devel@nongnu.org Developers" <qemu-devel@nongnu.org>
Subject: Re: [Qemu-devel] [PATCH v1 5/5] Convert single line fprintf() to warn_report()
Date: Wed, 26 Jul 2017 17:36:57 +0100 [thread overview]
Message-ID: <20170726163657.GU7620@redhat.com> (raw)
In-Reply-To: <CAKmqyKNOB-FES0eghORkyvpHghu8J=EchXN9btx7ZBxa9Q9yEw@mail.gmail.com>
On Wed, Jul 26, 2017 at 09:33:56AM -0700, Alistair Francis wrote:
> On Wed, Jul 26, 2017 at 9:28 AM, Daniel P. Berrange <berrange@redhat.com> wrote:
> > On Wed, Jul 26, 2017 at 09:07:59AM -0700, Alistair Francis wrote:
> >> Convert any remaining uses of fprintf(stderr, "warning:"...
> >> to use warn_report() instead. This helps standardise on a single
> >> method of printing warnings to the user.
> >>
> >> All of the warnings were changed using this command:
> >> find ./* -type f -exec sed -i 's|fprintf(.*".*warning[,:] |warn_report("|Ig' {} +
> >>
> >> The #include lines and chagnes to the test Makefile were manually
> >> updated to allow the code to compile.
> >>
> >> Signed-off-by: Alistair Francis <alistair.francis@xilinx.com>
> >> ---
> >>
> >> tests/Makefile.include | 4 ++--
> >> util/cutils.c | 3 ++-
> >> 2 files changed, 4 insertions(+), 3 deletions(-)
> >>
> >> diff --git a/tests/Makefile.include b/tests/Makefile.include
> >> index 7af278db55..4886caf565 100644
> >> --- a/tests/Makefile.include
> >> +++ b/tests/Makefile.include
> >> @@ -560,8 +560,8 @@ tests/test-thread-pool$(EXESUF): tests/test-thread-pool.o $(test-block-obj-y)
> >> tests/test-iov$(EXESUF): tests/test-iov.o $(test-util-obj-y)
> >> tests/test-hbitmap$(EXESUF): tests/test-hbitmap.o $(test-util-obj-y) $(test-crypto-obj-y)
> >> tests/test-x86-cpuid$(EXESUF): tests/test-x86-cpuid.o
> >> -tests/test-xbzrle$(EXESUF): tests/test-xbzrle.o migration/xbzrle.o migration/page_cache.o $(test-util-obj-y)
> >> -tests/test-cutils$(EXESUF): tests/test-cutils.o util/cutils.o
> >> +tests/test-xbzrle$(EXESUF): tests/test-xbzrle.o migration/xbzrle.o migration/page_cache.o $(test-qom-obj-y)
> >> +tests/test-cutils$(EXESUF): tests/test-cutils.o util/cutils.o $(test-qom-obj-y)
> >
> > This doesn't look right to me - $(test-qom-obj-y) is the same as
> > $(test-util-obj-y), but with $(qom-obj-y) added. AFAIK, your
> > warn_report function doesn't use any code from $(qom-obj-y), so
> > we should not need to link to that. So I think there's something
> > else going on here.
>
> The problem I was seeing is that monitor_get_fd() is getting called in
> stubs/monitor.c which then requires error_setg_internal() to be linked
> in. Apparently this doesn't happen without this change as I kept
> seeing linker errors.
That's bizarre because error_setg_internal is included in libqemuutil.la
that we're already linking to.
Regards,
Daniel
--
|: https://berrange.com -o- https://www.flickr.com/photos/dberrange :|
|: https://libvirt.org -o- https://fstop138.berrange.com :|
|: https://entangle-photo.org -o- https://www.instagram.com/dberrange :|
next prev parent reply other threads:[~2017-07-26 16:37 UTC|newest]
Thread overview: 15+ messages / expand[flat|nested] mbox.gz Atom feed top
2017-07-26 16:07 [Qemu-devel] [PATCH v1 0/5] More warning reporting fixed Alistair Francis
2017-07-26 16:07 ` [Qemu-devel] [PATCH v1 1/5] hw/i386: Improve some of the warning messages Alistair Francis
2017-07-26 16:07 ` [Qemu-devel] [PATCH v1 2/5] Convert remaining error_report() to warn_report() Alistair Francis
2017-07-27 8:07 ` Cornelia Huck
2017-08-14 11:45 ` Markus Armbruster
2017-08-14 18:35 ` Alistair Francis
2017-07-26 16:07 ` [Qemu-devel] [PATCH v1 3/5] Convert single line fprintf() " Alistair Francis
2017-07-26 16:07 ` [Qemu-devel] [PATCH v1 4/5] Convert multi-line " Alistair Francis
2017-07-27 8:13 ` Cornelia Huck
2017-08-15 6:42 ` Markus Armbruster
2017-07-26 16:07 ` [Qemu-devel] [PATCH v1 5/5] Convert single line " Alistair Francis
2017-07-26 16:28 ` Daniel P. Berrange
2017-07-26 16:33 ` Alistair Francis
2017-07-26 16:36 ` Daniel P. Berrange [this message]
2017-07-26 16:39 ` Alistair Francis
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=20170726163657.GU7620@redhat.com \
--to=berrange@redhat.com \
--cc=alistair.francis@xilinx.com \
--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).