[virt-tools-list] [PATCH 1/4] msi: use libvirt conditionally

Fabiano Fidêncio fidencio at redhat.com
Wed Dec 17 11:34:08 UTC 2014


On Wed, 2014-12-17 at 12:32 +0100, Christophe Fergeau wrote:
> On Wed, Dec 17, 2014 at 12:24:06PM +0100, Fabiano Fidêncio wrote:
> > On Wed, 2014-12-17 at 12:20 +0100, Christophe Fergeau wrote:
> > > > > It's defined in the configure.ac, the same is valid for GTK_API_VERSION,
> > > > > HAVE_SPICE_GTK, HAVE_GTK_VNC and HAVE_OVIRT.
> > > > > IIRC I had problems using $(VAR) instead of $VAR or ${VAR}.
> > > > 
> > > > They are not defined the same way: AC_SUBST vs AC_DEFINE
> > > 
> > > Fwiw, there are AM_CONDITIONAL for each of the HAVE_XXX used in this
> > > series, something like
> > > if HAVE_LIBVIRT
> > >   WIXL_FLAGS += "-D HaveLibvirt=1"
> > > endif
> > > would probably work
> > 
> > And do you think would be better/clearer than the way it is now?
> 
> AC_SUBST will be substituted in Makefile.am, I think AC_DEFINE only gets
> defined in config.h. As Marc-André was pointing out, HAVE_LIBVIRT (and
> other HAVE_XXX vars that you use in your patches) are only set with
> AC_DEFINE and AM_CONDITIONAL, so I don't think using $(HAVE_LIBVIRT) as
> you are doing currently will do the right thing.

Hmm. I see your point.
I've tested and it seems to work (at least when explicitly
disabling/enabling something). I'll rework the series and send it
again. 

> 
> Christophe

Best Regards,
--
Fabiano Fidêncio




More information about the virt-tools-list mailing list