summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorMatthias Maier <tamiko@gentoo.org>2023-06-17 20:42:49 -0500
committerMatthias Maier <tamiko@gentoo.org>2023-06-17 20:54:05 -0500
commitc433fe97671c3f9786ffe2405e91ba9f00ae04fe (patch)
treec3e4029a9a56e2127c142d538105186a077c5595
parentapp-emulation/libvirt: add 9.4.0 (diff)
downloadgentoo-c433fe97671c3f9786ffe2405e91ba9f00ae04fe.tar.gz
gentoo-c433fe97671c3f9786ffe2405e91ba9f00ae04fe.tar.bz2
gentoo-c433fe97671c3f9786ffe2405e91ba9f00ae04fe.zip
app-emulation/libvirt: drop 8.7.0-r1, 8.8.0-r1, 8.9.0, 8.9.0-r2, 9.2.0
Bug: https://bugs.gentoo.org/908042 Bug: https://bugs.gentoo.org/836128 Signed-off-by: Matthias Maier <tamiko@gentoo.org>
-rw-r--r--app-emulation/libvirt/Manifest8
-rw-r--r--app-emulation/libvirt/files/libvirt-8.7.0-meson-Stop-detecting-Wl-version-script.patch55
-rw-r--r--app-emulation/libvirt/files/libvirt-9.2.0-meson-Stop-detecting-Wl-version-script.patch53
-rw-r--r--app-emulation/libvirt/libvirt-8.7.0-r1.ebuild353
-rw-r--r--app-emulation/libvirt/libvirt-8.8.0-r1.ebuild353
-rw-r--r--app-emulation/libvirt/libvirt-8.9.0-r2.ebuild360
-rw-r--r--app-emulation/libvirt/libvirt-8.9.0.ebuild356
-rw-r--r--app-emulation/libvirt/libvirt-9.2.0.ebuild359
8 files changed, 0 insertions, 1897 deletions
diff --git a/app-emulation/libvirt/Manifest b/app-emulation/libvirt/Manifest
index 5e6f37dd471e..e8ae7f99693f 100644
--- a/app-emulation/libvirt/Manifest
+++ b/app-emulation/libvirt/Manifest
@@ -1,11 +1,3 @@
-DIST libvirt-8.7.0.tar.xz 8937316 BLAKE2B 131d46206662627e952b6daa3ceeab187321ff5fb1984980bc2816dfedf730c6ccd4b5a1cbfb46f33cc9e84508621e2625fa661f06b9e35561e8de52906824e5 SHA512 35d33d0e0dab525e8f0a8a592d286e9d17fc5c5d1ff2fab5af5c40b85248481dd17b5c3daf64e8c6e1b8a93328eebee6ece3e95edacff208a81d8b78dc102d7a
-DIST libvirt-8.7.0.tar.xz.asc 833 BLAKE2B ebea1430670bcb44e9ffb4460388b2ab41e8b409d1513d09ac56b12f379621f5ad39af0dba9691b36220bbed5634ad24b2efda8315b41bb2e7f3f6a65e9b028c SHA512 5ac09b10de74283c474fb80cfe600a171d6b49039df73113702cda565889f6c6919e99aff6ce60538ee7fda52287ef035ee15e8f47e5f724384c6ec474e6bed8
-DIST libvirt-8.8.0.tar.xz 8941928 BLAKE2B f3b8cb4fe30a156884a03e5c873f3fcef0c8d13315c79b865f387ea053635ae2435a3b4d6e81c988cfcd087d55223450e7b874e24e4503479d152b417c398250 SHA512 868e49b369afe200c5af6e2cd0606de2eeebfa92523b5ad3c653203c8838d304bd0cdc5acfb3c4d4c33c0a87ab8e769b84cc62e3f06e055936c43573a23d7190
-DIST libvirt-8.8.0.tar.xz.asc 833 BLAKE2B 3919af7c208d9a5f863a9351cfcf72916ff67cbef26fe7b86bb3b1042b5556f75a4a0c5210cdb67aee79bd3706047d2d2244c967297dbf2aba2d28c625797361 SHA512 9bc3c0ae6f7fa9d6ee17ca183e218b0f2f6e413b303bd429cda090828ac0521c142178ca4c3c3bc6030c9e58f36ae5d33c7c8a9d6c8147f214e1740a78f66d2a
-DIST libvirt-8.9.0.tar.xz 8946352 BLAKE2B 537b6badb6171110e99561613fb1318144991107139401296248afb747ae6f9cfafcd17b2292b8d8dcc9188ff4206035ea814efa6c129bae50c0518f61be9b81 SHA512 10426d45d55bb18e8e5d4327d698fbc6efd83c5f515ac40a0fcd72048a77936fe0b422ac14bce9966a65379d262df294c314f854a97861a223a0cbc6a8fd2382
-DIST libvirt-8.9.0.tar.xz.asc 833 BLAKE2B a2054d0d9c8301aa0f8697253690b1ddd530a577bc789c7f38dc36a835134d0c8e5fc88536371c75da66afd9808540b9236e8d1247e4d7bd5f3a0aaf35c45f97 SHA512 087d5406ef23d6beee4a37e471d7d0aa433990b892f0beb7be76609fbdfcb69381acd59d63c62dcd2e2f9ccfcdefc35109cc175a0da4263e9b189981cb2baff1
-DIST libvirt-9.2.0.tar.xz 9182060 BLAKE2B 8b9ffc86e088de6b1ec6b38b649bded3abbbce8eec9c1ba19f31e73ecd7ee13a5c521a6e1fd8da9f308158dd05c87171aa443cd00f0c87a73f205e3d57a22567 SHA512 9afd4fcccb9ef39c1ed50eb0db94cd8b06cc5b60041cdb9aa5fe7b27e5ab11855f4b538d6868413725d603dc1a6090e0983207137dcd43ed2bbcfbeb6fc69c58
-DIST libvirt-9.2.0.tar.xz.asc 833 BLAKE2B 64882091890860119c92c6cb0337ea20bfdd8206f5db648cb505ee0d4673cfb8aa5996e6cf3152a7293df98592aa7187d10bb42b4ee979770e9b0040e6bb2d48 SHA512 3c47c5ea182c1310b56641cc2df5adf2f82ae9b35fdeccfddef42f3e2149499b23c61eeafd5e4995ef596ed003ab55b4b17d041dff72ae5f8851b355bfadfb78
DIST libvirt-9.3.0.tar.xz 9246292 BLAKE2B 6e47a70ec247b37c1958e324d5bf7ebcbff6aca5a7a9860f437ebe6a969d569a449d3dd5720081ad27926f445bcbe10089cb3b1d27960decc6239306f82259f9 SHA512 b9349dcd7798c76d75bb20afad67d6e676758cb201acaf7aed5109f0e91422b2bcca964a2f19aa8dc4fd0eca2923902474e16e3839bf8b15aca827028e88ddb7
DIST libvirt-9.3.0.tar.xz.asc 833 BLAKE2B 25810919210bd489ecfd85f172c472d52e911e90d651fac2c7fa4f73220890bd2448317448f0469e8abfe8ad5ea6f3eb6b321e6d989e64f6ad4b676a5a38312c SHA512 0b51a621cef616ac55ac40c9bf9da56d3e1d59b5e87bcd04deaac7f775faab8f30861e53112be2242d9c8c6be41f1ed1c29d345d96e39be0ac33ef0b01494c45
DIST libvirt-9.4.0.tar.xz 9250724 BLAKE2B 837a6eef509a43a0cd25a2ecaac9de95f21e903b553d5e56b404a689495e66bb0053866c9aea672cbe69130286d5a2ff2eb38ff447c77100e92bcb56cd244ee3 SHA512 8a8e3983c47c5ed5f4b50d90cb04e435717afddd27e16112ceeddda458d45c693daf65575f5d50274cfffcd1c83cbdd290819d8ece63f3bf9441b6bdaa309852
diff --git a/app-emulation/libvirt/files/libvirt-8.7.0-meson-Stop-detecting-Wl-version-script.patch b/app-emulation/libvirt/files/libvirt-8.7.0-meson-Stop-detecting-Wl-version-script.patch
deleted file mode 100644
index 749e580b4432..000000000000
--- a/app-emulation/libvirt/files/libvirt-8.7.0-meson-Stop-detecting-Wl-version-script.patch
+++ /dev/null
@@ -1,55 +0,0 @@
-From ab5ce6ac561b9ef5d97ee8268df048b3432d7b8b Mon Sep 17 00:00:00 2001
-Message-Id: <ab5ce6ac561b9ef5d97ee8268df048b3432d7b8b.1679397051.git.mprivozn@redhat.com>
-From: Michal Privoznik <mprivozn@redhat.com>
-Date: Mon, 20 Mar 2023 13:38:27 +0100
-Subject: [PATCH] meson: Stop detecting -Wl,--version-script=
-MIME-Version: 1.0
-Content-Type: text/plain; charset=UTF-8
-Content-Transfer-Encoding: 8bit
-
-With its version 16.0, the LLVM's linker turned on
---no-undefined-version by default [1]. This breaks how we detect
---version-script= detection, because at the compile time there's
-no library built yet that we can use to make --version-script=
-happy. Unfortunately, meson does not provide a way to detect this
-either [2].
-
-But there's not much sense in detecting the argument either. We
-already special case some systems (windows, darwin) and do the
-check for others, which are expected to support versioned
-symbols, because of ELF. Worst case scenario - the error is
-reported during compile time rather than configure time.
-
-1: https://reviews.llvm.org/D135402
-2: https://github.com/mesonbuild/meson/issues/3047
-
-Resolves: https://bugs.gentoo.org/902211
-Signed-off-by: Michal Privoznik <mprivozn@redhat.com>
-Reviewed-by: Daniel P. Berrangé <berrange@redhat.com>
-(cherry picked from commit 743fdb97c81f38adc6e9b55f402244f7982352f4)
-Signed-off-by: Michal Privoznik <mprivozn@redhat.com>
----
- meson.build | 7 +------
- 1 file changed, 1 insertion(+), 6 deletions(-)
-
-diff --git a/meson.build b/meson.build
-index 0b3187ad88..53156329a4 100644
---- a/meson.build
-+++ b/meson.build
-@@ -514,12 +514,7 @@ elif host_machine.system() == 'darwin'
- # macOS libraries don't support symbol versioning
- version_script_flags = ''
- else
-- test_file = '@0@/src/libvirt_qemu.syms'.format(meson.source_root())
-- if cc.has_link_argument('-Wl,--version-script=@0@'.format(test_file))
-- version_script_flags = '-Wl,--version-script='
-- else
-- error('No supported version script link argument found.')
-- endif
-+ version_script_flags = '-Wl,--version-script='
- endif
-
- libvirt_flat_namespace = []
---
-2.39.2
-
diff --git a/app-emulation/libvirt/files/libvirt-9.2.0-meson-Stop-detecting-Wl-version-script.patch b/app-emulation/libvirt/files/libvirt-9.2.0-meson-Stop-detecting-Wl-version-script.patch
deleted file mode 100644
index 18b36c92a149..000000000000
--- a/app-emulation/libvirt/files/libvirt-9.2.0-meson-Stop-detecting-Wl-version-script.patch
+++ /dev/null
@@ -1,53 +0,0 @@
-From 743fdb97c81f38adc6e9b55f402244f7982352f4 Mon Sep 17 00:00:00 2001
-Message-Id: <743fdb97c81f38adc6e9b55f402244f7982352f4.1679396460.git.mprivozn@redhat.com>
-From: Michal Privoznik <mprivozn@redhat.com>
-Date: Mon, 20 Mar 2023 13:38:27 +0100
-Subject: [PATCH] meson: Stop detecting -Wl,--version-script=
-MIME-Version: 1.0
-Content-Type: text/plain; charset=UTF-8
-Content-Transfer-Encoding: 8bit
-
-With its version 16.0, the LLVM's linker turned on
---no-undefined-version by default [1]. This breaks how we detect
---version-script= detection, because at the compile time there's
-no library built yet that we can use to make --version-script=
-happy. Unfortunately, meson does not provide a way to detect this
-either [2].
-
-But there's not much sense in detecting the argument either. We
-already special case some systems (windows, darwin) and do the
-check for others, which are expected to support versioned
-symbols, because of ELF. Worst case scenario - the error is
-reported during compile time rather than configure time.
-
-1: https://reviews.llvm.org/D135402
-2: https://github.com/mesonbuild/meson/issues/3047
-
-Resolves: https://bugs.gentoo.org/902211
-Signed-off-by: Michal Privoznik <mprivozn@redhat.com>
-Reviewed-by: Daniel P. Berrangé <berrange@redhat.com>
----
- meson.build | 7 +------
- 1 file changed, 1 insertion(+), 6 deletions(-)
-
-diff --git a/meson.build b/meson.build
-index c35823a79a..a0682e8d0b 100644
---- a/meson.build
-+++ b/meson.build
-@@ -534,12 +534,7 @@ elif host_machine.system() == 'darwin'
- # macOS libraries don't support symbol versioning
- version_script_flags = ''
- else
-- test_file = '@0@/src/libvirt_qemu.syms'.format(meson.project_source_root())
-- if cc.has_link_argument('-Wl,--version-script=@0@'.format(test_file))
-- version_script_flags = '-Wl,--version-script='
-- else
-- error('No supported version script link argument found.')
-- endif
-+ version_script_flags = '-Wl,--version-script='
- endif
-
- libvirt_flat_namespace = []
---
-2.39.2
-
diff --git a/app-emulation/libvirt/libvirt-8.7.0-r1.ebuild b/app-emulation/libvirt/libvirt-8.7.0-r1.ebuild
deleted file mode 100644
index c8769138db8b..000000000000
--- a/app-emulation/libvirt/libvirt-8.7.0-r1.ebuild
+++ /dev/null
@@ -1,353 +0,0 @@
-# Copyright 1999-2023 Gentoo Authors
-# Distributed under the terms of the GNU General Public License v2
-
-EAPI=8
-
-# Packages which get releases together:
-# app-emacs/nxml-libvirt-schemas
-# dev-python/libvirt-python
-# dev-perl/Sys-Virt
-# app-emulation/libvirt
-# Please bump them together!
-
-PYTHON_COMPAT=( python3_{9..11} )
-VERIFY_SIG_OPENPGP_KEY_PATH="${BROOT}"/usr/share/openpgp-keys/libvirt.org.asc
-inherit meson linux-info python-any-r1 readme.gentoo-r1 tmpfiles verify-sig
-
-if [[ ${PV} = *9999* ]]; then
- inherit git-r3
- EGIT_REPO_URI="https://gitlab.com/libvirt/libvirt.git"
- EGIT_BRANCH="master"
-else
- SRC_URI="https://libvirt.org/sources/${P}.tar.xz
- verify-sig? ( https://libvirt.org/sources/${P}.tar.xz.asc )"
- KEYWORDS="amd64 ~arm arm64 ~ppc64 x86"
-fi
-
-DESCRIPTION="C toolkit to manipulate virtual machines"
-HOMEPAGE="https://www.libvirt.org/ https://gitlab.com/libvirt/libvirt/"
-LICENSE="LGPL-2.1"
-SLOT="0/${PV}"
-IUSE="
- apparmor audit bash-completion +caps dtrace firewalld fuse glusterfs
- iscsi iscsi-direct +libvirtd lvm libssh libssh2 lxc nfs nls numa openvz
- parted pcap policykit +qemu rbd sasl selinux +udev
- virtualbox +virt-network wireshark-plugins xen zfs
-"
-
-REQUIRED_USE="
- firewalld? ( virt-network )
- libvirtd? ( || ( lxc openvz qemu virtualbox xen ) )
- lxc? ( caps libvirtd )
- openvz? ( libvirtd )
- qemu? ( libvirtd )
- virt-network? ( libvirtd )
- virtualbox? ( libvirtd )
- xen? ( libvirtd )"
-
-BDEPEND="
- app-text/xhtml1
- dev-lang/perl
- dev-libs/libxslt
- dev-perl/XML-XPath
- dev-python/docutils
- virtual/pkgconfig
- net-libs/rpcsvc-proto
- bash-completion? ( >=app-shells/bash-completion-2.0 )
- verify-sig? ( sec-keys/openpgp-keys-libvirt )"
-
-# gettext.sh command is used by the libvirt command wrappers, and it's
-# non-optional, so put it into RDEPEND.
-# We can use both libnl:1.1 and libnl:3, but if you have both installed, the
-# package will use 3 by default. Since we don't have slot pinning in an API,
-# we must go with the most recent
-RDEPEND="
- acct-user/qemu
- app-misc/scrub
- >=dev-libs/glib-2.56.0
- dev-libs/libgcrypt
- dev-libs/libnl:3
- >=dev-libs/libxml2-2.9.1
- >=net-analyzer/openbsd-netcat-1.105-r1
- >=net-libs/gnutls-3.2.0:=
- net-libs/libtirpc:=
- >=net-misc/curl-7.18.0
- sys-apps/dbus
- sys-apps/dmidecode
- sys-devel/gettext
- >=sys-libs/readline-7.0:=
- virtual/acl
- apparmor? ( sys-libs/libapparmor )
- audit? ( sys-process/audit )
- caps? ( sys-libs/libcap-ng )
- dtrace? ( dev-util/systemtap )
- firewalld? ( >=net-firewall/firewalld-0.6.3 )
- fuse? ( sys-fs/fuse:= )
- glusterfs? ( >=sys-cluster/glusterfs-3.4.1 )
- iscsi? ( >=sys-block/open-iscsi-1.18.0 )
- iscsi-direct? ( >=net-libs/libiscsi-1.18.0 )
- libssh? ( >=net-libs/libssh-0.7:= )
- libssh2? ( >=net-libs/libssh2-1.3 )
- lvm? ( >=sys-fs/lvm2-2.02.48-r2[lvm] )
- lxc? ( !sys-apps/systemd[cgroup-hybrid(-)] )
- nfs? ( net-fs/nfs-utils )
- numa? (
- >sys-process/numactl-2.0.2
- sys-process/numad
- )
- parted? (
- >=sys-block/parted-1.8[device-mapper]
- sys-fs/lvm2[lvm]
- )
- pcap? ( >=net-libs/libpcap-1.8.0 )
- policykit? (
- acct-group/libvirt
- >=sys-auth/polkit-0.9
- )
- qemu? (
- >=app-emulation/qemu-4.2
- >=dev-libs/yajl-2.0.3:=
- )
- rbd? ( sys-cluster/ceph )
- sasl? ( >=dev-libs/cyrus-sasl-2.1.26 )
- selinux? ( >=sys-libs/libselinux-2.0.85 )
- virt-network? (
- net-dns/dnsmasq[dhcp,ipv6(+),script]
- net-firewall/ebtables
- >=net-firewall/iptables-1.4.10[ipv6(+)]
- net-misc/radvd
- sys-apps/iproute2[-minimal]
- )
- wireshark-plugins? ( >=net-analyzer/wireshark-2.6.0:= )
- xen? (
- >=app-emulation/xen-4.9.0
- app-emulation/xen-tools:=
- )
- udev? (
- virtual/libudev:=
- >=x11-libs/libpciaccess-0.10.9
- )
- zfs? ( sys-fs/zfs )
- kernel_linux? ( sys-apps/util-linux )"
-DEPEND="${BDEPEND}
- ${RDEPEND}
- ${PYTHON_DEPS}"
-
-PATCHES=(
- "${FILESDIR}"/${PN}-6.0.0-fix_paths_in_libvirt-guests_sh.patch
- "${FILESDIR}"/${PN}-8.2.0-do-not-use-sysconfig.patch
- "${FILESDIR}"/${PN}-8.2.0-fix-paths-for-apparmor.patch
- "${FILESDIR}"/${PN}-8.7.0-meson-Stop-detecting-Wl-version-script.patch
-)
-
-pkg_setup() {
- # Check kernel configuration:
- CONFIG_CHECK=""
- use fuse && CONFIG_CHECK+="
- ~FUSE_FS"
-
- use lvm && CONFIG_CHECK+="
- ~BLK_DEV_DM
- ~DM_MULTIPATH
- ~DM_SNAPSHOT"
-
- use lxc && CONFIG_CHECK+="
- ~BLK_CGROUP
- ~CGROUP_CPUACCT
- ~CGROUP_DEVICE
- ~CGROUP_FREEZER
- ~CGROUP_NET_PRIO
- ~CGROUP_PERF
- ~CGROUPS
- ~CGROUP_SCHED
- ~CPUSETS
- ~IPC_NS
- ~MACVLAN
- ~NAMESPACES
- ~NET_CLS_CGROUP
- ~NET_NS
- ~PID_NS
- ~POSIX_MQUEUE
- ~SECURITYFS
- ~USER_NS
- ~UTS_NS
- ~VETH
- ~!GRKERNSEC_CHROOT_MOUNT
- ~!GRKERNSEC_CHROOT_DOUBLE
- ~!GRKERNSEC_CHROOT_PIVOT
- ~!GRKERNSEC_CHROOT_CHMOD
- ~!GRKERNSEC_CHROOT_CAPS"
-
- kernel_is lt 4 7 && use lxc && CONFIG_CHECK+="
- ~DEVPTS_MULTIPLE_INSTANCES"
-
- use virt-network && CONFIG_CHECK+="
- ~BRIDGE_EBT_MARK_T
- ~BRIDGE_NF_EBTABLES
- ~NETFILTER_ADVANCED
- ~NETFILTER_XT_CONNMARK
- ~NETFILTER_XT_MARK
- ~NETFILTER_XT_TARGET_CHECKSUM
- ~IP_NF_FILTER
- ~IP_NF_MANGLE
- ~IP_NF_NAT
- ~IP6_NF_FILTER
- ~IP6_NF_MANGLE
- ~IP6_NF_NAT"
-
- # This was renamed in kernel commit v5.2-rc1~133^2~174^2~6
- if use virt-network ; then
- if kernel_is -lt 5 2 ; then
- CONFIG_CHECK+="
- ~IP_NF_TARGET_MASQUERADE"
- else
- CONFIG_CHECK+="
- ~NETFILTER_XT_TARGET_MASQUERADE"
- fi
- fi
-
- # Bandwidth Limiting Support
- use virt-network && CONFIG_CHECK+="
- ~BRIDGE_EBT_T_NAT
- ~IP_NF_TARGET_REJECT
- ~NET_ACT_POLICE
- ~NET_CLS_FW
- ~NET_CLS_U32
- ~NET_SCH_HTB
- ~NET_SCH_INGRESS
- ~NET_SCH_SFQ"
-
- ERROR_USER_NS="Optional depending on LXC configuration."
-
- if [[ -n ${CONFIG_CHECK} ]]; then
- linux-info_pkg_setup
- fi
-
- python-any-r1_pkg_setup
-}
-
-src_prepare() {
- touch "${S}/.mailmap" || die
-
- default
- python_fix_shebang .
-
- # Skip fragile tests which relies on pristine environment
- # (Breaks because of sandbox environment variables)
- # bug #802876
- sed -i -e "/commandtest/d" tests/meson.build || die
-
- # Tweak the init script:
- cp "${FILESDIR}/libvirtd.init-r19" "${S}/libvirtd.init" || die
- sed -e "s/USE_FLAG_FIREWALLD/$(usex firewalld 'need firewalld' '')/" \
- -i "${S}/libvirtd.init" || die "sed failed"
-}
-
-src_configure() {
- local emesonargs=(
- $(meson_feature apparmor)
- $(meson_feature apparmor apparmor_profiles)
- $(meson_feature audit)
- $(meson_feature caps capng)
- $(meson_feature dtrace)
- $(meson_feature firewalld)
- $(meson_feature fuse)
- $(meson_feature glusterfs)
- $(meson_feature glusterfs storage_gluster)
- $(meson_feature iscsi storage_iscsi)
- $(meson_feature iscsi-direct storage_iscsi_direct)
- $(meson_feature libvirtd driver_libvirtd)
- $(meson_feature libssh)
- $(meson_feature libssh2)
- $(meson_feature lvm storage_lvm)
- $(meson_feature lvm storage_mpath)
- $(meson_feature lxc driver_lxc)
- $(meson_feature nls)
- $(meson_feature numa numactl)
- $(meson_feature numa numad)
- $(meson_feature openvz driver_openvz)
- $(meson_feature parted storage_disk)
- $(meson_feature pcap libpcap)
- $(meson_feature policykit polkit)
- $(meson_feature qemu driver_qemu)
- $(meson_feature qemu yajl)
- $(meson_feature rbd storage_rbd)
- $(meson_feature sasl)
- $(meson_feature selinux)
- $(meson_feature udev)
- $(meson_feature virt-network driver_network)
- $(meson_feature virtualbox driver_vbox)
- $(meson_feature wireshark-plugins wireshark_dissector)
- $(meson_feature xen driver_libxl)
- $(meson_feature zfs storage_zfs)
-
- -Dnetcf=disabled
- -Dsanlock=disabled
- -Dopenwsman=disabled
-
- -Ddriver_esx=enabled
- -Dinit_script=systemd
- -Dqemu_user=$(usex caps qemu root)
- -Dqemu_group=$(usex caps qemu root)
- -Ddriver_remote=enabled
- -Dstorage_fs=enabled
- -Ddriver_vmware=enabled
-
- --localstatedir="${EPREFIX}/var"
- -Drunstatedir="${EPREFIX}/run"
- -Ddocdir="${EPREFIX}/usr/share/doc/${PF}"
- )
-
- meson_src_configure
-}
-
-src_test() {
- export VIR_TEST_DEBUG=1
- # Don't run the syntax check tests, they're fragile and not relevant
- # to us downstream anyway.
- # We also crank up the timeout (as Fedora does) just to preempt failures
- # on slower arches.
- meson_src_test --no-suite syntax-check --timeout-multiplier 10
-}
-
-src_install() {
- meson_src_install
-
- # Depending on configuration option, libvirt will create some bogus
- # directoreis. They are either not used, or libvirtd is able to create
- # them on demand, so let's remove them.
- #
- # Note, we are using -f here so that rm does not fail or warn if the
- # directory is nonexistent.
- rm -rf "${D}"/etc/sysconfig
- rm -rf "${D}"/var
- rm -rf "${D}"/run
-
- use libvirtd || return 0
- # From here, only libvirtd-related instructions, be warned!
-
- newtmpfiles "${FILESDIR}"/libvirtd.tmpfiles.conf libvirtd.conf
-
- newinitd "${S}/libvirtd.init" libvirtd
- newinitd "${FILESDIR}/libvirt-guests.init-r4" libvirt-guests
- newinitd "${FILESDIR}/virtlockd.init-r2" virtlockd
- newinitd "${FILESDIR}/virtlogd.init-r2" virtlogd
-
- newconfd "${FILESDIR}/libvirtd.confd-r5" libvirtd
- newconfd "${FILESDIR}/libvirt-guests.confd" libvirt-guests
-
- DOC_CONTENTS=$(<"${FILESDIR}/README.gentoo-r3")
- DISABLE_AUTOFORMATTING=true
- readme.gentoo_create_doc
-}
-
-pkg_postinst() {
- if [[ -e "${ROOT}"/etc/libvirt/qemu/networks/default.xml ]]; then
- touch "${ROOT}"/etc/libvirt/qemu/networks/default.xml || die
- fi
-
- use libvirtd || return 0
- # From here, only libvirtd-related instructions, be warned!
- tmpfiles_process libvirtd.conf
- readme.gentoo_print_elog
-}
diff --git a/app-emulation/libvirt/libvirt-8.8.0-r1.ebuild b/app-emulation/libvirt/libvirt-8.8.0-r1.ebuild
deleted file mode 100644
index e0f5cde83128..000000000000
--- a/app-emulation/libvirt/libvirt-8.8.0-r1.ebuild
+++ /dev/null
@@ -1,353 +0,0 @@
-# Copyright 1999-2023 Gentoo Authors
-# Distributed under the terms of the GNU General Public License v2
-
-EAPI=8
-
-# Packages which get releases together:
-# app-emacs/nxml-libvirt-schemas
-# dev-python/libvirt-python
-# dev-perl/Sys-Virt
-# app-emulation/libvirt
-# Please bump them together!
-
-PYTHON_COMPAT=( python3_{9..11} )
-VERIFY_SIG_OPENPGP_KEY_PATH="${BROOT}"/usr/share/openpgp-keys/libvirt.org.asc
-inherit meson linux-info python-any-r1 readme.gentoo-r1 tmpfiles verify-sig
-
-if [[ ${PV} = *9999* ]]; then
- inherit git-r3
- EGIT_REPO_URI="https://gitlab.com/libvirt/libvirt.git"
- EGIT_BRANCH="master"
-else
- SRC_URI="https://libvirt.org/sources/${P}.tar.xz
- verify-sig? ( https://libvirt.org/sources/${P}.tar.xz.asc )"
- KEYWORDS="~amd64 ~arm ~arm64 ~ppc64 ~x86"
-fi
-
-DESCRIPTION="C toolkit to manipulate virtual machines"
-HOMEPAGE="https://www.libvirt.org/ https://gitlab.com/libvirt/libvirt/"
-LICENSE="LGPL-2.1"
-SLOT="0/${PV}"
-IUSE="
- apparmor audit bash-completion +caps dtrace firewalld fuse glusterfs
- iscsi iscsi-direct +libvirtd lvm libssh libssh2 lxc nfs nls numa openvz
- parted pcap policykit +qemu rbd sasl selinux +udev
- virtualbox +virt-network wireshark-plugins xen zfs
-"
-
-REQUIRED_USE="
- firewalld? ( virt-network )
- libvirtd? ( || ( lxc openvz qemu virtualbox xen ) )
- lxc? ( caps libvirtd )
- openvz? ( libvirtd )
- qemu? ( libvirtd )
- virt-network? ( libvirtd )
- virtualbox? ( libvirtd )
- xen? ( libvirtd )"
-
-BDEPEND="
- app-text/xhtml1
- dev-lang/perl
- dev-libs/libxslt
- dev-perl/XML-XPath
- dev-python/docutils
- virtual/pkgconfig
- net-libs/rpcsvc-proto
- bash-completion? ( >=app-shells/bash-completion-2.0 )
- verify-sig? ( sec-keys/openpgp-keys-libvirt )"
-
-# gettext.sh command is used by the libvirt command wrappers, and it's
-# non-optional, so put it into RDEPEND.
-# We can use both libnl:1.1 and libnl:3, but if you have both installed, the
-# package will use 3 by default. Since we don't have slot pinning in an API,
-# we must go with the most recent
-RDEPEND="
- acct-user/qemu
- app-misc/scrub
- >=dev-libs/glib-2.56.0
- dev-libs/libgcrypt
- dev-libs/libnl:3
- >=dev-libs/libxml2-2.9.1
- >=net-analyzer/openbsd-netcat-1.105-r1
- >=net-libs/gnutls-3.2.0:=
- net-libs/libtirpc:=
- >=net-misc/curl-7.18.0
- sys-apps/dbus
- sys-apps/dmidecode
- sys-devel/gettext
- >=sys-libs/readline-7.0:=
- virtual/acl
- apparmor? ( sys-libs/libapparmor )
- audit? ( sys-process/audit )
- caps? ( sys-libs/libcap-ng )
- dtrace? ( dev-util/systemtap )
- firewalld? ( >=net-firewall/firewalld-0.6.3 )
- fuse? ( sys-fs/fuse:= )
- glusterfs? ( >=sys-cluster/glusterfs-3.4.1 )
- iscsi? ( >=sys-block/open-iscsi-1.18.0 )
- iscsi-direct? ( >=net-libs/libiscsi-1.18.0 )
- libssh? ( >=net-libs/libssh-0.8.1:= )
- libssh2? ( >=net-libs/libssh2-1.3 )
- lvm? ( >=sys-fs/lvm2-2.02.48-r2[lvm] )
- lxc? ( !sys-apps/systemd[cgroup-hybrid(-)] )
- nfs? ( net-fs/nfs-utils )
- numa? (
- >sys-process/numactl-2.0.2
- sys-process/numad
- )
- parted? (
- >=sys-block/parted-1.8[device-mapper]
- sys-fs/lvm2[lvm]
- )
- pcap? ( >=net-libs/libpcap-1.8.0 )
- policykit? (
- acct-group/libvirt
- >=sys-auth/polkit-0.9
- )
- qemu? (
- >=app-emulation/qemu-4.2
- >=dev-libs/yajl-2.0.3:=
- )
- rbd? ( sys-cluster/ceph )
- sasl? ( >=dev-libs/cyrus-sasl-2.1.26 )
- selinux? ( >=sys-libs/libselinux-2.0.85 )
- virt-network? (
- net-dns/dnsmasq[dhcp,ipv6(+),script]
- net-firewall/ebtables
- >=net-firewall/iptables-1.4.10[ipv6(+)]
- net-misc/radvd
- sys-apps/iproute2[-minimal]
- )
- wireshark-plugins? ( >=net-analyzer/wireshark-2.6.0:= )
- xen? (
- >=app-emulation/xen-4.9.0
- app-emulation/xen-tools:=
- )
- udev? (
- virtual/libudev:=
- >=x11-libs/libpciaccess-0.10.9
- )
- zfs? ( sys-fs/zfs )
- kernel_linux? ( sys-apps/util-linux )"
-DEPEND="${BDEPEND}
- ${RDEPEND}
- ${PYTHON_DEPS}"
-
-PATCHES=(
- "${FILESDIR}"/${PN}-6.0.0-fix_paths_in_libvirt-guests_sh.patch
- "${FILESDIR}"/${PN}-8.2.0-do-not-use-sysconfig.patch
- "${FILESDIR}"/${PN}-8.2.0-fix-paths-for-apparmor.patch
- "${FILESDIR}"/${PN}-8.7.0-meson-Stop-detecting-Wl-version-script.patch
-)
-
-pkg_setup() {
- # Check kernel configuration:
- CONFIG_CHECK=""
- use fuse && CONFIG_CHECK+="
- ~FUSE_FS"
-
- use lvm && CONFIG_CHECK+="
- ~BLK_DEV_DM
- ~DM_MULTIPATH
- ~DM_SNAPSHOT"
-
- use lxc && CONFIG_CHECK+="
- ~BLK_CGROUP
- ~CGROUP_CPUACCT
- ~CGROUP_DEVICE
- ~CGROUP_FREEZER
- ~CGROUP_NET_PRIO
- ~CGROUP_PERF
- ~CGROUPS
- ~CGROUP_SCHED
- ~CPUSETS
- ~IPC_NS
- ~MACVLAN
- ~NAMESPACES
- ~NET_CLS_CGROUP
- ~NET_NS
- ~PID_NS
- ~POSIX_MQUEUE
- ~SECURITYFS
- ~USER_NS
- ~UTS_NS
- ~VETH
- ~!GRKERNSEC_CHROOT_MOUNT
- ~!GRKERNSEC_CHROOT_DOUBLE
- ~!GRKERNSEC_CHROOT_PIVOT
- ~!GRKERNSEC_CHROOT_CHMOD
- ~!GRKERNSEC_CHROOT_CAPS"
-
- kernel_is lt 4 7 && use lxc && CONFIG_CHECK+="
- ~DEVPTS_MULTIPLE_INSTANCES"
-
- use virt-network && CONFIG_CHECK+="
- ~BRIDGE_EBT_MARK_T
- ~BRIDGE_NF_EBTABLES
- ~NETFILTER_ADVANCED
- ~NETFILTER_XT_CONNMARK
- ~NETFILTER_XT_MARK
- ~NETFILTER_XT_TARGET_CHECKSUM
- ~IP_NF_FILTER
- ~IP_NF_MANGLE
- ~IP_NF_NAT
- ~IP6_NF_FILTER
- ~IP6_NF_MANGLE
- ~IP6_NF_NAT"
-
- # This was renamed in kernel commit v5.2-rc1~133^2~174^2~6
- if use virt-network ; then
- if kernel_is -lt 5 2 ; then
- CONFIG_CHECK+="
- ~IP_NF_TARGET_MASQUERADE"
- else
- CONFIG_CHECK+="
- ~NETFILTER_XT_TARGET_MASQUERADE"
- fi
- fi
-
- # Bandwidth Limiting Support
- use virt-network && CONFIG_CHECK+="
- ~BRIDGE_EBT_T_NAT
- ~IP_NF_TARGET_REJECT
- ~NET_ACT_POLICE
- ~NET_CLS_FW
- ~NET_CLS_U32
- ~NET_SCH_HTB
- ~NET_SCH_INGRESS
- ~NET_SCH_SFQ"
-
- ERROR_USER_NS="Optional depending on LXC configuration."
-
- if [[ -n ${CONFIG_CHECK} ]]; then
- linux-info_pkg_setup
- fi
-
- python-any-r1_pkg_setup
-}
-
-src_prepare() {
- touch "${S}/.mailmap" || die
-
- default
- python_fix_shebang .
-
- # Skip fragile tests which relies on pristine environment
- # (Breaks because of sandbox environment variables)
- # bug #802876
- sed -i -e "/commandtest/d" tests/meson.build || die
-
- # Tweak the init script:
- cp "${FILESDIR}/libvirtd.init-r19" "${S}/libvirtd.init" || die
- sed -e "s/USE_FLAG_FIREWALLD/$(usex firewalld 'need firewalld' '')/" \
- -i "${S}/libvirtd.init" || die "sed failed"
-}
-
-src_configure() {
- local emesonargs=(
- $(meson_feature apparmor)
- $(meson_feature apparmor apparmor_profiles)
- $(meson_feature audit)
- $(meson_feature caps capng)
- $(meson_feature dtrace)
- $(meson_feature firewalld)
- $(meson_feature fuse)
- $(meson_feature glusterfs)
- $(meson_feature glusterfs storage_gluster)
- $(meson_feature iscsi storage_iscsi)
- $(meson_feature iscsi-direct storage_iscsi_direct)
- $(meson_feature libvirtd driver_libvirtd)
- $(meson_feature libssh)
- $(meson_feature libssh2)
- $(meson_feature lvm storage_lvm)
- $(meson_feature lvm storage_mpath)
- $(meson_feature lxc driver_lxc)
- $(meson_feature nls)
- $(meson_feature numa numactl)
- $(meson_feature numa numad)
- $(meson_feature openvz driver_openvz)
- $(meson_feature parted storage_disk)
- $(meson_feature pcap libpcap)
- $(meson_feature policykit polkit)
- $(meson_feature qemu driver_qemu)
- $(meson_feature qemu yajl)
- $(meson_feature rbd storage_rbd)
- $(meson_feature sasl)
- $(meson_feature selinux)
- $(meson_feature udev)
- $(meson_feature virt-network driver_network)
- $(meson_feature virtualbox driver_vbox)
- $(meson_feature wireshark-plugins wireshark_dissector)
- $(meson_feature xen driver_libxl)
- $(meson_feature zfs storage_zfs)
-
- -Dnetcf=disabled
- -Dsanlock=disabled
- -Dopenwsman=disabled
-
- -Ddriver_esx=enabled
- -Dinit_script=systemd
- -Dqemu_user=$(usex caps qemu root)
- -Dqemu_group=$(usex caps qemu root)
- -Ddriver_remote=enabled
- -Dstorage_fs=enabled
- -Ddriver_vmware=enabled
-
- --localstatedir="${EPREFIX}/var"
- -Drunstatedir="${EPREFIX}/run"
- -Ddocdir="${EPREFIX}/usr/share/doc/${PF}"
- )
-
- meson_src_configure
-}
-
-src_test() {
- export VIR_TEST_DEBUG=1
- # Don't run the syntax check tests, they're fragile and not relevant
- # to us downstream anyway.
- # We also crank up the timeout (as Fedora does) just to preempt failures
- # on slower arches.
- meson_src_test --no-suite syntax-check --timeout-multiplier 10
-}
-
-src_install() {
- meson_src_install
-
- # Depending on configuration option, libvirt will create some bogus
- # directoreis. They are either not used, or libvirtd is able to create
- # them on demand, so let's remove them.
- #
- # Note, we are using -f here so that rm does not fail or warn if the
- # directory is nonexistent.
- rm -rf "${D}"/etc/sysconfig
- rm -rf "${D}"/var
- rm -rf "${D}"/run
-
- use libvirtd || return 0
- # From here, only libvirtd-related instructions, be warned!
-
- newtmpfiles "${FILESDIR}"/libvirtd.tmpfiles.conf libvirtd.conf
-
- newinitd "${S}/libvirtd.init" libvirtd
- newinitd "${FILESDIR}/libvirt-guests.init-r4" libvirt-guests
- newinitd "${FILESDIR}/virtlockd.init-r2" virtlockd
- newinitd "${FILESDIR}/virtlogd.init-r2" virtlogd
-
- newconfd "${FILESDIR}/libvirtd.confd-r5" libvirtd
- newconfd "${FILESDIR}/libvirt-guests.confd" libvirt-guests
-
- DOC_CONTENTS=$(<"${FILESDIR}/README.gentoo-r3")
- DISABLE_AUTOFORMATTING=true
- readme.gentoo_create_doc
-}
-
-pkg_postinst() {
- if [[ -e "${ROOT}"/etc/libvirt/qemu/networks/default.xml ]]; then
- touch "${ROOT}"/etc/libvirt/qemu/networks/default.xml || die
- fi
-
- use libvirtd || return 0
- # From here, only libvirtd-related instructions, be warned!
- tmpfiles_process libvirtd.conf
- readme.gentoo_print_elog
-}
diff --git a/app-emulation/libvirt/libvirt-8.9.0-r2.ebuild b/app-emulation/libvirt/libvirt-8.9.0-r2.ebuild
deleted file mode 100644
index e531e9999331..000000000000
--- a/app-emulation/libvirt/libvirt-8.9.0-r2.ebuild
+++ /dev/null
@@ -1,360 +0,0 @@
-# Copyright 1999-2023 Gentoo Authors
-# Distributed under the terms of the GNU General Public License v2
-
-EAPI=8
-
-# Packages which get releases together:
-# app-emacs/nxml-libvirt-schemas
-# dev-python/libvirt-python
-# dev-perl/Sys-Virt
-# app-emulation/libvirt
-# Please bump them together!
-
-PYTHON_COMPAT=( python3_{9..11} )
-VERIFY_SIG_OPENPGP_KEY_PATH="${BROOT}"/usr/share/openpgp-keys/libvirt.org.asc
-inherit meson linux-info python-any-r1 readme.gentoo-r1 tmpfiles verify-sig
-
-if [[ ${PV} = *9999* ]]; then
- inherit git-r3
- EGIT_REPO_URI="https://gitlab.com/libvirt/libvirt.git"
- EGIT_BRANCH="master"
-else
- SRC_URI="https://libvirt.org/sources/${P}.tar.xz
- verify-sig? ( https://libvirt.org/sources/${P}.tar.xz.asc )"
- KEYWORDS="amd64 ~arm arm64 ~ppc64 x86"
-fi
-
-DESCRIPTION="C toolkit to manipulate virtual machines"
-HOMEPAGE="https://www.libvirt.org/ https://gitlab.com/libvirt/libvirt/"
-LICENSE="LGPL-2.1"
-SLOT="0/${PV}"
-IUSE="
- apparmor audit bash-completion +caps dtrace firewalld fuse glusterfs
- iscsi iscsi-direct +libvirtd lvm libssh libssh2 lxc nfs nls numa openvz
- parted pcap policykit +qemu rbd sasl selinux +udev
- virtualbox +virt-network wireshark-plugins xen zfs
-"
-
-REQUIRED_USE="
- firewalld? ( virt-network )
- libvirtd? ( || ( lxc openvz qemu virtualbox xen ) )
- lxc? ( caps libvirtd )
- openvz? ( libvirtd )
- qemu? ( libvirtd )
- virt-network? ( libvirtd )
- virtualbox? ( libvirtd )
- xen? ( libvirtd )"
-
-BDEPEND="
- app-text/xhtml1
- dev-lang/perl
- dev-libs/libxslt
- dev-perl/XML-XPath
- dev-python/docutils
- virtual/pkgconfig
- net-libs/rpcsvc-proto
- bash-completion? ( >=app-shells/bash-completion-2.0 )
- verify-sig? ( sec-keys/openpgp-keys-libvirt )"
-
-# gettext.sh command is used by the libvirt command wrappers, and it's
-# non-optional, so put it into RDEPEND.
-# We can use both libnl:1.1 and libnl:3, but if you have both installed, the
-# package will use 3 by default. Since we don't have slot pinning in an API,
-# we must go with the most recent.
-RDEPEND="
- acct-user/qemu
- app-misc/scrub
- >=dev-libs/glib-2.56.0
- dev-libs/libgcrypt
- dev-libs/libnl:3
- >=dev-libs/libxml2-2.9.1
- >=net-analyzer/openbsd-netcat-1.105-r1
- >=net-libs/gnutls-3.2.0:=
- net-libs/libtirpc:=
- >=net-misc/curl-7.18.0
- sys-apps/dbus
- sys-apps/dmidecode
- sys-devel/gettext
- >=sys-libs/readline-7.0:=
- virtual/acl
- apparmor? ( sys-libs/libapparmor )
- audit? ( sys-process/audit )
- caps? ( sys-libs/libcap-ng )
- dtrace? ( dev-util/systemtap )
- firewalld? ( >=net-firewall/firewalld-0.6.3 )
- fuse? ( sys-fs/fuse:= )
- glusterfs? ( >=sys-cluster/glusterfs-3.4.1 )
- iscsi? ( >=sys-block/open-iscsi-1.18.0 )
- iscsi-direct? ( >=net-libs/libiscsi-1.18.0 )
- libssh? ( >=net-libs/libssh-0.8.1:= )
- libssh2? ( >=net-libs/libssh2-1.3 )
- lvm? ( >=sys-fs/lvm2-2.02.48-r2[lvm] )
- lxc? ( !sys-apps/systemd[cgroup-hybrid(-)] )
- nfs? ( net-fs/nfs-utils )
- numa? (
- >sys-process/numactl-2.0.2
- sys-process/numad
- )
- parted? (
- >=sys-block/parted-1.8[device-mapper]
- sys-fs/lvm2[lvm]
- )
- pcap? ( >=net-libs/libpcap-1.8.0 )
- policykit? (
- acct-group/libvirt
- >=sys-auth/polkit-0.9
- )
- qemu? (
- >=app-emulation/qemu-4.2
- >=dev-libs/yajl-2.0.3:=
- )
- rbd? ( sys-cluster/ceph )
- sasl? ( >=dev-libs/cyrus-sasl-2.1.26 )
- selinux? ( >=sys-libs/libselinux-2.0.85 )
- virt-network? (
- net-dns/dnsmasq[dhcp,ipv6(+),script]
- net-firewall/ebtables
- >=net-firewall/iptables-1.4.10[ipv6(+)]
- net-misc/radvd
- sys-apps/iproute2[-minimal]
- )
- wireshark-plugins? ( >=net-analyzer/wireshark-2.6.0:= )
- xen? (
- >=app-emulation/xen-4.9.0
- app-emulation/xen-tools:=
- )
- udev? (
- virtual/libudev:=
- >=x11-libs/libpciaccess-0.10.9
- )
- zfs? ( sys-fs/zfs )
- kernel_linux? ( sys-apps/util-linux )"
-DEPEND="
- ${BDEPEND}
- ${RDEPEND}
- ${PYTHON_DEPS}
-"
-# The 'circular' dependency on dev-python/libvirt-python is because of
-# virt-qemu-qmp-proxy.
-PDEPEND="
- qemu? ( dev-python/libvirt-python )
-"
-
-PATCHES=(
- "${FILESDIR}"/${PN}-6.0.0-fix_paths_in_libvirt-guests_sh.patch
- "${FILESDIR}"/${PN}-8.2.0-do-not-use-sysconfig.patch
- "${FILESDIR}"/${PN}-8.2.0-fix-paths-for-apparmor.patch
- "${FILESDIR}"/${PN}-9.2.0-meson-Stop-detecting-Wl-version-script.patch
-)
-
-pkg_setup() {
- # Check kernel configuration:
- CONFIG_CHECK=""
- use fuse && CONFIG_CHECK+="
- ~FUSE_FS"
-
- use lvm && CONFIG_CHECK+="
- ~BLK_DEV_DM
- ~DM_MULTIPATH
- ~DM_SNAPSHOT"
-
- use lxc && CONFIG_CHECK+="
- ~BLK_CGROUP
- ~CGROUP_CPUACCT
- ~CGROUP_DEVICE
- ~CGROUP_FREEZER
- ~CGROUP_NET_PRIO
- ~CGROUP_PERF
- ~CGROUPS
- ~CGROUP_SCHED
- ~CPUSETS
- ~IPC_NS
- ~MACVLAN
- ~NAMESPACES
- ~NET_CLS_CGROUP
- ~NET_NS
- ~PID_NS
- ~POSIX_MQUEUE
- ~SECURITYFS
- ~USER_NS
- ~UTS_NS
- ~VETH
- ~!GRKERNSEC_CHROOT_MOUNT
- ~!GRKERNSEC_CHROOT_DOUBLE
- ~!GRKERNSEC_CHROOT_PIVOT
- ~!GRKERNSEC_CHROOT_CHMOD
- ~!GRKERNSEC_CHROOT_CAPS"
-
- kernel_is lt 4 7 && use lxc && CONFIG_CHECK+="
- ~DEVPTS_MULTIPLE_INSTANCES"
-
- use virt-network && CONFIG_CHECK+="
- ~BRIDGE_EBT_MARK_T
- ~BRIDGE_NF_EBTABLES
- ~NETFILTER_ADVANCED
- ~NETFILTER_XT_CONNMARK
- ~NETFILTER_XT_MARK
- ~NETFILTER_XT_TARGET_CHECKSUM
- ~IP_NF_FILTER
- ~IP_NF_MANGLE
- ~IP_NF_NAT
- ~IP6_NF_FILTER
- ~IP6_NF_MANGLE
- ~IP6_NF_NAT"
-
- # This was renamed in kernel commit v5.2-rc1~133^2~174^2~6
- if use virt-network ; then
- if kernel_is -lt 5 2 ; then
- CONFIG_CHECK+="
- ~IP_NF_TARGET_MASQUERADE"
- else
- CONFIG_CHECK+="
- ~NETFILTER_XT_TARGET_MASQUERADE"
- fi
- fi
-
- # Bandwidth Limiting Support
- use virt-network && CONFIG_CHECK+="
- ~BRIDGE_EBT_T_NAT
- ~IP_NF_TARGET_REJECT
- ~NET_ACT_POLICE
- ~NET_CLS_FW
- ~NET_CLS_U32
- ~NET_SCH_HTB
- ~NET_SCH_INGRESS
- ~NET_SCH_SFQ"
-
- ERROR_USER_NS="Optional depending on LXC configuration."
-
- if [[ -n ${CONFIG_CHECK} ]]; then
- linux-info_pkg_setup
- fi
-
- python-any-r1_pkg_setup
-}
-
-src_prepare() {
- touch "${S}/.mailmap" || die
-
- default
- python_fix_shebang .
-
- # Skip fragile tests which relies on pristine environment
- # (Breaks because of sandbox environment variables)
- # bug #802876
- sed -i -e "/commandtest/d" tests/meson.build || die
-
- # Tweak the init script:
- cp "${FILESDIR}/libvirtd.init-r19" "${S}/libvirtd.init" || die
- sed -e "s/USE_FLAG_FIREWALLD/$(usex firewalld 'need firewalld' '')/" \
- -i "${S}/libvirtd.init" || die "sed failed"
-}
-
-src_configure() {
- local emesonargs=(
- $(meson_feature apparmor)
- $(meson_feature apparmor apparmor_profiles)
- $(meson_feature audit)
- $(meson_feature caps capng)
- $(meson_feature dtrace)
- $(meson_feature firewalld)
- $(meson_feature fuse)
- $(meson_feature glusterfs)
- $(meson_feature glusterfs storage_gluster)
- $(meson_feature iscsi storage_iscsi)
- $(meson_feature iscsi-direct storage_iscsi_direct)
- $(meson_feature libvirtd driver_libvirtd)
- $(meson_feature libssh)
- $(meson_feature libssh2)
- $(meson_feature lvm storage_lvm)
- $(meson_feature lvm storage_mpath)
- $(meson_feature lxc driver_lxc)
- $(meson_feature nls)
- $(meson_feature numa numactl)
- $(meson_feature numa numad)
- $(meson_feature openvz driver_openvz)
- $(meson_feature parted storage_disk)
- $(meson_feature pcap libpcap)
- $(meson_feature policykit polkit)
- $(meson_feature qemu driver_qemu)
- $(meson_feature qemu yajl)
- $(meson_feature rbd storage_rbd)
- $(meson_feature sasl)
- $(meson_feature selinux)
- $(meson_feature udev)
- $(meson_feature virt-network driver_network)
- $(meson_feature virtualbox driver_vbox)
- $(meson_feature wireshark-plugins wireshark_dissector)
- $(meson_feature xen driver_libxl)
- $(meson_feature zfs storage_zfs)
-
- -Dnetcf=disabled
- -Dsanlock=disabled
- -Dopenwsman=disabled
-
- -Ddriver_esx=enabled
- -Dinit_script=systemd
- -Dqemu_user=$(usex caps qemu root)
- -Dqemu_group=$(usex caps qemu root)
- -Ddriver_remote=enabled
- -Dstorage_fs=enabled
- -Ddriver_vmware=enabled
-
- --localstatedir="${EPREFIX}/var"
- -Drunstatedir="${EPREFIX}/run"
- -Ddocdir="${EPREFIX}/usr/share/doc/${PF}"
- )
-
- meson_src_configure
-}
-
-src_test() {
- export VIR_TEST_DEBUG=1
- # Don't run the syntax check tests, they're fragile and not relevant
- # to us downstream anyway.
- # We also crank up the timeout (as Fedora does) just to preempt failures
- # on slower arches.
- meson_src_test --no-suite syntax-check --timeout-multiplier 10
-}
-
-src_install() {
- meson_src_install
-
- # Depending on configuration option, libvirt will create some bogus
- # directoreis. They are either not used, or libvirtd is able to create
- # them on demand, so let's remove them.
- #
- # Note, we are using -f here so that rm does not fail or warn if the
- # directory is nonexistent.
- rm -rf "${D}"/etc/sysconfig
- rm -rf "${D}"/var
- rm -rf "${D}"/run
-
- use libvirtd || return 0
- # From here, only libvirtd-related instructions, be warned!
-
- newtmpfiles "${FILESDIR}"/libvirtd.tmpfiles.conf libvirtd.conf
-
- newinitd "${S}/libvirtd.init" libvirtd
- newinitd "${FILESDIR}/libvirt-guests.init-r4" libvirt-guests
- newinitd "${FILESDIR}/virtlockd.init-r2" virtlockd
- newinitd "${FILESDIR}/virtlogd.init-r2" virtlogd
-
- newconfd "${FILESDIR}/libvirtd.confd-r5" libvirtd
- newconfd "${FILESDIR}/libvirt-guests.confd" libvirt-guests
-
- DOC_CONTENTS=$(<"${FILESDIR}/README.gentoo-r3")
- DISABLE_AUTOFORMATTING=true
- readme.gentoo_create_doc
-}
-
-pkg_postinst() {
- if [[ -e "${ROOT}"/etc/libvirt/qemu/networks/default.xml ]]; then
- touch "${ROOT}"/etc/libvirt/qemu/networks/default.xml || die
- fi
-
- use libvirtd || return 0
- # From here, only libvirtd-related instructions, be warned!
- tmpfiles_process libvirtd.conf
- readme.gentoo_print_elog
-}
diff --git a/app-emulation/libvirt/libvirt-8.9.0.ebuild b/app-emulation/libvirt/libvirt-8.9.0.ebuild
deleted file mode 100644
index 5436a91bf68e..000000000000
--- a/app-emulation/libvirt/libvirt-8.9.0.ebuild
+++ /dev/null
@@ -1,356 +0,0 @@
-# Copyright 1999-2023 Gentoo Authors
-# Distributed under the terms of the GNU General Public License v2
-
-EAPI=8
-
-# Packages which get releases together:
-# app-emacs/nxml-libvirt-schemas
-# dev-python/libvirt-python
-# dev-perl/Sys-Virt
-# app-emulation/libvirt
-# Please bump them together!
-
-PYTHON_COMPAT=( python3_{9..11} )
-VERIFY_SIG_OPENPGP_KEY_PATH="${BROOT}"/usr/share/openpgp-keys/libvirt.org.asc
-inherit meson linux-info python-any-r1 readme.gentoo-r1 tmpfiles verify-sig
-
-if [[ ${PV} = *9999* ]]; then
- inherit git-r3
- EGIT_REPO_URI="https://gitlab.com/libvirt/libvirt.git"
- EGIT_BRANCH="master"
-else
- SRC_URI="https://libvirt.org/sources/${P}.tar.xz
- verify-sig? ( https://libvirt.org/sources/${P}.tar.xz.asc )"
- KEYWORDS="amd64 ~arm ~arm64 ~ppc64 x86"
-fi
-
-DESCRIPTION="C toolkit to manipulate virtual machines"
-HOMEPAGE="https://www.libvirt.org/ https://gitlab.com/libvirt/libvirt/"
-LICENSE="LGPL-2.1"
-SLOT="0/${PV}"
-IUSE="
- apparmor audit bash-completion +caps dtrace firewalld fuse glusterfs
- iscsi iscsi-direct +libvirtd lvm libssh libssh2 lxc nfs nls numa openvz
- parted pcap policykit +qemu rbd sasl selinux +udev
- virtualbox +virt-network wireshark-plugins xen zfs
-"
-
-REQUIRED_USE="
- firewalld? ( virt-network )
- libvirtd? ( || ( lxc openvz qemu virtualbox xen ) )
- lxc? ( caps libvirtd )
- openvz? ( libvirtd )
- qemu? ( libvirtd )
- virt-network? ( libvirtd )
- virtualbox? ( libvirtd )
- xen? ( libvirtd )"
-
-BDEPEND="
- app-text/xhtml1
- dev-lang/perl
- dev-libs/libxslt
- dev-perl/XML-XPath
- dev-python/docutils
- virtual/pkgconfig
- net-libs/rpcsvc-proto
- bash-completion? ( >=app-shells/bash-completion-2.0 )
- verify-sig? ( sec-keys/openpgp-keys-libvirt )"
-
-# gettext.sh command is used by the libvirt command wrappers, and it's
-# non-optional, so put it into RDEPEND.
-# We can use both libnl:1.1 and libnl:3, but if you have both installed, the
-# package will use 3 by default. Since we don't have slot pinning in an API,
-# we must go with the most recent.
-# The 'circular' dependency on dev-python/libvirt-python is because of
-# virt-qemu-qmp-proxy.
-RDEPEND="
- acct-user/qemu
- app-misc/scrub
- >=dev-libs/glib-2.56.0
- dev-libs/libgcrypt
- dev-libs/libnl:3
- >=dev-libs/libxml2-2.9.1
- >=net-analyzer/openbsd-netcat-1.105-r1
- >=net-libs/gnutls-3.2.0:=
- net-libs/libtirpc:=
- >=net-misc/curl-7.18.0
- sys-apps/dbus
- sys-apps/dmidecode
- sys-devel/gettext
- >=sys-libs/readline-7.0:=
- virtual/acl
- apparmor? ( sys-libs/libapparmor )
- audit? ( sys-process/audit )
- caps? ( sys-libs/libcap-ng )
- dtrace? ( dev-util/systemtap )
- firewalld? ( >=net-firewall/firewalld-0.6.3 )
- fuse? ( sys-fs/fuse:= )
- glusterfs? ( >=sys-cluster/glusterfs-3.4.1 )
- iscsi? ( >=sys-block/open-iscsi-1.18.0 )
- iscsi-direct? ( >=net-libs/libiscsi-1.18.0 )
- libssh? ( >=net-libs/libssh-0.8.1:= )
- libssh2? ( >=net-libs/libssh2-1.3 )
- lvm? ( >=sys-fs/lvm2-2.02.48-r2[lvm] )
- lxc? ( !sys-apps/systemd[cgroup-hybrid(-)] )
- nfs? ( net-fs/nfs-utils )
- numa? (
- >sys-process/numactl-2.0.2
- sys-process/numad
- )
- parted? (
- >=sys-block/parted-1.8[device-mapper]
- sys-fs/lvm2[lvm]
- )
- pcap? ( >=net-libs/libpcap-1.8.0 )
- policykit? (
- acct-group/libvirt
- >=sys-auth/polkit-0.9
- )
- qemu? (
- >=app-emulation/qemu-4.2
- >=dev-libs/yajl-2.0.3:=
- dev-python/libvirt-python
- )
- rbd? ( sys-cluster/ceph )
- sasl? ( >=dev-libs/cyrus-sasl-2.1.26 )
- selinux? ( >=sys-libs/libselinux-2.0.85 )
- virt-network? (
- net-dns/dnsmasq[dhcp,ipv6(+),script]
- net-firewall/ebtables
- >=net-firewall/iptables-1.4.10[ipv6(+)]
- net-misc/radvd
- sys-apps/iproute2[-minimal]
- )
- wireshark-plugins? ( >=net-analyzer/wireshark-2.6.0:= )
- xen? (
- >=app-emulation/xen-4.9.0
- app-emulation/xen-tools:=
- )
- udev? (
- virtual/libudev:=
- >=x11-libs/libpciaccess-0.10.9
- )
- zfs? ( sys-fs/zfs )
- kernel_linux? ( sys-apps/util-linux )"
-DEPEND="${BDEPEND}
- ${RDEPEND}
- ${PYTHON_DEPS}"
-
-PATCHES=(
- "${FILESDIR}"/${PN}-6.0.0-fix_paths_in_libvirt-guests_sh.patch
- "${FILESDIR}"/${PN}-8.2.0-do-not-use-sysconfig.patch
- "${FILESDIR}"/${PN}-8.2.0-fix-paths-for-apparmor.patch
- "${FILESDIR}"/${PN}-9.2.0-meson-Stop-detecting-Wl-version-script.patch
-)
-
-pkg_setup() {
- # Check kernel configuration:
- CONFIG_CHECK=""
- use fuse && CONFIG_CHECK+="
- ~FUSE_FS"
-
- use lvm && CONFIG_CHECK+="
- ~BLK_DEV_DM
- ~DM_MULTIPATH
- ~DM_SNAPSHOT"
-
- use lxc && CONFIG_CHECK+="
- ~BLK_CGROUP
- ~CGROUP_CPUACCT
- ~CGROUP_DEVICE
- ~CGROUP_FREEZER
- ~CGROUP_NET_PRIO
- ~CGROUP_PERF
- ~CGROUPS
- ~CGROUP_SCHED
- ~CPUSETS
- ~IPC_NS
- ~MACVLAN
- ~NAMESPACES
- ~NET_CLS_CGROUP
- ~NET_NS
- ~PID_NS
- ~POSIX_MQUEUE
- ~SECURITYFS
- ~USER_NS
- ~UTS_NS
- ~VETH
- ~!GRKERNSEC_CHROOT_MOUNT
- ~!GRKERNSEC_CHROOT_DOUBLE
- ~!GRKERNSEC_CHROOT_PIVOT
- ~!GRKERNSEC_CHROOT_CHMOD
- ~!GRKERNSEC_CHROOT_CAPS"
-
- kernel_is lt 4 7 && use lxc && CONFIG_CHECK+="
- ~DEVPTS_MULTIPLE_INSTANCES"
-
- use virt-network && CONFIG_CHECK+="
- ~BRIDGE_EBT_MARK_T
- ~BRIDGE_NF_EBTABLES
- ~NETFILTER_ADVANCED
- ~NETFILTER_XT_CONNMARK
- ~NETFILTER_XT_MARK
- ~NETFILTER_XT_TARGET_CHECKSUM
- ~IP_NF_FILTER
- ~IP_NF_MANGLE
- ~IP_NF_NAT
- ~IP6_NF_FILTER
- ~IP6_NF_MANGLE
- ~IP6_NF_NAT"
-
- # This was renamed in kernel commit v5.2-rc1~133^2~174^2~6
- if use virt-network ; then
- if kernel_is -lt 5 2 ; then
- CONFIG_CHECK+="
- ~IP_NF_TARGET_MASQUERADE"
- else
- CONFIG_CHECK+="
- ~NETFILTER_XT_TARGET_MASQUERADE"
- fi
- fi
-
- # Bandwidth Limiting Support
- use virt-network && CONFIG_CHECK+="
- ~BRIDGE_EBT_T_NAT
- ~IP_NF_TARGET_REJECT
- ~NET_ACT_POLICE
- ~NET_CLS_FW
- ~NET_CLS_U32
- ~NET_SCH_HTB
- ~NET_SCH_INGRESS
- ~NET_SCH_SFQ"
-
- ERROR_USER_NS="Optional depending on LXC configuration."
-
- if [[ -n ${CONFIG_CHECK} ]]; then
- linux-info_pkg_setup
- fi
-
- python-any-r1_pkg_setup
-}
-
-src_prepare() {
- touch "${S}/.mailmap" || die
-
- default
- python_fix_shebang .
-
- # Skip fragile tests which relies on pristine environment
- # (Breaks because of sandbox environment variables)
- # bug #802876
- sed -i -e "/commandtest/d" tests/meson.build || die
-
- # Tweak the init script:
- cp "${FILESDIR}/libvirtd.init-r19" "${S}/libvirtd.init" || die
- sed -e "s/USE_FLAG_FIREWALLD/$(usex firewalld 'need firewalld' '')/" \
- -i "${S}/libvirtd.init" || die "sed failed"
-}
-
-src_configure() {
- local emesonargs=(
- $(meson_feature apparmor)
- $(meson_feature apparmor apparmor_profiles)
- $(meson_feature audit)
- $(meson_feature caps capng)
- $(meson_feature dtrace)
- $(meson_feature firewalld)
- $(meson_feature fuse)
- $(meson_feature glusterfs)
- $(meson_feature glusterfs storage_gluster)
- $(meson_feature iscsi storage_iscsi)
- $(meson_feature iscsi-direct storage_iscsi_direct)
- $(meson_feature libvirtd driver_libvirtd)
- $(meson_feature libssh)
- $(meson_feature libssh2)
- $(meson_feature lvm storage_lvm)
- $(meson_feature lvm storage_mpath)
- $(meson_feature lxc driver_lxc)
- $(meson_feature nls)
- $(meson_feature numa numactl)
- $(meson_feature numa numad)
- $(meson_feature openvz driver_openvz)
- $(meson_feature parted storage_disk)
- $(meson_feature pcap libpcap)
- $(meson_feature policykit polkit)
- $(meson_feature qemu driver_qemu)
- $(meson_feature qemu yajl)
- $(meson_feature rbd storage_rbd)
- $(meson_feature sasl)
- $(meson_feature selinux)
- $(meson_feature udev)
- $(meson_feature virt-network driver_network)
- $(meson_feature virtualbox driver_vbox)
- $(meson_feature wireshark-plugins wireshark_dissector)
- $(meson_feature xen driver_libxl)
- $(meson_feature zfs storage_zfs)
-
- -Dnetcf=disabled
- -Dsanlock=disabled
- -Dopenwsman=disabled
-
- -Ddriver_esx=enabled
- -Dinit_script=systemd
- -Dqemu_user=$(usex caps qemu root)
- -Dqemu_group=$(usex caps qemu root)
- -Ddriver_remote=enabled
- -Dstorage_fs=enabled
- -Ddriver_vmware=enabled
-
- --localstatedir="${EPREFIX}/var"
- -Drunstatedir="${EPREFIX}/run"
- -Ddocdir="${EPREFIX}/usr/share/doc/${PF}"
- )
-
- meson_src_configure
-}
-
-src_test() {
- export VIR_TEST_DEBUG=1
- # Don't run the syntax check tests, they're fragile and not relevant
- # to us downstream anyway.
- # We also crank up the timeout (as Fedora does) just to preempt failures
- # on slower arches.
- meson_src_test --no-suite syntax-check --timeout-multiplier 10
-}
-
-src_install() {
- meson_src_install
-
- # Depending on configuration option, libvirt will create some bogus
- # directoreis. They are either not used, or libvirtd is able to create
- # them on demand, so let's remove them.
- #
- # Note, we are using -f here so that rm does not fail or warn if the
- # directory is nonexistent.
- rm -rf "${D}"/etc/sysconfig
- rm -rf "${D}"/var
- rm -rf "${D}"/run
-
- use libvirtd || return 0
- # From here, only libvirtd-related instructions, be warned!
-
- newtmpfiles "${FILESDIR}"/libvirtd.tmpfiles.conf libvirtd.conf
-
- newinitd "${S}/libvirtd.init" libvirtd
- newinitd "${FILESDIR}/libvirt-guests.init-r4" libvirt-guests
- newinitd "${FILESDIR}/virtlockd.init-r2" virtlockd
- newinitd "${FILESDIR}/virtlogd.init-r2" virtlogd
-
- newconfd "${FILESDIR}/libvirtd.confd-r5" libvirtd
- newconfd "${FILESDIR}/libvirt-guests.confd" libvirt-guests
-
- DOC_CONTENTS=$(<"${FILESDIR}/README.gentoo-r3")
- DISABLE_AUTOFORMATTING=true
- readme.gentoo_create_doc
-}
-
-pkg_postinst() {
- if [[ -e "${ROOT}"/etc/libvirt/qemu/networks/default.xml ]]; then
- touch "${ROOT}"/etc/libvirt/qemu/networks/default.xml || die
- fi
-
- use libvirtd || return 0
- # From here, only libvirtd-related instructions, be warned!
- tmpfiles_process libvirtd.conf
- readme.gentoo_print_elog
-}
diff --git a/app-emulation/libvirt/libvirt-9.2.0.ebuild b/app-emulation/libvirt/libvirt-9.2.0.ebuild
deleted file mode 100644
index 0713f78055c0..000000000000
--- a/app-emulation/libvirt/libvirt-9.2.0.ebuild
+++ /dev/null
@@ -1,359 +0,0 @@
-# Copyright 1999-2023 Gentoo Authors
-# Distributed under the terms of the GNU General Public License v2
-
-EAPI=8
-
-# Packages which get releases together:
-# app-emacs/nxml-libvirt-schemas
-# dev-python/libvirt-python
-# dev-perl/Sys-Virt
-# app-emulation/libvirt
-# Please bump them together!
-
-PYTHON_COMPAT=( python3_{9..11} )
-VERIFY_SIG_OPENPGP_KEY_PATH="${BROOT}"/usr/share/openpgp-keys/libvirt.org.asc
-inherit meson linux-info python-any-r1 readme.gentoo-r1 tmpfiles verify-sig
-
-if [[ ${PV} = *9999* ]]; then
- inherit git-r3
- EGIT_REPO_URI="https://gitlab.com/libvirt/libvirt.git"
- EGIT_BRANCH="master"
-else
- SRC_URI="https://libvirt.org/sources/${P}.tar.xz
- verify-sig? ( https://libvirt.org/sources/${P}.tar.xz.asc )"
- KEYWORDS="~amd64 ~arm ~arm64 ~ppc64 ~x86"
-fi
-
-DESCRIPTION="C toolkit to manipulate virtual machines"
-HOMEPAGE="https://www.libvirt.org/ https://gitlab.com/libvirt/libvirt/"
-LICENSE="LGPL-2.1"
-SLOT="0/${PV}"
-IUSE="
- apparmor audit bash-completion +caps dtrace firewalld fuse glusterfs
- iscsi iscsi-direct +libvirtd lvm libssh libssh2 lxc nfs nls numa openvz
- parted pcap policykit +qemu rbd sasl selinux +udev
- virtualbox +virt-network wireshark-plugins xen zfs
-"
-
-REQUIRED_USE="
- firewalld? ( virt-network )
- libvirtd? ( || ( lxc openvz qemu virtualbox xen ) )
- lxc? ( caps libvirtd )
- openvz? ( libvirtd )
- qemu? ( libvirtd )
- virt-network? ( libvirtd )
- virtualbox? ( libvirtd )
- xen? ( libvirtd )"
-
-BDEPEND="
- app-text/xhtml1
- dev-lang/perl
- dev-libs/libxslt
- dev-perl/XML-XPath
- dev-python/docutils
- virtual/pkgconfig
- net-libs/rpcsvc-proto
- bash-completion? ( >=app-shells/bash-completion-2.0 )
- verify-sig? ( sec-keys/openpgp-keys-libvirt )"
-
-# gettext.sh command is used by the libvirt command wrappers, and it's
-# non-optional, so put it into RDEPEND.
-# We can use both libnl:1.1 and libnl:3, but if you have both installed, the
-# package will use 3 by default. Since we don't have slot pinning in an API,
-# we must go with the most recent.
-RDEPEND="
- acct-user/qemu
- app-misc/scrub
- >=dev-libs/glib-2.56.0
- dev-libs/libgcrypt
- dev-libs/libnl:3
- >=dev-libs/libxml2-2.9.1
- >=net-analyzer/openbsd-netcat-1.105-r1
- >=net-libs/gnutls-3.2.0:=
- net-libs/libtirpc:=
- >=net-misc/curl-7.18.0
- sys-apps/dbus
- sys-apps/dmidecode
- sys-devel/gettext
- >=sys-libs/readline-7.0:=
- virtual/acl
- apparmor? ( sys-libs/libapparmor )
- audit? ( sys-process/audit )
- caps? ( sys-libs/libcap-ng )
- dtrace? ( dev-util/systemtap )
- firewalld? ( >=net-firewall/firewalld-0.6.3 )
- fuse? ( sys-fs/fuse:= )
- glusterfs? ( >=sys-cluster/glusterfs-3.4.1 )
- iscsi? ( >=sys-block/open-iscsi-1.18.0 )
- iscsi-direct? ( >=net-libs/libiscsi-1.18.0 )
- libssh? ( >=net-libs/libssh-0.8.1:= )
- libssh2? ( >=net-libs/libssh2-1.3 )
- lvm? ( >=sys-fs/lvm2-2.02.48-r2[lvm] )
- lxc? ( !sys-apps/systemd[cgroup-hybrid(-)] )
- nfs? ( net-fs/nfs-utils )
- numa? (
- >sys-process/numactl-2.0.2
- sys-process/numad
- )
- parted? (
- >=sys-block/parted-1.8[device-mapper]
- sys-fs/lvm2[lvm]
- )
- pcap? ( >=net-libs/libpcap-1.8.0 )
- policykit? (
- acct-group/libvirt
- >=sys-auth/polkit-0.9
- )
- qemu? (
- >=app-emulation/qemu-4.2
- >=dev-libs/yajl-2.0.3:=
- )
- rbd? ( sys-cluster/ceph )
- sasl? ( >=dev-libs/cyrus-sasl-2.1.26 )
- selinux? ( >=sys-libs/libselinux-2.0.85 )
- virt-network? (
- net-dns/dnsmasq[dhcp,ipv6(+),script]
- net-firewall/ebtables
- >=net-firewall/iptables-1.4.10[ipv6(+)]
- net-misc/radvd
- sys-apps/iproute2[-minimal]
- )
- wireshark-plugins? ( >=net-analyzer/wireshark-2.6.0:= )
- xen? (
- >=app-emulation/xen-4.9.0
- app-emulation/xen-tools:=
- )
- udev? (
- virtual/libudev:=
- >=x11-libs/libpciaccess-0.10.9
- )
- zfs? ( sys-fs/zfs )
- kernel_linux? ( sys-apps/util-linux )"
-DEPEND="
- ${BDEPEND}
- ${RDEPEND}
- ${PYTHON_DEPS}
-"
-# The 'circular' dependency on dev-python/libvirt-python is because of
-# virt-qemu-qmp-proxy.
-PDEPEND="
- qemu? ( dev-python/libvirt-python )
-"
-
-PATCHES=(
- "${FILESDIR}"/${PN}-6.0.0-fix_paths_in_libvirt-guests_sh.patch
- "${FILESDIR}"/${PN}-8.2.0-do-not-use-sysconfig.patch
- "${FILESDIR}"/${PN}-8.2.0-fix-paths-for-apparmor.patch
-)
-
-pkg_setup() {
- # Check kernel configuration:
- CONFIG_CHECK=""
- use fuse && CONFIG_CHECK+="
- ~FUSE_FS"
-
- use lvm && CONFIG_CHECK+="
- ~BLK_DEV_DM
- ~DM_MULTIPATH
- ~DM_SNAPSHOT"
-
- use lxc && CONFIG_CHECK+="
- ~BLK_CGROUP
- ~CGROUP_CPUACCT
- ~CGROUP_DEVICE
- ~CGROUP_FREEZER
- ~CGROUP_NET_PRIO
- ~CGROUP_PERF
- ~CGROUPS
- ~CGROUP_SCHED
- ~CPUSETS
- ~IPC_NS
- ~MACVLAN
- ~NAMESPACES
- ~NET_CLS_CGROUP
- ~NET_NS
- ~PID_NS
- ~POSIX_MQUEUE
- ~SECURITYFS
- ~USER_NS
- ~UTS_NS
- ~VETH
- ~!GRKERNSEC_CHROOT_MOUNT
- ~!GRKERNSEC_CHROOT_DOUBLE
- ~!GRKERNSEC_CHROOT_PIVOT
- ~!GRKERNSEC_CHROOT_CHMOD
- ~!GRKERNSEC_CHROOT_CAPS"
-
- kernel_is lt 4 7 && use lxc && CONFIG_CHECK+="
- ~DEVPTS_MULTIPLE_INSTANCES"
-
- use virt-network && CONFIG_CHECK+="
- ~BRIDGE_EBT_MARK_T
- ~BRIDGE_NF_EBTABLES
- ~NETFILTER_ADVANCED
- ~NETFILTER_XT_CONNMARK
- ~NETFILTER_XT_MARK
- ~NETFILTER_XT_TARGET_CHECKSUM
- ~IP_NF_FILTER
- ~IP_NF_MANGLE
- ~IP_NF_NAT
- ~IP6_NF_FILTER
- ~IP6_NF_MANGLE
- ~IP6_NF_NAT"
-
- # This was renamed in kernel commit v5.2-rc1~133^2~174^2~6
- if use virt-network ; then
- if kernel_is -lt 5 2 ; then
- CONFIG_CHECK+="
- ~IP_NF_TARGET_MASQUERADE"
- else
- CONFIG_CHECK+="
- ~NETFILTER_XT_TARGET_MASQUERADE"
- fi
- fi
-
- # Bandwidth Limiting Support
- use virt-network && CONFIG_CHECK+="
- ~BRIDGE_EBT_T_NAT
- ~IP_NF_TARGET_REJECT
- ~NET_ACT_POLICE
- ~NET_CLS_FW
- ~NET_CLS_U32
- ~NET_SCH_HTB
- ~NET_SCH_INGRESS
- ~NET_SCH_SFQ"
-
- ERROR_USER_NS="Optional depending on LXC configuration."
-
- if [[ -n ${CONFIG_CHECK} ]]; then
- linux-info_pkg_setup
- fi
-
- python-any-r1_pkg_setup
-}
-
-src_prepare() {
- touch "${S}/.mailmap" || die
-
- default
- python_fix_shebang .
-
- # Skip fragile tests which relies on pristine environment
- # (Breaks because of sandbox environment variables)
- # bug #802876
- sed -i -e "/commandtest/d" tests/meson.build || die
-
- # Tweak the init script:
- cp "${FILESDIR}/libvirtd.init-r19" "${S}/libvirtd.init" || die
- sed -e "s/USE_FLAG_FIREWALLD/$(usex firewalld 'need firewalld' '')/" \
- -i "${S}/libvirtd.init" || die "sed failed"
-}
-
-src_configure() {
- local emesonargs=(
- $(meson_feature apparmor)
- $(meson_feature apparmor apparmor_profiles)
- $(meson_feature audit)
- $(meson_feature caps capng)
- $(meson_feature dtrace)
- $(meson_feature firewalld)
- $(meson_feature fuse)
- $(meson_feature glusterfs)
- $(meson_feature glusterfs storage_gluster)
- $(meson_feature iscsi storage_iscsi)
- $(meson_feature iscsi-direct storage_iscsi_direct)
- $(meson_feature libvirtd driver_libvirtd)
- $(meson_feature libssh)
- $(meson_feature libssh2)
- $(meson_feature lvm storage_lvm)
- $(meson_feature lvm storage_mpath)
- $(meson_feature lxc driver_lxc)
- $(meson_feature nls)
- $(meson_feature numa numactl)
- $(meson_feature numa numad)
- $(meson_feature openvz driver_openvz)
- $(meson_feature parted storage_disk)
- $(meson_feature pcap libpcap)
- $(meson_feature policykit polkit)
- $(meson_feature qemu driver_qemu)
- $(meson_feature qemu yajl)
- $(meson_feature rbd storage_rbd)
- $(meson_feature sasl)
- $(meson_feature selinux)
- $(meson_feature udev)
- $(meson_feature virt-network driver_network)
- $(meson_feature virtualbox driver_vbox)
- $(meson_feature wireshark-plugins wireshark_dissector)
- $(meson_feature xen driver_libxl)
- $(meson_feature zfs storage_zfs)
-
- -Dnetcf=disabled
- -Dsanlock=disabled
- -Dopenwsman=disabled
-
- -Ddriver_esx=enabled
- -Dinit_script=systemd
- -Dqemu_user=$(usex caps qemu root)
- -Dqemu_group=$(usex caps qemu root)
- -Ddriver_remote=enabled
- -Dstorage_fs=enabled
- -Ddriver_vmware=enabled
-
- --localstatedir="${EPREFIX}/var"
- -Drunstatedir="${EPREFIX}/run"
- -Ddocdir="${EPREFIX}/usr/share/doc/${PF}"
- )
-
- meson_src_configure
-}
-
-src_test() {
- export VIR_TEST_DEBUG=1
- # Don't run the syntax check tests, they're fragile and not relevant
- # to us downstream anyway.
- # We also crank up the timeout (as Fedora does) just to preempt failures
- # on slower arches.
- meson_src_test --no-suite syntax-check --timeout-multiplier 10
-}
-
-src_install() {
- meson_src_install
-
- # Depending on configuration option, libvirt will create some bogus
- # directoreis. They are either not used, or libvirtd is able to create
- # them on demand, so let's remove them.
- #
- # Note, we are using -f here so that rm does not fail or warn if the
- # directory is nonexistent.
- rm -rf "${D}"/etc/sysconfig
- rm -rf "${D}"/var
- rm -rf "${D}"/run
-
- use libvirtd || return 0
- # From here, only libvirtd-related instructions, be warned!
-
- newtmpfiles "${FILESDIR}"/libvirtd.tmpfiles.conf libvirtd.conf
-
- newinitd "${S}/libvirtd.init" libvirtd
- newinitd "${FILESDIR}/libvirt-guests.init-r4" libvirt-guests
- newinitd "${FILESDIR}/virtlockd.init-r2" virtlockd
- newinitd "${FILESDIR}/virtlogd.init-r2" virtlogd
-
- newconfd "${FILESDIR}/libvirtd.confd-r5" libvirtd
- newconfd "${FILESDIR}/libvirt-guests.confd" libvirt-guests
-
- DOC_CONTENTS=$(<"${FILESDIR}/README.gentoo-r3")
- DISABLE_AUTOFORMATTING=true
- readme.gentoo_create_doc
-}
-
-pkg_postinst() {
- if [[ -e "${ROOT}"/etc/libvirt/qemu/networks/default.xml ]]; then
- touch "${ROOT}"/etc/libvirt/qemu/networks/default.xml || die
- fi
-
- use libvirtd || return 0
- # From here, only libvirtd-related instructions, be warned!
- tmpfiles_process libvirtd.conf
- readme.gentoo_print_elog
-}