mirror of
https://github.com/ilyakooo0/nixpkgs.git
synced 2024-12-25 04:12:44 +03:00
Merge pull request #11924 from mayflower/libvirt-pcap
libvirt: fix including libpcap and add xen support
This commit is contained in:
commit
a9159db387
@ -1,6 +1,6 @@
|
||||
{ stdenv, fetchurl, pkgconfig, intltool, glib, libxml2, gtk3, gtkvnc, gmp
|
||||
, libgcrypt, gnupg, cyrus_sasl, shared_mime_info, libvirt, libcap_ng, yajl
|
||||
, gsettings_desktop_schemas, makeWrapper, numactl
|
||||
, gsettings_desktop_schemas, makeWrapper, xen, numactl
|
||||
, spiceSupport ? true, spice_gtk ? null, spice_protocol ? null, libcap ? null, gdbm ? null
|
||||
}:
|
||||
|
||||
@ -9,25 +9,20 @@ assert spiceSupport ->
|
||||
|
||||
with stdenv.lib;
|
||||
|
||||
let sourceInfo = rec {
|
||||
baseName="virt-viewer";
|
||||
version="2.0";
|
||||
name="${baseName}-${version}";
|
||||
url="http://virt-manager.org/download/sources/${baseName}/${name}.tar.gz";
|
||||
hash="0dylhpk5rq9jz0l1cxs50q2s74z0wingygm1m33bmnmcnny87ig9";
|
||||
}; in
|
||||
|
||||
stdenv.mkDerivation {
|
||||
inherit (sourceInfo) name version;
|
||||
stdenv.mkDerivation rec {
|
||||
baseName = "virt-viewer";
|
||||
version = "2.0";
|
||||
name = "${baseName}-${version}";
|
||||
|
||||
src = fetchurl {
|
||||
url = sourceInfo.url;
|
||||
sha256 = sourceInfo.hash;
|
||||
url = "http://virt-manager.org/download/sources/${baseName}/${name}.tar.gz";
|
||||
sha256 = "0dylhpk5rq9jz0l1cxs50q2s74z0wingygm1m33bmnmcnny87ig9";
|
||||
};
|
||||
|
||||
buildInputs = [
|
||||
pkgconfig intltool glib libxml2 gtk3 gtkvnc gmp libgcrypt gnupg cyrus_sasl numactl
|
||||
buildInputs = [
|
||||
pkgconfig intltool glib libxml2 gtk3 gtkvnc gmp libgcrypt gnupg cyrus_sasl
|
||||
shared_mime_info libvirt libcap_ng yajl gsettings_desktop_schemas makeWrapper
|
||||
xen numactl
|
||||
] ++ optionals spiceSupport [ spice_gtk spice_protocol libcap gdbm ];
|
||||
|
||||
postInstall = ''
|
||||
|
@ -2,8 +2,8 @@
|
||||
, glib, gobjectIntrospection, libxml2, gtk3, gtkvnc, libvirt, spice_gtk
|
||||
, spice_protocol, libuuid, libsoup, libosinfo, systemd, tracker, vala
|
||||
, libcap_ng, libcap, yajl, gmp, gdbm, cyrus_sasl, gnome3, librsvg
|
||||
, desktop_file_utils, mtools, cdrkit, libcdio
|
||||
, libusb, libarchive, acl
|
||||
, desktop_file_utils, mtools, cdrkit, libcdio, libgudev
|
||||
, libusb, libarchive, acl, xen, numactl
|
||||
}:
|
||||
|
||||
# TODO: ovirt (optional)
|
||||
@ -25,7 +25,7 @@ stdenv.mkDerivation rec {
|
||||
gobjectIntrospection libxml2 gtk3 gtkvnc libvirt spice_gtk spice_protocol
|
||||
libuuid libsoup libosinfo systemd tracker vala libcap_ng libcap yajl gmp
|
||||
gdbm cyrus_sasl gnome3.defaultIconTheme libusb libarchive
|
||||
librsvg desktop_file_utils acl
|
||||
librsvg desktop_file_utils acl libgudev xen numactl
|
||||
];
|
||||
|
||||
preFixup = ''
|
||||
|
@ -2,8 +2,8 @@
|
||||
, glib, gobjectIntrospection, libxml2, gtk3, gtkvnc, libvirt, spice_gtk
|
||||
, spice_protocol, libuuid, libsoup, libosinfo, systemd, tracker, vala
|
||||
, libcap_ng, libcap, yajl, gmp, gdbm, cyrus_sasl, gnome3, librsvg
|
||||
, desktop_file_utils, mtools, cdrkit, libcdio
|
||||
, libusb, libarchive, acl
|
||||
, desktop_file_utils, mtools, cdrkit, libcdio, numactl, xen
|
||||
, libusb, libarchive, acl, libgudev
|
||||
}:
|
||||
|
||||
# TODO: ovirt (optional)
|
||||
@ -20,7 +20,7 @@ stdenv.mkDerivation rec {
|
||||
gobjectIntrospection libxml2 gtk3 gtkvnc libvirt spice_gtk spice_protocol
|
||||
libuuid libsoup libosinfo systemd tracker vala libcap_ng libcap yajl gmp
|
||||
gdbm cyrus_sasl gnome3.defaultIconTheme libusb libarchive
|
||||
librsvg desktop_file_utils acl
|
||||
librsvg desktop_file_utils acl libgudev numactl xen
|
||||
];
|
||||
|
||||
preFixup = ''
|
||||
|
@ -1,7 +1,7 @@
|
||||
{ stdenv, fetchurl, pkgconfig, autoconf, automake, libtool, makeWrapper
|
||||
, ncurses, cpio, gperf, perl, cdrkit, flex, bison, qemu, pcre, augeas, libxml2
|
||||
, acl, libcap, libcap_ng, libconfig, systemd, fuse, yajl, libvirt, hivex
|
||||
, gmp, readline, file, libintlperl, GetoptLong, SysVirt }:
|
||||
, gmp, readline, file, libintlperl, GetoptLong, SysVirt, numactl, xen }:
|
||||
|
||||
stdenv.mkDerivation rec {
|
||||
name = "libguestfs-${version}";
|
||||
@ -21,7 +21,7 @@ stdenv.mkDerivation rec {
|
||||
makeWrapper pkgconfig autoconf automake libtool ncurses cpio gperf perl
|
||||
cdrkit flex bison qemu pcre augeas libxml2 acl libcap libcap_ng libconfig
|
||||
systemd fuse yajl libvirt gmp readline file hivex libintlperl GetoptLong
|
||||
SysVirt
|
||||
SysVirt numactl xen
|
||||
];
|
||||
|
||||
configureFlags = "--disable-appliance --disable-daemon";
|
||||
|
@ -3,11 +3,11 @@
|
||||
}:
|
||||
|
||||
stdenv.mkDerivation rec {
|
||||
name = "libosinfo-0.2.11";
|
||||
name = "libosinfo-0.2.12";
|
||||
|
||||
src = fetchurl {
|
||||
url = "https://fedorahosted.org/releases/l/i/libosinfo/${name}.tar.gz";
|
||||
sha256 = "0889zvidhmpk3nd7c1xhh3fkk9i014dkr6zdlddh89kbflva2sxv";
|
||||
sha256 = "1vcg8ylh7q69s9y6hj94dqfffwfbann3i28yqgfc01navf6yl07s";
|
||||
};
|
||||
|
||||
buildInputs = [
|
||||
|
@ -1,36 +1,21 @@
|
||||
{ stdenv, fetchurl, pkgconfig, libvirt, glib, libxml2, intltool, libtool, yajl
|
||||
, nettle, libgcrypt, python, pygobject, gobjectIntrospection, libcap_ng, numactl
|
||||
, xen
|
||||
}:
|
||||
|
||||
stdenv.mkDerivation rec {
|
||||
name = "libvirt-glib-0.2.0";
|
||||
name = "libvirt-glib-0.2.3";
|
||||
|
||||
src = fetchurl {
|
||||
url = "http://libvirt.org/sources/glib/${name}.tar.gz";
|
||||
sha256 = "02saqkk4wzsimsan7s9yc5bx05xn7j00hnxhq4sczkgr4krf1drh";
|
||||
sha256 = "1pahj8qa7k2307sd57rwqwq1hijya02v0sxk91hl3cw48niimcf3";
|
||||
};
|
||||
|
||||
buildInputs = [
|
||||
pkgconfig libvirt glib libxml2 intltool libtool yajl nettle libgcrypt
|
||||
python pygobject gobjectIntrospection libcap_ng numactl
|
||||
python pygobject gobjectIntrospection libcap_ng numactl xen
|
||||
];
|
||||
|
||||
# Compiler flag -fstack-protector-all fixes this build error:
|
||||
#
|
||||
# ./.libs/libvirt-glib-1.0.so: undefined reference to `__stack_chk_guard'
|
||||
#
|
||||
# And the extra include path fixes this build error:
|
||||
#
|
||||
# In file included from ../libvirt-gobject/libvirt-gobject-domain-device.h:30:0,
|
||||
# from /tmp/nix-build-libvirt-glib-0.1.7.drv-2/libvirt-glib-0.1.7/libvirt-gobject/libvirt-gobject.h:33,
|
||||
# from <stdin>:4:
|
||||
# ../libvirt-gobject/libvirt-gobject-domain.h:33:29: fatal error: libvirt/libvirt.h: No such file or directory
|
||||
# compilation terminated.
|
||||
# make[3]: *** [LibvirtGObject-1.0.gir] Error 1
|
||||
preConfigure = ''
|
||||
export NIX_CFLAGS_COMPILE="-fstack-protector-all -I${libvirt}/include"
|
||||
'';
|
||||
|
||||
meta = with stdenv.lib; {
|
||||
description = "Library for working with virtual machines";
|
||||
longDescription = ''
|
||||
|
@ -2,7 +2,7 @@
|
||||
, iproute, iptables, readline, lvm2, utillinux, udev, libpciaccess, gettext
|
||||
, libtasn1, ebtables, libgcrypt, yajl, makeWrapper, pmutils, libcap_ng
|
||||
, dnsmasq, libnl, libpcap, libxslt, xhtml1, numad, numactl, perlPackages
|
||||
, curl, libiconv, gmp
|
||||
, curl, libiconv, gmp, xen
|
||||
}:
|
||||
|
||||
stdenv.mkDerivation rec {
|
||||
@ -17,9 +17,10 @@ stdenv.mkDerivation rec {
|
||||
buildInputs = [
|
||||
pkgconfig libxml2 gnutls perl python readline
|
||||
gettext libtasn1 libgcrypt yajl makeWrapper
|
||||
libxslt xhtml1 perlPackages.XMLXPath curl
|
||||
libxslt xhtml1 perlPackages.XMLXPath curl libpcap
|
||||
] ++ stdenv.lib.optionals stdenv.isLinux [
|
||||
libpciaccess devicemapper lvm2 utillinux udev libcap_ng libnl numad numactl
|
||||
libpciaccess devicemapper lvm2 utillinux udev libcap_ng
|
||||
libnl numad numactl xen
|
||||
] ++ stdenv.lib.optionals stdenv.isDarwin [
|
||||
libiconv gmp
|
||||
];
|
||||
|
@ -13469,7 +13469,7 @@ let
|
||||
|
||||
neovim-pygui = pythonPackages.neovim_gui;
|
||||
|
||||
virtviewer = callPackage ../applications/virtualization/virt-viewer {
|
||||
virt-viewer = callPackage ../applications/virtualization/virt-viewer {
|
||||
gtkvnc = gtkvnc.override { enableGTK3 = true; };
|
||||
spice_gtk = spice_gtk.override { enableGTK3 = true; };
|
||||
};
|
||||
@ -15865,6 +15865,7 @@ aliases = with self; rec {
|
||||
tftp_hpa = tftp-hpa; # added 2015-04-03
|
||||
manpages = man-pages; # added 2015-12-06
|
||||
mssys = ms-sys; # added 2015-12-13
|
||||
virtviewer = virt-viewer; # added 2015-12-24
|
||||
};
|
||||
|
||||
tweakAlias = _n: alias: with lib;
|
||||
|
Loading…
Reference in New Issue
Block a user