[libvirt] [PATCH v3] nwfilter: fix loadable module support

Daniel P. Berrange berrange at redhat.com
Tue Jun 22 09:55:16 UTC 2010


On Mon, Jun 21, 2010 at 02:27:36PM -0400, Stefan Berger wrote:
> On 06/21/2010 11:33 AM, Daniel P. Berrange wrote:
> >On Wed, Jun 16, 2010 at 11:33:48AM -0400, Stefan Berger wrote:
> >   
> >>Following Daniel Berrange's multiple helpful suggestions for improving
> >>this patch and introducing another driver interface, I now wrote the
> >>below patch where the nwfilter driver registers the functions to
> >>instantiate and teardown the nwfilters with a function in
> >>conf/domain_nwfilter.c called virDomainConfNWFilterRegister. Previous
> >>helper functions that were called from qemu_driver.c and qemu_conf.c
> >>were move into conf/domain_nwfilter.h with slight renaming done for
> >>consistency. Those functions now call the function expored by
> >>domain_nwfilter.c, which in turn call the functions of the new driver
> >>interface, if available.
> >>
> >>V3: no more inline functions
> >>
> >>Signed-off-by: Stefan Berger<stefanb at us.ibm.com>
> >>
> >>---
> >>  src/Makefile.am                        |    3 +
> >>  src/conf/domain_nwfilter.c             |   61
> >>+++++++++++++++++++++++++++++++++
> >>  src/conf/domain_nwfilter.h             |   43 +++++++++++++++++++++++
> >>  src/libvirt_private.syms               |    5 ++
> >>  src/nwfilter/nwfilter_driver.c         |   23 ++++++++++++
> >>  src/nwfilter/nwfilter_gentech_driver.h |   17 ---------
> >>  src/qemu/qemu_conf.c                   |   17 ++++-----
> >>  src/qemu/qemu_driver.c                 |   10 ++---
> >>  8 files changed, 148 insertions(+), 31 deletions(-)
> >>     
> >ACK, this looks good now
> >   
> 
> Thanks. Pushed it now.
> 
> The only patch that I need now to compile with --with-driver-modules 
> (using --without-xen) is this here:
> 
> diff --git a/src/Makefile.am b/src/Makefile.am
> index 5109302..e553f35 100644
> --- a/src/Makefile.am
> +++ b/src/Makefile.am
> @@ -1001,7 +1001,7 @@ libvirt_la_LDFLAGS = 
> $(VERSION_SCRIPT_FLAGS)$(LIBVIRT_SYMB
>                     $(CYGWIN_EXTRA_LDFLAGS) $(MINGW_EXTRA_LDFLAGS)
>  libvirt_la_BUILT_LIBADD += ../gnulib/lib/libgnu.la
>  libvirt_la_LIBADD += $(LIBXML_LIBS) \
> -                   $(LIBPCAP_LIBS) $(LIBNL_LIBS) \
> +                   $(LIBPCAP_LIBS) $(LIBNL_LIBS) $(GNUTLS_LIBS) \
>                     $(DRIVER_MODULE_LIBS) \
>                     $(CYGWIN_EXTRA_LIBADD)
>  libvirt_la_CFLAGS = $(COVERAGE_CFLAGS) -DIN_LIBVIRT

I think that one needs to be against libvirt_driver_la_CFLAGS instead.
since that's where the source file using gnutls is.

Regards,
Daniel
-- 
|: Red Hat, Engineering, London    -o-   http://people.redhat.com/berrange/ :|
|: http://libvirt.org -o- http://virt-manager.org -o- http://deltacloud.org :|
|: http://autobuild.org        -o-         http://search.cpan.org/~danberr/ :|
|: GnuPG: 7D3B9505  -o-   F3C9 553F A1DA 4AC2 5648 23C1 B3DF F742 7D3B 9505 :|




More information about the libvir-list mailing list