Re: [libvirt] [PATCH] Fix use of dlopen modules

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



On Thu, Sep 10, 2009 at 03:57:07PM +0200, Daniel Veillard wrote:
> On Thu, Sep 10, 2009 at 02:31:00PM +0100, Daniel P. Berrange wrote:
> > Remove the bogus dependancy between node_device.c & storage_backend.c
> > by moving the virWaitForDevices into util.h where it can be shared
> > safely
> > 
> > * src/storage_backend_disk.c, src/storage_backend_logical.c,
> >   src/storage_backend_mpath.c, src/storage_backend_scsi.c: Replace
> >   virStorageBackendWaitForDevices with virFileWaitForDevices
> > * src/storage_backend.c, src/storage_backend.h: Remove
> >   virStorageBackendWaitForDevices, virWaitForDevices
> > * src/util.h, src/util.c: Add virFileWaitForDevices
> > * configure.in: Move xmlrpc check further down after pkgconfig
> >   is detected
> > * src/Makefile.am: Add missing XMLRPC_CFLAGS/LIBS to opennebula
> > * src/libvirt_private.syms: Add many missing exports
> > ---
> >  configure.in                  |    6 +++---
> >  src/Makefile.am               |    4 ++--
> >  src/libvirt_private.syms      |   14 +++++++++++++-
> >  src/node_device.c             |    4 ++--
> >  src/storage_backend.c         |   31 -------------------------------
> >  src/storage_backend.h         |    2 --
> >  src/storage_backend_disk.c    |    4 ++--
> >  src/storage_backend_logical.c |    2 +-
> >  src/storage_backend_mpath.c   |    2 +-
> >  src/storage_backend_scsi.c    |    4 ++--
> >  src/util.c                    |   27 +++++++++++++++++++++++++++
> >  src/util.h                    |    2 ++
> >  12 files changed, 55 insertions(+), 47 deletions(-)
> > 
> > diff --git a/configure.in b/configure.in
> > index 060eb50..120f7e7 100644
> > --- a/configure.in
> > +++ b/configure.in
> > @@ -463,6 +463,9 @@ if test "$with_qemu" = "yes" -o "$with_lxc" = "yes" ; then
> >  fi
> >  
> >  
> > +dnl Need to test if pkg-config exists
> > +PKG_PROG_PKG_CONFIG
> > +
> >  dnl OpenNebula driver Compilation setting
> >  dnl
> >  
> > @@ -491,9 +494,6 @@ AC_SUBST([XMLRPC_CFLAGS])
> >  AC_SUBST([XMLRPC_LIBS])
> >  
> >  
> > -dnl Need to test if pkg-config exists
> > -PKG_PROG_PKG_CONFIG
> > -
> >  dnl ==========================================================================
> >  dnl find libxml2 library, borrowed from xmlsec
> >  dnl ==========================================================================
> > diff --git a/src/Makefile.am b/src/Makefile.am
> > index 628edc5..02c1f74 100644
> > --- a/src/Makefile.am
> > +++ b/src/Makefile.am
> > @@ -396,8 +396,8 @@ noinst_LTLIBRARIES += libvirt_driver_one.la
> >  # Stateful, so linked to daemon instead
> >  #libvirt_la_LIBADD  += libvirt_driver_one.la
> >  endif
> > -libvirt_driver_one_la_CFLAGS = $(ONE_LIBS)
> > -libvirt_driver_one_la_LDFLAGS = $(ONE_LIBS)
> > +libvirt_driver_one_la_CFLAGS = $(XMLRPC_CFLAGS)
> > +libvirt_driver_one_la_LDFLAGS = $(XMLRPC_LIBS)
> >  #libvirt_driver_one_la_CFLAGS  = "-DWITH_ONE"
> >  if WITH_DRIVER_MODULES
> >  libvirt_driver_one_la_LDFLAGS += -module -avoid-version
> 
>  Okay, those 2 are really unrelated, but ACK

They are related actually. OpenNebula has always needed XMLRPC linker
flags, but this mistake was preventing it seeing them directly. By
accident it still worked though, probably because some other thing w
link to also pulls in the XMLRPC libs. When built as a dlopen'able
module though this bug was exposed.

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

--
Libvir-list mailing list
Libvir-list@xxxxxxxxxx
https://www.redhat.com/mailman/listinfo/libvir-list

[Index of Archives]     [Virt Tools]     [Libvirt Users]     [Lib OS Info]     [Fedora Users]     [Fedora Desktop]     [Fedora SELinux]     [Big List of Linux Books]     [Yosemite News]     [KDE Users]     [Fedora Tools]