On Fri, Nov 20, 2015 at 02:28:40PM +0100, Michal Privoznik wrote:
Our domain_conf.* files are big enough. Not only they contain XML
parsing code, but they served as a storage of all functions whose
name is virDomain prefixed. This is just wrong as it gathers not
related functions (and modules) into one big file which is then
harder to maintain. Split virDomainObjList module into a separate
file called virdomainobjlist.[ch].
Signed-off-by: Michal Privoznik <mprivozn(a)redhat.com>
---
[...]
diff --git a/src/vz/vz_utils.h b/src/vz/vz_utils.h
index 84cf08f..b7a4c81 100644
--- a/src/vz/vz_utils.h
+++ b/src/vz/vz_utils.h
@@ -27,6 +27,7 @@
# include "driver.h"
# include "conf/domain_conf.h"
+# include "conf/virdomainobjlist.h"
I was checking other drivers and this probably needs to be used in most
of them. Even though I tried checking all drivers, there's a huge mess
in includes, so I only found out that you missed bhyve driver and maybe
lxc, but that probably gets it transitively from some other includes.
The rest looks fine and adding it there would probably be enough, but
the messg got me thinking. Why don't we have a conf.h that would have
all the conf/*.h files in and so on, when at the end this is all just an
internal stuff we're using. Or most of harmless includes could be in
internal.h for the sake of simplicity and error-prone behaviour. It
might be super-bad idea, but I can't think of a reason against that.
And it would clean up buch of files, I guess. Check, for example,
src/lxc/lxc_driver.c.
Anyway, in the meantime, ACK with the bhyve fixed.