[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: [Qemu-devel] [PATCH RFC v2 1/5] Use #include "..." exactly for our o
Re: [Qemu-devel] [PATCH RFC v2 1/5] Use #include "..." exactly for our own headers
Mon, 27 Jun 2016 10:50:16 +0200
Gnus/5.13 (Gnus v5.13) Emacs/24.5 (gnu/linux)
Eric Blake <address@hidden> writes:
> On 06/24/2016 08:19 AM, Markus Armbruster wrote:
>> Signed-off-by: Markus Armbruster <address@hidden>
>> Reviewed-by: Peter Maydell <address@hidden>
> Worth mentioning how you found the culprits in the commit message, so
> that someone could repeat the task when backporting this patch or
> dealing with future cruft that inevitably creeps back in without an
> automated checkin validation tool?
With an ugly Perl script, of course %-/
If our use of -I was sane, the mapping from #include's file to the
actual file would be straightforward. It isn't, because we add
different -I for different parts of the code. To spice up things, we
also name a few of our headers just like system headers we use
elsewhere, e.g. "util.h" in net/ vs. <util.h> in util/qemu-openpty.c.
My Perl script tries to match #include directives against source files,
and prints its findings. The headers it can't map to source files must
either be generated headers or system headers. The headers it can map
might be system headers anyway.
I'm afraid my script and its usage is too brittle to be of much use
later on. I attach it anyway.
Description: Text document
[Qemu-devel] [PATCH RFC v2 3/5] tests: Make check-block a phony target, Markus Armbruster, 2016/06/24
[Qemu-devel] [PATCH RFC v2 5/5] include: Include exec/hwaddr.h where hwaddr is used, Markus Armbruster, 2016/06/24
[Qemu-devel] [PATCH RFC v2 2/5] tests: New make target check-source, Markus Armbruster, 2016/06/24