From 7fa8a1e3f149eea4c844c47cfe26136ed7614c58 Mon Sep 17 00:00:00 2001 From: V3n3RiX Date: Mon, 15 Apr 2024 12:04:03 +0100 Subject: gentoo auto-resync : 15:04:2024 - 12:04:02 --- app-emulation/Manifest.gz | Bin 15629 -> 15634 bytes app-emulation/cloud-init/Manifest | 4 +- app-emulation/cloud-init/cloud-init-23.4.ebuild | 4 +- app-emulation/cloud-init/cloud-init-9999.ebuild | 4 +- app-emulation/diskimage-builder/Manifest | 4 +- .../diskimage-builder-3.32.0.ebuild | 2 +- .../diskimage-builder-9999.ebuild | 4 +- app-emulation/glean/Manifest | 2 +- app-emulation/glean/glean-1.23.0-r1.ebuild | 2 +- app-emulation/libvirt/Manifest | 15 +- ...y-one-error-in-udevListInterfacesByStatus.patch | 42 +++ ...k-for-negative-array-lengths-before-alloc.patch | 222 +++++++++++++ app-emulation/libvirt/libvirt-10.0.0-r1.ebuild | 365 -------------------- app-emulation/libvirt/libvirt-10.0.0-r2.ebuild | 367 +++++++++++++++++++++ app-emulation/libvirt/libvirt-10.1.0-r1.ebuild | 366 ++++++++++++++++++++ app-emulation/libvirt/libvirt-10.1.0.ebuild | 365 -------------------- app-emulation/libvirt/libvirt-10.2.0.ebuild | 365 ++++++++++++++++++++ app-emulation/libvirt/libvirt-9.8.0-r1.ebuild | 364 -------------------- app-emulation/libvirt/libvirt-9.8.0-r2.ebuild | 366 ++++++++++++++++++++ app-emulation/libvirt/libvirt-9.9.0-r1.ebuild | 365 -------------------- app-emulation/libvirt/libvirt-9.9.0-r2.ebuild | 367 +++++++++++++++++++++ app-emulation/libvirt/libvirt-9999.ebuild | 2 +- 22 files changed, 2119 insertions(+), 1478 deletions(-) create mode 100644 app-emulation/libvirt/files/libvirt-10.1.0-Fix-off-by-one-error-in-udevListInterfacesByStatus.patch create mode 100644 app-emulation/libvirt/files/libvirt-10.2.0-remote-check-for-negative-array-lengths-before-alloc.patch delete mode 100644 app-emulation/libvirt/libvirt-10.0.0-r1.ebuild create mode 100644 app-emulation/libvirt/libvirt-10.0.0-r2.ebuild create mode 100644 app-emulation/libvirt/libvirt-10.1.0-r1.ebuild delete mode 100644 app-emulation/libvirt/libvirt-10.1.0.ebuild create mode 100644 app-emulation/libvirt/libvirt-10.2.0.ebuild delete mode 100644 app-emulation/libvirt/libvirt-9.8.0-r1.ebuild create mode 100644 app-emulation/libvirt/libvirt-9.8.0-r2.ebuild delete mode 100644 app-emulation/libvirt/libvirt-9.9.0-r1.ebuild create mode 100644 app-emulation/libvirt/libvirt-9.9.0-r2.ebuild (limited to 'app-emulation') diff --git a/app-emulation/Manifest.gz b/app-emulation/Manifest.gz index c0b58377e512..82d8e05479e4 100644 Binary files a/app-emulation/Manifest.gz and b/app-emulation/Manifest.gz differ diff --git a/app-emulation/cloud-init/Manifest b/app-emulation/cloud-init/Manifest index 688bde01afdf..165c2fd2ecf7 100644 --- a/app-emulation/cloud-init/Manifest +++ b/app-emulation/cloud-init/Manifest @@ -3,6 +3,6 @@ DIST cloud-init-22.4.tar.gz 1494295 BLAKE2B 5f961c895c0d6c78a7cee47d2b52acd57d95 DIST cloud-init-23.4.tar.gz 1648908 BLAKE2B 0acec9c437c7a5a86ed9cd8718830a7311c257ae9f223a68959b8d1eccc693b35f6a716de5c04112d848c1e2e54f6461a3919fd733debba18989145f6669d359 SHA512 34966b173571764bf83779bef0e89a86971310ff0fa62feceef4fbe17c9fa6d1b69f11f57caaa32cc4ae4a74f598f157dfb3ce356221044666401230cfb1ad13 EBUILD cloud-init-22.2.2.ebuild 2349 BLAKE2B 7d07d812fd91251e685abc7896c27d37f6b73c8fe6459fbb844e009fac79b29621f4f6dfc1e5f53f62dea78f3e49ebf44fc27ba486e3d0df0ba59978a60e3608 SHA512 561c83ee47dbb3ea4c6265cfcf79b10e9feff76a1ed3c9a7cc6d09e7b1cb730e3684c89bc12eff0d3cd943cc0529aad469aeedf2a953f86782cbe363d6103982 EBUILD cloud-init-22.4.ebuild 2360 BLAKE2B 40394aaadaacb9b629b521f612aac61bb995f4d179c324ed20f5fcd479d42356af2ec1a8f5476cbed047d8d590a4c2925aeac42b16f8701eef526c72a1b5da58 SHA512 a9a56b8d950bb123b4dc634da1b532ab529c963433e0295b9c5e03536abe288f51cfa37cb3a4d0720fdfae199d20e73c85d6f860e8b0fa9dd6d4ba9a39616f92 -EBUILD cloud-init-23.4.ebuild 2354 BLAKE2B 2f081769cf558bcdf92bf9814547e83864b3ef8731267d1ac7e322846cb9b8672e05bfb64919579aa09086025008e4ad5fb42272e94453a7b06a31f4064676f7 SHA512 fb13fb91d763eddf461299bbc27ba7a7675aa36a18cf0100a337179fdc26bf6e161f7dcc467a6efb391fbe1db3e58e08d422cddd9d7e1917f6cadd0b11771fbd -EBUILD cloud-init-9999.ebuild 2316 BLAKE2B dc9f5e7d8961bcd68dbf527b04f9167781eb8a3245c8ec46a9e232cec862ebe8107504f3682b32316533202f5d7c4231f35a95c7c9a842345ac58433f79774bb SHA512 8b9c76dc7f85ad335365bcc11b972542599e872dad8670bb47727248074541dc2696ad7828796add480bb45e1c3d4ce3e935bb9e27b22126d6e3af7e1203e9a4 +EBUILD cloud-init-23.4.ebuild 2365 BLAKE2B d85524509daaab0c9aab97da1ae3cc23d818c80a524d42e219282ab6bd60ec94adb885906842e52ebc87a23ada6bc2788521fd77916222a0bf70c9f7e095827e SHA512 2c541f842cd337846495f2d905f9ebc953cd553c445376927dadfce0c7602e89a1545888231bf3418fd3b00a703a30c12e7d6ce6f6f6fba894ecb04f25746569 +EBUILD cloud-init-9999.ebuild 2327 BLAKE2B 3da5e804a5e009d0cb3181c9e70bcf9a3dbbcb234fbc0f29fc3418d467ec09aa98ee101f9562ac792f03a6ea0c2e0eaea40d1d7f6f4d51bd5417f16a5bd5dfac SHA512 7f5179f3c0d3433415f9a84b744fda5b09d6feb8b2bdb4bf134f27e23ebde917baae5ebdaa482e68e65da433031160b644268e7c90660fecc796622ca1a97610 MISC metadata.xml 714 BLAKE2B 22888016216cea9e471f7cef63e94022c344961263a3319508d5b23db64eeaaeb34a470fc51482bf7a0a4cb658dd814f5655393ee4498a7212ccec28caee5256 SHA512 3bd7be60f29d5a1e4a830577c0afc8c5925123f1258a78b82dbc36c8f76f096149db8bcebfaf3b6db5feeab0bc82ccb65d7d71ec12feb4f56027f05eeb930401 diff --git a/app-emulation/cloud-init/cloud-init-23.4.ebuild b/app-emulation/cloud-init/cloud-init-23.4.ebuild index a0b8bf1f21f8..eba8a0ee55f0 100644 --- a/app-emulation/cloud-init/cloud-init-23.4.ebuild +++ b/app-emulation/cloud-init/cloud-init-23.4.ebuild @@ -1,4 +1,4 @@ -# Copyright 1999-2023 Gentoo Authors +# Copyright 1999-2024 Gentoo Authors # Distributed under the terms of the GNU General Public License v2 EAPI=8 @@ -6,7 +6,7 @@ EAPI=8 # Disabled for now: bug #850628 # https://bugs.launchpad.net/cloud-init/+bug/1978328 #DISTUTILS_USE_PEP517=setuptools -PYTHON_COMPAT=( python3_10 python3_11 ) +PYTHON_COMPAT=( python3_10 python3_11 python3_12 ) inherit distutils-r1 udev diff --git a/app-emulation/cloud-init/cloud-init-9999.ebuild b/app-emulation/cloud-init/cloud-init-9999.ebuild index e3c6b940635d..7bb69ee6336a 100644 --- a/app-emulation/cloud-init/cloud-init-9999.ebuild +++ b/app-emulation/cloud-init/cloud-init-9999.ebuild @@ -1,4 +1,4 @@ -# Copyright 1999-2023 Gentoo Authors +# Copyright 1999-2024 Gentoo Authors # Distributed under the terms of the GNU General Public License v2 EAPI=8 @@ -6,7 +6,7 @@ EAPI=8 # Disabled for now: bug #850628 #DISTUTILS_USE_PEP517=setuptools # https://bugs.launchpad.net/cloud-init/+bug/1978328 -PYTHON_COMPAT=( python3_10 python3_11 ) +PYTHON_COMPAT=( python3_10 python3_11 python3_12 ) inherit distutils-r1 udev diff --git a/app-emulation/diskimage-builder/Manifest b/app-emulation/diskimage-builder/Manifest index 1a484e1e3a3d..0a50f10ee962 100644 --- a/app-emulation/diskimage-builder/Manifest +++ b/app-emulation/diskimage-builder/Manifest @@ -1,4 +1,4 @@ DIST diskimage-builder-3.32.0.tar.gz 532942 BLAKE2B e436e5268b649dc5e050f66b098e527b79f172df00da93f23c115e3d88692c3f6546774c2046c8d4722cdd4139af4d05701725496f283b60e08ce0885b70de66 SHA512 6f5c2e0df428bf85b847fdc0ceebfdb66823b92b5b903de247d0e83ff2588c36e6f9786ea91f252c838cedeec22913f491d79643e77d83ad1fb690da7566af47 -EBUILD diskimage-builder-3.32.0.ebuild 1145 BLAKE2B bc6f453a98fc9d6b4041c018d9610f8a60386e981b08f3a11d4c766baa576ec59455659f2b221fcf0ce4a1e05e01b715ce7961dfc89fe62b25469da6d896162f SHA512 2403af62eac05230f2fc8fe7f7ea8329ca40547c50a30599f83e31afeaba0ed01dd12ba455639361e265d28ced056d646d81be1b35481a9c37a29078b935d09b -EBUILD diskimage-builder-9999.ebuild 1147 BLAKE2B 0a2b1c0b02c91e39b784599fc72eb00fa640250a504f31743a8d08ebdb6dcb4a2ea7c2adc9b1c615db51f76b6cbe26ee97d6d6753222e1780e397180f39b061f SHA512 b71f155820cbbbb8f02e84b3dd0df18fe9000349d3e1a1006244c56c210490e622e16fcbb37c1d86b94424feb63a64d2fe4ad858154e7110bf7a033f738a5acd +EBUILD diskimage-builder-3.32.0.ebuild 1148 BLAKE2B 80cdd4dd6d827fea40acabbfe40c45db3f6c1e5669141be85e5386730a1cd5ce2a60653351e66cd0d0a34039dae66e241bb4df6cd0e4f8c088943c0d471949dc SHA512 a20766404d440a7ee0fa9fde578bfbe5b8cab8aaa9d50547c5198e7e627f844e73a74accb755bd549016ae1abad4157b02e7ceb6b3a4b5a14d6a54f1d0e7c029 +EBUILD diskimage-builder-9999.ebuild 1150 BLAKE2B cb6b0c907222e777a71259ae7ad392fddaaa7414de8e2e184a1b166468cd2e22b290bbe73ba0e8bc42ade365abb98e1f84bbafb300175a34ce46bb2848fd701b SHA512 420b978f701cf15c76c88b52e73baf64e3e9c8d7862e549d434150739d9b2504387744b5c187ae6894500651ca986d49a500b1d5534e6dfa363805e73bd78968 MISC metadata.xml 719 BLAKE2B 872a4d37e8ddb2a28eb85d18cd88990934327bc23194f3be9e5dea03627a6169987b246a93b50754cbe5e331f8c854a808bf307b70521c481d83b846f7385606 SHA512 d151fd95659211b2057ef0a61a6020e2f9efebebf3d7c5e1392ddb9954e3627e1040f2a9fe84ea4caeb65a745411fefebf2d896bbddbe0ddbb56acf42d2fedc3 diff --git a/app-emulation/diskimage-builder/diskimage-builder-3.32.0.ebuild b/app-emulation/diskimage-builder/diskimage-builder-3.32.0.ebuild index 65265e1f5201..ee67baf77be4 100644 --- a/app-emulation/diskimage-builder/diskimage-builder-3.32.0.ebuild +++ b/app-emulation/diskimage-builder/diskimage-builder-3.32.0.ebuild @@ -3,7 +3,7 @@ EAPI=8 -PYTHON_COMPAT=( python3_{9,10,11} ) +PYTHON_COMPAT=( python3_{9,10,11,12} ) DISTUTILS_USE_PEP517=setuptools PYPI_NO_NORMALIZE=1 inherit distutils-r1 diff --git a/app-emulation/diskimage-builder/diskimage-builder-9999.ebuild b/app-emulation/diskimage-builder/diskimage-builder-9999.ebuild index 2f2696ced6ca..f94dda84287d 100644 --- a/app-emulation/diskimage-builder/diskimage-builder-9999.ebuild +++ b/app-emulation/diskimage-builder/diskimage-builder-9999.ebuild @@ -1,9 +1,9 @@ -# Copyright 1999-2023 Gentoo Authors +# Copyright 1999-2024 Gentoo Authors # Distributed under the terms of the GNU General Public License v2 EAPI=8 -PYTHON_COMPAT=( python3_{9,10,11} ) +PYTHON_COMPAT=( python3_{9,10,11,12} ) DISTUTILS_USE_PEP517=setuptools PYPI_NO_NORMALIZE=1 inherit distutils-r1 diff --git a/app-emulation/glean/Manifest b/app-emulation/glean/Manifest index 0b2cbee1e222..6a1bb4b0e456 100644 --- a/app-emulation/glean/Manifest +++ b/app-emulation/glean/Manifest @@ -1,4 +1,4 @@ AUX glean.initd 241 BLAKE2B ea451713203da8dd61eef5155e2ab2d5fa7be5d9cd210ce2d0ce890fe54af05b461671702d1a2b60b8e6b8e0cb0f4d12f90ff2884409e9f2a3dcc380ba48bb60 SHA512 a5af77b16e1864158dfe858f932dd4eecb5633bd71fbdd00085863e56bd1862d7eba4500d0f4ac8c692b06750fcfe3f9f5b2bb7a4ca6a4ba72dbc43bb12856c5 DIST glean-1.23.0.tar.gz 76426 BLAKE2B bca6d2da0393bb28392d3c9ab7708cf4b053e4736203b9c26bc278a52c6a829abead13ecb63ebb60ade9a4127ebba9dd560b75b765c3a168ea389025b07638a0 SHA512 4eca5ccd18bd7864fdecd35b483e5da6a0854c076d0266f802b70b7838de61790c9237f8928807a45d6845fa8ca9a37e2228653326759204483803b28de191ee -EBUILD glean-1.23.0-r1.ebuild 534 BLAKE2B 07cd2be60bf62876dc530ff2e9213097c92fc97c8e487fca0ce7cc3e565e8673b6db3a76317832895bdbc6b458e5c2dbe3fd48f481bddb267b0389eaae52e569 SHA512 7cabc193b63f9a7a0d2796cdcf8a00e9ac9eef9f7d851d762ed5f0ea0b3d1d7ade75b48859aae0fd93486ea916946f4ea63321f8402cf6a180ac3e9387ce2e20 +EBUILD glean-1.23.0-r1.ebuild 537 BLAKE2B 5e96c93c5544ef98ddc773d3c63869b112ba25ea354b83bc08910bcf1b978b9f15936a4f0240505e916300c4b31743c7287154310a6da6476b24f09a59311db9 SHA512 a74c925931ae41abb3b1780cbdcb58ce33acc545d69579166b6beeadebe83b50130f1d5d9fc34e083d02dee8a7b09123e2ed5e7fa5d46c1ed9ed93228fa878ea MISC metadata.xml 698 BLAKE2B a0702c57b38fbe6c2f8493833895d6a411ac75d35b6e216338dd51fb2f13dc35756174ad8f5b6e36ec584046973fb8644cc32c0c010184f945065fe58eb95d1e SHA512 4e9e178d4030e02fa469412886fb40cecebc4611daf31028840a36b55521992c278780f7a5cd1dd57faa4d98eabcdd7bdc925aacfed3aa3235c87f1906259e26 diff --git a/app-emulation/glean/glean-1.23.0-r1.ebuild b/app-emulation/glean/glean-1.23.0-r1.ebuild index ab8799b85a34..d5c813a3e0ad 100644 --- a/app-emulation/glean/glean-1.23.0-r1.ebuild +++ b/app-emulation/glean/glean-1.23.0-r1.ebuild @@ -3,7 +3,7 @@ EAPI=7 -PYTHON_COMPAT=( python3_{9,10,11} ) +PYTHON_COMPAT=( python3_{9,10,11,12} ) DISTUTILS_USE_PEP517=setuptools inherit distutils-r1 pypi diff --git a/app-emulation/libvirt/Manifest b/app-emulation/libvirt/Manifest index cfdb01d6f513..5bf5358665f9 100644 --- a/app-emulation/libvirt/Manifest +++ b/app-emulation/libvirt/Manifest @@ -1,4 +1,6 @@ AUX README.gentoo-r3 2065 BLAKE2B f3677b916121126c431ba32e324bcc9f04b4dfeef1ee54517cae1118c67274592d890d6d919a48af6709e9220379797549277904a02fea740a69b1bf8f2397aa SHA512 77ede8a3e1a380b334595e65ae148acd2e52d594200253dc67d68dd256db5bf72ce7ce222d067c739ce53f84634421e74726f30c0ab7a1c76b86ccdc191c8a69 +AUX libvirt-10.1.0-Fix-off-by-one-error-in-udevListInterfacesByStatus.patch 1665 BLAKE2B 25c162ca5d33c36e1b97185f3db8517e707a20d8ee2573dfd15f9540af1a2a1d39706ffbc1b6e55be0b7156ca0d146715c9f629add883ff0d89122dd7a9962e4 SHA512 dd5dc696412529a6d004ea03ef75c991fbe7c7be839467e9bf2e8a8b2119275b053b4549e9924907b146e841c4a81e8f1ee2744c7d275c5a4007d80b87e5b1af +AUX libvirt-10.2.0-remote-check-for-negative-array-lengths-before-alloc.patch 9364 BLAKE2B 05ac0aaea8741102a34657b4910569ae5601364bdfd419743900823537f982348ba68cbac37fe10b21c2869531a35d68de8fbeb462c1f66aa0c3af4a97630405 SHA512 72a40984e6de167af8de9aedabdecf79c0f99bb5e7152b6521e87268bf1a1050b9d0d9acbb86c54810029dbde671a518ebd8a3f11590594a3226d818b89188f1 AUX libvirt-9.10.0-virxml-include-libxml-xmlsave.h-for-xmlIndentTreeOut.patch 1125 BLAKE2B d161698463c56b9fbb8b4c4a5ec1b7d65e87e088d68ea1a2cde316449c80d9ba2a4ad5883962eb3e4d31b0441917f6b02d4c781869083c47c8eeb432f6826e8b SHA512 d1dbcb9f6e1c66a38fa09af84248c8ac68d1f263f07b275e12ae3087a6fbd223eeefe20c7b241d02be9529c14bcf311d850d418bc8cecac4cb4e225d78800a41 AUX libvirt-9.4.0-do-not-use-sysconfig.patch 8195 BLAKE2B b731d57dc86fe725d3cbd47b6e691a414107d3594377bd1c73e19735368937a0983e407ec05700213d2ec5802e90f429fd5c7354cd03fb25d3acced952ab6f38 SHA512 2a2e08a6034ed37cafebde3b0fd27913d972d1e9f8816e10a9af951e99f10bd3b9bc7ada1ac50c5085e3fdd3d02301365d031eb6ce3b71102e4b3072d609f21b AUX libvirt-9.4.0-fix_paths_in_libvirt-guests_sh.patch 988 BLAKE2B 5936eafa5c300edad7ed368ec13063d31aea59e3daefeac59cf515ea44667f61aa63b0e2c2a5c88ace24c48cc132789cc5fa1a7c6c04c17e9ac61b114778e46d SHA512 5b80a5ec2898c1c821d0d49b9de67a256f82cb60879215ddde07c2a51f2e8a8b6893fec65617c27edec50cd51a362fb1fcdd21827e8de954f26879adcfa12418 @@ -15,13 +17,16 @@ DIST libvirt-10.0.0.tar.xz 9395076 BLAKE2B bfbea7805a949999481293a31e52a5511bcf8 DIST libvirt-10.0.0.tar.xz.asc 833 BLAKE2B e6377fe80a96025fe643d9bb14b3d64da3cf7f53000d8ee55606b4bc635d735943c4a7baa3796cbb7ce5812f03e2efd700aeef72e5bfcce68938b873aeca3f1f SHA512 08681d45c39695b07c88b27fddc471284ed66caa091a73ea3957e42ec92776d435ecb4dc71b6bb18a825322468fccb09263f612aa1bde53deea3d6c5305313d8 DIST libvirt-10.1.0.tar.xz 9444244 BLAKE2B bfdce9d067e3a319b81d867d27f1a6b4e724ab6aaa25d19d7383c9be26ad7dc92b3c0aaa92894b772f09e20c3c2eb0ea0a8707feee4c63be58578fa22854305f SHA512 08e73ae15de5681430b62db85ec9901242dca5e9a4ca9685614f4a67092c6e28f27f9187144b3ceb18ad6b40e6eb1a90b1a4b056b0888724d04a62002ee2bc48 DIST libvirt-10.1.0.tar.xz.asc 833 BLAKE2B 1046403fb6ee084eb68e081a0fa4a1cfbf30378faf2f54591917ab6a4648a4c2a23da055cfe2577ec7ec80922c29ca7a918386259f747f052abfdfc420ff7749 SHA512 40ec184b4c33f21bf99d38fec0722e165854f723017f3cddaef63120cdf8dcf6df0c03b7e4aea5c3706f65d46f5335db667321b1ece1c123d9517fcd303b2bd8 +DIST libvirt-10.2.0.tar.xz 9466588 BLAKE2B 7ee6f4bdbb6a22f1b3c5c0326d41e269e8a5a07e41bc4f9a17fd023f3e33e46735066656dffa3004e1f36d46324270351593c89f60106933042e8a19a2aa64e6 SHA512 65faf2346e66bdba606ba99b9e4da2be8bd94ef42ac49c2801f9e9253ceea10f5fe772d5c7ada59f48aa34ff528726719b690c3acfd3e63a5c3580db17b023ae +DIST libvirt-10.2.0.tar.xz.asc 833 BLAKE2B 34031ed3c1896d3bb86d05b3efc158a48a70084bd6ea0308df779c351142e0f04395f62d62b4bb225c731a6f259f7ccb950428292691a656799eed06ecb2c3b2 SHA512 d366b0b64642f3358bdaee0ed5e06c4c3eba8b5ce2d1791f3d83d74c139a00282e45d7382af26706657c18e32ab956761d26f5b8595e32ad545c2f27f214fb76 DIST libvirt-9.8.0.tar.xz 9307064 BLAKE2B aae47e8d4eeaf97532a0356de23ed5a9eea71b369d025eda95b5fd74576779eb4b843d05df6c87b79a14f218c341953749e319ee7244846a2db410a74a746880 SHA512 0118725073de33eec3fa3e4616d3154707f9828fdb9ec973f503fe68f18eab72b9704da660f281152630ddc95e605c786673af9d23dc9bdfc0108422e0efbd41 DIST libvirt-9.8.0.tar.xz.asc 833 BLAKE2B 3ecd0a925992eeadd50675f7ad8e815bde532c0f66e331ea766fff8e613b6a60b002bedee82fd03684e703057bc13d4e92191268dcd5efe2611ce9bd3cf6b505 SHA512 e041db13281eae9323c22189b7a258caf8d0e2a350cbd31b6cbed7054ccaf09d05c155c3c09daea07940affdf15e8d42bb2339945480cd141a6e8cb417a78536 DIST libvirt-9.9.0.tar.xz 9321556 BLAKE2B 21eae5a95feaf7f5c6ba8dd48732c08212904882a11c48eccfa827d85ddc3df7e064503f21710dbe1b678670e02f003674de915a43a7403fbf85685c4832e21d SHA512 77cea28acf4f3e8c92fbd5bd72ad084be183c07f14e3a9ce35d6d9d62d36ee97a30cef55fb204b3e43f282890ecd7d5827a784a517e7f4ed8b22ee502c3f09d7 DIST libvirt-9.9.0.tar.xz.asc 833 BLAKE2B 3de3674d33c595692e71eeb9c312de76e865d3859d2482ec5b4d29d3cd7644cde080cba0001668efe7876b462f78c0233ab76076ef32943e118b34cca8c1ab4d SHA512 357fc2d1bdbbc26c6e0119a1b5c42e86a116f94bb714da855ab27ca83da0e50c7239d1b8abde3cee8a460ac537f63d518f43470d8329b727b39491771ad191e5 -EBUILD libvirt-10.0.0-r1.ebuild 9479 BLAKE2B ef1ef1720d69a4b4159e496a15ed0ff7e9b479d1cbf785aa44f51c8554f1ff213b3833ddbadf7fc300957bb559246474b8fc761e8d13a2496282380ad10ae821 SHA512 c3c4303dc2e0da2f6a64df1007f48f2dd4faf37670d41d80cd4c15a6124179c6768a01df5dd417b02d08f6d01cdacb991a0bf73dd88f7c2b1b468332f5012e67 -EBUILD libvirt-10.1.0.ebuild 9480 BLAKE2B 92c52396d10d728ff1417fce0f888a644bfbbee1a758f543e12b132d491fdd96244707f7d89d1303f855ac83803ca7795ce764f6e1046ef0252b660d6d7764f6 SHA512 b263250d244b1df458f184e4e813931a303c62fadc6ead76337a046d9503f2f7e87ae1aaaf2d36092bede66079b93aadc161df0a8ba396d2867e0d0bb4a17e09 -EBUILD libvirt-9.8.0-r1.ebuild 9475 BLAKE2B ea488b7745a11708eb64472061b18cdb7779055de774a1c5645a095c4453253d787447dd90b98b935f5eab324e1e59605caf808c5937f7eba78286faaf0cf951 SHA512 e04654fe9ce9b49b38425a30d2d1dfc2e71bcfa62bd0bc79887506df84a4e861ea75cc1ce7cf0eb9f54a8a61bd2b16f5fad0d99b0928b753ba81ec36425ab4d6 -EBUILD libvirt-9.9.0-r1.ebuild 9529 BLAKE2B 4fa7eab15cf1bdcaa52e89d1ad9a21be7c2a9806eac59ac37a571ccdc1d7a924d911d38a50743453611baf1a8009178383527dda193747b3df1299dded6f7a04 SHA512 30fc14d9deea709d8302933af59825510f94055a1f704621348802beaa5089cc4ae7083ad494ac0d7da5271dda092b995bc5216ab0aa786f0f0cebd4071df600 -EBUILD libvirt-9999.ebuild 9480 BLAKE2B 92c52396d10d728ff1417fce0f888a644bfbbee1a758f543e12b132d491fdd96244707f7d89d1303f855ac83803ca7795ce764f6e1046ef0252b660d6d7764f6 SHA512 b263250d244b1df458f184e4e813931a303c62fadc6ead76337a046d9503f2f7e87ae1aaaf2d36092bede66079b93aadc161df0a8ba396d2867e0d0bb4a17e09 +EBUILD libvirt-10.0.0-r2.ebuild 9651 BLAKE2B 97cf379807393cc939fd0dcd40f65bf2177b4957ba600382f5b3eeed1255fe2a3e640f147c923a597430a080cd936fae8977a2a6055c548b70206e429fdf58fb SHA512 beebff18fb91e4db4e30ab063fd02f8344b32d2fc7b645e77e0323250d76bbe6a941734eea60052ac8199e87ec91129f28141f6ecc7bdc8a9ecd45f90205c611 +EBUILD libvirt-10.1.0-r1.ebuild 9567 BLAKE2B 541b3ab8320a9c076c409cac1573e0f005c8a0bb1e11c905474fba6cfdf1c14f75ef2a42dcf93a089df415160db11f3e508327232b6c69ee67dd9a04b656f6c7 SHA512 d32b4e414d697dcb6a5991fe39232f61b087c307806562de3ff93519aa2f1065ed6984ece1ec06030dd4beb9a5a858b1a0eee0f728d521fc3126f903235172fb +EBUILD libvirt-10.2.0.ebuild 9480 BLAKE2B c78a4504eb025cad151dae29ab488c7bc870f982c81980f1c77ed2c47b2791791e8a98ed6a9334c65e2cdf846e426c6449dc108c7744d8e841b1fc076839fadf SHA512 3b12b6fd7ea290c44c97756cb58f5b8113c64d509507c7fe9f4335ab5709a18f283c47e529f40774c54d70dc848fdf26dc0cccf8cbcda495574ff8200a898e9c +EBUILD libvirt-9.8.0-r2.ebuild 9647 BLAKE2B e8118d9d46ac98ad406421fb37f428ccea980cbad40e66d765bb6711c4e75f390cf93560d9be5f0826db4ea52d251bef7f4f43b693fcc903c77add4180d52143 SHA512 17ec206969afb23d01ab0568776475d9d2ffba610382bfba5289825b3c9e4975d2239601ffaf1c48f9a15088779e90b42831c8e3c6cb0355add60f66570ed9d2 +EBUILD libvirt-9.9.0-r2.ebuild 9701 BLAKE2B 9c9ad40d523b3c36cc37cf1beeca8014e528270484ec88f15984bdca00abde541c0ef4cd1677788af30dc1ee1a206168c9ca894c4e8abeb649170e4903b0ce0c SHA512 4236b7d848c2e01009837bdfefcd81fedd1e95ecae24829473afcbd364fcaf378858dc3fad8cf0a93c5f00dcc7e18ee71b160d26229e5fe9499c8e7b5b3dc3d5 +EBUILD libvirt-9999.ebuild 9480 BLAKE2B c78a4504eb025cad151dae29ab488c7bc870f982c81980f1c77ed2c47b2791791e8a98ed6a9334c65e2cdf846e426c6449dc108c7744d8e841b1fc076839fadf SHA512 3b12b6fd7ea290c44c97756cb58f5b8113c64d509507c7fe9f4335ab5709a18f283c47e529f40774c54d70dc848fdf26dc0cccf8cbcda495574ff8200a898e9c MISC metadata.xml 3930 BLAKE2B 20ba8d6fd52d7c76800ab3ef487b2649d51a99bf1c2399bf48396646816b632a970ebeef44d8049f98b75e16c1cf6da6ae4ecdb0b0d0e7b014c31885432bb027 SHA512 459c957baf217b156a6d016c880f9071c53688179d66d309409c373662541f62bfd55812b8e67fdc4e0de56efb61f0800438000c5eb3b8aae99bb7000cfef773 diff --git a/app-emulation/libvirt/files/libvirt-10.1.0-Fix-off-by-one-error-in-udevListInterfacesByStatus.patch b/app-emulation/libvirt/files/libvirt-10.1.0-Fix-off-by-one-error-in-udevListInterfacesByStatus.patch new file mode 100644 index 000000000000..7ef0652faa38 --- /dev/null +++ b/app-emulation/libvirt/files/libvirt-10.1.0-Fix-off-by-one-error-in-udevListInterfacesByStatus.patch @@ -0,0 +1,42 @@ +From 2127032ed8cd49001465dc0dce9f842e13467bc2 Mon Sep 17 00:00:00 2001 +Message-ID: <2127032ed8cd49001465dc0dce9f842e13467bc2.1713033988.git.mprivozn@redhat.com> +From: Martin Kletzander +Date: Tue, 27 Feb 2024 16:20:12 +0100 +Subject: [PATCH 1/2] Fix off-by-one error in udevListInterfacesByStatus +MIME-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit + +Ever since this function was introduced in 2012 it could've tried +filling in an extra interface name. That was made worse in 2019 when +the caller functions started accepting NULL arrays of size 0. + +This is assigned CVE-2024-1441. + +Signed-off-by: Martin Kletzander +Reported-by: Alexander Kuznetsov +Fixes: 5a33366f5c0b18c93d161bd144f9f079de4ac8ca +Fixes: d6064e2759a24e0802f363e3a810dc5a7d7ebb15 +Reviewed-by: Ján Tomko +(cherry picked from commit c664015fe3a7bf59db26686e9ed69af011c6ebb8) +Signed-off-by: Michal Privoznik +--- + src/interface/interface_backend_udev.c | 2 +- + 1 file changed, 1 insertion(+), 1 deletion(-) + +diff --git a/src/interface/interface_backend_udev.c b/src/interface/interface_backend_udev.c +index fb6799ed94..4091483060 100644 +--- a/src/interface/interface_backend_udev.c ++++ b/src/interface/interface_backend_udev.c +@@ -222,7 +222,7 @@ udevListInterfacesByStatus(virConnectPtr conn, + g_autoptr(virInterfaceDef) def = NULL; + + /* Ensure we won't exceed the size of our array */ +- if (count > names_len) ++ if (count >= names_len) + break; + + path = udev_list_entry_get_name(dev_entry); +-- +2.43.2 + diff --git a/app-emulation/libvirt/files/libvirt-10.2.0-remote-check-for-negative-array-lengths-before-alloc.patch b/app-emulation/libvirt/files/libvirt-10.2.0-remote-check-for-negative-array-lengths-before-alloc.patch new file mode 100644 index 000000000000..3e0426634f42 --- /dev/null +++ b/app-emulation/libvirt/files/libvirt-10.2.0-remote-check-for-negative-array-lengths-before-alloc.patch @@ -0,0 +1,222 @@ +From 10fa5f6ba64b354b99b0f7b372e66e45bb4d9379 Mon Sep 17 00:00:00 2001 +Message-ID: <10fa5f6ba64b354b99b0f7b372e66e45bb4d9379.1713033988.git.mprivozn@redhat.com> +In-Reply-To: <2127032ed8cd49001465dc0dce9f842e13467bc2.1713033988.git.mprivozn@redhat.com> +References: <2127032ed8cd49001465dc0dce9f842e13467bc2.1713033988.git.mprivozn@redhat.com> +From: =?UTF-8?q?Daniel=20P=2E=20Berrang=C3=A9?= +Date: Fri, 15 Mar 2024 10:47:50 +0000 +Subject: [PATCH 2/2] remote: check for negative array lengths before + allocation +MIME-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit + +While the C API entry points will validate non-negative lengths +for various parameters, the RPC server de-serialization code +will need to allocate memory for arrays before entering the C +API. These allocations will thus happen before the non-negative +length check is performed. + +Passing a negative length to the g_new0 function will usually +result in a crash due to the negative length being treated as +a huge positive number. + +This was found and diagnosed by ALT Linux Team with AFLplusplus. + +CVE-2024-2494 +Reviewed-by: Michal Privoznik +Found-by: Alexandr Shashkin +Co-developed-by: Alexander Kuznetsov +Signed-off-by: Daniel P. Berrangé +(cherry picked from commit 8a3f8d957507c1f8223fdcf25a3ff885b15557f2) +Signed-off-by: Michal Privoznik +--- + src/remote/remote_daemon_dispatch.c | 65 +++++++++++++++++++++++++++++ + src/rpc/gendispatch.pl | 5 +++ + 2 files changed, 70 insertions(+) + +diff --git a/src/remote/remote_daemon_dispatch.c b/src/remote/remote_daemon_dispatch.c +index 7daf503b51..7542caa952 100644 +--- a/src/remote/remote_daemon_dispatch.c ++++ b/src/remote/remote_daemon_dispatch.c +@@ -2291,6 +2291,10 @@ remoteDispatchDomainGetSchedulerParameters(virNetServer *server G_GNUC_UNUSED, + if (!conn) + goto cleanup; + ++ if (args->nparams < 0) { ++ virReportError(VIR_ERR_INTERNAL_ERROR, "%s", _("nparams must be non-negative")); ++ goto cleanup; ++ } + if (args->nparams > REMOTE_DOMAIN_SCHEDULER_PARAMETERS_MAX) { + virReportError(VIR_ERR_INTERNAL_ERROR, "%s", _("nparams too large")); + goto cleanup; +@@ -2339,6 +2343,10 @@ remoteDispatchDomainGetSchedulerParametersFlags(virNetServer *server G_GNUC_UNUS + if (!conn) + goto cleanup; + ++ if (args->nparams < 0) { ++ virReportError(VIR_ERR_INTERNAL_ERROR, "%s", _("nparams must be non-negative")); ++ goto cleanup; ++ } + if (args->nparams > REMOTE_DOMAIN_SCHEDULER_PARAMETERS_MAX) { + virReportError(VIR_ERR_INTERNAL_ERROR, "%s", _("nparams too large")); + goto cleanup; +@@ -2497,6 +2505,10 @@ remoteDispatchDomainBlockStatsFlags(virNetServer *server G_GNUC_UNUSED, + goto cleanup; + flags = args->flags; + ++ if (args->nparams < 0) { ++ virReportError(VIR_ERR_INTERNAL_ERROR, "%s", _("nparams must be non-negative")); ++ goto cleanup; ++ } + if (args->nparams > REMOTE_DOMAIN_BLOCK_STATS_PARAMETERS_MAX) { + virReportError(VIR_ERR_INTERNAL_ERROR, "%s", _("nparams too large")); + goto cleanup; +@@ -2717,6 +2729,14 @@ remoteDispatchDomainGetVcpuPinInfo(virNetServer *server G_GNUC_UNUSED, + if (!(dom = get_nonnull_domain(conn, args->dom))) + goto cleanup; + ++ if (args->ncpumaps < 0) { ++ virReportError(VIR_ERR_INTERNAL_ERROR, "%s", _("ncpumaps must be non-negative")); ++ goto cleanup; ++ } ++ if (args->maplen < 0) { ++ virReportError(VIR_ERR_INTERNAL_ERROR, "%s", _("maplen must be non-negative")); ++ goto cleanup; ++ } + if (args->ncpumaps > REMOTE_VCPUINFO_MAX) { + virReportError(VIR_ERR_INTERNAL_ERROR, "%s", _("ncpumaps > REMOTE_VCPUINFO_MAX")); + goto cleanup; +@@ -2811,6 +2831,11 @@ remoteDispatchDomainGetEmulatorPinInfo(virNetServer *server G_GNUC_UNUSED, + if (!(dom = get_nonnull_domain(conn, args->dom))) + goto cleanup; + ++ if (args->maplen < 0) { ++ virReportError(VIR_ERR_INTERNAL_ERROR, "%s", _("maplen must be non-negative")); ++ goto cleanup; ++ } ++ + /* Allocate buffers to take the results */ + if (args->maplen > 0) + cpumaps = g_new0(unsigned char, args->maplen); +@@ -2858,6 +2883,14 @@ remoteDispatchDomainGetVcpus(virNetServer *server G_GNUC_UNUSED, + if (!(dom = get_nonnull_domain(conn, args->dom))) + goto cleanup; + ++ if (args->maxinfo < 0) { ++ virReportError(VIR_ERR_INTERNAL_ERROR, "%s", _("maxinfo must be non-negative")); ++ goto cleanup; ++ } ++ if (args->maplen < 0) { ++ virReportError(VIR_ERR_INTERNAL_ERROR, "%s", _("maxinfo must be non-negative")); ++ goto cleanup; ++ } + if (args->maxinfo > REMOTE_VCPUINFO_MAX) { + virReportError(VIR_ERR_INTERNAL_ERROR, "%s", _("maxinfo > REMOTE_VCPUINFO_MAX")); + goto cleanup; +@@ -3096,6 +3129,10 @@ remoteDispatchDomainGetMemoryParameters(virNetServer *server G_GNUC_UNUSED, + + flags = args->flags; + ++ if (args->nparams < 0) { ++ virReportError(VIR_ERR_INTERNAL_ERROR, "%s", _("nparams must be non-negative")); ++ goto cleanup; ++ } + if (args->nparams > REMOTE_DOMAIN_MEMORY_PARAMETERS_MAX) { + virReportError(VIR_ERR_INTERNAL_ERROR, "%s", _("nparams too large")); + goto cleanup; +@@ -3156,6 +3193,10 @@ remoteDispatchDomainGetNumaParameters(virNetServer *server G_GNUC_UNUSED, + + flags = args->flags; + ++ if (args->nparams < 0) { ++ virReportError(VIR_ERR_INTERNAL_ERROR, "%s", _("nparams must be non-negative")); ++ goto cleanup; ++ } + if (args->nparams > REMOTE_DOMAIN_NUMA_PARAMETERS_MAX) { + virReportError(VIR_ERR_INTERNAL_ERROR, "%s", _("nparams too large")); + goto cleanup; +@@ -3216,6 +3257,10 @@ remoteDispatchDomainGetBlkioParameters(virNetServer *server G_GNUC_UNUSED, + + flags = args->flags; + ++ if (args->nparams < 0) { ++ virReportError(VIR_ERR_INTERNAL_ERROR, "%s", _("nparams must be non-negative")); ++ goto cleanup; ++ } + if (args->nparams > REMOTE_DOMAIN_BLKIO_PARAMETERS_MAX) { + virReportError(VIR_ERR_INTERNAL_ERROR, "%s", _("nparams too large")); + goto cleanup; +@@ -3277,6 +3322,10 @@ remoteDispatchNodeGetCPUStats(virNetServer *server G_GNUC_UNUSED, + + flags = args->flags; + ++ if (args->nparams < 0) { ++ virReportError(VIR_ERR_INTERNAL_ERROR, "%s", _("nparams must be non-negative")); ++ goto cleanup; ++ } + if (args->nparams > REMOTE_NODE_CPU_STATS_MAX) { + virReportError(VIR_ERR_INTERNAL_ERROR, "%s", _("nparams too large")); + goto cleanup; +@@ -3339,6 +3388,10 @@ remoteDispatchNodeGetMemoryStats(virNetServer *server G_GNUC_UNUSED, + + flags = args->flags; + ++ if (args->nparams < 0) { ++ virReportError(VIR_ERR_INTERNAL_ERROR, "%s", _("nparams must be non-negative")); ++ goto cleanup; ++ } + if (args->nparams > REMOTE_NODE_MEMORY_STATS_MAX) { + virReportError(VIR_ERR_INTERNAL_ERROR, "%s", _("nparams too large")); + goto cleanup; +@@ -3514,6 +3567,10 @@ remoteDispatchDomainGetBlockIoTune(virNetServer *server G_GNUC_UNUSED, + if (!conn) + goto cleanup; + ++ if (args->nparams < 0) { ++ virReportError(VIR_ERR_INTERNAL_ERROR, "%s", _("nparams must be non-negative")); ++ goto cleanup; ++ } + if (args->nparams > REMOTE_DOMAIN_BLOCK_IO_TUNE_PARAMETERS_MAX) { + virReportError(VIR_ERR_INTERNAL_ERROR, "%s", _("nparams too large")); + goto cleanup; +@@ -5079,6 +5136,10 @@ remoteDispatchDomainGetInterfaceParameters(virNetServer *server G_GNUC_UNUSED, + + flags = args->flags; + ++ if (args->nparams < 0) { ++ virReportError(VIR_ERR_INTERNAL_ERROR, "%s", _("nparams must be non-negative")); ++ goto cleanup; ++ } + if (args->nparams > REMOTE_DOMAIN_INTERFACE_PARAMETERS_MAX) { + virReportError(VIR_ERR_INTERNAL_ERROR, "%s", _("nparams too large")); + goto cleanup; +@@ -5299,6 +5360,10 @@ remoteDispatchNodeGetMemoryParameters(virNetServer *server G_GNUC_UNUSED, + + flags = args->flags; + ++ if (args->nparams < 0) { ++ virReportError(VIR_ERR_INTERNAL_ERROR, "%s", _("nparams must be non-negative")); ++ goto cleanup; ++ } + if (args->nparams > REMOTE_NODE_MEMORY_PARAMETERS_MAX) { + virReportError(VIR_ERR_INTERNAL_ERROR, "%s", _("nparams too large")); + goto cleanup; +diff --git a/src/rpc/gendispatch.pl b/src/rpc/gendispatch.pl +index fa45d15a92..294e21f8a1 100755 +--- a/src/rpc/gendispatch.pl ++++ b/src/rpc/gendispatch.pl +@@ -1070,6 +1070,11 @@ elsif ($mode eq "server") { + print "\n"; + + if ($single_ret_as_list) { ++ print " if (args->$single_ret_list_max_var < 0) {\n"; ++ print " virReportError(VIR_ERR_RPC,\n"; ++ print " \"%s\", _(\"max$single_ret_list_name must be non-negative\"));\n"; ++ print " goto cleanup;\n"; ++ print " }\n"; + print " if (args->$single_ret_list_max_var > $single_ret_list_max_define) {\n"; + print " virReportError(VIR_ERR_RPC,\n"; + print " \"%s\", _(\"max$single_ret_list_name > $single_ret_list_max_define\"));\n"; +-- +2.43.2 + diff --git a/app-emulation/libvirt/libvirt-10.0.0-r1.ebuild b/app-emulation/libvirt/libvirt-10.0.0-r1.ebuild deleted file mode 100644 index 25ba088988c0..000000000000 --- a/app-emulation/libvirt/libvirt-10.0.0-r1.ebuild +++ /dev/null @@ -1,365 +0,0 @@ -# Copyright 1999-2024 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=/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 nbd nfs nls numa - openvz parted pcap policykit +qemu rbd sasl selinux test +udev - virtiofsd virtualbox +virt-network wireshark-plugins xen zfs -" -RESTRICT="!test? ( test )" - -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 - 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-debug/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(-)] ) - nbd? ( sys-block/nbdkit ) - 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 - app-crypt/swtpm - >=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] - ) - virtiofsd? ( app-emulation/virtiofsd ) - 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}-9.4.0-fix_paths_in_libvirt-guests_sh.patch - "${FILESDIR}"/${PN}-9.9.0-do-not-use-sysconfig.patch - "${FILESDIR}"/${PN}-9.6.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 nbd nbdkit) - $(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 test tests) - $(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" - -Dinitconfdir="${EPREFIX}/etc/systemd" - -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-10.0.0-r2.ebuild b/app-emulation/libvirt/libvirt-10.0.0-r2.ebuild new file mode 100644 index 000000000000..baf260598704 --- /dev/null +++ b/app-emulation/libvirt/libvirt-10.0.0-r2.ebuild @@ -0,0 +1,367 @@ +# Copyright 1999-2024 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..12} ) +VERIFY_SIG_OPENPGP_KEY_PATH=/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 nbd nfs nls numa + openvz parted pcap policykit +qemu rbd sasl selinux test +udev + virtiofsd virtualbox +virt-network wireshark-plugins xen zfs +" +RESTRICT="!test? ( test )" + +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 + 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-debug/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(-)] ) + nbd? ( sys-block/nbdkit ) + 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 + app-crypt/swtpm + >=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] + ) + virtiofsd? ( app-emulation/virtiofsd ) + 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}-9.4.0-fix_paths_in_libvirt-guests_sh.patch + "${FILESDIR}"/${PN}-9.9.0-do-not-use-sysconfig.patch + "${FILESDIR}"/${PN}-9.6.0-fix-paths-for-apparmor.patch + "${FILESDIR}"/${PN}-10.1.0-Fix-off-by-one-error-in-udevListInterfacesByStatus.patch + "${FILESDIR}"/${PN}-10.2.0-remote-check-for-negative-array-lengths-before-alloc.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 nbd nbdkit) + $(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 test tests) + $(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" + -Dinitconfdir="${EPREFIX}/etc/systemd" + -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-10.1.0-r1.ebuild b/app-emulation/libvirt/libvirt-10.1.0-r1.ebuild new file mode 100644 index 000000000000..128f76475972 --- /dev/null +++ b/app-emulation/libvirt/libvirt-10.1.0-r1.ebuild @@ -0,0 +1,366 @@ +# Copyright 1999-2024 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_{10..12} ) +VERIFY_SIG_OPENPGP_KEY_PATH=/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 nbd nfs nls numa + openvz parted pcap policykit +qemu rbd sasl selinux test +udev + virtiofsd virtualbox +virt-network wireshark-plugins xen zfs +" +RESTRICT="!test? ( test )" + +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 + 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-debug/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(-)] ) + nbd? ( sys-block/nbdkit ) + 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 + app-crypt/swtpm + >=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] + ) + virtiofsd? ( app-emulation/virtiofsd ) + 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}-9.4.0-fix_paths_in_libvirt-guests_sh.patch + "${FILESDIR}"/${PN}-9.9.0-do-not-use-sysconfig.patch + "${FILESDIR}"/${PN}-9.6.0-fix-paths-for-apparmor.patch + "${FILESDIR}"/${PN}-10.2.0-remote-check-for-negative-array-lengths-before-alloc.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 nbd nbdkit) + $(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 test tests) + $(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" + -Dinitconfdir="${EPREFIX}/etc/systemd" + -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-10.1.0.ebuild b/app-emulation/libvirt/libvirt-10.1.0.ebuild deleted file mode 100644 index 38baa163aaa0..000000000000 --- a/app-emulation/libvirt/libvirt-10.1.0.ebuild +++ /dev/null @@ -1,365 +0,0 @@ -# Copyright 1999-2024 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_{10..11} ) -VERIFY_SIG_OPENPGP_KEY_PATH=/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 nbd nfs nls numa - openvz parted pcap policykit +qemu rbd sasl selinux test +udev - virtiofsd virtualbox +virt-network wireshark-plugins xen zfs -" -RESTRICT="!test? ( test )" - -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 - 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-debug/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(-)] ) - nbd? ( sys-block/nbdkit ) - 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 - app-crypt/swtpm - >=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] - ) - virtiofsd? ( app-emulation/virtiofsd ) - 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}-9.4.0-fix_paths_in_libvirt-guests_sh.patch - "${FILESDIR}"/${PN}-9.9.0-do-not-use-sysconfig.patch - "${FILESDIR}"/${PN}-9.6.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 nbd nbdkit) - $(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 test tests) - $(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" - -Dinitconfdir="${EPREFIX}/etc/systemd" - -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-10.2.0.ebuild b/app-emulation/libvirt/libvirt-10.2.0.ebuild new file mode 100644 index 000000000000..f1c08714d713 --- /dev/null +++ b/app-emulation/libvirt/libvirt-10.2.0.ebuild @@ -0,0 +1,365 @@ +# Copyright 1999-2024 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_{10..12} ) +VERIFY_SIG_OPENPGP_KEY_PATH=/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 nbd nfs nls numa + openvz parted pcap policykit +qemu rbd sasl selinux test +udev + virtiofsd virtualbox +virt-network wireshark-plugins xen zfs +" +RESTRICT="!test? ( test )" + +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 + 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-debug/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(-)] ) + nbd? ( sys-block/nbdkit ) + 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 + app-crypt/swtpm + >=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] + ) + virtiofsd? ( app-emulation/virtiofsd ) + 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}-9.4.0-fix_paths_in_libvirt-guests_sh.patch + "${FILESDIR}"/${PN}-9.9.0-do-not-use-sysconfig.patch + "${FILESDIR}"/${PN}-9.6.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 nbd nbdkit) + $(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 test tests) + $(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" + -Dinitconfdir="${EPREFIX}/etc/systemd" + -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.8.0-r1.ebuild b/app-emulation/libvirt/libvirt-9.8.0-r1.ebuild deleted file mode 100644 index 425a8cb1d985..000000000000 --- a/app-emulation/libvirt/libvirt-9.8.0-r1.ebuild +++ /dev/null @@ -1,364 +0,0 @@ -# Copyright 1999-2024 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_{10..11} ) -VERIFY_SIG_OPENPGP_KEY_PATH=/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 test +udev - virtualbox +virt-network wireshark-plugins xen zfs -" -RESTRICT="!test? ( test )" - -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-debug/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 - app-crypt/swtpm - >=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}-9.4.0-fix_paths_in_libvirt-guests_sh.patch - "${FILESDIR}"/${PN}-9.4.0-do-not-use-sysconfig.patch - "${FILESDIR}"/${PN}-9.6.0-fix-paths-for-apparmor.patch - "${FILESDIR}"/${PN}-9.10.0-virxml-include-libxml-xmlsave.h-for-xmlIndentTreeOut.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 test tests) - $(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" - -Dinitconfdir="${EPREFIX}/etc/systemd" - -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.8.0-r2.ebuild b/app-emulation/libvirt/libvirt-9.8.0-r2.ebuild new file mode 100644 index 000000000000..500ab7f572ad --- /dev/null +++ b/app-emulation/libvirt/libvirt-9.8.0-r2.ebuild @@ -0,0 +1,366 @@ +# Copyright 1999-2024 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_{10..12} ) +VERIFY_SIG_OPENPGP_KEY_PATH=/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 test +udev + virtualbox +virt-network wireshark-plugins xen zfs +" +RESTRICT="!test? ( test )" + +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-debug/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 + app-crypt/swtpm + >=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}-9.4.0-fix_paths_in_libvirt-guests_sh.patch + "${FILESDIR}"/${PN}-9.4.0-do-not-use-sysconfig.patch + "${FILESDIR}"/${PN}-9.6.0-fix-paths-for-apparmor.patch + "${FILESDIR}"/${PN}-9.10.0-virxml-include-libxml-xmlsave.h-for-xmlIndentTreeOut.patch + "${FILESDIR}"/${PN}-10.1.0-Fix-off-by-one-error-in-udevListInterfacesByStatus.patch + "${FILESDIR}"/${PN}-10.2.0-remote-check-for-negative-array-lengths-before-alloc.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 test tests) + $(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" + -Dinitconfdir="${EPREFIX}/etc/systemd" + -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.9.0-r1.ebuild b/app-emulation/libvirt/libvirt-9.9.0-r1.ebuild deleted file mode 100644 index cc922f97df11..000000000000 --- a/app-emulation/libvirt/libvirt-9.9.0-r1.ebuild +++ /dev/null @@ -1,365 +0,0 @@ -# Copyright 1999-2024 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_{10..11} ) -VERIFY_SIG_OPENPGP_KEY_PATH=/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 test +udev virtiofsd - virtualbox +virt-network wireshark-plugins xen zfs -" -RESTRICT="!test? ( test )" - -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-debug/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 - app-crypt/swtpm - >=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] - ) - virtiofsd? ( app-emulation/virtiofsd ) - 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}-9.4.0-fix_paths_in_libvirt-guests_sh.patch - "${FILESDIR}"/${PN}-9.9.0-do-not-use-sysconfig.patch - "${FILESDIR}"/${PN}-9.6.0-fix-paths-for-apparmor.patch - "${FILESDIR}"/${PN}-9.10.0-virxml-include-libxml-xmlsave.h-for-xmlIndentTreeOut.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 test tests) - $(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" - -Dinitconfdir="${EPREFIX}/etc/systemd" - -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.9.0-r2.ebuild b/app-emulation/libvirt/libvirt-9.9.0-r2.ebuild new file mode 100644 index 000000000000..684c0dc7afe2 --- /dev/null +++ b/app-emulation/libvirt/libvirt-9.9.0-r2.ebuild @@ -0,0 +1,367 @@ +# Copyright 1999-2024 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_{10..12} ) +VERIFY_SIG_OPENPGP_KEY_PATH=/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 test +udev virtiofsd + virtualbox +virt-network wireshark-plugins xen zfs +" +RESTRICT="!test? ( test )" + +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-debug/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 + app-crypt/swtpm + >=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] + ) + virtiofsd? ( app-emulation/virtiofsd ) + 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}-9.4.0-fix_paths_in_libvirt-guests_sh.patch + "${FILESDIR}"/${PN}-9.9.0-do-not-use-sysconfig.patch + "${FILESDIR}"/${PN}-9.6.0-fix-paths-for-apparmor.patch + "${FILESDIR}"/${PN}-9.10.0-virxml-include-libxml-xmlsave.h-for-xmlIndentTreeOut.patch + "${FILESDIR}"/${PN}-10.1.0-Fix-off-by-one-error-in-udevListInterfacesByStatus.patch + "${FILESDIR}"/${PN}-10.2.0-remote-check-for-negative-array-lengths-before-alloc.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 test tests) + $(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" + -Dinitconfdir="${EPREFIX}/etc/systemd" + -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-9999.ebuild b/app-emulation/libvirt/libvirt-9999.ebuild index 38baa163aaa0..f1c08714d713 100644 --- a/app-emulation/libvirt/libvirt-9999.ebuild +++ b/app-emulation/libvirt/libvirt-9999.ebuild @@ -10,7 +10,7 @@ EAPI=8 # app-emulation/libvirt # Please bump them together! -PYTHON_COMPAT=( python3_{10..11} ) +PYTHON_COMPAT=( python3_{10..12} ) VERIFY_SIG_OPENPGP_KEY_PATH=/usr/share/openpgp-keys/libvirt.org.asc inherit meson linux-info python-any-r1 readme.gentoo-r1 tmpfiles verify-sig -- cgit v1.2.3