[libvirt] [PATCH] src: remove WITH_LIBVIRTD condition around hal/udev build

Daniel P. Berrangé posted 1 patch 6 years, 2 months ago
Patches applied successfully (tree, apply log)
git fetch https://github.com/patchew-project/libvirt tags/patchew/20180221152241.8467-1-berrange@redhat.com
Test syntax-check passed
src/Makefile.am | 2 --
1 file changed, 2 deletions(-)
[libvirt] [PATCH] src: remove WITH_LIBVIRTD condition around hal/udev build
Posted by Daniel P. Berrangé 6 years, 2 months ago
Currently building --without-libvirtd causes a failure to link the node
device driver:

node_device/.libs/libvirt_driver_nodedev_la-node_device_driver.o: In function `nodedevRegister':
/home/berrange/src/virt/libvirt/src/node_device/node_device_driver.c:649: undefined reference to `udevNodeRegister'
collect2: error: ld returned 1 exit status

because it causes us to build the core nodedev driver, but then skip the
implementations, despite udev being available.

Signed-off-by: Daniel P. Berrangé <berrange@redhat.com>
---
 src/Makefile.am | 2 --
 1 file changed, 2 deletions(-)

diff --git a/src/Makefile.am b/src/Makefile.am
index db68e01db4..38fa1e3393 100644
--- a/src/Makefile.am
+++ b/src/Makefile.am
@@ -1863,7 +1863,6 @@ libvirt_driver_nodedev_la_CFLAGS = \
 libvirt_driver_nodedev_la_LDFLAGS = $(AM_LDFLAGS_MOD_NOUNDEF)
 libvirt_driver_nodedev_la_LIBADD =
 
-if WITH_LIBVIRTD
 if WITH_HAL
 libvirt_driver_nodedev_la_SOURCES += $(NODE_DEVICE_DRIVER_HAL_SOURCES)
 libvirt_driver_nodedev_la_CFLAGS += $(HAL_CFLAGS)
@@ -1874,7 +1873,6 @@ libvirt_driver_nodedev_la_SOURCES += $(NODE_DEVICE_DRIVER_UDEV_SOURCES)
 libvirt_driver_nodedev_la_CFLAGS += $(UDEV_CFLAGS) $(PCIACCESS_CFLAGS)
 libvirt_driver_nodedev_la_LIBADD += $(UDEV_LIBS) $(PCIACCESS_LIBS)
 endif WITH_UDEV
-endif WITH_LIBVIRTD
 
 libvirt_driver_nodedev_la_LIBADD += libvirt.la ../gnulib/lib/libgnu.la
 endif WITH_NODE_DEVICES
-- 
2.14.3

--
libvir-list mailing list
libvir-list@redhat.com
https://www.redhat.com/mailman/listinfo/libvir-list
Re: [libvirt] [PATCH] src: remove WITH_LIBVIRTD condition around hal/udev build
Posted by Michal Privoznik 6 years, 2 months ago
On 02/21/2018 04:22 PM, Daniel P. Berrangé wrote:
> Currently building --without-libvirtd causes a failure to link the node
> device driver:
> 
> node_device/.libs/libvirt_driver_nodedev_la-node_device_driver.o: In function `nodedevRegister':
> /home/berrange/src/virt/libvirt/src/node_device/node_device_driver.c:649: undefined reference to `udevNodeRegister'
> collect2: error: ld returned 1 exit status
> 
> because it causes us to build the core nodedev driver, but then skip the
> implementations, despite udev being available.
> 
> Signed-off-by: Daniel P. Berrangé <berrange@redhat.com>
> ---
>  src/Makefile.am | 2 --
>  1 file changed, 2 deletions(-)

ACK, although you already pushed this. You could use both rules for
pushing patches without review - this patch fixes broken build and is
trivial. Speaking of which, do we document the rules somewhere? I don't
think we do.

Michal

--
libvir-list mailing list
libvir-list@redhat.com
https://www.redhat.com/mailman/listinfo/libvir-list
Re: [libvirt] [PATCH] src: remove WITH_LIBVIRTD condition around hal/udev build
Posted by Daniel P. Berrangé 6 years, 2 months ago
On Thu, Feb 22, 2018 at 08:15:26AM +0100, Michal Privoznik wrote:
> On 02/21/2018 04:22 PM, Daniel P. Berrangé wrote:
> > Currently building --without-libvirtd causes a failure to link the node
> > device driver:
> > 
> > node_device/.libs/libvirt_driver_nodedev_la-node_device_driver.o: In function `nodedevRegister':
> > /home/berrange/src/virt/libvirt/src/node_device/node_device_driver.c:649: undefined reference to `udevNodeRegister'
> > collect2: error: ld returned 1 exit status
> > 
> > because it causes us to build the core nodedev driver, but then skip the
> > implementations, despite udev being available.
> > 
> > Signed-off-by: Daniel P. Berrangé <berrange@redhat.com>
> > ---
> >  src/Makefile.am | 2 --
> >  1 file changed, 2 deletions(-)
> 
> ACK, although you already pushed this. You could use both rules for
> pushing patches without review - this patch fixes broken build and is
> trivial. Speaking of which, do we document the rules somewhere? I don't
> think we do.

Opps, yes, I actually pushed this without realizing I had left it in
master !  I don't think we have ever documented the trivial/build breaker
fix guidelines explicitly.  I just tend to explain them to people when I
granted them commit access.

Regards,
Daniel
-- 
|: https://berrange.com      -o-    https://www.flickr.com/photos/dberrange :|
|: https://libvirt.org         -o-            https://fstop138.berrange.com :|
|: https://entangle-photo.org    -o-    https://www.instagram.com/dberrange :|

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