pkgsrc-Users archive

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

sysutils/libvirt: Patch for building on Linux


build of sysutils/libvirt fails on Linux (Ubuntu 10.04, 12.04, 14.04):

    nwfilter/nwfilter_dhcpsnoop.c:46:19: error: pcap.h: No such file or directory
    nwfilter/nwfilter_dhcpsnoop.c:279: error: expected specifier-qualifier-list before 'pcap_t'
    nwfilter/nwfilter_dhcpsnoop.c:1073: error: expected '=', ',', ';', 'asm' or '__attribute__' before '*' token
    nwfilter/nwfilter_dhcpsnoop.c:1187: error: expected declaration specifiers or '...' before 'pcap_direction_t'
    nwfilter/nwfilter_dhcpsnoop.c: In function 'virNWFilterSnoopDHCPDecodeJobSubmit':
    nwfilter/nwfilter_dhcpsnoop.c:1201: error: 'dir' undeclared (first use in this function)

When I add 

    .include "../../net/libpcap/"

to Makefile, building succeeds, but "bmake package" still fails, because
charset.alias cannot be found (on NetBSD this file is generated).

Inspired by a comment in net/lftp/PLIST

    @comment belongs to libiconv: lib/charset.alias

I also added 

    .include "../../converters/libiconv/"

to Makefile.

On NetBSD, this leads to charset.alias _not_ being generated, so it is
related, although I don't know what the difference is between a
lib/charset.alias file and using libiconv.

Attached patch includes both additions (libpcap, libiconv) to
sysutils/libvirt/Makefile and removes charset.alias from PLIST.

Index: Makefile
RCS file: /cvsroot/pkgsrc/sysutils/libvirt/Makefile,v
retrieving revision 1.26
diff -u -p -r1.26 Makefile
--- Makefile	19 Oct 2014 08:48:07 -0000	1.26
+++ Makefile	26 Nov 2014 13:40:51 -0000
@@ -43,6 +43,7 @@ RCD_SCRIPTS=            libvirtd
 .include "../../lang/python/"
 .include "../../lang/python/"
+.include "../../converters/libiconv/"
 .include "../../devel/gettext-lib/"
 .include "../../mk/"
 .include "../../security/gnutls/"
@@ -52,5 +53,7 @@ RCD_SCRIPTS=            libvirtd
 .include "../../textproc/py-xml/"
 .include "../../www/curl/"
+.include "../../net/libpcap/"
 .include "../../mk/"
 .include "../../mk/"
Index: PLIST
RCS file: /cvsroot/pkgsrc/sysutils/libvirt/PLIST,v
retrieving revision 1.10
diff -u -p -r1.10 PLIST
--- PLIST	19 Oct 2014 08:48:07 -0000	1.10
+++ PLIST	26 Nov 2014 13:40:51 -0000
@@ -7,7 +7,6 @@ include/libvirt/libvirt-lxc.h

Home | Main Index | Thread Index | Old Index