Sync with portage [Sun Sep 24 14:52:41 MSK 2023].

master 2481
root 7 months ago
parent 8112e1c77b
commit 6b7fb93244

Binary file not shown.

Binary file not shown.

@ -1,3 +1,2 @@
DIST at-spi2-core-2.48.3.tar.xz 554388 BLAKE2B 9692df8cc0bc8de82f6e339b9358be7ab1bc598afdb39503f5f05ca772109b962a513fe2ef79d8f094ea732457225409f3c765784a54cbabf27b8fc72c893eb9 SHA512 e79ef0eb0f23241d61ba2a62f4024a5df5ff7125bc085590f9038b3397d255b88b8266deec14f3fe53bee4072ab85695a47d27d8be0529b18a103ad792fa0e54
DIST at-spi2-core-2.48.4.tar.xz 554916 BLAKE2B 6329407e1e0d0a085189174ad31ac65d890e36a1b20179d68155fffa029b476a6b094765b6d3c300a8fa3cdeb01936a1b14cac34c530650287e711132c136ddc SHA512 fa85b680ad5254a8281197969f335c69b6c71d3ea4ec04efb8d70ba9feafd76330cd23a09169eef6f04abf0000e4823d2c2591999e8ed88bc035a26ed8bebdf0
DIST at-spi2-core-2.50.0.tar.xz 567664 BLAKE2B 18b9c84542bffc13e762e770da08f289358b5987b27c0159818c6f1f09981be029a8f15ce2b7dd6ed99b049ad7e4a4cbbf2bc4d5e97a81d9096b247df218328f SHA512 7de02efa7e3cb9db4a7da8bb2e9350dc00458e2ba9bf9dafb68d2cab8512b525fc7dcecb45f5912de7459b86d901ab3a188f0a07f5bdc068a51433c900de2308

@ -1,75 +0,0 @@
# Copyright 1999-2023 Gentoo Authors
# Distributed under the terms of the GNU General Public License v2
EAPI=8
inherit gnome.org meson-multilib systemd virtualx xdg
DESCRIPTION="D-Bus accessibility specifications and registration daemon"
HOMEPAGE="https://wiki.gnome.org/Accessibility https://gitlab.gnome.org/GNOME/at-spi2-core"
LICENSE="LGPL-2.1+"
SLOT="2"
KEYWORDS="~alpha ~amd64 ~arm ~arm64 ~hppa ~ia64 ~loong ~mips ~ppc ~ppc64 ~riscv ~s390 ~sparc ~x86 ~amd64-linux ~x86-linux ~x64-macos"
IUSE="X dbus-broker gtk-doc +introspection systemd"
REQUIRED_USE="
dbus-broker? ( systemd )
gtk-doc? ( X )
"
DEPEND="
>=sys-apps/dbus-1.5[${MULTILIB_USEDEP}]
>=dev-libs/glib-2.67.4:2[${MULTILIB_USEDEP}]
>=dev-libs/libxml2-2.9.1:2[${MULTILIB_USEDEP}]
introspection? ( >=dev-libs/gobject-introspection-1.54.0:= )
systemd? ( sys-apps/systemd[${MULTILIB_USEDEP}] )
X? (
x11-libs/libX11[${MULTILIB_USEDEP}]
x11-libs/libXtst[${MULTILIB_USEDEP}]
x11-libs/libXi[${MULTILIB_USEDEP}]
)
!<dev-libs/atk-2.46.0
!<app-accessibility/at-spi2-atk-2.46.0
"
RDEPEND="${DEPEND}
dbus-broker? ( sys-apps/dbus-broker )
"
BDEPEND="
dev-util/glib-utils
gtk-doc? (
dev-python/sphinx
dev-util/gdbus-codegen
>=dev-util/gi-docgen-2021.1
)
>=sys-devel/gettext-0.19.8
virtual/pkgconfig
"
multilib_src_configure() {
local emesonargs=(
-Ddefault_bus=$(usex dbus-broker dbus-broker dbus-daemon)
$(meson_use systemd use_systemd)
-Dsystemd_user_dir="$(systemd_get_userunitdir)"
$(meson_native_use_bool gtk-doc docs)
$(meson_native_use_feature introspection)
$(meson_feature X x11)
-Ddisable_p2p=false
-Datk_only=false
)
meson_src_configure
}
multilib_src_test() {
virtx dbus-run-session meson test -C "${BUILD_DIR}" || die
}
multilib_src_install_all() {
einstalldocs
if use gtk-doc; then
mkdir -p "${ED}"/usr/share/gtk-doc/{libatspi,atk} || die
mv "${ED}"/usr/share/doc/libatspi "${ED}"/usr/share/gtk-doc/libatspi/html || die
mv "${ED}"/usr/share/doc/atk "${ED}"/usr/share/gtk-doc/atk/html || die
fi
}

@ -1,3 +1,2 @@
DIST orca-44.1.tar.xz 3760772 BLAKE2B 1e2825e9183b86563d85f106f80b7fa84d7d0cc06c818cb72c2a307c9c85a421cbbfc581df7829afde558ddf468bc048382d059ae995661a5163d390585961b4 SHA512 951a60b7efd9b61762404c20b62d476c1ebc3fc2662c0be1feef307fa1761feb5195c89ce725db1585dde4c39d96e1aa74c2b5c934115a3c2669880c3c7ac200
DIST orca-45.0.tar.xz 3949908 BLAKE2B 135dff79cda2a1a116256f2c1b68a40d29b17e5507fd3407d61dfc2478339aab1d7627c3aaac5f388a0140008e8a492820f0e56caac7ea83216c50f4f3fa32d8 SHA512 3213d5f0b8e0eacc5daad3df3e521548c5e6dd5ad8584e50d60a7fd054fee86793e956d3db3dcdc223d34d72bcfbfa0b436bc40f6e965528eafa2abf36259c83
DIST orca-45.rc.tar.xz 3923500 BLAKE2B e7f919e0badf804612d2c778abab598437dca812507b2d5e5ba6b7fc34897ed8baaa739d3f72a1e56db13badf725675d468a525ab663db6e1eaa08191abd3654 SHA512 897e667b7c9fd98d01eafb79f1fcd02da078fa5d023a22301ba7ea2a84cd18c05684c4c297a1edd22232c5f72d64fa5fb78b35037ea4d8cfd3fdfa350c3500a7

@ -2,7 +2,7 @@
# Distributed under the terms of the GNU General Public License v2
EAPI=8
PYTHON_COMPAT=( python3_{10..12} )
PYTHON_COMPAT=( python3_{10..11} )
inherit gnome2 python-single-r1

@ -1,59 +0,0 @@
# Copyright 1999-2023 Gentoo Authors
# Distributed under the terms of the GNU General Public License v2
EAPI=8
PYTHON_COMPAT=( python3_{10..12} )
inherit gnome2 python-single-r1
DESCRIPTION="Extensible screen reader that provides access to the desktop"
HOMEPAGE="https://wiki.gnome.org/Projects/Orca"
LICENSE="LGPL-2.1+ CC-BY-SA-3.0"
SLOT="0"
KEYWORDS="~alpha ~amd64 ~arm ~arm64 ~ia64 ~loong ~ppc ~ppc64 ~riscv ~sparc ~x86"
IUSE="+braille"
REQUIRED_USE="${PYTHON_REQUIRED_USE}"
DEPEND="${PYTHON_DEPS}
>=app-accessibility/at-spi2-core-2.48:2[introspection]
>=dev-libs/glib-2.28:2
media-libs/gstreamer:1.0[introspection]
>=x11-libs/gtk+-3.6.2:3[introspection]
$(python_gen_cond_dep '
dev-python/gst-python:1.0[${PYTHON_USEDEP}]
>=dev-python/pygobject-3.18:3[${PYTHON_USEDEP}]
')
braille? (
$(python_gen_cond_dep '
>=app-accessibility/brltty-5.0-r3[python,${PYTHON_USEDEP}]
dev-libs/liblouis[python,${PYTHON_USEDEP}]
')
)
"
RDEPEND="${DEPEND}
$(python_gen_cond_dep '
>=app-accessibility/speech-dispatcher-0.8[python,${PYTHON_USEDEP}]
>=dev-python/pyatspi-2.46[${PYTHON_USEDEP}]
dev-python/setproctitle[${PYTHON_USEDEP}]
')
x11-libs/libwnck:3[introspection]
x11-libs/pango[introspection]
"
BDEPEND="
dev-util/itstool
>=sys-devel/gettext-0.19.8
virtual/pkgconfig
"
# app-text/yelp-tools
src_configure() {
gnome2_src_configure \
$(use_with braille liblouis)
}
src_install() {
gnome2_src_install
python_optimize
}

Binary file not shown.

@ -15,3 +15,4 @@ DIST aws-cli-1.29.49.gh.tar.gz 2533689 BLAKE2B 0ead02f739adc66eed988bedf41b9b508
DIST aws-cli-1.29.50.gh.tar.gz 2534012 BLAKE2B 1089a689851648125e0a04f4ec004bc141059201a8e885db3a88ac3912b47997af797e21ce8d759be5ba03a0a09d278c612068a8cd55eb4b9a971b11077d5175 SHA512 4dfd35be02641b77c3f4047645a7d6aaada62550ac725e1aefa154dbad15839b19fb222ea8194f919823d25b3a30c8275f3760dbf7d0828b1b1fa4537c2c26a4
DIST aws-cli-1.29.51.gh.tar.gz 2534506 BLAKE2B 79ff26738b1008b3b19de7d4838dab11711d540f147fb60eb13b1d820f50dcf0544375cc7e37a9a6571a0931593ad1de6416c4e54bbcd27ab9e89a8b702303d2 SHA512 537a395f99d6b7fd9d4597f719dbf151620fe9f3c747e4ebaf54f63e2943621faaefe4ce1f278b09047e381da865e27ad394a166035ecace742f3294d6cc58ef
DIST aws-cli-1.29.52.gh.tar.gz 2547970 BLAKE2B 49ae8ce6051907b13c7c4eb5d5431e652050617f469cfc32ef70cb6ce7db335bb0ddf9105909705c840c693b7857f9e7396d983c6cd0a13bfadb210421cb83d7 SHA512 ccfb02b66854f4fd288086f1f9bea7f6ff8aa67e20ff253e0483e2133204be4efd3b50e87398feb68fd7852fdb53d4ac31dd2d1548248608b6a5351a618b0458
DIST aws-cli-1.29.53.gh.tar.gz 2549518 BLAKE2B 4c9932ddbfb5f8619006589c0ed8f00b5d0230bc9d7fa811875cc4b16e9b5583a3abe4ccbb290524565dde2f78ae5696162863ea6e5224517c98414d7cb74344 SHA512 1150c20f5cc3da3a0ba2e25741441a7db8b6e399a927366902b30fd30a394634d015cc6b53bbfe7bcb759ce0aec6e0f9432a23e5b8d00cd9c2bb71afd5744627

@ -0,0 +1,84 @@
# Copyright 1999-2023 Gentoo Authors
# Distributed under the terms of the GNU General Public License v2
EAPI=8
DISTUTILS_USE_PEP517=setuptools
PYTHON_COMPAT=( python3_{10..11} )
inherit bash-completion-r1 distutils-r1 multiprocessing
MY_P=aws-cli-${PV}
DESCRIPTION="Universal Command Line Environment for AWS"
HOMEPAGE="
https://github.com/aws/aws-cli/
https://pypi.org/project/awscli/
"
SRC_URI="
https://github.com/aws/aws-cli/archive/${PV}.tar.gz
-> ${MY_P}.gh.tar.gz
"
S=${WORKDIR}/${MY_P}
LICENSE="Apache-2.0"
SLOT="0"
KEYWORDS="~amd64 ~arm ~arm64 ~ppc ~ppc64 ~riscv ~sparc ~x86"
# botocore is x.(y+2).z
BOTOCORE_PV="$(ver_cut 1).$(( $(ver_cut 2) + 2)).$(ver_cut 3-)"
RDEPEND="
>=dev-python/botocore-${BOTOCORE_PV}[${PYTHON_USEDEP}]
dev-python/colorama[${PYTHON_USEDEP}]
dev-python/docutils[${PYTHON_USEDEP}]
dev-python/rsa[${PYTHON_USEDEP}]
>=dev-python/s3transfer-0.6.0[${PYTHON_USEDEP}]
dev-python/pyyaml[${PYTHON_USEDEP}]
!app-admin/awscli-bin
"
BDEPEND="
test? (
dev-python/pytest-forked[${PYTHON_USEDEP}]
dev-python/pytest-xdist[${PYTHON_USEDEP}]
)
"
distutils_enable_tests pytest
src_prepare() {
# do not rely on bundled deps in botocore (sic!)
find -name '*.py' -exec sed -i \
-e 's:from botocore[.]vendored import:import:' \
-e 's:from botocore[.]vendored[.]:from :' \
{} + || die
# strip overzealous upper bounds on requirements
sed -i -e 's:,<[0-9.]*::' -e 's:==:>=:' setup.py || die
distutils-r1_src_prepare
}
python_test() {
local EPYTEST_DESELECT=(
# broken xdist (signal() works only in main thread)
tests/functional/ecs/test_execute_command.py::TestExecuteCommand::test_execute_command_success
tests/unit/customizations/codeartifact/test_adapter_login.py::TestDotNetLogin::test_login_dotnet_sources_listed_with_backtracking
tests/unit/customizations/codeartifact/test_adapter_login.py::TestDotNetLogin::test_login_dotnet_sources_listed_with_backtracking_windows
tests/unit/customizations/codeartifact/test_adapter_login.py::TestNuGetLogin::test_login_nuget_sources_listed_with_backtracking
tests/unit/customizations/ecs/test_executecommand_startsession.py::TestExecuteCommand::test_execute_command_success
tests/unit/test_help.py::TestHelpPager::test_can_handle_ctrl_c
tests/unit/test_help.py::TestHelpPager::test_can_render_contents
tests/unit/test_utils.py::TestIgnoreCtrlC::test_ctrl_c_is_ignored
)
local -x PYTEST_DISABLE_PLUGIN_AUTOLOAD=1
# integration tests require AWS credentials and Internet access
epytest tests/{functional,unit} -p xdist -n "$(makeopts_jobs)"
}
python_install_all() {
newbashcomp bin/aws_bash_completer aws
insinto /usr/share/zsh/site-functions
newins bin/aws_zsh_completer.sh _aws
distutils-r1_python_install_all
rm "${ED}"/usr/bin/{aws.cmd,aws_bash_completer,aws_zsh_completer.sh} || die
}

@ -1,4 +1,4 @@
DIST salt-3005.1.tar.gz 17914349 BLAKE2B 697c2068bf119e4a19f92a86ce880fec9375c10ba549cdcdd2182cfeaacce31c7bc4c4c91e1a609906b4c5373bb5e3120e0db47ede5b45ee20942d7b2d201e64 SHA512 391f995f0129f3d7104a0eea4fd83b18aa6ecae0fd7a2c77c1154e24b0bcd52cef4b63db12597c85737bb33ddf605e0c23370cef3bf47f9ea85af5b77d74dc50
DIST salt-3005.2.tar.gz 17935313 BLAKE2B 550853b8245351b251438ac87d775e8b39d71ddc1eee0375f4bb29c04e2aacf5905ef9ac5373d9e7ff47a1cc8d6b9ce1a2a4c3d75b5647d4047bc06a5e526664 SHA512 07e7afc732a97006557d4556d60aa1854934893d0566bf8c295d4b1c01515988a1bf2798ce228f6b37e657de8fdfff51153ad2ea8d54baa6a5c377e30794f317
DIST salt-3005.3.tar.gz 17932868 BLAKE2B 18b1b3fe0708c2b425a410766df1545c093b43e69527b1213e1b043668b914016dc95b5c96c0619b1234b57fa404fdbe4fc245ac11d4f0b121edf4b0deacb3ee SHA512 4a40b21f0ee8ac31d3ca3d4d43706c3a484b9e19bd5797764475772af42fe682476b19f9097f003c838683529f15a757aab769eb0a15578cbc2fc449d8216604
DIST salt-3006.2.tar.gz 20411634 BLAKE2B dff474017918ef3ee0031856a2739282077205d8c2589809a91e5f1c3741cb26d2bd2458734ea4d3533118c881851dfd853f4ba4f1c631e7db28e95bc1b6f7f8 SHA512 2626cb5beb1b30fc63f554f5804f0d9b7e36b7c569c5f9049e5f5ac5a413e9d99a98b3d91089683338e3d3890ec973dff80782b4e41acb291872e45084fd2546
DIST salt-3006.3.tar.gz 20461738 BLAKE2B dfa4698dbc611c9c4954b4631d11b685e1efc978915918ce6d8f1890bb4a230d234b6a191166ffff9243058d44530bfc14b43386c8bc295c035c6609d6bf3fa0 SHA512 9cced766db2144de445ed53b52c1551c986ba43774c40512fd07973862d6d3a361e25f55fcfeeb0e03ba44eec1051909834e5d0a352ead5ec6f418b15c909628

Binary file not shown.

@ -8,7 +8,7 @@ if [[ ${PV} == 9999* ]]; then
inherit git-r3
else
SRC_URI="https://github.com/mate-desktop/${PN}/archive/${P}.tar.xz"
KEYWORDS="~amd64 ~arm ~arm64 ~loong ~riscv ~x86"
KEYWORDS="amd64 ~arm ~arm64 ~loong ~riscv x86"
fi
inherit mate optfeature

@ -10,7 +10,7 @@ HOMEPAGE="https://wiki.gnome.org/Apps/FileRoller"
LICENSE="GPL-2+ CC-BY-SA-3.0"
SLOT="0"
KEYWORDS="~alpha amd64 ~arm arm64 ~ia64 ~loong ~ppc ~ppc64 ~riscv ~sparc x86 ~amd64-linux ~x86-linux"
KEYWORDS="~alpha amd64 ~arm arm64 ~loong ~ppc ~ppc64 ~riscv x86 ~amd64-linux ~x86-linux"
IUSE="gtk-doc +introspection nautilus"
REQUIRED_USE="gtk-doc? ( introspection )"

@ -31,7 +31,7 @@ fi
LICENSE="GPL-3+"
SLOT="0"
if [[ ${PV} != *_p* ]] ; then
KEYWORDS="~alpha ~amd64 ~arm ~arm64 ~hppa ~ia64 ~loong ~m68k ~mips ~ppc ~ppc64 ~riscv ~s390 ~sparc ~x86 ~amd64-linux ~x86-linux ~arm64-macos ~ppc-macos ~x64-macos ~x64-solaris"
KEYWORDS="~alpha amd64 ~arm arm64 ~hppa ~ia64 ~loong ~m68k ~mips ~ppc ppc64 ~riscv ~s390 sparc ~x86 ~amd64-linux ~x86-linux ~arm64-macos ~ppc-macos ~x64-macos ~x64-solaris"
fi
IUSE="pic static"

@ -17,7 +17,7 @@ SRC_URI="
LICENSE="GPL-2 LGPL-2"
SLOT="0"
KEYWORDS="~alpha ~amd64 ~arm ~arm64 ~hppa ~ia64 ~loong ~mips ~ppc ~ppc64 ~riscv ~s390 ~sparc ~x86 ~amd64-linux ~x86-linux"
KEYWORDS="~alpha amd64 arm arm64 ~hppa ~ia64 ~loong ~mips ~ppc ppc64 ~riscv ~s390 ~sparc x86 ~amd64-linux ~x86-linux"
IUSE="acl audit caps +berkdb doc dbus nls openmp python readline selinux +sqlite test +zstd"
REQUIRED_USE="
${LUA_REQUIRED_USE}

@ -1 +1,2 @@
DIST tarlz-0.23.tar.lz 112276 BLAKE2B 87153b1e843ed74b5efd339d29e79ddef2bbd11ff951898383ae4c6c099f4e97ef58b8bd2f14ff5bff2cfd6baccb433ab55b9b9b78d0893caef5bd1f4d07a36e SHA512 623407142d03e0ddae3dbb057b8ef5f1aea850418dbb47c6278affa42c88bc1786cd3249d1e8c018643f41516787225cb2ed3aca2fc02ba8e65dfe4744f965d8
DIST tarlz-0.24.tar.lz 113503 BLAKE2B 5d9f3a65c29ba5131faacaf0b519494e4ba659182a7dd30c49aa3d0b0a507ce699ba0539684f36a65dd30bc2bf58b59ebedf7906cc210944c98bf3f6cb765608 SHA512 8aa617ce016675b24c3286ca44afef2801f37b8f617f89665aedd20266fdde1bc8a0ad6293a70b788fb36ad1f5c761d3141c26ab7b4615c8625d72f11c680d5c

@ -0,0 +1,32 @@
# Copyright 1999-2023 Gentoo Authors
# Distributed under the terms of the GNU General Public License v2
EAPI=8
inherit toolchain-funcs unpacker
DESCRIPTION="A parallel archiver combining tar and lzip"
HOMEPAGE="https://www.nongnu.org/lzip/tarlz.html"
SRC_URI="https://download.savannah.gnu.org/releases/lzip/${PN}/${P}.tar.lz"
LICENSE="GPL-2+"
SLOT="0"
KEYWORDS="~amd64"
RDEPEND="
>=app-arch/lzlib-1.12
"
DEPEND="
${RDEPEND}
"
BDEPEND="
$(unpacker_src_uri_depends)
"
src_configure() {
econf \
CXX="$(tc-getCXX)" \
CXXFLAGS="${CXXFLAGS}" \
CPPFLAGS="${CPPFLAGS}" \
LDFLAGS="${LDFLAGS}"
}

Binary file not shown.

@ -12,7 +12,7 @@ HOMEPAGE="https://wiki.gnome.org/Apps/Brasero"
LICENSE="GPL-2+ CC-BY-SA-3.0"
SLOT="0/3.1" # subslot is 3.suffix of libbrasero-burn3
IUSE="+css +introspection +libburn mp3 nautilus playlist tracker"
KEYWORDS="~alpha amd64 ~arm arm64 ~ia64 ~loong ppc ppc64 ~riscv ~sparc x86"
KEYWORDS="~alpha amd64 ~arm arm64 ~loong ppc ppc64 ~riscv x86"
DEPEND="
>=dev-libs/glib-2.29.14:2

Binary file not shown.

@ -0,0 +1 @@
DIST containers-common-0.56.0.tar.gz 12616120 BLAKE2B 6495ca7d0c9134bc8bd5f7b7541bb4f1160c74abb7a64bd4d2124104ea563f5381f0092da20ab45d81929a8632b1fcc1107ac05fdae011be446cff14ebf88c45 SHA512 4af720be95e6b5ca7d0664f99a389bf092b9f45d4e0602d9b49ef1d21b359d2307a94e0c88378fe0c751f5b40db54d7aab67eb497185a289cea9288cbfaa042c

@ -0,0 +1,76 @@
# Copyright 1999-2023 Gentoo Authors
# Distributed under the terms of the GNU General Public License v2
EAPI=8
DESCRIPTION="Common config files and docs for Containers eco-system"
HOMEPAGE="https://github.com/containers/common"
if [[ ${PV} == *9999* ]]; then
inherit git-r3
EGIT_REPO_URI="https://github.com/containers/common.git"
else
SRC_URI="https://github.com/containers/common/archive/v${PV}.tar.gz -> ${P}.tar.gz"
S="${WORKDIR}/${P#containers-}"
KEYWORDS="~amd64"
fi
LICENSE="Apache-2.0"
SLOT="0"
RDEPEND="
app-containers/containers-image
app-containers/containers-storage
app-containers/containers-shortnames
net-firewall/nftables
net-firewall/iptables[nftables]
|| ( app-containers/crun app-containers/runc )
|| (
( >=app-containers/netavark-1.6.0 >=app-containers/aardvark-dns-1.6.0 )
>=app-containers/cni-plugins-0.9.1
)
"
BDEPEND="
>=dev-go/go-md2man-2.0.2
"
src_prepare() {
default
[[ -f docs/Makefile ]] || die
sed -i -e 's|/usr/local|/usr|g;' docs/Makefile || die
eapply "${FILESDIR}/fix-warnings.patch"
}
src_configure() {
return
}
src_compile() {
emake docs
}
src_test() {
return
}
src_install() {
emake DESTDIR="${D}" install
insinto /etc/containers
# https://github.com/containers/skopeo/raw/main/default-policy.json
doins pkg/config/containers.conf "${FILESDIR}/policy.json"
insinto /etc/containers/registries.d
# https://github.com/containers/skopeo/raw/main/default.yaml
doins "${FILESDIR}/default.yaml"
insinto /usr/share/containers
# https://github.com/containers/common/raw/main/pkg/seccomp/seccomp.json
# https://github.com/containers/common/raw/main/pkg/subscriptions/mounts.conf
doins "${FILESDIR}/seccomp.json" "${FILESDIR}/mounts.conf"
keepdir /etc/containers/certs.d /etc/containers/oci/hooks.d /etc/containers/systemd /var/lib/containers/sigstore
}

@ -0,0 +1,76 @@
# Copyright 1999-2023 Gentoo Authors
# Distributed under the terms of the GNU General Public License v2
EAPI=8
DESCRIPTION="Common config files and docs for Containers eco-system"
HOMEPAGE="https://github.com/containers/common"
if [[ ${PV} == *9999* ]]; then
inherit git-r3
EGIT_REPO_URI="https://github.com/containers/common.git"
else
SRC_URI="https://github.com/containers/common/archive/v${PV}.tar.gz -> ${P}.tar.gz"
S="${WORKDIR}/${P#containers-}"
KEYWORDS="~amd64"
fi
LICENSE="Apache-2.0"
SLOT="0"
RDEPEND="
app-containers/containers-image
app-containers/containers-storage
app-containers/containers-shortnames
net-firewall/nftables
net-firewall/iptables[nftables]
|| ( app-containers/crun app-containers/runc )
|| (
( >=app-containers/netavark-1.6.0 >=app-containers/aardvark-dns-1.6.0 )
>=app-containers/cni-plugins-0.9.1
)
"
BDEPEND="
>=dev-go/go-md2man-2.0.2
"
src_prepare() {
default
[[ -f docs/Makefile ]] || die
sed -i -e 's|/usr/local|/usr|g;' docs/Makefile || die
eapply "${FILESDIR}/fix-warnings.patch"
}
src_configure() {
return
}
src_compile() {
emake docs
}
src_test() {
return
}
src_install() {
emake DESTDIR="${D}" install
insinto /etc/containers
# https://github.com/containers/skopeo/raw/main/default-policy.json
doins pkg/config/containers.conf "${FILESDIR}/policy.json"
insinto /etc/containers/registries.d
# https://github.com/containers/skopeo/raw/main/default.yaml
doins "${FILESDIR}/default.yaml"
insinto /usr/share/containers
# https://github.com/containers/common/raw/main/pkg/seccomp/seccomp.json
# https://github.com/containers/common/raw/main/pkg/subscriptions/mounts.conf
doins "${FILESDIR}/seccomp.json" "${FILESDIR}/mounts.conf"
keepdir /etc/containers/certs.d /etc/containers/oci/hooks.d /etc/containers/systemd /var/lib/containers/sigstore
}

@ -0,0 +1,28 @@
# This is a default registries.d configuration file. You may
# add to this file or create additional files in registries.d/.
#
# lookaside: for reading/writing simple signing signatures
# lookaside-staging: for writing simple signing signatures, preferred over lookaside
#
# lookaside and lookaside-staging take a value of the following:
# lookaside: {schema}://location
#
# For reading signatures, schema may be http, https, or file.
# For writing signatures, schema may only be file.
# The default locations are built-in, for both reading and writing:
# /var/lib/containers/sigstore for root, or
# ~/.local/share/containers/sigstore for non-root users.
default-docker:
# lookaside: https://…
# lookaside-staging: file:///…
# The 'docker' indicator here is the start of the configuration
# for docker registries.
#
# docker:
#
# privateregistry.com:
# lookaside: https://privateregistry.com/sigstore/
# lookaside-staging: /mnt/nfs/privateregistry/sigstore

@ -0,0 +1,24 @@
--- a/Makefile
+++ b/Makefile
@@ -4,20 +4,5 @@
DESTDIR ?=
-PREFIX := /usr/local
+PREFIX := /usr
CONFIGDIR := ${PREFIX}/share/containers
-define go-build
- CGO_ENABLED=0 \
- GOOS=$(1) GOARCH=$(2) $(GO) build -tags "$(3)" ./...
-endef
-
-ifeq ($(shell uname -s),Linux)
-define go-build-c
- CGO_ENABLED=1 \
- GOOS=$(1) GOARCH=$(2) $(GO) build -tags "$(3)" ./...
-endef
-else
-define go-build-c
-endef
-endif
-
.PHONY:

@ -0,0 +1,3 @@
# Refer to containers-mounts.conf(5)
# Example:
# /usr/share/rhel/secrets:/run/secrets

@ -0,0 +1,14 @@
{
"default": [
{
"type": "insecureAcceptAnything"
}
],
"transports":
{
"docker-daemon":
{
"": [{"type":"insecureAcceptAnything"}]
}
}
}

File diff suppressed because it is too large Load Diff

@ -0,0 +1,17 @@
<?xml version="1.0" encoding="UTF-8"?>
<!DOCTYPE pkgmetadata SYSTEM "https://www.gentoo.org/dtd/metadata.dtd">
<pkgmetadata>
<maintainer type="project" proxied="proxy">
<email>proxy-maint@gentoo.org</email>
<name>Proxy Maintainers</name>
</maintainer>
<maintainer type="person" proxied="yes">
<email>rahil3108@gmail.com</email>
<name>Rahil Bhimjiani</name>
</maintainer>
<upstream>
<remote-id type="github">containers/common</remote-id>
<bugs-to>https://github.com/containers/common/issues</bugs-to>
<doc>https://github.com/containers/common/blob/main/README.md</doc>
</upstream>
</pkgmetadata>

@ -0,0 +1 @@
DIST containers-image-5.28.0.tar.gz 688100 BLAKE2B 0cee8be579bd11eb0524590d8afe16b6ef863d7adfd74db51b68385142804c8096fec3f2a492e0d5a5021eba9edc91219b327138635aaa329c6ef7d0c01129c8 SHA512 0b76539e04016f5f1067c576a877ace475f25d0f0840fc969606601105a8a7f0e242cc054b0a2cfb6f1b751d850734360a524c78563fdf2330c8ae8c11bba1cf

@ -0,0 +1,45 @@
# Copyright 1999-2023 Gentoo Authors
# Distributed under the terms of the GNU General Public License v2
EAPI=8
DESCRIPTION="Default config and docs related to Containers' images"
HOMEPAGE="https://github.com/containers/image"
if [[ ${PV} == *9999* ]]; then
inherit git-r3
EGIT_REPO_URI="https://github.com/containers/image.git"
else
SRC_URI="https://github.com/containers/image/archive/v${PV}.tar.gz -> ${P}.tar.gz"
S="${WORKDIR}/${P#containers-}"
KEYWORDS="~amd64"
fi
LICENSE="Apache-2.0"
SLOT="0"
DEPEND=">=dev-go/go-md2man-2.0.2"
src_prepare() {
default
eapply "${FILESDIR}/fix-warnings.patch"
}
src_configure() {
return
}
src_compile() {
emake docs
}
src_test() {
return
}
src_install() {
emake DESTDIR="${D}" install
insinto /etc/containers
doins registries.conf
}

@ -0,0 +1,45 @@
# Copyright 1999-2023 Gentoo Authors
# Distributed under the terms of the GNU General Public License v2
EAPI=8
DESCRIPTION="Default config and docs related to Containers' images"
HOMEPAGE="https://github.com/containers/image"
if [[ ${PV} == *9999* ]]; then
inherit git-r3
EGIT_REPO_URI="https://github.com/containers/image.git"
else
SRC_URI="https://github.com/containers/image/archive/v${PV}.tar.gz -> ${P}.tar.gz"
S="${WORKDIR}/${P#containers-}"
KEYWORDS="~amd64"
fi
LICENSE="Apache-2.0"
SLOT="0"
DEPEND=">=dev-go/go-md2man-2.0.2"
src_prepare() {
default
eapply "${FILESDIR}/fix-warnings.patch"
}
src_configure() {
return
}
src_compile() {
emake docs
}
src_test() {
return
}
src_install() {
emake DESTDIR="${D}" install
insinto /etc/containers
doins registries.conf
}

@ -0,0 +1,14 @@
--- a/Makefile
+++ b/Makefile
@@ -5,7 +5,2 @@
-GOBIN := $(shell go env GOBIN)
-ifeq ($(GOBIN),)
-GOBIN := $(shell go env GOPATH)/bin
-endif
-
# when cross compiling _for_ a Darwin or windows host, then we must use openpgp
@@ -17,3 +12,2 @@
-PACKAGES := $(shell GO111MODULE=on go list $(BUILDFLAGS) ./...)
SOURCE_DIRS = $(shell echo $(PACKAGES) | awk 'BEGIN{FS="/"; RS=" "}{print $$4}' | uniq)

@ -0,0 +1,17 @@
<?xml version="1.0" encoding="UTF-8"?>
<!DOCTYPE pkgmetadata SYSTEM "https://www.gentoo.org/dtd/metadata.dtd">
<pkgmetadata>
<maintainer type="project" proxied="proxy">
<email>proxy-maint@gentoo.org</email>
<name>Proxy Maintainers</name>
</maintainer>
<maintainer type="person" proxied="yes">
<email>rahil3108@gmail.com</email>
<name>Rahil Bhimjiani</name>
</maintainer>
<upstream>
<remote-id type="github">containers/image</remote-id>
<bugs-to>https://github.com/containers/image/issues</bugs-to>
<doc>https://github.com/containers/image/blob/main/README.md</doc>
</upstream>
</pkgmetadata>

@ -0,0 +1 @@
DIST containers-shortnames-2023.02.20.tar.gz 13527 BLAKE2B 165a4c51bd284078990c94059145bb6b4bd5de4d8595eb2ccd2acc6fe8561e7edc300b7edadc684675ee281d7ada1c3a6d5aa0117c640ec22c2d2ef7e46486b5 SHA512 856dbbeb2acda276e9605bd1ecec0f8d65952c597ee2af61dd8909d7d3c04e5ef06c40b69ec4a98f79e623c536850f614c1b0af3a19637e300e7d3a285933193

@ -0,0 +1,36 @@
# Copyright 1999-2023 Gentoo Authors
# Distributed under the terms of the GNU General Public License v2
EAPI=8
DESCRIPTION="Configures default shortnames (aliases) for Containers"
HOMEPAGE="https://github.com/containers/shortnames"
if [[ ${PV} == *9999* ]]; then
inherit git-r3
EGIT_REPO_URI="https://github.com/containers/shortnames.git"
else
SRC_URI="https://github.com/containers/shortnames/archive/v${PV}.tar.gz -> ${P}.tar.gz"
S="${WORKDIR}/${P#containers-}"
KEYWORDS="~amd64"
fi
LICENSE="Apache-2.0"
SLOT="0"
src_configure() {
return
}
src_compile() {
return
}
src_test() {
return
}
src_install() {
insinto /etc/containers/registries.conf.d
newins shortnames.conf 000-shortnames.conf
}

@ -0,0 +1,36 @@
# Copyright 1999-2023 Gentoo Authors
# Distributed under the terms of the GNU General Public License v2
EAPI=8
DESCRIPTION="Configures default shortnames (aliases) for Containers"
HOMEPAGE="https://github.com/containers/shortnames"
if [[ ${PV} == *9999* ]]; then
inherit git-r3
EGIT_REPO_URI="https://github.com/containers/shortnames.git"
else
SRC_URI="https://github.com/containers/shortnames/archive/v${PV}.tar.gz -> ${P}.tar.gz"
S="${WORKDIR}/${P#containers-}"
KEYWORDS="~amd64"
fi
LICENSE="Apache-2.0"
SLOT="0"
src_configure() {
return
}
src_compile() {
return
}
src_test() {
return
}
src_install() {
insinto /etc/containers/registries.conf.d
newins shortnames.conf 000-shortnames.conf
}

@ -0,0 +1,17 @@
<?xml version="1.0" encoding="UTF-8"?>
<!DOCTYPE pkgmetadata SYSTEM "https://www.gentoo.org/dtd/metadata.dtd">
<pkgmetadata>
<maintainer type="project" proxied="proxy">
<email>proxy-maint@gentoo.org</email>
<name>Proxy Maintainers</name>
</maintainer>
<maintainer type="person" proxied="yes">
<email>rahil3108@gmail.com</email>
<name>Rahil Bhimjiani</name>
</maintainer>
<upstream>
<remote-id type="github">containers/shortnames</remote-id>
<bugs-to>https://github.com/containers/shortnames/issues</bugs-to>
<doc>https://github.com/containers/shortnames/blob/main/README.md</doc>
</upstream>
</pkgmetadata>

@ -1,2 +1 @@
DIST containers-storage-1.41.0.tar.gz 3685908 BLAKE2B 5835fa222127d8e2398a33ec02b24ee0b5a94943ed30a19d8b5f76ce4b852f1e7ad9eceb052dcbb2a2c3db96d3ec4ca0150ab81cd0e0a0e351b353f47c0862b5 SHA512 e2d4d887f067d4bdab97426d9cfe7f941b8148d3c40ddb60d5cbc08f1b3a8c5e6a182586f9cdb96873377b8467368527ff89220ba8a5cd7ad4682a90a1243f56
DIST containers-storage-1.42.0.tar.gz 3767236 BLAKE2B 3cca3833695bb5e15a0ab5d97d5f72e14102d8c6eee1c132932e4177f64ab9a171cf8486f4fe8d9e09a0537a325c988c6b766249c3c0843bb5f1b270a705b523 SHA512 c8a4fdfbc71915dd3a1d5c1fabef4be7641b8a0edb14805719d93bc9de5bd8fe150636c4457fa544487a6bccbb0f58ad36ca3990d6ca3c2b73935418aaf98f22
DIST containers-storage-1.50.2.tar.gz 4278269 BLAKE2B 3a2b08c710c043cfc130b9ffe39807e5ced8aa3cdb9805e9d9a4d0f60d8136f99e78ca03992c566b7c7d9aa1c25a2ab9da5e9edc4f1f841663302f5873dce419 SHA512 eb2ca9d243511abd5d6d1727c60166422dbfef4a3ddbb5062e58d915d0705afcd10ded8f1f79e897f9f5244fb6b6d349fbf3ed86ae57f41e31a1965c4e926941

@ -1,58 +0,0 @@
# Copyright 1999-2022 Gentoo Authors
# Distributed under the terms of the GNU General Public License v2
EAPI=7
inherit go-module
KEYWORDS="~amd64"
DESCRIPTION="containers/storage library"
HOMEPAGE="https://github.com/containers/storage"
LICENSE="Apache-2.0 BSD BSD-2 CC-BY-SA-4.0 ISC MIT"
SLOT="0"
IUSE="btrfs +device-mapper test"
SRC_URI="https://github.com/containers/storage/archive/v${PV}.tar.gz -> ${P}.tar.gz"
RDEPEND="
btrfs? ( sys-fs/btrfs-progs )
device-mapper? ( sys-fs/lvm2:= )"
DEPEND="${RDEPEND}
dev-go/go-md2man
test? (
sys-fs/btrfs-progs
sys-fs/lvm2
sys-apps/util-linux
)"
RESTRICT="test"
S=${WORKDIR}/${P#containers-}
src_prepare() {
default
sed -e 's|: install\.tools|:|' -i Makefile || die
[[ -f hack/btrfs_tag.sh ]] || die
use btrfs || { echo -e "#!/bin/sh\necho exclude_graphdriver_btrfs" > \
"hack/btrfs_tag.sh" || die; }
[[ -f hack/libdm_tag.sh ]] || die
use device-mapper || { echo -e "#!/bin/sh\necho btrfs_noversion exclude_graphdriver_devicemapper" > \
"hack/libdm_tag.sh" || die; }
}
src_compile() {
export -n GOCACHE GOPATH XDG_CACHE_HOME #678856
emake GOMD2MAN=go-md2man FFJSON= containers-storage docs
}
src_install() {
dobin "${PN}"
while read -r -d ''; do
mv "${REPLY}" "${REPLY%.1}" || die
done < <(find "${S}/docs" -name '*.[[:digit:]].1' -print0)
find "${S}/docs" -name '*.[[:digit:]]' -exec doman '{}' + || die
}
src_test() {
env -u GOFLAGS unshare -m emake local-test-unit || die
}

@ -1,58 +0,0 @@
# Copyright 1999-2022 Gentoo Authors
# Distributed under the terms of the GNU General Public License v2
EAPI=7
inherit go-module
KEYWORDS="~amd64"
DESCRIPTION="containers/storage library"
HOMEPAGE="https://github.com/containers/storage"
LICENSE="Apache-2.0 BSD BSD-2 CC-BY-SA-4.0 ISC MIT"
SLOT="0"
IUSE="btrfs +device-mapper test"
SRC_URI="https://github.com/containers/storage/archive/v${PV}.tar.gz -> ${P}.tar.gz"
RDEPEND="
btrfs? ( sys-fs/btrfs-progs )
device-mapper? ( sys-fs/lvm2:= )"
DEPEND="${RDEPEND}
dev-go/go-md2man
test? (
sys-fs/btrfs-progs
sys-fs/lvm2
sys-apps/util-linux
)"
RESTRICT="test"
S=${WORKDIR}/${P#containers-}
src_prepare() {
default
sed -e 's|: install\.tools|:|' -i Makefile || die
[[ -f hack/btrfs_tag.sh ]] || die
use btrfs || { echo -e "#!/bin/sh\necho exclude_graphdriver_btrfs" > \
"hack/btrfs_tag.sh" || die; }
[[ -f hack/libdm_tag.sh ]] || die
use device-mapper || { echo -e "#!/bin/sh\necho btrfs_noversion exclude_graphdriver_devicemapper" > \
"hack/libdm_tag.sh" || die; }
}
src_compile() {
export -n GOCACHE GOPATH XDG_CACHE_HOME #678856
emake GOMD2MAN=go-md2man FFJSON= containers-storage docs
}
src_install() {
dobin "${PN}"
while read -r -d ''; do
mv "${REPLY}" "${REPLY%.1}" || die
done < <(find "${S}/docs" -name '*.[[:digit:]].1' -print0)
find "${S}/docs" -name '*.[[:digit:]]' -exec doman '{}' + || die
}
src_test() {
env -u GOFLAGS unshare -m emake local-test-unit || die
}

@ -0,0 +1,45 @@
# Copyright 1999-2023 Gentoo Authors
# Distributed under the terms of the GNU General Public License v2
EAPI=8
DESCRIPTION="Default config and docs related to Containers' storage"
HOMEPAGE="https://github.com/containers/storage"
if [[ ${PV} == *9999* ]]; then
inherit git-r3
EGIT_REPO_URI="https://github.com/containers/storage.git"
else
SRC_URI="https://github.com/containers/storage/archive/v${PV}.tar.gz -> ${P}.tar.gz"
S="${WORKDIR}/${P#containers-}"
KEYWORDS="~amd64"
fi
LICENSE="Apache-2.0"
SLOT="0"
DEPEND=">=dev-go/go-md2man-2.0.2"
src_prepare() {
default
eapply "${FILESDIR}"/system-md2man-path.patch
}
src_configure() {
return
}
src_compile() {
emake -C docs containers-storage.conf.5
}
src_test() {
return
}
src_install() {
emake DESTDIR="${D}" -C docs install
insinto /etc/containers
doins storage.conf
}

@ -0,0 +1,45 @@
# Copyright 1999-2023 Gentoo Authors
# Distributed under the terms of the GNU General Public License v2
EAPI=8
DESCRIPTION="Default config and docs related to Containers' storage"
HOMEPAGE="https://github.com/containers/storage"
if [[ ${PV} == *9999* ]]; then
inherit git-r3
EGIT_REPO_URI="https://github.com/containers/storage.git"
else
SRC_URI="https://github.com/containers/storage/archive/v${PV}.tar.gz -> ${P}.tar.gz"
S="${WORKDIR}/${P#containers-}"
KEYWORDS="~amd64"
fi
LICENSE="Apache-2.0"
SLOT="0"
DEPEND=">=dev-go/go-md2man-2.0.2"
src_prepare() {
default
eapply "${FILESDIR}"/system-md2man-path.patch
}
src_configure() {
return
}
src_compile() {
emake -C docs containers-storage.conf.5
}
src_test() {
return
}
src_install() {
emake DESTDIR="${D}" -C docs install
insinto /etc/containers
doins storage.conf
}

@ -0,0 +1,7 @@
--- a/docs/Makefile
+++ b/docs/Makefile
@@ -1,2 +1,3 @@
-GOMD2MAN = ../tests/tools/build/go-md2man
+GOMD2MAN = $(shell command -v go-md2man)
+
PREFIX ?= ${DESTDIR}/usr

@ -1,21 +1,21 @@
<?xml version="1.0" encoding="UTF-8"?>
<!DOCTYPE pkgmetadata SYSTEM "https://www.gentoo.org/dtd/metadata.dtd">
<pkgmetadata>
<maintainer type="person">
<email>zmedico@gentoo.org</email>
<name>Zac Medico</name>
</maintainer>
<use>
<flag name="btrfs">
Enables dependencies for the "btrfs" graph driver, including
necessary kernel flags.
</flag>
<flag name="device-mapper">
Enables dependencies for the "devicemapper" graph driver, including
necessary kernel flags.
</flag>
</use>
<upstream>
<remote-id type="github">containers/storage</remote-id>
</upstream>
<maintainer type="person">
<email>zmedico@gentoo.org</email>
<name>Zac Medico</name>
</maintainer>
<maintainer type="project" proxied="proxy">
<email>proxy-maint@gentoo.org</email>
<name>Proxy Maintainers</name>
</maintainer>
<maintainer type="person" proxied="yes">
<email>rahil3108@gmail.com</email>
<name>Rahil Bhimjiani</name>
</maintainer>
<upstream>
<remote-id type="github">containers/storage</remote-id>
<bugs-to>https://github.com/containers/storage/issues</bugs-to>
<doc>https://github.com/containers/storage/blob/main/README.md</doc>
</upstream>
</pkgmetadata>

@ -4,3 +4,5 @@ DIST lxd-5.0.2.tar.gz 16258766 BLAKE2B a0d4e3108664724c064fb8c16031ff7dfa3f49735
DIST lxd-5.0.2.tar.gz.asc 833 BLAKE2B 606cae1439148060acd3fb04fdb108654a351ce2b7484081f7874ab2b0af8de2b5befc5a5409a94af0da25308622234db2e3b411edb20324df458fe85f46ac21 SHA512 884c921a263a8baf2d94958c72e232a0a47d0747f5a9d36ed8fc270edfa18dfc240d1e858e75dcc03eae921dae08d3ddfd34d9146d1510de6a09031da26aaccc
DIST lxd-5.17.tar.gz 22319517 BLAKE2B b9dfd934fad6b21b6f2b1d25291b4201f647b2b09a1ae155577a88257c021cc36b43a08802411d0f3268b726da7fa38b8627302696f670a1747e3795db0b0efe SHA512 f5feca34fff0b01a9db8041dd18fde82ad089f36ab171cf338556ebec9b2accfa450b0734d72b25bbb7296aaaeafed247aac2117c32f3ebfce5ae716e4b196bf
DIST lxd-5.17.tar.gz.asc 833 BLAKE2B bc781d520b8314261b6681603f17fcb82d045bb969ebf8eec64c82ef73f493892d48d50c870f72e9f4f1f6c7dd4b63239a5039949e4f7bb49539c69538b4a2f2 SHA512 7e76a6cfcb1bf5b7b864125b412d5bd4766b4af6cdab40d70324c4103d1a716c39dfa5cf0eccf2cb7862f182c7c469f18ca46b981a1be3fc0fac8c47537d6c1c
DIST lxd-5.18.tar.gz 22536474 BLAKE2B 44dabd50c137adde794ed266484a071d1aecff9300f8710d748a550415bd5f21b5f4ab40602f7b648cc05f9acc403782209636bdb8fe9720ff2808e8816aa27b SHA512 a9bdc276fb040413bad47579fb420951a007d725319c89abfde14062933267c7e5c67c546f2222905232231997a8f47fa097ed603d93dde2b9990b3e7018103f
DIST lxd-5.18.tar.gz.asc 833 BLAKE2B 2eee2786d2930bce45b5f23943d3e9b0dab61595608a38077429585c3191476915d0ba7ef5eb05633a014dd92542cc5a5bfa70c4c0a63b94733297d37d78717e SHA512 959911019bffeca1cddae6b44c65b2cdbd71658cf9f714e41dd3de755629aedc0e8de196dac6ba0de0f27247e859f7090dc23edf4896e7a6c028b87e3665a5e2

@ -0,0 +1,21 @@
https://github.com/canonical/lxd/commit/2d8481712055d0cbb3bd952e25a1df469939990d.patch
From: Thomas Parrott <thomas.parrott@canonical.com>
Date: Thu, 21 Sep 2023 22:12:19 +0100
Subject: [PATCH] shared/simplestreams/products: Fix regression in
lxd_combined.tar.gz handling
For reasons that are likely lost to history simplestreams uses lxd.tar.xz
whereas the combined file is lxd_combined.tar.gz (not xz).
Signed-off-by: Thomas Parrott <thomas.parrott@canonical.com>
--- a/shared/simplestreams/products.go
+++ b/shared/simplestreams/products.go
@@ -10,7 +10,7 @@ import (
"github.com/canonical/lxd/shared/osarch"
)
-var lxdCompatCombinedItems = []string{"lxd_combined.tar.xz", "incus_combined.tar.xz"}
+var lxdCompatCombinedItems = []string{"lxd_combined.tar.gz", "incus_combined.tar.gz"}
var lxdCompatItems = []string{"lxd.tar.xz", "incus.tar.xz"}
// Products represents the base of download.json.

@ -0,0 +1,187 @@
# Copyright 1999-2023 Gentoo Authors
# Distributed under the terms of the GNU General Public License v2
EAPI=8
inherit bash-completion-r1 go-module linux-info optfeature systemd verify-sig
DESCRIPTION="Modern, secure and powerful system container and virtual machine manager"
HOMEPAGE="https://ubuntu.com/lxd https://github.com/canonical/lxd"
SRC_URI="https://github.com/canonical/lxd/releases/download/${P}/${P}.tar.gz
verify-sig? ( https://github.com/canonical/lxd/releases/download/${P}/${P}.tar.gz.asc
)"
LICENSE="Apache-2.0 BSD LGPL-3 MIT"
SLOT="0/stable"
KEYWORDS="~amd64 ~arm64 ~x86"
IUSE="apparmor nls"
DEPEND="acct-group/lxd
app-arch/xz-utils
>=app-containers/lxc-5.0.0:=[apparmor?,seccomp(+)]
dev-db/sqlite:3
>=dev-libs/dqlite-1.13.0:=
dev-libs/lzo
>=dev-libs/raft-0.17.1:=[lz4]
>=dev-util/xdelta-3.0[lzma(+)]
net-dns/dnsmasq[dhcp]
sys-libs/libcap
virtual/udev"
RDEPEND="${DEPEND}
net-firewall/ebtables
net-firewall/iptables
sys-apps/iproute2
sys-fs/fuse:3
>=sys-fs/lxcfs-5.0.0
sys-fs/squashfs-tools[lzma]
virtual/acl"
BDEPEND="dev-lang/go
nls? ( sys-devel/gettext )
verify-sig? ( sec-keys/openpgp-keys-canonical )"
CONFIG_CHECK="
~CGROUPS
~IPC_NS
~NET_NS
~PID_NS
~SECCOMP
~USER_NS
~UTS_NS
~KVM
~MACVTAP
~VHOST_VSOCK
"
ERROR_IPC_NS="CONFIG_IPC_NS is required."
ERROR_NET_NS="CONFIG_NET_NS is required."
ERROR_PID_NS="CONFIG_PID_NS is required."
ERROR_SECCOMP="CONFIG_SECCOMP is required."
ERROR_UTS_NS="CONFIG_UTS_NS is required."
WARNING_KVM="CONFIG_KVM and CONFIG_KVM_AMD/-INTEL is required for virtual machines."
WARNING_MACVTAP="CONFIG_MACVTAP is required for virtual machines."
WARNING_VHOST_VSOCK="CONFIG_VHOST_VSOCK is required for virtual machines."
# Go magic.
QA_PREBUILT="/usr/bin/fuidshift
/usr/bin/lxc
/usr/bin/lxc-to-lxd
/usr/bin/lxd-agent
/usr/bin/lxd-benchmark
/usr/bin/lxd-migrate
/usr/sbin/lxd"
VERIFY_SIG_OPENPGP_KEY_PATH=${BROOT}/usr/share/openpgp-keys/canonical.asc
# The testsuite must be run as root.
# make: *** [Makefile:156: check] Error 1
RESTRICT="test"
GOPATH="${S}/_dist"
PATCHES=(
"${FILESDIR}"/${P}-handle-regression-in-lxd_combined.tar.gz-handling.patch
)
src_prepare() {
export GOPATH="${S}/_dist"
default
sed -i \
-e "s:\./configure:./configure --prefix=/usr --libdir=${EPREFIX}/usr/lib/lxd:g" \
-e "s:make:make ${MAKEOPTS}:g" \
Makefile || die
# Fix hardcoded ovmf file path, see bug 763180
sed -i \
-e "s:/usr/share/OVMF:/usr/share/edk2-ovmf:g" \
-e "s:OVMF_VARS.ms.fd:OVMF_VARS.fd:g" \
doc/environment.md \
lxd/apparmor/instance.go \
lxd/apparmor/instance_qemu.go \
lxd/instance/drivers/driver_qemu.go || die "Failed to fix hardcoded ovmf paths."
# Fix hardcoded virtfs-proxy-helper file path, see bug 798924
sed -i \
-e "s:/usr/lib/qemu/virtfs-proxy-helper:/usr/libexec/virtfs-proxy-helper:g" \
lxd/device/device_utils_disk.go || die "Failed to fix virtfs-proxy-helper path."
cp "${FILESDIR}"/lxd-4.0.9-r1.service "${T}"/lxd.service || die
if use apparmor; then
sed -i \
'/^EnvironmentFile=.*/a ExecStartPre=\/usr\/libexec\/lxc\/lxc-apparmor-load' \
"${T}"/lxd.service || die
fi
# Disable -Werror's from go modules.
find "${S}" -name "cgo.go" -exec sed -i "s/ -Werror / /g" {} + || die
}
src_configure() { :; }
src_compile() {
export GOPATH="${S}/_dist"
export CGO_LDFLAGS_ALLOW="-Wl,-z,now"
for k in fuidshift lxd-benchmark lxc lxc-to-lxd; do
go install -v -x "${S}/${k}" || die "failed compiling ${k}"
done
go install -v -x -tags libsqlite3 "${S}"/lxd || die "Failed to build the daemon"
# Needs to be built statically
CGO_ENABLED=0 go install -v -tags netgo "${S}"/lxd-migrate
CGO_ENABLED=0 go install -v -tags agent,netgo "${S}"/lxd-agent
use nls && emake build-mo
}
src_test() {
emake check
}
src_install() {
export GOPATH="${S}/_dist"
local bindir="_dist/bin"
dosbin ${bindir}/lxd
for l in fuidshift lxd-agent lxd-benchmark lxd-migrate lxc lxc-to-lxd; do
dobin ${bindir}/${l}
done
newbashcomp scripts/bash/lxd-client lxc
newconfd "${FILESDIR}"/lxd-4.0.0.confd lxd
newinitd "${FILESDIR}"/lxd-5.0.2-r1.initd lxd
systemd_dounit "${T}"/lxd.service
systemd_newunit "${FILESDIR}"/lxd-containers-4.0.0.service lxd-containers.service
systemd_newunit "${FILESDIR}"/lxd-4.0.0.socket lxd.socket
dodoc AUTHORS
dodoc -r doc/*
use nls && domo po/*.mo
}
pkg_postinst() {
elog
elog "Consult https://wiki.gentoo.org/wiki/LXD for more information,"
elog "including a Quick Start."
elog "For virtual machine support, see:"
elog "https://wiki.gentoo.org/wiki/LXD#Virtual_machines"
elog
elog "Please run 'lxc-checkconfig' to see all optional kernel features."
elog
optfeature "virtual machine support" app-emulation/qemu[spice,usbredir,virtfs]
optfeature "btrfs storage backend" sys-fs/btrfs-progs
optfeature "ipv6 support" net-dns/dnsmasq[ipv6]
optfeature "full lxd-migrate support"
optfeature "lvm2 storage backend" sys-fs/lvm2
optfeature "zfs storage backend" sys-fs/zfs
elog
elog "Be sure to add your local user to the lxd group."
}

@ -13,10 +13,6 @@
<email>virtualization@gentoo.org</email>
<name>Gentoo Virtualization Project</name>
</maintainer>
<maintainer type="project" proxied="proxy">
<email>proxy-maint@gentoo.org</email>
<name>Proxy Maintainers</name>
</maintainer>
<longdescription>
LXD is a modern, secure and powerful system container and virtual machine manager.

Binary file not shown.

@ -1,124 +0,0 @@
# Copyright 1999-2023 Gentoo Authors
# Distributed under the terms of the GNU General Public License v2
EAPI=8
inherit autotools desktop gnome2-utils
DESCRIPTION="Electronic Identity Card middleware supplied by the Belgian Federal Government"
HOMEPAGE="https://eid.belgium.be"
SRC_URI="https://codeload.github.com/fedict/${PN}/tar.gz/v${PV} -> ${P}.tar.gz"
LICENSE="LGPL-3"
SLOT="0"
KEYWORDS="~amd64 ~arm ~arm64 ~x86"
IUSE="+dialogs +gtk p11-kit"
RDEPEND=">=sys-apps/pcsc-lite-1.2.9
gtk? (
x11-libs/gdk-pixbuf[jpeg]
x11-libs/gtk+:3
dev-libs/libxml2
net-misc/curl[ssl]
net-libs/libproxy
>=app-crypt/pinentry-1.1.0-r4[gtk]
)
p11-kit? ( app-crypt/p11-kit )"
DEPEND="${RDEPEND}
virtual/pkgconfig"
REQUIRED_USE="dialogs? ( gtk )"
src_prepare() {
default
# Buggy internal versioning when autoreconf a tarball release.
# Weird numbering is required otherwise we get a seg fault in
# about-eid-mw program.
echo "${PV}-v${PV}" > .version
# See bug #862306
sed -i \
-e 's:PACKAGE_VERSION:MAINVERSION:' \
cardcomm/pkcs11/src/libbeidpkcs11.pc.in || die
# xpi module : we don't want it anymore
sed -i -e '/SUBDIRS/ s:plugins_tools/xpi ::' Makefile.am || die
sed -i -e '/plugins_tools\/xpi/ d' configure.ac || die
# hardcoded lsb_info
sed -i \
-e "s:get_lsb_info('i'):strdup(_(\"Gentoo\")):" \
-e "s:get_lsb_info('r'):strdup(_(\"n/a\")):" \
-e "s:get_lsb_info('c'):strdup(_(\"n/a\")):" \
plugins_tools/aboutmw/gtk/about-main.c || die
# Fix libdir for manifestdir
sed -i \
-e "/pkcs11_manifestdir/ s:prefix)/lib:libdir):" \
-e "/managed_storage_manifestdir/ s:prefix)/lib:libdir):" \
cardcomm/pkcs11/src/Makefile.am || die
# See bug #732994
sed -i \
-e '/LDFLAGS="/ s:$CPPFLAGS:$LDFLAGS:' \
configure.ac || die
# See bug #751472
eapply "${FILESDIR}/use-printf-in-Makefile.patch"
# See bug #811270 (remove uml build)
sed -i \
-e 's:cardlayer/uml::' \
cardcomm/pkcs11/src/Makefile.am || die
sed -i \
-e 's:uml::' \
plugins_tools/eid-viewer/Makefile.am || die
eautoreconf
}
src_configure() {
econf \
$(use_enable dialogs) \
$(use_enable p11-kit p11kit) \
$(use_with gtk gtkvers 'detect') \
--with-gnu-ld \
--disable-static
}
src_install() {
default
rm -r "${ED}"/usr/$(get_libdir)/*.la || die
if use gtk; then
domenu plugins_tools/eid-viewer/eid-viewer.desktop
doicon plugins_tools/eid-viewer/gtk/eid-viewer.png
fi
}
pkg_postinst() {
if use gtk; then
gnome2_schemas_update
xdg_desktop_database_update
xdg_icon_cache_update
local peimpl=$(eselect --brief --colour=no pinentry show)
case "${peimpl}" in
*gnome*|*qt*) ;;
*) ewarn "The pinentry front-end currently selected is not supported by eid-mw."
ewarn "You may be prompted for your pin code in an inaccessible shell!!"
ewarn "Please select pinentry-gnome3 as default pinentry provider:"
ewarn " # eselect pinentry set pinentry-gnome3"
;;
esac
fi
}
pkg_postrm() {
if use gtk; then
gnome2_schemas_update
xdg_desktop_database_update
xdg_icon_cache_update
fi
}

@ -1,2 +1,2 @@
DIST libsecret-0.20.5.tar.xz 187340 BLAKE2B cde5094eaaf54f251c19afb015c39cc88435dafe6ee682ca8f9d1917dd5b3dc8cc1609cdbf2a3a42d2592c2a149bec5fe28b2f4ec179b92c0d0f07d2f14c1792 SHA512 61ca248aafd265e1f31d56c9084c68d880ebf03660ace3d4a6c6622ab306b56e921ac24647b6a60633bfa99c8a0407d4ae1aa6148511f289bf5ce2025b72692a
DIST libsecret-0.21.0.tar.xz 190320 BLAKE2B 0775f1b80eea303793aa9c1e940e0cb47ada4cee10ebae947a7e17d5a749736a3219a7edf937693b32df5505c2dd96bffc523b4cfcb41c6a7f12cea0b43449b3 SHA512 666a67f3f06274ab57e1b6e3e855033ce244ab45b9b237851fc06f33ef7922179b5bcbe96a5dc50d1136cbb8d74c2d0af0af4d0ae9de918b4a63b36abb1f2b97
DIST libsecret-0.21.1.tar.xz 190796 BLAKE2B 862c2aac0c519d2607c1c5b057d1e0d00d3d5bce06744ab8c6e074393ede2f154af9ab3ee988820c936c8c22dba205ee7bd570287aaa47e64fde21ae3a7dfc2b SHA512 e201b2292280c355d08f8bd2d90d6d785d7b618c82e731eb9c051599a24d8f6a0cc3e271b1876d738f4a15aab24c2b6607b6d15d4335a990e74bb0371fe941ae

@ -27,7 +27,7 @@ RDEPEND="
dev-libs/openssl:*
doc? ( app-text/linuxdoc-tools )"
DEPEND="${RDEPEND}"
BDEPEND="dev-qt/linguist-tools:5"
BDEPEND="dev-qt/linguist-tools:5 doc? ( dev-python/sphinx dev-python/sphinxcontrib-htmlhelp dev-python/sphinxcontrib-qthelp )"
PATCHES=(
"${FILESDIR}/${PN}-1.0.0-desktop.patch"

Binary file not shown.

@ -13,7 +13,7 @@ S="${WORKDIR}"/${PN}-$(ver_cut 1-3)
LICENSE="GPL-2"
SLOT="0"
KEYWORDS="~amd64 ~ppc ~riscv ~x86"
KEYWORDS="~amd64 ~ppc ~riscv x86"
DEPEND=">=dev-libs/eb-3.3.4"
RDEPEND="${DEPEND}"

@ -1,8 +1,8 @@
# Copyright 1999-2021 Gentoo Authors
# Copyright 1999-2023 Gentoo Authors
# Distributed under the terms of the GNU General Public License v2
EAPI=8
USE_RUBY="ruby25 ruby26 ruby27 ruby30"
USE_RUBY="ruby31"
inherit ruby-ng

@ -10,7 +10,7 @@ SRC_URI="https://github.com/wojtekka/${PN}/archive/${PV}.tar.gz -> ${P}.tar.gz"
LICENSE="GPL-2"
SLOT="0"
KEYWORDS="~amd64 ~riscv ~x86"
KEYWORDS="amd64 ~riscv x86"
IUSE="ao"
RDEPEND="

Binary file not shown.

@ -1,2 +1,3 @@
DIST doxygen-1.9.6.src.tar.gz 5293513 BLAKE2B 35d3286b47922776814bb7941c7a1cb27a5a50be35a9f231b1f072333d966630bbf0b97813f56711f71f040a0ceb87e7e1cbee04ca2aa3f035754ba844561697 SHA512 f8b0d19d33fa8a5bb92b38f1c775bd3cde7f024566cf93ed61ab0cafe86643971c04b7f2492364767b3e6ce5b518bad5e0321c82f0a72875ccf936ea7d3595b2
DIST doxygen-1.9.7.src.tar.gz 5736446 BLAKE2B e0f6e06399a2dda7226fe8fea351a79f19bf71aee51fba0ce113c3423b85aa633ce8d98894e3e49027839c2accc18af87c7f23a1fd37c0de441de42a8a76d307 SHA512 618ff58aa6f0a2eb89f95b570995ea3ebbcda64f502cabcecd9be2967abffb56d0d6747de0c06df422705919757e6af9c6e5a56ca603b1ddf7a09a7ee79b1803
DIST doxygen-1.9.8.src.tar.gz 8087770 BLAKE2B 9b93bd394e9fdafef1c274596f790db0956028332a945e0359b7b24440aefa5362b2126649c529e71341bba172cd1fa514455567ffffd37243a740a1ffbc1944 SHA512 edcd382538ecf0afd9d1c891afe302092cd541a30840dda6b00dc0f1d6c5b39a696ab98042c5bb4012c1c051609bfdbfa7d29e3098a72f6cb504d90097767ebb

@ -0,0 +1,157 @@
# Copyright 1999-2023 Gentoo Authors
# Distributed under the terms of the GNU General Public License v2
EAPI=8
LLVM_MAX_SLOT=17
PYTHON_COMPAT=( python3_{10..12} )
PYTHON_REQ_USE="xml(+)"
inherit cmake flag-o-matic llvm python-any-r1
DESCRIPTION="Documentation system for most programming languages"
HOMEPAGE="https://www.doxygen.nl/"
if [[ ${PV} == *9999* ]]; then
inherit git-r3
EGIT_REPO_URI="https://github.com/doxygen/doxygen.git"
else
SRC_URI="https://doxygen.nl/files/${P}.src.tar.gz"
SRC_URI+=" mirror://sourceforge/doxygen/rel-${PV}/${P}.src.tar.gz"
KEYWORDS="~alpha ~amd64 ~arm ~arm64 ~loong ~m68k ~mips ~ppc ~ppc64 ~riscv ~x86 ~amd64-linux ~x86-linux ~ppc-macos ~x64-macos ~x64-solaris"
fi
# GPL-2 also for bundled libmscgen
LICENSE="GPL-2"
SLOT="0"
IUSE="clang debug doc dot doxysearch gui sqlite test"
# - We need TeX for tests, bug #765472
# - We keep the odd construct of noop USE=test because of
# the special relationship b/t RESTRICT & USE for tests.
# Also, it's a hint which avoids tests being silently skipped during arch testing.
REQUIRED_USE="test? ( doc )"
RESTRICT="!test? ( test )"
BDEPEND="
sys-devel/bison
sys-devel/flex
${PYTHON_DEPS}
"
RDEPEND="
app-text/ghostscript-gpl
dev-db/sqlite:3
dev-lang/perl
dev-libs/libfmt:=
dev-libs/spdlog:=
media-libs/libpng:=
virtual/libiconv
clang? (
<sys-devel/clang-$((${LLVM_MAX_SLOT} + 1)):=
)
dot? (
media-gfx/graphviz
media-libs/freetype
)
doc? (
dev-texlive/texlive-bibtexextra
dev-texlive/texlive-fontsextra
dev-texlive/texlive-fontutils
dev-texlive/texlive-latex
dev-texlive/texlive-latexextra
dev-texlive/texlive-plaingeneric
)
doxysearch? ( dev-libs/xapian:= )
gui? (
dev-qt/qtcore:5
dev-qt/qtgui:5
dev-qt/qtwidgets:5
dev-qt/qtxml:5
)
"
DEPEND="${RDEPEND}"
PATCHES=(
"${FILESDIR}/${PN}-1.9.4-link_with_pthread.patch"
"${FILESDIR}/${PN}-1.9.7-musl-1.2.4.patch"
"${FILESDIR}/${PN}-1.9.8-suppress-unused-option-libcxx.patch"
# Backports
"${FILESDIR}/${P}-spdlog-link.patch"
"${FILESDIR}/${P}-unbundle-sqlite.patch"
)
DOCS=( LANGUAGE.HOWTO README.md )
pkg_setup() {
use clang && llvm_pkg_setup
python-any-r1_pkg_setup
}
src_prepare() {
cmake_src_prepare
# Call dot with -Teps instead of -Tps for EPS generation - bug #282150
sed -i -e '/addJob("ps"/ s/"ps"/"eps"/g' src/dot.cpp || die
# fix pdf doc
sed -i.orig -e "s:g_kowal:g kowal:" \
doc/maintainers.txt || die
if is-flagq "-O3" ; then
ewarn
ewarn "Compiling with -O3 is known to produce incorrectly"
ewarn "optimized code which breaks doxygen."
ewarn
elog
elog "Continuing with -O2 instead ..."
elog
replace-flags "-O3" "-O2"
fi
}
src_configure() {
# -Wodr warnings, see bug #854357 and https://github.com/doxygen/doxygen/issues/9287
filter-lto
local mycmakeargs=(
-Duse_libclang=$(usex clang)
# Let the user choose instead, see also bug #822615
-Duse_libc++=OFF
-Dbuild_doc=$(usex doc)
-Dbuild_search=$(usex doxysearch)
-Dbuild_wizard=$(usex gui)
-Duse_sys_spdlog=ON
-Duse_sys_sqlite3=ON
-DBUILD_SHARED_LIBS=OFF
-DGIT_EXECUTABLE="false"
)
use doc && mycmakeargs+=(
-DDOC_INSTALL_DIR="share/doc/${P}"
)
cmake_src_configure
}
src_compile() {
cmake_src_compile
if use doc; then
export VARTEXFONTS="${T}/fonts" # bug #564944
if ! use dot; then
sed -i -e "s/HAVE_DOT = YES/HAVE_DOT = NO/" \
{testing/Doxyfile,doc/Doxyfile} \
|| die "disabling dot failed"
fi
# -j1 for bug #770070
cmake_src_compile docs -j1
fi
}
src_install() {
cmake_src_install
doman doc/*.1
}

@ -3,43 +3,51 @@
EAPI=8
LLVM_MAX_SLOT=17
PYTHON_COMPAT=( python3_{10..12} )
PYTHON_REQ_USE="xml(+)"
inherit cmake flag-o-matic llvm python-any-r1
if [[ ${PV} = *9999* ]]; then
DESCRIPTION="Documentation system for most programming languages"
HOMEPAGE="https://www.doxygen.nl/"
if [[ ${PV} == *9999* ]]; then
inherit git-r3
EGIT_REPO_URI="https://github.com/doxygen/doxygen.git"
else
SRC_URI="https://doxygen.nl/files/${P}.src.tar.gz"
SRC_URI+=" mirror://sourceforge/doxygen/rel-${PV}/${P}.src.tar.gz"
KEYWORDS="~alpha ~amd64 ~arm ~arm64 ~hppa ~ia64 ~loong ~m68k ~mips ~ppc ~ppc64 ~riscv ~s390 ~sparc ~x86 ~amd64-linux ~x86-linux ~ppc-macos ~x64-macos ~x64-solaris"
KEYWORDS="~alpha ~amd64 ~arm ~arm64 ~loong ~m68k ~mips ~ppc ~ppc64 ~riscv ~x86 ~amd64-linux ~x86-linux ~ppc-macos ~x64-macos ~x64-solaris"
fi
DESCRIPTION="Documentation system for most programming languages"
HOMEPAGE="https://www.doxygen.nl/"
# GPL-2 also for bundled libmscgen, MIT for bundled spdlog
LICENSE="GPL-2 MIT"
# GPL-2 also for bundled libmscgen
LICENSE="GPL-2"
SLOT="0"
IUSE="clang debug doc dot doxysearch qt5 sqlite test"
# We need TeX for tests, bug #765472
# We keep the odd construct of noop USE=test because of
# the special relationship b/t RESTRICT & USE for tests. Also, it's a hint
# which avoids tests being silently skipped during arch testing.
IUSE="clang debug doc dot doxysearch gui sqlite test"
# - We need TeX for tests, bug #765472
# - We keep the odd construct of noop USE=test because of
# the special relationship b/t RESTRICT & USE for tests.
# Also, it's a hint which avoids tests being silently skipped during arch testing.
REQUIRED_USE="test? ( doc )"
RESTRICT="!test? ( test )"
BDEPEND="sys-devel/bison
BDEPEND="
sys-devel/bison
sys-devel/flex
${PYTHON_DEPS}
"
RDEPEND="app-text/ghostscript-gpl
RDEPEND="
app-text/ghostscript-gpl
dev-db/sqlite:3
dev-lang/perl
dev-libs/libfmt:=
dev-libs/spdlog:=
media-libs/libpng:0=
media-libs/libpng:=
virtual/libiconv
clang? ( >=sys-devel/clang-10:= )
clang? (
<sys-devel/clang-$((${LLVM_MAX_SLOT} + 1)):=
)
dot? (
media-gfx/graphviz
media-libs/freetype
@ -53,7 +61,8 @@ RDEPEND="app-text/ghostscript-gpl
dev-texlive/texlive-plaingeneric
)
doxysearch? ( dev-libs/xapian:= )
qt5? (
gui? (
dev-qt/qtcore:5
dev-qt/qtgui:5
dev-qt/qtwidgets:5
dev-qt/qtxml:5
@ -63,9 +72,10 @@ DEPEND="${RDEPEND}"
PATCHES=(
"${FILESDIR}/${PN}-1.9.4-link_with_pthread.patch"
"${FILESDIR}/${PN}-1.9.1-ignore-bad-encoding.patch"
"${FILESDIR}/${PN}-1.9.1-do_not_force_libcxx.patch"
"${FILESDIR}/${PN}-1.9.7-musl-1.2.4.patch"
"${FILESDIR}/${PN}-1.9.8-suppress-unused-option-libcxx.patch"
# Backports
)
DOCS=( LANGUAGE.HOWTO README.md )
@ -103,10 +113,13 @@ src_configure() {
local mycmakeargs=(
-Duse_libclang=$(usex clang)
# Let the user choose instead, see also bug #822615
-Duse_libc++=OFF
-Dbuild_doc=$(usex doc)
-Dbuild_search=$(usex doxysearch)
-Dbuild_wizard=$(usex qt5)
-Dbuild_wizard=$(usex gui)
-Duse_sys_spdlog=ON
-Duse_sys_sqlite3=ON
-DBUILD_SHARED_LIBS=OFF
-DGIT_EXECUTABLE="false"
)

@ -0,0 +1,51 @@
https://github.com/doxygen/doxygen/issues/10265
https://github.com/doxygen/doxygen/pull/10284
From 70bb112352ae7f3130647dcc009d8de5d4134e6d Mon Sep 17 00:00:00 2001
From: =?UTF-8?q?=D9=85=D9=87=D8=AF=D9=8A=20=D8=B4=D9=8A=D9=86=D9=88=D9=86?=
=?UTF-8?q?=20=28Mehdi=20Chinoune=29?= <mehdi.chinoune@hotmail.com>
Date: Mon, 4 Sep 2023 18:49:27 +0100
Subject: [PATCH 1/2] doxyapp: Fix linking to spdlog
---
addon/doxyapp/CMakeLists.txt | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/addon/doxyapp/CMakeLists.txt b/addon/doxyapp/CMakeLists.txt
index 4f3c31feacd..6097a3cca69 100644
--- a/addon/doxyapp/CMakeLists.txt
+++ b/addon/doxyapp/CMakeLists.txt
@@ -46,7 +46,7 @@ mscgen
doxygen_version
doxycfg
vhdlparser
-spdlog
+spdlog::spdlog
${ICONV_LIBRARIES}
${CMAKE_THREAD_LIBS_INIT}
${SQLITE3_LIBRARIES}
From 71f2ed171a6d14a67f1905802714add974c31789 Mon Sep 17 00:00:00 2001
From: =?UTF-8?q?=D9=85=D9=87=D8=AF=D9=8A=20=D8=B4=D9=8A=D9=86=D9=88=D9=86?=
=?UTF-8?q?=20=28Mehdi=20Chinoune=29?= <mehdi.chinoune@hotmail.com>
Date: Mon, 4 Sep 2023 18:50:25 +0100
Subject: [PATCH 2/2] doxyparse: Fix linking to spdlog
---
addon/doxyparse/CMakeLists.txt | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/addon/doxyparse/CMakeLists.txt b/addon/doxyparse/CMakeLists.txt
index 24881e3ef12..0157afb45e2 100644
--- a/addon/doxyparse/CMakeLists.txt
+++ b/addon/doxyparse/CMakeLists.txt
@@ -35,7 +35,7 @@ mscgen
doxygen_version
doxycfg
vhdlparser
-spdlog
+spdlog::spdlog
${ICONV_LIBRARIES}
${CMAKE_THREAD_LIBS_INIT}
${SQLITE3_LIBRARIES}

@ -0,0 +1,16 @@
Always expose the use_libc++ option. It's only useful for Clang but cmake.class
tries to find when we've used CMake options which are unused/unknown and this
triggers it for GCC builds if we set -Duse_libc++=OFF.
So, always expose the option so we can turn it off without a warning.
--- a/CMakeLists.txt
+++ b/CMakeLists.txt
@@ -21,7 +21,7 @@ option(build_xmlparser "Automatically update the XML parser modules when updatin
option(build_search "Build external search tools (doxysearch and doxyindexer)" OFF)
option(build_doc "Build user manual (HTML and PDF)" OFF)
option(build_doc_chm "Build user manual (CHM)" OFF)
-if (CMAKE_CXX_COMPILER_ID STREQUAL "Clang")
+if (TRUE)
option(use_libc++ "Use libc++ as C++ standard library." ON)
endif()
option(use_libclang "Add support for libclang parsing." OFF)

@ -0,0 +1,119 @@
https://github.com/doxygen/doxygen/issues/10263
https://github.com/doxygen/doxygen/commit/28609fecd41d885e54fa170e499a0e5b55def2c2
From 28609fecd41d885e54fa170e499a0e5b55def2c2 Mon Sep 17 00:00:00 2001
From: Dimitri van Heesch <doxygen@gmail.com>
Date: Mon, 28 Aug 2023 20:19:16 +0200
Subject: [PATCH] issue #10263 please add a use_sys_sqlite3 config option
---
CMakeLists.txt | 6 +++++-
cmake/FindSQLite3.cmake | 38 ++++++++++++++++++++++++++++++++++++++
deps/CMakeLists.txt | 4 +++-
src/CMakeLists.txt | 4 +++-
4 files changed, 49 insertions(+), 3 deletions(-)
create mode 100644 cmake/FindSQLite3.cmake
diff --git a/CMakeLists.txt b/CMakeLists.txt
index 4957c34c24d..31e53cc8440 100644
--- a/CMakeLists.txt
+++ b/CMakeLists.txt
@@ -25,7 +25,8 @@ if (CMAKE_CXX_COMPILER_ID STREQUAL "Clang")
option(use_libc++ "Use libc++ as C++ standard library." ON)
endif()
option(use_libclang "Add support for libclang parsing." OFF)
-option(use_sys_spdlog "Use system spdlog instead of bundled." OFF)
+option(use_sys_spdlog "Use system spdlog library instead of the one bundled." OFF)
+option(use_sys_sqlite3 "Use system sqlite3 library instead of the one bundled." OFF)
option(static_libclang "Link to a statically compiled version of LLVM/libclang." OFF)
option(win_static "Link with /MT in stead of /MD on windows" OFF)
option(enable_console "Enable that executables on Windows get the CONSOLE bit set for the doxywizard executable [development]" OFF)
@@ -67,6 +68,9 @@ endif()
if (use_sys_spdlog)
find_package(spdlog CONFIG REQUIRED)
endif()
+if (use_sys_sqlite3)
+ find_package(SQLite3 REQUIRED)
+endif()
if (build_wizard)
if (force_qt STREQUAL "Qt6")
if (CMAKE_SYSTEM MATCHES "Darwin")
diff --git a/cmake/FindSQLite3.cmake b/cmake/FindSQLite3.cmake
new file mode 100644
index 00000000000..7c21de223a7
--- /dev/null
+++ b/cmake/FindSQLite3.cmake
@@ -0,0 +1,38 @@
+# Copyright (C) 2007-2009 LuaDist.
+# Created by Peter Kapec <kapecp@gmail.com>
+# Redistribution and use of this file is allowed according to the terms of the MIT license.
+# For details see the COPYRIGHT file distributed with LuaDist.
+# Note:
+# Searching headers and libraries is very simple and is NOT as powerful as scripts
+# distributed with CMake, because LuaDist defines directories to search for.
+# Everyone is encouraged to contact the author with improvements. Maybe this file
+# becomes part of CMake distribution sometimes.
+
+# - Find sqlite3
+# Find the native SQLite3 headers and libraries.
+#
+# SQLite3_INCLUDE_DIRS - where to find sqlite3.h, etc.
+# SQLite3_LIBRARIES - List of libraries when using sqlite.
+# SQLite3_FOUND - True if sqlite found.
+
+# Look for the header file.
+FIND_PATH(SQLite3_INCLUDE_DIR NAMES sqlite3.h)
+
+# Look for the library.
+FIND_LIBRARY(SQLite3_LIBRARY NAMES sqlite3)
+
+# Handle the QUIETLY and REQUIRED arguments and set SQLITE3_FOUND to TRUE if all listed variables are TRUE.
+INCLUDE(FindPackageHandleStandardArgs)
+FIND_PACKAGE_HANDLE_STANDARD_ARGS(SQLite3 DEFAULT_MSG SQLite3_LIBRARY SQLite3_INCLUDE_DIR)
+
+# Copy the results to the output variables.
+IF(SQLite3_FOUND)
+ SET(SQLite3_LIBRARIES ${SQLite3_LIBRARY})
+ SET(SQLite3_INCLUDE_DIRS ${SQLite3_INCLUDE_DIR})
+ELSE(SQLite3_FOUND)
+ SET(SQLite3_LIBRARIES)
+ SET(SQLite3_INCLUDE_DIRS)
+ENDIF(SQLite3_FOUND)
+
+MARK_AS_ADVANCED(SQLite3_INCLUDE_DIRS SQLite3_LIBRARIES)
+
diff --git a/deps/CMakeLists.txt b/deps/CMakeLists.txt
index a689b4a7018..eb716417f22 100644
--- a/deps/CMakeLists.txt
+++ b/deps/CMakeLists.txt
@@ -4,4 +4,6 @@ add_subdirectory(libmscgen)
if (NOT use_sys_spdlog)
add_subdirectory(spdlog)
endif()
-add_subdirectory(sqlite3)
+if (NOT use_sys_sqlite3)
+ add_subdirectory(sqlite3)
+endif()
diff --git a/src/CMakeLists.txt b/src/CMakeLists.txt
index 78a55c3f2bf..02c52240e5b 100644
--- a/src/CMakeLists.txt
+++ b/src/CMakeLists.txt
@@ -6,7 +6,6 @@ include_directories(
${PROJECT_SOURCE_DIR}/deps/libmd5
${PROJECT_SOURCE_DIR}/deps/liblodepng
${PROJECT_SOURCE_DIR}/deps/libmscgen
- ${PROJECT_SOURCE_DIR}/deps/sqlite3
${PROJECT_SOURCE_DIR}/libversion
${PROJECT_SOURCE_DIR}/libxml
${PROJECT_SOURCE_DIR}/vhdlparser
@@ -18,6 +17,9 @@ include_directories(
if (NOT use_sys_spdlog)
include_directories(${PROJECT_SOURCE_DIR}/deps/spdlog/include)
endif()
+if (NOT use_sys_sqlite)
+ include_directories(${PROJECT_SOURCE_DIR}/deps/sqlite3)
+endif()
file(MAKE_DIRECTORY ${GENERATED_SRC})

@ -1,2 +1,3 @@
DIST gnucash-docs-4.13.tar.gz 76306335 BLAKE2B 61944e3da12d4f7b4a26f1301e640deca87656c4a9c7cd935f4c52ae69e49bf746850f09513d8fbd92314827f683c3a9c83c59479d583c192d977afdf9d8fce4 SHA512 7081a84c3426ef84e88aef520458a0d06382853cb9a51880766033b655f873d0926848387d573a38eca82cf0c6bceecdbd56704ab9ecb3068c78d7ce5c8d4da0
DIST gnucash-docs-5.1.tar.gz 76533404 BLAKE2B 6601548123b6c1bdb3f04f54a5a598eb12ca803b604c02357a4126a52ce2d39f4f44b3cc35eb874590898b0792a99190d8ddca795bd45457c9ee565b95405b39 SHA512 6976964c4163987c867142bbf5c23ebf05585a73bd78926e35983602cf0caa024e5e334c19603a568e3fc5cd1e2f6b96e61ca888d5c6679b76f764429b8acdd1
DIST gnucash-docs-5.2.tar.gz 76537611 BLAKE2B 6abd9981cd0380358548ab5260bce766417ad25509eb4f8f5c890ad8b87a9d69a8d5b3a97227780d936986d2385a0d9cdb89aefb46d5fc533ccebd2472ea14ae SHA512 0b52d1d08cf217c6e9ebc0641b7f717abae960d801ee2f23e0a4bd2f21b7f82ca37f87359b4fb5329d8321dc2576e88bc1fcbc85935d69ba1f2205a4be153cf4

@ -0,0 +1,72 @@
# Copyright 1999-2023 Gentoo Authors
# Distributed under the terms of the GNU General Public License v2
EAPI=8
# Please bump with app-office/gnucash
CMAKE_MAKEFILE_GENERATOR=emake
inherit cmake optfeature
DESCRIPTION="Documentation package for GnuCash"
HOMEPAGE="https://www.gnucash.org/"
SRC_URI="https://github.com/Gnucash/${PN}/archive/${PV}.tar.gz -> ${P}.tar.gz"
LICENSE="GPL-2 FDL-1.1"
SLOT="0"
KEYWORDS="~amd64 ~arm64 ~ppc ~ppc64 ~riscv ~x86"
LOCALES=( de it ja pt )
IUSE="${LOCALES[*]/#/l10n_}"
BDEPEND="
app-text/docbook-xml-dtd:4.5
app-text/docbook-xsl-stylesheets
dev-libs/libxml2
dev-libs/libxslt
"
src_prepare() {
eapply "${FILESDIR}/${PN}-5.1-partially-revert-kde-help-dir.patch"
cmake_src_prepare
}
src_compile() {
cmake_src_compile
}
src_install() {
local doc_type my_lang
for doc_type in manual guide; do
for my_lang in C ${L10N}; do
[[ -z ${my_lang} ]] && continue
case "${my_lang}" in
# Both help and guides translated
C|de|it|pt) ;;
ja|ru) # Only guides translated
if [[ "${doc_type}" == "manual" ]] ; then
elog "Help documentation hasn't been translated for ${my_lang}"
elog "Will do English instead."
continue
fi
;;
*)
die "Invalid locale: ${my_lang}"
;;
esac
emake \
-C "${BUILD_DIR}/${my_lang}/${doc_type}" \
DESTDIR="${D}" \
install
done
done
einstalldocs
}
pkg_postinst() {
optfeature "generating PDF files" dev-java/fop
optfeature "viewing the docs" gnome-extra/yelp
}

@ -1,3 +1,2 @@
DIST kicad-doc-7.0.1.tar.bz2 104103280 BLAKE2B dbdcd82e65c9d3a2bff629f8fa4e3cc34c2adbfa3fe9a808e3802addc3d75f3875ad52c4f5e79cb2bfb7563a6288d0c2eb6f119adf4f7fd2f31360cea82d1ea7 SHA512 5274ef673db9e415d5b82522681acdd4ee2b2f615bb52abdd11ebd17b72f36852ee297fdb98f9cf1dee12671a23adc24a6a8a03be720b579bbee7a9ead167e41
DIST kicad-doc-7.0.2.tar.bz2 104105560 BLAKE2B e6617c5390fd03c7e388a532bd34fbf13baa2fffabac0a63ad84a1e30c398ff5d240cb7ac890945a56fdbdd7300398f37667974797d60afc8a4f6438a6bf324b SHA512 d05a1b9988bbaaa630d036c0b90e81020bd0d51dbccbe6918983bea7894476e0a186fa133fc88aa365c9d26e51b1184f7ce5f375847b828f6b9a85abfe6fd33e
DIST kicad-doc-7.0.6.tar.bz2 104105032 BLAKE2B d8cf3cdbaf4088793ba0f6b5625c92b83972620a9da2240827b3a38ae18f66e3fa277c7c930195e18604a6b13dd8fa2a8a5d90de70cbe609575f3d9f89d75d01 SHA512 2162119a1e0b3626a65841e6a6e60561512a27c10b79345ee3713f3b046a58448ad9765f6b430ad77d67ca75cb0d9f37018f2540020406cde0b5a35969db20f4
DIST kicad-doc-7.0.7.tar.bz2 104103652 BLAKE2B f5ce0ccde126c062dd877ce8023b0c22e33bc1df47e12494d6a41cb198e0100c690fb9325f6e8b74198af77af1c6afb92f6a6f8c417828527bfa8904c88f6432 SHA512 fd37e06dcac907d8fca6cdf8e3eaf2c5197a82572d92f2b2af8aca8ea3603e7dd4ffc1c77b1e28aee245b4d611dca2a3565eec1d23051925d9969582232862c1

@ -1,59 +0,0 @@
# Copyright 1999-2023 Gentoo Authors
# Distributed under the terms of the GNU General Public License v2
EAPI=8
inherit cmake
DESCRIPTION="Electronic Schematic and PCB design tools manuals"
HOMEPAGE="https://docs.kicad.org/"
if [[ ${PV} == 9999 ]]; then
EGIT_REPO_URI="https://gitlab.com/kicad/services/kicad-doc.git"
inherit git-r3
# x11-misc-util/macros only required on live ebuilds
LIVE_DEPEND=">=x11-misc/util-macros-1.18"
else
SRC_URI="https://gitlab.com/kicad/services/${PN}/-/archive/${PV}/${P}.tar.bz2"
KEYWORDS="~amd64 ~arm64 ~riscv ~x86"
fi
LICENSE="|| ( GPL-3+ CC-BY-3.0 ) GPL-2"
SLOT="0"
# TODO: Change default back to +pdf once asciidoctor-pdf is packaged?
IUSE="+html pdf"
LANG_USE=" l10n_ca l10n_de l10n_en l10n_es l10n_fr l10n_id l10n_it l10n_ja l10n_pl l10n_ru l10n_zh"
IUSE+=${LANG_USE}
REQUIRED_USE="|| ( html pdf ) ^^ ( ${LANG_USE} )"
unset LANG_USE
# TODO: need asciidoctor-pdf for pdf
# bug #697450
BDEPEND="
>=dev-ruby/asciidoctor-2.0.12
>=app-text/dblatex-0.3.10
>=app-text/po4a-0.45
>=sys-devel/gettext-0.18
dev-perl/Unicode-LineBreak
dev-util/source-highlight
l10n_ca? ( dev-texlive/texlive-langspanish )
l10n_de? ( dev-texlive/texlive-langgerman )
l10n_en? ( dev-texlive/texlive-langenglish )
l10n_es? ( dev-texlive/texlive-langspanish )
l10n_fr? ( dev-texlive/texlive-langfrench )
l10n_it? ( dev-texlive/texlive-langitalian )
l10n_ja? ( dev-texlive/texlive-langjapanese media-fonts/vlgothic )
l10n_pl? ( dev-texlive/texlive-langpolish )
l10n_ru? ( dev-texlive/texlive-langcyrillic )
l10n_zh? ( dev-texlive/texlive-langchinese )"
src_configure() {
local mycmakeargs=(
-DPDF_GENERATOR="DBLATEX"
-DBUILD_FORMATS="$(usev html);$(usev pdf)"
-DSINGLE_LANGUAGE="${L10N}"
-DKICAD_DOC_PATH="${EPREFIX}"/usr/share/doc/${P}/help
)
cmake_src_configure
}

Binary file not shown.

@ -1,3 +1,2 @@
DIST gnome-text-editor-44.0.tar.xz 610996 BLAKE2B 02ab81055402df584a448d0e611b608e5fa10d6f4a600755cbab9f730aa1806268f7277dafb4fd3aa95ff2be64d2894806c6038ad81dae7cfb87b28dccc7da24 SHA512 bca373a124c3e648fa28da1a493163d768488fa3645fcfbfa7a115e195c0c971dc98e007c9c0fdf7fe415df64e76071fc83e33831707bb31154e66355948bbb3
DIST gnome-text-editor-45.0.tar.xz 616972 BLAKE2B 41907137026f6175901965c713451292c9cc172381c9f371c00f236cf5bf70ac9604025c856bafcba87eea1a5f31e468b716fd6307e2aaf82570ac64d6574f3a SHA512 5bec27bb7674f8b6d737e24508e9839600145e4ec5e2cbacdb80e1a4f884782e2bb24808595cfcd0139f101104ce94e70cb90229b514d1dd6ed8e672c878304d
DIST gnome-text-editor-45.beta.tar.xz 606824 BLAKE2B bea05d6ca321993ff1f2e563b9c6041b381cb1c9986654166b6fda174a0ed678a05521181c603b4d0847ef878838e5773256bf6afea1855afe4bf3a042feeb3a SHA512 32e07cb8c8c605224e1d915b9579efdf7146291835582da7ab460a4dc23e8207d9cdbc19261bd5060421f9ad06869a49d22b6b1b46e14bcf6fc93238c6eef329

@ -14,7 +14,7 @@ SLOT="0"
IUSE="spell"
KEYWORDS="~amd64 ~riscv"
KEYWORDS="~amd64 ~loong ~riscv"
DEPEND="
>=dev-libs/glib-2.73.0:2

@ -1,57 +0,0 @@
# Copyright 2022-2023 Gentoo Authors
# Distributed under the terms of the GNU General Public License v2
EAPI=8
inherit gnome.org gnome2-utils meson xdg
DESCRIPTION="A simple text editor for the GNOME desktop"
HOMEPAGE="https://gitlab.gnome.org/GNOME/gnome-text-editor"
S="${WORKDIR}/gnome-text-editor-${PV/_/.}"
LICENSE="GPL-3+ CC-BY-SA-3.0"
SLOT="0"
IUSE="spell"
KEYWORDS="~amd64 ~riscv"
DEPEND="
>=dev-libs/glib-2.73.0:2
>=gui-libs/gtk-4.7:4
>=gui-libs/gtksourceview-5.5.0:5
>=gui-libs/libadwaita-1.4_alpha:1
app-text/editorconfig-core-c
x11-libs/cairo
spell? (
>=app-text/enchant-2.2.0:2
dev-libs/icu:=
)
"
RDEPEND="${DEPEND}
gnome-base/gsettings-desktop-schemas
"
BDEPEND="
dev-util/glib-utils
dev-util/itstool
>=sys-devel/gettext-0.21
virtual/pkgconfig
"
src_configure() {
local emesonargs=(
$(meson_feature spell enchant)
-Dbugreport_url="https://bugs.gentoo.org"
)
meson_src_configure
}
pkg_postinst() {
xdg_pkg_postinst
gnome2_schemas_update
}
pkg_postrm() {
xdg_pkg_postrm
gnome2_schemas_update
}

@ -1,3 +1,2 @@
DIST neovim-0.9.0.tar.gz 11549103 BLAKE2B f07b61f02a11acf678358999ea364b6a64724451a9a75f2d6ca436edc5ead9c6422f1c7e99c4322dc0bb92daacf306e32e214ab34d10f78f28d4ffad17b878c7 SHA512 e42f09f408b83fc34e8f169321e0349d1f851e67a998265c53d2ddb1a4792c3f4777fabe32baf2c7eff7d3745ff60d4a07da542ccd272883f7f4e080b2c9c1bf
DIST neovim-0.9.1.tar.gz 11567358 BLAKE2B 7aa56c672f7d26db7d47df39941487de32008b9e78921d71860281e8319b30dc6cd889a029c83b61814baecac947f39a950245ed7e51c35509b30e9b39046a58 SHA512 339efd3d8c1a73aa3b43e8770d6943aeba9e4ce6a3598c0424e388f80759d50b14aa7c60fd435bf2d17997476e06d28b79e7e98670d02ca9ceec031841e8b9b8
DIST neovim-0.9.2.tar.gz 11580390 BLAKE2B 097b0b245e8f987c7f980df2d170f4d62fc08e107f6166f1df4a78776b0aa8b8dc3c699648ae5fa123e54e7599321f0170f93ccee4d89302f25d1b8bba6161c7 SHA512 f12ae48c82c4a3622e464a23966cb06e9da1a7cd000b4efeb8408bb55e189ffeb4ece99e9488244c16f7de70356303e4dc964afd70ab24d23a5e07c59e902ed9

@ -1,119 +0,0 @@
# Copyright 1999-2023 Gentoo Authors
# Distributed under the terms of the GNU General Public License v2
EAPI=8
# RelWithDebInfo sets -Og -g
CMAKE_BUILD_TYPE=Release
LUA_COMPAT=( lua5-{1..2} luajit )
inherit cmake lua-single optfeature xdg
DESCRIPTION="Vim-fork focused on extensibility and agility"
HOMEPAGE="https://neovim.io"
if [[ ${PV} == 9999 ]]; then
inherit git-r3
EGIT_REPO_URI="https://github.com/neovim/neovim.git"
else
SRC_URI="https://github.com/neovim/neovim/archive/v${PV}.tar.gz -> ${P}.tar.gz"
KEYWORDS="amd64 ~arm arm64 ~ppc64 ~riscv x86 ~x64-macos"
fi
LICENSE="Apache-2.0 vim"
SLOT="0"
IUSE="+lto +nvimpager test"
# Upstream say the test library needs LuaJIT
# https://github.com/neovim/neovim/blob/91109ffda23d0ce61cec245b1f4ffb99e7591b62/CMakeLists.txt#L377
REQUIRED_USE="${LUA_REQUIRED_USE} test? ( lua_single_target_luajit )"
# TODO: Get tests running
RESTRICT="!test? ( test ) test"
# Upstream build scripts invoke the Lua interpreter
BDEPEND="${LUA_DEPS}
>=dev-util/gperf-3.1
>=sys-devel/gettext-0.20.1
virtual/libiconv
virtual/libintl
virtual/pkgconfig
"
# Check https://github.com/neovim/neovim/blob/master/third-party/CMakeLists.txt for
# new dependency bounds and so on on bumps (obviously adjust for right branch/tag).
DEPEND="${LUA_DEPS}
>=dev-lua/luv-1.44.2[${LUA_SINGLE_USEDEP}]
$(lua_gen_cond_dep '
dev-lua/lpeg[${LUA_USEDEP}]
dev-lua/mpack[${LUA_USEDEP}]
')
$(lua_gen_cond_dep '
dev-lua/LuaBitOp[${LUA_USEDEP}]
' lua5-{1,2})
>=dev-libs/libuv-1.44.2:=
>=dev-libs/libvterm-0.3
>=dev-libs/msgpack-3.0.0:=
>=dev-libs/tree-sitter-0.20.8:=
>=dev-libs/libtermkey-0.22
>=dev-libs/unibilium-2.0.0:0=
"
RDEPEND="
${DEPEND}
app-eselect/eselect-vi
"
BDEPEND+="
test? (
$(lua_gen_cond_dep 'dev-lua/busted[${LUA_USEDEP}]')
)
"
PATCHES=(
"${FILESDIR}/${PN}-0.9.0-cmake_lua_version.patch"
"${FILESDIR}/${PN}-0.9.0-cmake-darwin.patch"
"${FILESDIR}/${PN}-0.9.0-cmake-release-type.patch"
)
src_prepare() {
# Use our system vim dir
sed -e "/^# define SYS_VIMRC_FILE/s|\$VIM|${EPREFIX}/etc/vim|" \
-i src/nvim/globals.h || die
# https://forums.gentoo.org/viewtopic-p-8750050.html
xdg_environment_reset
cmake_src_prepare
}
src_configure() {
# Upstream default to LTO on non-debug builds
# Let's expose it as a USE flag because upstream
# have preferences for how we should use LTO
# if we want it on (not just -flto)
# ... but allow turning it off.
# TODO: Investigate USE_BUNDLED, doesn't seem to be needed right now
local mycmakeargs=(
-DENABLE_LTO=$(usex lto)
-DPREFER_LUA=$(usex lua_single_target_luajit no "$(lua_get_version)")
-DLUA_PRG="${ELUA}"
)
cmake_src_configure
}
src_install() {
cmake_src_install
# install a default configuration file
insinto /etc/vim
doins "${FILESDIR}"/sysinit.vim
# conditionally install a symlink for nvimpager
if use nvimpager; then
dosym ../share/nvim/runtime/macros/less.sh /usr/bin/nvimpager
fi
}
pkg_postinst() {
xdg_pkg_postinst
optfeature "clipboard support" x11-misc/xsel x11-misc/xclip gui-apps/wl-clipboard
optfeature "Python plugin support" dev-python/pynvim
optfeature "Ruby plugin support" dev-ruby/neovim-ruby-client
optfeature "remote/nvr support" dev-python/neovim-remote
}

@ -40,7 +40,7 @@ BDEPEND="${LUA_DEPS}
# Check https://github.com/neovim/neovim/blob/master/third-party/CMakeLists.txt for
# new dependency bounds and so on on bumps (obviously adjust for right branch/tag).
DEPEND="${LUA_DEPS}
>=dev-lua/luv-1.44.2[${LUA_SINGLE_USEDEP}]
>=dev-lua/luv-1.45.0[${LUA_SINGLE_USEDEP}]
$(lua_gen_cond_dep '
dev-lua/lpeg[${LUA_USEDEP}]
dev-lua/mpack[${LUA_USEDEP}]
@ -48,8 +48,8 @@ DEPEND="${LUA_DEPS}
$(lua_gen_cond_dep '
dev-lua/LuaBitOp[${LUA_USEDEP}]
' lua5-{1,2})
>=dev-libs/libuv-1.44.2:=
>=dev-libs/libvterm-0.3
>=dev-libs/libuv-1.46.0:=
>=dev-libs/libvterm-0.3.3
>=dev-libs/msgpack-3.0.0:=
>=dev-libs/tree-sitter-0.20.8:=
>=dev-libs/libtermkey-0.22

Binary file not shown.

@ -1 +0,0 @@
DIST libvirt-snmp-0.0.4.tar.gz 157859 BLAKE2B e2c8fcdd97ba9b55bd4d318c63f7738024c1360ee10aa4e685c2ea6ca02478206febff30f3e1a82eb1a2dadaa52a377cfbce538e12e33f4ea2fe10b1a089945d SHA512 dbf47e7983f9bd6fcff205fffd1f6006268cca774cf427d39dec84dc7de37b545c0dfcbb2c6f171f55d73487cdec13341097137e24de2dea58ce90494d281162

@ -1,6 +0,0 @@
# Specify the URI where your libvirt instance is listening
LIBVIRT_DEFAULT_URI="qemu:///system"
# additional options
LIBVIRT_SNMP_OPTIONS=""

@ -1,26 +0,0 @@
#!/sbin/openrc-run
# Copyright 1999-2012 Gentoo Foundation
# Distributed under the terms of the GNU General Public License v2
depend() {
need snmpd
use snmptrapd
use libvirtd
}
start() {
ebegin "Starting libvirt subagent"
start-stop-daemon --start \
--env LIBVIRT_DEFAULT_URI="${LIBVIRT_DEFAULT_URI}" \
--exec /usr/bin/libvirtMib_subagent \
-- ${LIBVIRT_SNMP_OPTIONS}
eend $?
}
stop() {
ebegin "Stopping libvirt subagent"
# "--exec /usr/bin/libvirtMib_subagent" does not work and the name gets truncated
start-stop-daemon --stop \
--name libvirtMib_suba
eend $?
}

@ -1,38 +0,0 @@
# Copyright 1999-2023 Gentoo Authors
# Distributed under the terms of the GNU General Public License v2
EAPI=7
DESCRIPTION="Provides SNMP functionality for libvirt"
HOMEPAGE="https://wiki.libvirt.org/Libvirt-snmp.html"
SRC_URI="https://download.libvirt.org/snmp/${P}.tar.gz"
LICENSE="GPL-2"
SLOT="0"
KEYWORDS="amd64 x86"
IUSE=""
DEPEND=""
RDEPEND="${DEPEND}
app-emulation/libvirt
net-analyzer/net-snmp"
BDEPEND="
virtual/pkgconfig"
src_install() {
default
newinitd "${FILESDIR}/libvirt-snmp.initd-r1" "${PN}"
newconfd "${FILESDIR}/libvirt-snmp.confd" "${PN}"
}
pkg_postinst() {
elog "This daemon runs as an AgentX sub-daemon for snmpd. You should therefore"
elog "enable the AgentX functionality in snmpd by specifying the following"
elog "in /etc/snmp/snmpd.conf:"
elog " master agentx"
elog "It is further recommended to send traps to the localhost as well using"
elog "this option:"
elog " trap2sink localhost"
elog "More information is available here:"
elog " http://wiki.libvirt.org/page/Libvirt-snmp"
}

@ -1,8 +0,0 @@
<?xml version="1.0" encoding="UTF-8"?>
<!DOCTYPE pkgmetadata SYSTEM "https://www.gentoo.org/dtd/metadata.dtd">
<pkgmetadata>
<!-- maintainer-needed -->
<upstream>
<remote-id type="gitlab">libvirt/libvirt-snmp</remote-id>
</upstream>
</pkgmetadata>

@ -3,10 +3,13 @@ DIST qemu-7.2.0.tar.xz 122408576 BLAKE2B 415ff621356c59f88b29cfe3ef5db1e282b26bb
DIST qemu-7.2.1.tar.xz 122400592 BLAKE2B bae1df5d332beaca313c4bac88f06dd5992988d7c1b6fdc6ced4043d858f437339cd7d0009ae667f9e66705117697bee7ee44ec4e911cc203d34eecc3d8f139b SHA512 e286dc66c923a5df77eb02d69235d048e80a7cced638fae52fbed385b4c3cd736cfea66bb3c9843bebf0a33e81ea141fc015e0bd82108df304f148ce59d9ae8a
DIST qemu-7.2.3.tar.xz 122395692 BLAKE2B 4e65cac7505a56da85c1d98dc6029d516dd4f07f0211ea5213724d231d448d9b49cc91a3058a2a89908608078854d97da480e6f0bc7ce47d9555c2bb1177fbdc SHA512 09523d456175da47d58d8d56fe9a95416ee3e6fd8aa7766383033396a1e5bd10f7758832f7f2b8662068ef94b21ab6a3a351c9158fb6bde0e1d7d5fb393bf6c7
DIST qemu-7.2.4.tar.xz 121849100 BLAKE2B a9c5ffce9ff0fac4e2d1fa4be1a1dcee2f5d7f793ddf726871c5ae9a68c22f7ba03692a8a5096de3051030d3c2f34e46697d5af2d66c34984b8161ae3bb07b42 SHA512 fa765673833a1f2cbecdb9d47dc7dc29d7613be5a5c8fc63925ae70e1f5aafb4f9f02e45b212a329f17b689351b8a9cdf5f5235ab6adb71bb40e41868898d95b
DIST qemu-7.2.6.tar.xz 121322888 BLAKE2B c3f51cc1647f5c75774513f624c2e1a1e4badd7275c9f9a64a175809daf17d0b3c58eab0c36fa98fc46834d4d79f8552d1c9f34e840ee21ddd049cc3adba480a SHA512 534fffe2d751a707a7cf15db8d5b9eddc2468fd7fe875715e79ee879fb20d7370553588384d345b586eeaddf9284de36f2d0d69f747380ee55161cc6eb09bf30
DIST qemu-8.0.0-docs.tar.xz 3218024 BLAKE2B b764a625024e78a39470048355471e12cfb57ab3c34e764dc4200fdf5c1aea635d26095ec961979bf46f177101c5bd38618bacf7e98e04bd64688ab5e29591aa SHA512 d9dfe191372e105fe16fe8f66f41ed793ade4c89b5ab1d84b39459f3419a1ca61bd49422a83981965cc257c05eca7fd49054703f58f179f5c7b656e9473a1054
DIST qemu-8.0.0.tar.xz 127835148 BLAKE2B 9b54aae10fe09691a26e68374723ded5fdda6409673b4de9461a25ee060cfd03968a16ddeadc21d48b9262e53aa6d4e5eb645376969f97c65807fad19607b04f SHA512 1f31d1e653dec2d35f1b7a5468ee3f471553b48eca8c8afafffcf9243c6b2260e78a5b73da3fe567f9b85d4133573eebd397747b3aec501fb24076263eb07b27
DIST qemu-8.0.2.tar.xz 126707132 BLAKE2B f2b1a63e10c42aabfe39722c7732d0f04818ad367b769b3deb29c5bf9adcabc3aca1706f3c40fafeeb57ac1f7a61ded5066de32134c483e2fd27bc65b4b7d30a SHA512 4e915d33a662bf55b09247fb85150be376c92270d3764e3d6470c452cb70cc558f54e84de5610dd60a9eb3ea02d5d4277b1ec75c9804967d278fa8361c7f9b9a
DIST qemu-8.0.3.tar.xz 126710536 BLAKE2B 071cc1a35209a02e8c5dd4f43cb112f110b4655adb0f870a04fdf9a6e2c761699574e8c9426f70f60787a99acf252d7a64d94a8e837cdfeda93d89428d7866f3 SHA512 18b2ccb65f7ec2ae92f0e04406539620c881e2b75f63816588c86043a07464bb99d16a83e792ed9508de393f4b694c46d52f4d07edf52741e85224c8b8d5d5c3
DIST qemu-8.0.4.tar.xz 126179324 BLAKE2B dfb98964c629b251f0004b4630ae4500a52465579417d6f5c7dbbb1f672e10d8d7ffb98a4b00e26fb98b3c867208146dbdca026e4d30cbf1752ac733c4d9b915 SHA512 bd5ed682d51f974abd4be93f949701f9b5bfb87fd9929e31df130534da2f2c03b99adc9f924b3efd47d3b254e0e3c0046f4e69fbe9f6d0c4ac1f6babecb29449
DIST qemu-8.0.5.tar.xz 126175064 BLAKE2B 1d1f78c185ab64b4ca946a44ad04d0bbb6ea48de058037e4ba18176abeb0f0528754c6e832f742f93227182bbce145544eca5b908a366006e7ee58876aca0bda SHA512 ec9679473dda84a2f56ae8ee0039ec4dafb056414bfc5a3a147b2b6bb45ae3b130dd80f6385e8567b5d18f4be94f3536bc8acc45c61eddf40c9678b46cb8bddc
DIST qemu-8.1.0-docs.tar.xz 2129912 BLAKE2B 8aaf7b748538afdb5bcb6da15dbd96572d086824377c4b0e93f1ddc695f9a4775471e360a9616d2d481dbf8113e91d2601c69d92cef565fb90b65ffacfdb304e SHA512 905515742bb56a439fc8117ec48ea668e7b2bf0244587673e4352d9e8e49911eb84ff093596ff566e44787197cf9789ec8950e3d75fb7a670c5546394a322ac9
DIST qemu-8.1.0.tar.xz 123550284 BLAKE2B b0fd87a19b13d4bbc6526caa46533073cb4dee6004df5d4fbbef204ee3bc8c2f10ec1eaff554adbb25c9f3143dd68abd09d4a0519c4766299a3ff261d03c73f2 SHA512 c5f5e7ce2d8e3c93a02012b136c866e8577df07da4705a0045916c71caeaa21fa1b2d59a4b22a660789a4159b192e12a443e7cbb0724ee85fea258251731724c
DIST qemu-8.1.1.tar.xz 123558860 BLAKE2B 71220fad7c9f74bed6211879f01566ac1e52835feb3d45eaa1b2fe1d5f95d9fa5db53b7aec72b4ef098c03d0c4070076c907fb3e6b839002de6f56ee5ab44340 SHA512 199db58f9a413cbe4449ff557bc362e666c6c0291f9963cb74e5542e8abd1edcd65001fa1fd453b850a376de455f93258707ce6feee5a44bf40753b12a2e956c

@ -0,0 +1,972 @@
# Copyright 1999-2023 Gentoo Authors
# Distributed under the terms of the GNU General Public License v2
EAPI=8
# Generate using https://github.com/thesamesam/sam-gentoo-scripts/blob/main/niche/generate-qemu-docs
# Set to 1 if prebuilt, 0 if not
# (the construct below is to allow overriding from env for script)
QEMU_DOCS_PREBUILT=${QEMU_DOCS_PREBUILT:-1}
QEMU_DOCS_PREBUILT_DEV=ajak
QEMU_DOCS_VERSION="7.2.0"
# Default to generating docs (inc. man pages) if no prebuilt; overridden later
# bug #830088
QEMU_DOC_USEFLAG="+doc"
PYTHON_COMPAT=( python3_{9,10,11} )
PYTHON_REQ_USE="ncurses,readline"
FIRMWARE_ABI_VERSION="7.2.0"
inherit linux-info toolchain-funcs python-r1 udev fcaps readme.gentoo-r1 \
pax-utils xdg-utils
if [[ ${PV} == *9999* ]]; then
QEMU_DOCS_PREBUILT=0
EGIT_REPO_URI="https://gitlab.com/qemu-project/qemu.git/"
EGIT_SUBMODULES=(
tests/fp/berkeley-softfloat-3
tests/fp/berkeley-testfloat-3
ui/keycodemapdb
)
inherit git-r3
SRC_URI=""
else
MY_P="${PN}-${PV/_rc/-rc}"
SRC_URI="https://download.qemu.org/${MY_P}.tar.xz"
if [[ ${QEMU_DOCS_PREBUILT} == 1 ]] ; then
SRC_URI+=" !doc? ( https://dev.gentoo.org/~${QEMU_DOCS_PREBUILT_DEV}/distfiles/${CATEGORY}/${PN}/${PN}-${QEMU_DOCS_VERSION}-docs.tar.xz )"
fi
S="${WORKDIR}/${MY_P}"
[[ "${PV}" != *_rc* ]] && KEYWORDS="~amd64 ~arm ~arm64 ~loong ~ppc ~ppc64 ~riscv ~x86"
fi
DESCRIPTION="QEMU + Kernel-based Virtual Machine userland tools"
HOMEPAGE="https://www.qemu.org https://www.linux-kvm.org"
LICENSE="GPL-2 LGPL-2 BSD-2"
SLOT="0"
[[ ${QEMU_DOCS_PREBUILT} == 1 ]] && QEMU_DOC_USEFLAG="doc"
IUSE="accessibility +aio alsa bpf bzip2 capstone +curl debug ${QEMU_DOC_USEFLAG}
+fdt fuse glusterfs +gnutls gtk infiniband iscsi io-uring
jack jemalloc +jpeg
lzo multipath
ncurses nfs nls numa opengl +oss pam +pin-upstream-blobs
plugins +png pulseaudio python rbd sasl +seccomp sdl sdl-image selinux
+slirp
smartcard snappy spice ssh static static-user systemtap test udev usb
usbredir vde +vhost-net virgl virtfs +vnc vte xattr xen
zstd"
COMMON_TARGETS="
aarch64
alpha
arm
cris
hppa
i386
loongarch64
m68k
microblaze
microblazeel
mips
mips64
mips64el
mipsel
nios2
or1k
ppc
ppc64
riscv32
riscv64
s390x
sh4
sh4eb
sparc
sparc64
x86_64
xtensa
xtensaeb
"
IUSE_SOFTMMU_TARGETS="
${COMMON_TARGETS}
avr
rx
tricore
"
IUSE_USER_TARGETS="
${COMMON_TARGETS}
aarch64_be
armeb
hexagon
mipsn32
mipsn32el
ppc64le
sparc32plus
"
use_softmmu_targets=$(printf ' qemu_softmmu_targets_%s' ${IUSE_SOFTMMU_TARGETS})
use_user_targets=$(printf ' qemu_user_targets_%s' ${IUSE_USER_TARGETS})
IUSE+=" ${use_softmmu_targets} ${use_user_targets}"
RESTRICT="!test? ( test )"
# Allow no targets to be built so that people can get a tools-only build.
# Block USE flag configurations known to not work.
REQUIRED_USE="
${PYTHON_REQUIRED_USE}
qemu_softmmu_targets_arm? ( fdt )
qemu_softmmu_targets_microblaze? ( fdt )
qemu_softmmu_targets_mips64el? ( fdt )
qemu_softmmu_targets_ppc64? ( fdt )
qemu_softmmu_targets_ppc? ( fdt )
qemu_softmmu_targets_riscv32? ( fdt )
qemu_softmmu_targets_riscv64? ( fdt )
qemu_softmmu_targets_x86_64? ( fdt )
sdl-image? ( sdl )
static? ( static-user !alsa !gtk !jack !opengl !pam !pulseaudio !plugins !rbd !snappy !udev )
static-user? ( !plugins )
virgl? ( opengl )
virtfs? ( xattr )
vnc? ( gnutls )
vte? ( gtk )
multipath? ( udev )
plugins? ( !static !static-user )
"
for smname in ${IUSE_SOFTMMU_TARGETS} ; do
REQUIRED_USE+=" qemu_softmmu_targets_${smname}? ( seccomp ) "
done
# Dependencies required for qemu tools (qemu-nbd, qemu-img, qemu-io, ...)
# and user/softmmu targets (qemu-*, qemu-system-*).
#
# Yep, you need both libcap and libcap-ng since virtfs only uses libcap.
#
# The attr lib isn't always linked in (although the USE flag is always
# respected). This is because qemu supports using the C library's API
# when available rather than always using the external library.
ALL_DEPEND="
dev-libs/glib:2[static-libs(+)]
sys-libs/zlib[static-libs(+)]
python? ( ${PYTHON_DEPS} )
systemtap? ( dev-util/systemtap )
xattr? ( sys-apps/attr[static-libs(+)] )"
# Dependencies required for qemu tools (qemu-nbd, qemu-img, qemu-io, ...)
# softmmu targets (qemu-system-*).
SOFTMMU_TOOLS_DEPEND="
sys-libs/libcap-ng[static-libs(+)]
>=x11-libs/pixman-0.28.0[static-libs(+)]
accessibility? (
app-accessibility/brltty[api]
app-accessibility/brltty[static-libs(+)]
)
aio? ( dev-libs/libaio[static-libs(+)] )
alsa? ( >=media-libs/alsa-lib-1.0.13 )
bpf? ( dev-libs/libbpf:= )
bzip2? ( app-arch/bzip2[static-libs(+)] )
capstone? ( dev-libs/capstone:=[static-libs(+)] )
curl? ( >=net-misc/curl-7.15.4[static-libs(+)] )
fdt? ( >=sys-apps/dtc-1.5.1[static-libs(+)] )
fuse? ( >=sys-fs/fuse-3.1:3[static-libs(+)] )
glusterfs? ( >=sys-cluster/glusterfs-3.4.0[static-libs(+)] )
gnutls? (
>=net-libs/gnutls-3.0:=[static-libs(+)]
dev-libs/nettle:=[static-libs(+)]
)
gtk? (
x11-libs/cairo
x11-libs/gdk-pixbuf:2
x11-libs/gtk+:3
x11-libs/libX11
vte? ( x11-libs/vte:2.91 )
)
infiniband? ( sys-cluster/rdma-core[static-libs(+)] )
iscsi? ( net-libs/libiscsi )
io-uring? ( sys-libs/liburing:=[static-libs(+)] )
jack? ( virtual/jack )
jemalloc? ( dev-libs/jemalloc )
jpeg? ( media-libs/libjpeg-turbo:=[static-libs(+)] )
lzo? ( dev-libs/lzo:2[static-libs(+)] )
multipath? ( sys-fs/multipath-tools )
ncurses? (
sys-libs/ncurses:=[unicode(+)]
sys-libs/ncurses:=[static-libs(+)]
)
nfs? ( >=net-fs/libnfs-1.9.3:=[static-libs(+)] )
numa? ( sys-process/numactl[static-libs(+)] )
opengl? (
virtual/opengl
media-libs/libepoxy[static-libs(+)]
media-libs/mesa[static-libs(+)]
media-libs/mesa[egl(+),gbm(+)]
)
pam? ( sys-libs/pam )
png? ( media-libs/libpng:0=[static-libs(+)] )
pulseaudio? ( media-libs/libpulse )
rbd? ( sys-cluster/ceph )
sasl? ( dev-libs/cyrus-sasl[static-libs(+)] )
sdl? (
media-libs/libsdl2[video]
media-libs/libsdl2[static-libs(+)]
)
sdl-image? ( media-libs/sdl2-image[static-libs(+)] )
seccomp? ( >=sys-libs/libseccomp-2.1.0[static-libs(+)] )
slirp? ( net-libs/libslirp[static-libs(+)] )
smartcard? ( >=app-emulation/libcacard-2.5.0[static-libs(+)] )
snappy? ( app-arch/snappy:= )
spice? (
>=app-emulation/spice-protocol-0.12.3
>=app-emulation/spice-0.12.0[static-libs(+)]
)
ssh? ( >=net-libs/libssh-0.8.6[static-libs(+)] )
udev? ( virtual/libudev:= )
usb? ( >=virtual/libusb-1-r2:1[static-libs(+)] )
usbredir? ( >=sys-apps/usbredir-0.6[static-libs(+)] )
vde? ( net-misc/vde[static-libs(+)] )
virgl? ( media-libs/virglrenderer[static-libs(+)] )
virtfs? ( sys-libs/libcap )
xen? ( app-emulation/xen-tools:= )
zstd? ( >=app-arch/zstd-1.4.0[static-libs(+)] )
"
EDK2_OVMF_VERSION="202202"
SEABIOS_VERSION="1.16.0"
X86_FIRMWARE_DEPEND="
pin-upstream-blobs? (
~sys-firmware/edk2-ovmf-bin-${EDK2_OVMF_VERSION}
~sys-firmware/ipxe-1.21.1[binary,qemu]
~sys-firmware/seabios-bin-${SEABIOS_VERSION}
~sys-firmware/sgabios-0.1_pre10[binary]
)
!pin-upstream-blobs? (
|| (
>=sys-firmware/edk2-ovmf-${EDK2_OVMF_VERSION}
>=sys-firmware/edk2-ovmf-bin-${EDK2_OVMF_VERSION}
)
sys-firmware/ipxe[qemu]
|| (
>=sys-firmware/seabios-${SEABIOS_VERSION}[seavgabios]
>=sys-firmware/seabios-bin-${SEABIOS_VERSION}
)
sys-firmware/sgabios
)"
PPC_FIRMWARE_DEPEND="
pin-upstream-blobs? (
~sys-firmware/seabios-bin-${SEABIOS_VERSION}
)
!pin-upstream-blobs? (
|| (
>=sys-firmware/seabios-${SEABIOS_VERSION}[seavgabios]
>=sys-firmware/seabios-bin-${SEABIOS_VERSION}
)
)
"
BDEPEND="
$(python_gen_impl_dep)
dev-lang/perl
dev-util/meson
sys-apps/texinfo
virtual/pkgconfig
doc? (
dev-python/sphinx[${PYTHON_USEDEP}]
dev-python/sphinx-rtd-theme[${PYTHON_USEDEP}]
)
gtk? ( nls? ( sys-devel/gettext ) )
test? (
dev-libs/glib[utils]
sys-devel/bc
)
"
CDEPEND="
!static? (
${ALL_DEPEND//\[static-libs(+)]}
${SOFTMMU_TOOLS_DEPEND//\[static-libs(+)]}
)
qemu_softmmu_targets_i386? ( ${X86_FIRMWARE_DEPEND} )
qemu_softmmu_targets_x86_64? ( ${X86_FIRMWARE_DEPEND} )
qemu_softmmu_targets_ppc? ( ${PPC_FIRMWARE_DEPEND} )
qemu_softmmu_targets_ppc64? ( ${PPC_FIRMWARE_DEPEND} )
"
DEPEND="${CDEPEND}
kernel_linux? ( >=sys-kernel/linux-headers-2.6.35 )
static? (
${ALL_DEPEND}
${SOFTMMU_TOOLS_DEPEND}
)
static-user? ( ${ALL_DEPEND} )"
RDEPEND="${CDEPEND}
acct-group/kvm
selinux? (
sec-policy/selinux-qemu
sys-libs/libselinux
)"
PATCHES=(
"${FILESDIR}"/${PN}-5.2.0-disable-keymap.patch
"${FILESDIR}"/${PN}-6.0.0-make.patch
"${FILESDIR}"/${PN}-7.1.0-also-build-virtfs-proxy-helper.patch
"${FILESDIR}"/${PN}-7.1.0-capstone-include-path.patch
"${FILESDIR}"/${PN}-7.2.0-disable-gmp.patch
"${FILESDIR}"/${PN}-7.2.0-linux-headers-6.2-glibc-2.36.patch
)
QA_PREBUILT="
usr/share/qemu/hppa-firmware.img
usr/share/qemu/openbios-ppc
usr/share/qemu/openbios-sparc64
usr/share/qemu/openbios-sparc32
usr/share/qemu/opensbi-riscv64-generic-fw_dynamic.elf
usr/share/qemu/opensbi-riscv32-generic-fw_dynamic.elf
usr/share/qemu/palcode-clipper
usr/share/qemu/s390-ccw.img
usr/share/qemu/s390-netboot.img
usr/share/qemu/u-boot.e500
"
QA_WX_LOAD="usr/bin/qemu-i386
usr/bin/qemu-x86_64
usr/bin/qemu-alpha
usr/bin/qemu-arm
usr/bin/qemu-cris
usr/bin/qemu-m68k
usr/bin/qemu-microblaze
usr/bin/qemu-microblazeel
usr/bin/qemu-mips
usr/bin/qemu-mipsel
usr/bin/qemu-or1k
usr/bin/qemu-ppc
usr/bin/qemu-ppc64
usr/bin/qemu-sh4
usr/bin/qemu-sh4eb
usr/bin/qemu-sparc
usr/bin/qemu-sparc64
usr/bin/qemu-armeb
usr/bin/qemu-sparc32plus
usr/bin/qemu-s390x
usr/bin/qemu-unicore32
"
DOC_CONTENTS="If you don't have kvm compiled into the kernel, make sure you have the
kernel module loaded before running kvm. The easiest way to ensure that the
kernel module is loaded is to load it on boot.
For AMD CPUs the module is called 'kvm-amd'.
For Intel CPUs the module is called 'kvm-intel'.
Please review /etc/conf.d/modules for how to load these.
Make sure your user is in the 'kvm' group. Just run
$ gpasswd -a <USER> kvm
then have <USER> re-login.
For brand new installs, the default permissions on /dev/kvm might not let
you access it. You can tell udev to reset ownership/perms:
$ udevadm trigger -c add /dev/kvm
If you want to register binfmt handlers for qemu user targets:
For openrc:
# rc-update add qemu-binfmt
For systemd:
# ln -s /usr/share/qemu/binfmt.d/qemu.conf /etc/binfmt.d/qemu.conf"
pkg_pretend() {
if use kernel_linux && kernel_is lt 2 6 25; then
eerror "This version of KVM requires a host kernel of 2.6.25 or higher."
elif use kernel_linux; then
if ! linux_config_exists; then
eerror "Unable to check your kernel for KVM support"
else
CONFIG_CHECK="~KVM ~TUN ~BRIDGE"
ERROR_KVM="You must enable KVM in your kernel to continue"
ERROR_KVM_AMD="If you have an AMD CPU, you must enable KVM_AMD in"
ERROR_KVM_AMD+=" your kernel configuration."
ERROR_KVM_INTEL="If you have an Intel CPU, you must enable"
ERROR_KVM_INTEL+=" KVM_INTEL in your kernel configuration."
ERROR_TUN="You will need the Universal TUN/TAP driver compiled"
ERROR_TUN+=" into your kernel or loaded as a module to use the"
ERROR_TUN+=" virtual network device if using -net tap."
ERROR_BRIDGE="You will also need support for 802.1d"
ERROR_BRIDGE+=" Ethernet Bridging for some network configurations."
use vhost-net && CONFIG_CHECK+=" ~VHOST_NET"
ERROR_VHOST_NET="You must enable VHOST_NET to have vhost-net"
ERROR_VHOST_NET+=" support"
if use amd64 || use x86 || use amd64-linux || use x86-linux; then
if grep -q AuthenticAMD /proc/cpuinfo; then
CONFIG_CHECK+=" ~KVM_AMD"
elif grep -q GenuineIntel /proc/cpuinfo; then
CONFIG_CHECK+=" ~KVM_INTEL"
fi
fi
use python && CONFIG_CHECK+=" ~DEBUG_FS"
ERROR_DEBUG_FS="debugFS support required for kvm_stat"
# Now do the actual checks setup above
check_extra_config
fi
fi
if grep -qs '/usr/bin/qemu-kvm' "${EROOT}"/etc/libvirt/qemu/*.xml; then
eerror "The kvm/qemu-kvm wrappers no longer exist, but your libvirt"
eerror "instances are still pointing to it. Please update your"
eerror "configs in /etc/libvirt/qemu/ to use the -enable-kvm flag"
eerror "and the right system binary (e.g. qemu-system-x86_64)."
die "update your virt configs to not use qemu-kvm"
fi
}
# Sanity check to make sure target lists are kept up-to-date.
check_targets() {
local var=$1 mak=$2
local detected sorted
pushd "${S}"/configs/targets/ >/dev/null || die
# Force C locale until glibc is updated. #564936
detected=$(echo $(printf '%s\n' *-${mak}.mak | sed "s:-${mak}.mak::" | LC_COLLATE=C sort -u))
sorted=$(echo $(printf '%s\n' ${!var} | LC_COLLATE=C sort -u))
if [[ ${sorted} != "${detected}" ]] ; then
eerror "The ebuild needs to be kept in sync."
eerror "${var}: ${sorted}"
eerror "$(printf '%-*s' ${#var} configure): ${detected}"
die "sync ${var} to the list of targets"
fi
popd >/dev/null
}
src_prepare() {
check_targets IUSE_SOFTMMU_TARGETS softmmu
check_targets IUSE_USER_TARGETS linux-user
default
# Use correct toolchain to fix cross-compiling
tc-export AR AS LD NM OBJCOPY PKG_CONFIG RANLIB STRINGS
export WINDRES=${CHOST}-windres
# Verbose builds
MAKEOPTS+=" V=1"
# We already force -D_FORTIFY_SOURCE=2 (or 3) in our toolchain, but
# this setting (-U then -D..=2) will prevent us from trying out 3, so
# drop it. No change to level of protection b/c we patch our toolchain.
sed -i -e 's/-U_FORTIFY_SOURCE -D_FORTIFY_SOURCE=2//' configure || die
# Remove bundled modules
rm -r dtc meson roms/*/ || die
}
##
# configures qemu based on the build directory and the build type
# we are using.
#
qemu_src_configure() {
debug-print-function ${FUNCNAME} "$@"
local buildtype=$1
local builddir="${S}/${buildtype}-build"
mkdir "${builddir}" || die
local conf_opts=(
--prefix=/usr
--sysconfdir=/etc
--bindir=/usr/bin
--libdir=/usr/$(get_libdir)
--datadir=/usr/share
--docdir=/usr/share/doc/${PF}/html
--mandir=/usr/share/man
--localstatedir=/var
--disable-bsd-user
--disable-containers # bug #732972
--disable-guest-agent
--disable-strip
--with-git-submodules=ignore
# bug #746752: TCG interpreter has a few limitations:
# - it does not support FPU
# - it's generally slower on non-self-modifying code
# It's advantage is support for host architectures
# where native codegeneration is not implemented.
# Gentoo has qemu keyworded only on targets with
# native code generation available. Avoid the interpreter.
--disable-tcg-interpreter
--disable-werror
# We support gnutls/nettle for crypto operations. It is possible
# to use gcrypt when gnutls/nettle are disabled (but not when they
# are enabled), but it's not really worth the hassle. Disable it
# all the time to avoid automatically detecting it. #568856
--disable-gcrypt
--cc="$(tc-getCC)"
--cxx="$(tc-getCXX)"
--host-cc="$(tc-getBUILD_CC)"
$(use_enable alsa)
$(use_enable debug debug-info)
$(use_enable debug debug-tcg)
$(use_enable jack)
$(use_enable nls gettext)
$(use_enable oss)
$(use_enable plugins)
$(use_enable pulseaudio pa)
$(use_enable selinux)
$(use_enable xattr attr)
)
# Disable options not used by user targets. This simplifies building
# static user targets (USE=static-user) considerably.
conf_notuser() {
if [[ ${buildtype} == "user" ]] ; then
echo "--disable-${2:-$1}"
else
use_enable "$@"
fi
}
# Enable option only for softmmu build, but not 'user' or 'tools'
conf_softmmu() {
if [[ ${buildtype} == "softmmu" ]] ; then
use_enable "$@"
else
echo "--disable-${2:-$1}"
fi
}
# Enable option only for tools build, but not 'user' or 'softmmu'
conf_tools() {
if [[ ${buildtype} == "tools" ]] ; then
use_enable "$@"
else
echo "--disable-${2:-$1}"
fi
}
# Special case for the malloc flag, because the --disable flag does
# not exist and trying like above will break configuring.
conf_malloc() {
if [[ ! ${buildtype} == "user" ]] ; then
usex "${1}" "--enable-malloc=${1}" ""
fi
}
conf_opts+=(
$(conf_notuser accessibility brlapi)
$(conf_notuser aio linux-aio)
$(conf_softmmu bpf)
$(conf_notuser bzip2)
$(conf_notuser capstone)
$(conf_notuser curl)
$(conf_tools doc docs)
$(conf_notuser fdt)
$(conf_notuser fuse)
$(conf_notuser glusterfs)
$(conf_notuser gnutls)
$(conf_notuser gnutls nettle)
$(conf_notuser gtk)
$(conf_notuser infiniband rdma)
$(conf_notuser iscsi libiscsi)
$(conf_notuser io-uring linux-io-uring)
$(conf_malloc jemalloc)
$(conf_notuser jpeg vnc-jpeg)
$(conf_notuser kernel_linux kvm)
$(conf_notuser lzo)
$(conf_notuser multipath mpath)
$(conf_notuser ncurses curses)
$(conf_notuser nfs libnfs)
$(conf_notuser numa)
$(conf_notuser opengl)
$(conf_notuser pam auth-pam)
$(conf_notuser png)
$(conf_notuser rbd)
$(conf_notuser sasl vnc-sasl)
$(conf_notuser sdl)
$(conf_softmmu sdl-image)
$(conf_notuser seccomp)
$(conf_notuser slirp)
$(conf_notuser smartcard)
$(conf_notuser snappy)
$(conf_notuser spice)
$(conf_notuser ssh libssh)
$(conf_notuser udev libudev)
$(conf_notuser usb libusb)
$(conf_notuser usbredir usb-redir)
$(conf_notuser vde)
$(conf_notuser vhost-net)
$(conf_notuser virgl virglrenderer)
$(conf_softmmu virtfs)
$(conf_notuser vnc)
$(conf_notuser vte)
$(conf_notuser xen)
$(conf_notuser xen xen-pci-passthrough)
# use prebuilt keymaps, bug #759604
--disable-xkbcommon
$(conf_notuser zstd)
)
if [[ ! ${buildtype} == "user" ]] ; then
# audio options
local audio_opts=(
# Note: backend order matters here: #716202
# We iterate from higher-level to lower level.
$(usex pulseaudio pa "")
$(usev jack)
$(usev sdl)
$(usev alsa)
$(usev oss)
)
conf_opts+=(
--audio-drv-list=$(IFS=,; echo "${audio_opts[*]}")
)
fi
case ${buildtype} in
user)
conf_opts+=(
--enable-linux-user
--disable-system
--disable-blobs
--disable-tools
--disable-cap-ng
--disable-seccomp
)
local static_flag="static-user"
;;
softmmu)
conf_opts+=(
--disable-linux-user
--enable-system
--disable-tools
--enable-cap-ng
--enable-seccomp
)
local static_flag="static"
;;
tools)
conf_opts+=(
--disable-linux-user
--disable-system
--disable-blobs
--enable-tools
--enable-cap-ng
)
local static_flag="static"
;;
esac
local targets="${buildtype}_targets"
[[ -n ${targets} ]] && conf_opts+=( --target-list="${!targets}" )
# Add support for SystemTAP
use systemtap && conf_opts+=( --enable-trace-backend=dtrace )
# We always want to attempt to build with PIE support as it results
# in a more secure binary. But it doesn't work with static or if
# the current GCC doesn't have PIE support.
if use ${static_flag}; then
conf_opts+=( --static --disable-pie )
else
tc-enables-pie && conf_opts+=( --enable-pie )
fi
# Meson will not use a cross-file unless cross_prefix is set.
tc-is-cross-compiler && conf_opts+=( --cross-prefix="${CHOST}-" )
# Plumb through equivalent of EXTRA_ECONF to allow experiments
# like bug #747928.
conf_opts+=( ${EXTRA_CONF_QEMU} )
echo "../configure ${conf_opts[*]}"
cd "${builddir}"
../configure "${conf_opts[@]}" || die "configure failed"
}
src_configure() {
local target
python_setup
softmmu_targets= softmmu_bins=()
user_targets= user_bins=()
for target in ${IUSE_SOFTMMU_TARGETS} ; do
if use "qemu_softmmu_targets_${target}"; then
softmmu_targets+=",${target}-softmmu"
softmmu_bins+=( "qemu-system-${target}" )
fi
done
for target in ${IUSE_USER_TARGETS} ; do
if use "qemu_user_targets_${target}"; then
user_targets+=",${target}-linux-user"
user_bins+=( "qemu-${target}" )
fi
done
softmmu_targets=${softmmu_targets#,}
user_targets=${user_targets#,}
[[ -n ${softmmu_targets} ]] && qemu_src_configure "softmmu"
[[ -n ${user_targets} ]] && qemu_src_configure "user"
qemu_src_configure "tools"
}
src_compile() {
if [[ -n ${user_targets} ]]; then
cd "${S}/user-build" || die
default
fi
if [[ -n ${softmmu_targets} ]]; then
cd "${S}/softmmu-build" || die
default
fi
cd "${S}/tools-build" || die
default
}
src_test() {
if [[ -n ${softmmu_targets} ]]; then
cd "${S}/softmmu-build" || die
pax-mark m */qemu-system-* #515550
emake check
fi
}
qemu_python_install() {
python_domodule "${S}/python/qemu"
python_doscript "${S}/scripts/kvm/vmxcap"
python_doscript "${S}/scripts/qmp/qmp-shell"
python_doscript "${S}/scripts/qmp/qemu-ga-client"
}
# Generate binfmt support files.
# - /etc/init.d/qemu-binfmt script which registers the user handlers (openrc)
# - /usr/share/qemu/binfmt.d/qemu.conf (for use with systemd-binfmt)
generate_initd() {
local out="${T}/qemu-binfmt"
local out_systemd="${T}/qemu.conf"
local d="${T}/binfmt.d"
einfo "Generating qemu binfmt scripts and configuration files"
# Generate the debian fragments first.
mkdir -p "${d}"
"${S}"/scripts/qemu-binfmt-conf.sh \
--debian \
--exportdir "${d}" \
--qemu-path "${EPREFIX}/usr/bin" \
|| die
# Then turn the fragments into a shell script we can source.
sed -E -i \
-e 's:^([^ ]+) (.*)$:\1="\2":' \
"${d}"/* || die
# Generate the init.d script by assembling the fragments from above.
local f qcpu package interpreter magic mask
cat "${FILESDIR}"/qemu-binfmt.initd.head >"${out}" || die
for f in "${d}"/qemu-* ; do
source "${f}"
# Normalize the cpu logic like we do in the init.d for the native cpu.
qcpu=${package#qemu-}
case ${qcpu} in
arm*) qcpu="arm";;
mips*) qcpu="mips";;
ppc*) qcpu="ppc";;
s390*) qcpu="s390";;
sh*) qcpu="sh";;
sparc*) qcpu="sparc";;
esac
# we use 'printf' here to be portable across 'sh'
# implementations: #679168
cat <<EOF >>"${out}"
if [ "\${cpu}" != "${qcpu}" -a -x "${interpreter}" ] ; then
printf '%s\n' ':${package}:M::${magic}:${mask}:${interpreter}:'"\${QEMU_BINFMT_FLAGS}" >/proc/sys/fs/binfmt_misc/register
fi
EOF
echo ":${package}:M::${magic}:${mask}:${interpreter}:OC" >>"${out_systemd}"
done
cat "${FILESDIR}"/qemu-binfmt.initd.tail >>"${out}" || die
}
src_install() {
if [[ -n ${user_targets} ]]; then
cd "${S}/user-build"
emake DESTDIR="${ED}" install
# Install binfmt handler init script for user targets.
generate_initd
doinitd "${T}/qemu-binfmt"
# Install binfmt/qemu.conf.
insinto "/usr/share/qemu/binfmt.d"
doins "${T}/qemu.conf"
fi
if [[ -n ${softmmu_targets} ]]; then
cd "${S}/softmmu-build"
emake DESTDIR="${ED}" install
# This might not exist if the test failed. #512010
[[ -e check-report.html ]] && dodoc check-report.html
if use kernel_linux; then
udev_newrules "${FILESDIR}"/65-kvm.rules-r2 65-kvm.rules
fi
if use python; then
python_foreach_impl qemu_python_install
fi
fi
cd "${S}/tools-build" || die
emake DESTDIR="${ED}" install
# If USE=doc, there'll be newly generated docs which we install instead.
if ! use doc && [[ ${QEMU_DOCS_PREBUILT} == 1 ]] ; then
doman "${WORKDIR}"/${PN}-${QEMU_DOCS_VERSION}-docs/docs/*.[0-8]
fi
# Disable mprotect on the qemu binaries as they use JITs to be fast #459348
pushd "${ED}"/usr/bin >/dev/null || die
pax-mark mr "${softmmu_bins[@]}" "${user_bins[@]}" # bug 575594
popd >/dev/null || die
# Install config file example for qemu-bridge-helper
insinto "/etc/qemu"
doins "${FILESDIR}/bridge.conf"
cd "${S}" || die
dodoc MAINTAINERS docs/specs/pci-ids.txt
newdoc pc-bios/README README.pc-bios
# Disallow stripping of prebuilt firmware files.
dostrip -x ${QA_PREBUILT}
if [[ -n ${softmmu_targets} ]]; then
# Remove SeaBIOS since we're using the SeaBIOS packaged one
if use qemu_softmmu_targets_x86_64 || use qemu_softmmu_targets_i386; then
dosym ../seabios/bios-256k.bin /usr/share/qemu/bios-256k.bin
fi
# Remove vgabios since we're using the seavgabios packaged one
rm "${ED}/usr/share/qemu/vgabios.bin"
rm "${ED}/usr/share/qemu/vgabios-cirrus.bin"
rm "${ED}/usr/share/qemu/vgabios-qxl.bin"
rm "${ED}/usr/share/qemu/vgabios-stdvga.bin"
rm "${ED}/usr/share/qemu/vgabios-virtio.bin"
rm "${ED}/usr/share/qemu/vgabios-vmware.bin"
# PPC/PPC64 loads vgabios-stdvga
if use qemu_softmmu_targets_x86_64 || use qemu_softmmu_targets_i386 || use qemu_softmmu_targets_ppc || use qemu_softmmu_targets_ppc64; then
dosym ../seavgabios/vgabios-isavga.bin /usr/share/qemu/vgabios.bin
dosym ../seavgabios/vgabios-cirrus.bin /usr/share/qemu/vgabios-cirrus.bin
dosym ../seavgabios/vgabios-qxl.bin /usr/share/qemu/vgabios-qxl.bin
dosym ../seavgabios/vgabios-stdvga.bin /usr/share/qemu/vgabios-stdvga.bin
dosym ../seavgabios/vgabios-virtio.bin /usr/share/qemu/vgabios-virtio.bin
dosym ../seavgabios/vgabios-vmware.bin /usr/share/qemu/vgabios-vmware.bin
fi
# Remove sgabios since we're using the sgabios packaged one
if use qemu_softmmu_targets_x86_64 || use qemu_softmmu_targets_i386; then
dosym ../sgabios/sgabios.bin /usr/share/qemu/sgabios.bin
fi
# Remove iPXE since we're using the iPXE packaged one
if use qemu_softmmu_targets_x86_64 || use qemu_softmmu_targets_i386; then
dosym ../ipxe/8086100e.rom /usr/share/qemu/pxe-e1000.rom
dosym ../ipxe/80861209.rom /usr/share/qemu/pxe-eepro100.rom
dosym ../ipxe/10500940.rom /usr/share/qemu/pxe-ne2k_pci.rom
dosym ../ipxe/10222000.rom /usr/share/qemu/pxe-pcnet.rom
dosym ../ipxe/10ec8139.rom /usr/share/qemu/pxe-rtl8139.rom
dosym ../ipxe/1af41000.rom /usr/share/qemu/pxe-virtio.rom
fi
fi
DISABLE_AUTOFORMATTING=true
readme.gentoo_create_doc
}
firmware_abi_change() {
local pv
for pv in ${REPLACING_VERSIONS}; do
if ver_test ${pv} -lt ${FIRMWARE_ABI_VERSION}; then
return 0
fi
done
return 1
}
pkg_postinst() {
if [[ -n ${softmmu_targets} ]] && use kernel_linux; then
udev_reload
fi
xdg_icon_cache_update
[[ -z ${EPREFIX} ]] && [[ -f ${EROOT}/usr/libexec/qemu-bridge-helper ]] && \
fcaps cap_net_admin "${EROOT}"/usr/libexec/qemu-bridge-helper
DISABLE_AUTOFORMATTING=true
readme.gentoo_print_elog
if use pin-upstream-blobs && firmware_abi_change; then
ewarn "This version of qemu pins new versions of firmware blobs:"
if has_version 'sys-firmware/edk2-ovmf-bin'; then
ewarn " $(best_version sys-firmware/edk2-ovmf-bin)"
else
ewarn " $(best_version sys-firmware/edk2-ovmf)"
fi
if has_version 'sys-firmware/seabios-bin'; then
ewarn " $(best_version sys-firmware/seabios-bin)"
else
ewarn " $(best_version sys-firmware/seabios)"
fi
ewarn " $(best_version sys-firmware/ipxe)"
ewarn " $(best_version sys-firmware/sgabios)"
ewarn "This might break resume of hibernated guests (started with a different"
ewarn "firmware version) and live migration to/from qemu versions with different"
ewarn "firmware. Please (cold) restart all running guests. For functional"
ewarn "guest migration ensure that all"
ewarn "hosts run at least"
ewarn " app-emulation/qemu-${FIRMWARE_ABI_VERSION}."
fi
}
pkg_info() {
echo "Using:"
echo " $(best_version app-emulation/spice-protocol)"
if has_version 'sys-firmware/edk2-ovmf-bin'; then
echo " $(best_version sys-firmware/edk2-ovmf-bin)"
else
echo " $(best_version sys-firmware/edk2-ovmf)"
fi
if has_version 'sys-firmware/seabios-bin'; then
echo " $(best_version sys-firmware/seabios-bin)"
else
echo " $(best_version sys-firmware/seabios)"
fi
echo " $(best_version sys-firmware/ipxe)"
echo " $(best_version sys-firmware/sgabios)"
}
pkg_postrm() {
xdg_icon_cache_update
udev_reload
}

@ -0,0 +1,970 @@
# Copyright 1999-2023 Gentoo Authors
# Distributed under the terms of the GNU General Public License v2
EAPI=8
# Generate using https://github.com/thesamesam/sam-gentoo-scripts/blob/main/niche/generate-qemu-docs
# Set to 1 if prebuilt, 0 if not
# (the construct below is to allow overriding from env for script)
QEMU_DOCS_PREBUILT=${QEMU_DOCS_PREBUILT:-1}
QEMU_DOCS_PREBUILT_DEV=sam
QEMU_DOCS_VERSION="8.0.0"
# Default to generating docs (inc. man pages) if no prebuilt; overridden later
# bug #830088
QEMU_DOC_USEFLAG="+doc"
PYTHON_COMPAT=( python3_{10..12} )
PYTHON_REQ_USE="ncurses,readline"
FIRMWARE_ABI_VERSION="7.2.0"
inherit linux-info toolchain-funcs python-r1 udev fcaps readme.gentoo-r1 \
pax-utils xdg-utils
if [[ ${PV} == *9999* ]]; then
QEMU_DOCS_PREBUILT=0
EGIT_REPO_URI="https://gitlab.com/qemu-project/qemu.git/"
EGIT_SUBMODULES=(
tests/fp/berkeley-softfloat-3
tests/fp/berkeley-testfloat-3
ui/keycodemapdb
)
inherit git-r3
SRC_URI=""
else
MY_P="${PN}-${PV/_rc/-rc}"
SRC_URI="https://download.qemu.org/${MY_P}.tar.xz"
if [[ ${QEMU_DOCS_PREBUILT} == 1 ]] ; then
SRC_URI+=" !doc? ( https://dev.gentoo.org/~${QEMU_DOCS_PREBUILT_DEV}/distfiles/${CATEGORY}/${PN}/${PN}-${QEMU_DOCS_VERSION}-docs.tar.xz )"
fi
S="${WORKDIR}/${MY_P}"
[[ "${PV}" != *_rc* ]] && KEYWORDS="~amd64 ~arm ~arm64 ~loong ~ppc ~ppc64 ~riscv ~x86"
fi
DESCRIPTION="QEMU + Kernel-based Virtual Machine userland tools"
HOMEPAGE="https://www.qemu.org https://www.linux-kvm.org"
LICENSE="GPL-2 LGPL-2 BSD-2"
SLOT="0"
[[ ${QEMU_DOCS_PREBUILT} == 1 ]] && QEMU_DOC_USEFLAG="doc"
IUSE="accessibility +aio alsa bpf bzip2 capstone +curl debug ${QEMU_DOC_USEFLAG}
+fdt fuse glusterfs +gnutls gtk infiniband iscsi io-uring
jack jemalloc +jpeg
lzo multipath
ncurses nfs nls numa opengl +oss pam +pin-upstream-blobs
plugins +png pulseaudio python rbd sasl +seccomp sdl sdl-image selinux
+slirp
smartcard snappy spice ssh static-user systemtap test udev usb
usbredir vde +vhost-net virgl virtfs +vnc vte xattr xen
zstd"
COMMON_TARGETS="
aarch64
alpha
arm
cris
hppa
i386
loongarch64
m68k
microblaze
microblazeel
mips
mips64
mips64el
mipsel
nios2
or1k
ppc
ppc64
riscv32
riscv64
s390x
sh4
sh4eb
sparc
sparc64
x86_64
xtensa
xtensaeb
"
IUSE_SOFTMMU_TARGETS="
${COMMON_TARGETS}
avr
rx
tricore
"
IUSE_USER_TARGETS="
${COMMON_TARGETS}
aarch64_be
armeb
hexagon
mipsn32
mipsn32el
ppc64le
sparc32plus
"
use_softmmu_targets=$(printf ' qemu_softmmu_targets_%s' ${IUSE_SOFTMMU_TARGETS})
use_user_targets=$(printf ' qemu_user_targets_%s' ${IUSE_USER_TARGETS})
IUSE+=" ${use_softmmu_targets} ${use_user_targets}"
RESTRICT="!test? ( test )"
# Allow no targets to be built so that people can get a tools-only build.
# Block USE flag configurations known to not work.
REQUIRED_USE="
${PYTHON_REQUIRED_USE}
qemu_softmmu_targets_arm? ( fdt )
qemu_softmmu_targets_microblaze? ( fdt )
qemu_softmmu_targets_mips64el? ( fdt )
qemu_softmmu_targets_ppc64? ( fdt )
qemu_softmmu_targets_ppc? ( fdt )
qemu_softmmu_targets_riscv32? ( fdt )
qemu_softmmu_targets_riscv64? ( fdt )
qemu_softmmu_targets_x86_64? ( fdt )
sdl-image? ( sdl )
static-user? ( !plugins )
virgl? ( opengl )
virtfs? ( xattr )
vnc? ( gnutls )
vte? ( gtk )
multipath? ( udev )
plugins? ( !static-user )
"
for smname in ${IUSE_SOFTMMU_TARGETS} ; do
REQUIRED_USE+=" qemu_softmmu_targets_${smname}? ( kernel_linux? ( seccomp ) )"
done
# Dependencies required for qemu tools (qemu-nbd, qemu-img, qemu-io, ...)
# and user/softmmu targets (qemu-*, qemu-system-*).
#
# Yep, you need both libcap and libcap-ng since virtfs only uses libcap.
#
# The attr lib isn't always linked in (although the USE flag is always
# respected). This is because qemu supports using the C library's API
# when available rather than always using the external library.
ALL_DEPEND="
dev-libs/glib:2[static-libs(+)]
sys-libs/zlib[static-libs(+)]
python? ( ${PYTHON_DEPS} )
systemtap? ( dev-util/systemtap )
xattr? ( sys-apps/attr[static-libs(+)] )
"
# Dependencies required for qemu tools (qemu-nbd, qemu-img, qemu-io, ...)
# softmmu targets (qemu-system-*).
SOFTMMU_TOOLS_DEPEND="
>=x11-libs/pixman-0.28.0[static-libs(+)]
accessibility? (
app-accessibility/brltty[api]
app-accessibility/brltty[static-libs(+)]
)
aio? ( dev-libs/libaio[static-libs(+)] )
alsa? ( >=media-libs/alsa-lib-1.0.13 )
bpf? ( dev-libs/libbpf:= )
bzip2? ( app-arch/bzip2[static-libs(+)] )
capstone? ( dev-libs/capstone:=[static-libs(+)] )
curl? ( >=net-misc/curl-7.15.4[static-libs(+)] )
fdt? ( >=sys-apps/dtc-1.5.1[static-libs(+)] )
fuse? ( >=sys-fs/fuse-3.1:3[static-libs(+)] )
glusterfs? ( >=sys-cluster/glusterfs-3.4.0[static-libs(+)] )
gnutls? (
>=net-libs/gnutls-3.0:=[static-libs(+)]
dev-libs/nettle:=[static-libs(+)]
)
gtk? (
x11-libs/cairo
x11-libs/gdk-pixbuf:2
x11-libs/gtk+:3
x11-libs/libX11
vte? ( x11-libs/vte:2.91 )
)
infiniband? ( sys-cluster/rdma-core[static-libs(+)] )
iscsi? ( net-libs/libiscsi )
io-uring? ( sys-libs/liburing:=[static-libs(+)] )
jack? ( virtual/jack )
jemalloc? ( dev-libs/jemalloc )
jpeg? ( media-libs/libjpeg-turbo:=[static-libs(+)] )
kernel_linux? ( sys-libs/libcap-ng[static-libs(+)] )
lzo? ( dev-libs/lzo:2[static-libs(+)] )
multipath? ( sys-fs/multipath-tools )
ncurses? (
sys-libs/ncurses:=[unicode(+)]
sys-libs/ncurses:=[static-libs(+)]
)
nfs? ( >=net-fs/libnfs-1.9.3:=[static-libs(+)] )
numa? ( sys-process/numactl[static-libs(+)] )
opengl? (
virtual/opengl
media-libs/libepoxy[static-libs(+)]
media-libs/mesa[static-libs(+)]
media-libs/mesa[egl(+),gbm(+)]
)
pam? ( sys-libs/pam )
png? ( >=media-libs/libpng-1.6.34:=[static-libs(+)] )
pulseaudio? ( media-libs/libpulse )
rbd? ( sys-cluster/ceph )
sasl? ( dev-libs/cyrus-sasl[static-libs(+)] )
sdl? (
media-libs/libsdl2[video]
media-libs/libsdl2[static-libs(+)]
)
sdl-image? ( media-libs/sdl2-image[static-libs(+)] )
seccomp? ( >=sys-libs/libseccomp-2.1.0[static-libs(+)] )
slirp? ( net-libs/libslirp[static-libs(+)] )
smartcard? ( >=app-emulation/libcacard-2.5.0[static-libs(+)] )
snappy? ( app-arch/snappy:= )
spice? (
>=app-emulation/spice-protocol-0.14.0
>=app-emulation/spice-0.14.0[static-libs(+)]
)
ssh? ( >=net-libs/libssh-0.8.6[static-libs(+)] )
udev? ( virtual/libudev:= )
usb? ( >=virtual/libusb-1-r2:1[static-libs(+)] )
usbredir? ( >=sys-apps/usbredir-0.6[static-libs(+)] )
vde? ( net-misc/vde[static-libs(+)] )
virgl? ( media-libs/virglrenderer[static-libs(+)] )
virtfs? ( sys-libs/libcap )
xen? ( app-emulation/xen-tools:= )
zstd? ( >=app-arch/zstd-1.4.0[static-libs(+)] )
"
EDK2_OVMF_VERSION="202202"
SEABIOS_VERSION="1.16.0"
X86_FIRMWARE_DEPEND="
pin-upstream-blobs? (
~sys-firmware/edk2-ovmf-bin-${EDK2_OVMF_VERSION}
~sys-firmware/ipxe-1.21.1[binary,qemu]
~sys-firmware/seabios-bin-${SEABIOS_VERSION}
~sys-firmware/sgabios-0.1_pre10[binary]
)
!pin-upstream-blobs? (
|| (
>=sys-firmware/edk2-ovmf-${EDK2_OVMF_VERSION}
>=sys-firmware/edk2-ovmf-bin-${EDK2_OVMF_VERSION}
)
sys-firmware/ipxe[qemu]
|| (
>=sys-firmware/seabios-${SEABIOS_VERSION}[seavgabios]
>=sys-firmware/seabios-bin-${SEABIOS_VERSION}
)
sys-firmware/sgabios
)
"
PPC_FIRMWARE_DEPEND="
pin-upstream-blobs? (
~sys-firmware/seabios-bin-${SEABIOS_VERSION}
)
!pin-upstream-blobs? (
|| (
>=sys-firmware/seabios-${SEABIOS_VERSION}[seavgabios]
>=sys-firmware/seabios-bin-${SEABIOS_VERSION}
)
)
"
BDEPEND="
$(python_gen_impl_dep)
dev-lang/perl
dev-util/meson
sys-apps/texinfo
virtual/pkgconfig
doc? (
dev-python/sphinx[${PYTHON_USEDEP}]
dev-python/sphinx-rtd-theme[${PYTHON_USEDEP}]
)
gtk? ( nls? ( sys-devel/gettext ) )
test? (
dev-libs/glib[utils]
sys-devel/bc
)
"
CDEPEND="
${ALL_DEPEND//\[static-libs(+)]}
${SOFTMMU_TOOLS_DEPEND//\[static-libs(+)]}
qemu_softmmu_targets_i386? ( ${X86_FIRMWARE_DEPEND} )
qemu_softmmu_targets_x86_64? ( ${X86_FIRMWARE_DEPEND} )
qemu_softmmu_targets_ppc? ( ${PPC_FIRMWARE_DEPEND} )
qemu_softmmu_targets_ppc64? ( ${PPC_FIRMWARE_DEPEND} )
"
DEPEND="
${CDEPEND}
kernel_linux? ( >=sys-kernel/linux-headers-2.6.35 )
static-user? ( ${ALL_DEPEND} )
"
RDEPEND="
${CDEPEND}
acct-group/kvm
selinux? (
sec-policy/selinux-qemu
sys-libs/libselinux
)
"
PATCHES=(
"${FILESDIR}"/${PN}-8.0.0-disable-keymap.patch
"${FILESDIR}"/${PN}-8.0.0-make.patch
"${FILESDIR}"/${PN}-7.1.0-also-build-virtfs-proxy-helper.patch
"${FILESDIR}"/${PN}-7.1.0-capstone-include-path.patch
"${FILESDIR}"/${PN}-7.2.0-disable-gmp.patch
"${FILESDIR}"/${PN}-8.0.0-remove-python-meson-check.patch
)
QA_PREBUILT="
usr/share/qemu/hppa-firmware.img
usr/share/qemu/openbios-ppc
usr/share/qemu/openbios-sparc64
usr/share/qemu/openbios-sparc32
usr/share/qemu/opensbi-riscv64-generic-fw_dynamic.elf
usr/share/qemu/opensbi-riscv32-generic-fw_dynamic.elf
usr/share/qemu/palcode-clipper
usr/share/qemu/s390-ccw.img
usr/share/qemu/s390-netboot.img
usr/share/qemu/u-boot.e500
"
QA_WX_LOAD="
usr/bin/qemu-i386
usr/bin/qemu-x86_64
usr/bin/qemu-alpha
usr/bin/qemu-arm
usr/bin/qemu-cris
usr/bin/qemu-m68k
usr/bin/qemu-microblaze
usr/bin/qemu-microblazeel
usr/bin/qemu-mips
usr/bin/qemu-mipsel
usr/bin/qemu-or1k
usr/bin/qemu-ppc
usr/bin/qemu-ppc64
usr/bin/qemu-sh4
usr/bin/qemu-sh4eb
usr/bin/qemu-sparc
usr/bin/qemu-sparc64
usr/bin/qemu-armeb
usr/bin/qemu-sparc32plus
usr/bin/qemu-s390x
usr/bin/qemu-unicore32
"
DOC_CONTENTS="If you don't have kvm compiled into the kernel, make sure you have the
kernel module loaded before running kvm. The easiest way to ensure that the
kernel module is loaded is to load it on boot.
For AMD CPUs the module is called 'kvm-amd'.
For Intel CPUs the module is called 'kvm-intel'.
Please review /etc/conf.d/modules for how to load these.
Make sure your user is in the 'kvm' group. Just run
$ gpasswd -a <USER> kvm
then have <USER> re-login.
For brand new installs, the default permissions on /dev/kvm might not let
you access it. You can tell udev to reset ownership/perms:
$ udevadm trigger -c add /dev/kvm
If you want to register binfmt handlers for qemu user targets:
For openrc:
# rc-update add qemu-binfmt
For systemd:
# ln -s /usr/share/qemu/binfmt.d/qemu.conf /etc/binfmt.d/qemu.conf"
pkg_pretend() {
if use kernel_linux && kernel_is lt 2 6 25; then
eerror "This version of KVM requires a host kernel of 2.6.25 or higher."
elif use kernel_linux; then
if ! linux_config_exists; then
eerror "Unable to check your kernel for KVM support"
else
CONFIG_CHECK="~KVM ~TUN ~BRIDGE"
ERROR_KVM="You must enable KVM in your kernel to continue"
ERROR_KVM_AMD="If you have an AMD CPU, you must enable KVM_AMD in"
ERROR_KVM_AMD+=" your kernel configuration."
ERROR_KVM_INTEL="If you have an Intel CPU, you must enable"
ERROR_KVM_INTEL+=" KVM_INTEL in your kernel configuration."
ERROR_TUN="You will need the Universal TUN/TAP driver compiled"
ERROR_TUN+=" into your kernel or loaded as a module to use the"
ERROR_TUN+=" virtual network device if using -net tap."
ERROR_BRIDGE="You will also need support for 802.1d"
ERROR_BRIDGE+=" Ethernet Bridging for some network configurations."
use vhost-net && CONFIG_CHECK+=" ~VHOST_NET"
ERROR_VHOST_NET="You must enable VHOST_NET to have vhost-net"
ERROR_VHOST_NET+=" support"
if use amd64 || use x86 || use amd64-linux || use x86-linux; then
if grep -q AuthenticAMD /proc/cpuinfo; then
CONFIG_CHECK+=" ~KVM_AMD"
elif grep -q GenuineIntel /proc/cpuinfo; then
CONFIG_CHECK+=" ~KVM_INTEL"
fi
fi
use python && CONFIG_CHECK+=" ~DEBUG_FS"
ERROR_DEBUG_FS="debugFS support required for kvm_stat"
# Now do the actual checks setup above
check_extra_config
fi
fi
if grep -qs '/usr/bin/qemu-kvm' "${EROOT}"/etc/libvirt/qemu/*.xml; then
eerror "The kvm/qemu-kvm wrappers no longer exist, but your libvirt"
eerror "instances are still pointing to it. Please update your"
eerror "configs in /etc/libvirt/qemu/ to use the -enable-kvm flag"
eerror "and the right system binary (e.g. qemu-system-x86_64)."
die "update your virt configs to not use qemu-kvm"
fi
}
# Sanity check to make sure target lists are kept up-to-date.
check_targets() {
local var=$1 mak=$2
local detected sorted
pushd "${S}"/configs/targets/ >/dev/null || die
# Force C locale until glibc is updated. #564936
detected=$(echo $(printf '%s\n' *-${mak}.mak | sed "s:-${mak}.mak::" | LC_COLLATE=C sort -u))
sorted=$(echo $(printf '%s\n' ${!var} | LC_COLLATE=C sort -u))
if [[ ${sorted} != "${detected}" ]] ; then
eerror "The ebuild needs to be kept in sync."
eerror "${var}: ${sorted}"
eerror "$(printf '%-*s' ${#var} configure): ${detected}"
die "sync ${var} to the list of targets"
fi
popd >/dev/null
}
src_prepare() {
check_targets IUSE_SOFTMMU_TARGETS softmmu
check_targets IUSE_USER_TARGETS linux-user
default
# Use correct toolchain to fix cross-compiling
tc-export AR AS LD NM OBJCOPY PKG_CONFIG RANLIB STRINGS
export WINDRES=${CHOST}-windres
# Verbose builds
MAKEOPTS+=" V=1"
# We already force -D_FORTIFY_SOURCE=2 (or 3) in our toolchain, but
# this setting (-U then -D..=2) will prevent us from trying out 3, so
# drop it. No change to level of protection b/c we patch our toolchain.
sed -i -e 's/-U_FORTIFY_SOURCE -D_FORTIFY_SOURCE=2//' configure || die
# Remove bundled modules
rm -r dtc meson roms/*/ || die
}
##
# configures qemu based on the build directory and the build type
# we are using.
#
qemu_src_configure() {
debug-print-function ${FUNCNAME} "$@"
local buildtype=$1
local builddir="${S}/${buildtype}-build"
mkdir "${builddir}" || die
local conf_opts=(
--prefix=/usr
--sysconfdir=/etc
--bindir=/usr/bin
--libdir=/usr/$(get_libdir)
--datadir=/usr/share
--docdir=/usr/share/doc/${PF}/html
--mandir=/usr/share/man
--localstatedir=/var
--disable-bsd-user
--disable-containers # bug #732972
--disable-guest-agent
--disable-strip
--with-git-submodules=ignore
# bug #746752: TCG interpreter has a few limitations:
# - it does not support FPU
# - it's generally slower on non-self-modifying code
# It's advantage is support for host architectures
# where native codegeneration is not implemented.
# Gentoo has qemu keyworded only on targets with
# native code generation available. Avoid the interpreter.
--disable-tcg-interpreter
--disable-werror
# We support gnutls/nettle for crypto operations. It is possible
# to use gcrypt when gnutls/nettle are disabled (but not when they
# are enabled), but it's not really worth the hassle. Disable it
# all the time to avoid automatically detecting it. #568856
--disable-gcrypt
--cc="$(tc-getCC)"
--cxx="$(tc-getCXX)"
--host-cc="$(tc-getBUILD_CC)"
$(use_enable alsa)
$(use_enable debug debug-info)
$(use_enable debug debug-tcg)
$(use_enable jack)
$(use_enable nls gettext)
$(use_enable oss)
$(use_enable plugins)
$(use_enable pulseaudio pa)
$(use_enable selinux)
$(use_enable xattr attr)
)
# Disable options not used by user targets. This simplifies building
# static user targets (USE=static-user) considerably.
conf_notuser() {
if [[ ${buildtype} == "user" ]] ; then
echo "--disable-${2:-$1}"
else
use_enable "$@"
fi
}
# Enable option only for softmmu build, but not 'user' or 'tools'
conf_softmmu() {
if [[ ${buildtype} == "softmmu" ]] ; then
use_enable "$@"
else
echo "--disable-${2:-$1}"
fi
}
# Enable option only for tools build, but not 'user' or 'softmmu'
conf_tools() {
if [[ ${buildtype} == "tools" ]] ; then
use_enable "$@"
else
echo "--disable-${2:-$1}"
fi
}
# Special case for the malloc flag, because the --disable flag does
# not exist and trying like above will break configuring.
conf_malloc() {
if [[ ! ${buildtype} == "user" ]] ; then
usex "${1}" "--enable-malloc=${1}" ""
fi
}
conf_opts+=(
$(conf_notuser accessibility brlapi)
$(conf_notuser aio linux-aio)
$(conf_softmmu bpf)
$(conf_notuser bzip2)
$(conf_notuser capstone)
$(conf_notuser curl)
$(conf_tools doc docs)
$(conf_notuser fdt)
$(conf_notuser fuse)
$(conf_notuser glusterfs)
$(conf_notuser gnutls)
$(conf_notuser gnutls nettle)
$(conf_notuser gtk)
$(conf_notuser infiniband rdma)
$(conf_notuser iscsi libiscsi)
$(conf_notuser io-uring linux-io-uring)
$(conf_malloc jemalloc)
$(conf_notuser jpeg vnc-jpeg)
$(conf_notuser kernel_linux kvm)
$(conf_notuser lzo)
$(conf_notuser multipath mpath)
$(conf_notuser ncurses curses)
$(conf_notuser nfs libnfs)
$(conf_notuser numa)
$(conf_notuser opengl)
$(conf_notuser pam auth-pam)
$(conf_notuser png)
$(conf_notuser rbd)
$(conf_notuser sasl vnc-sasl)
$(conf_notuser sdl)
$(conf_softmmu sdl-image)
$(conf_notuser seccomp)
$(conf_notuser slirp)
$(conf_notuser smartcard)
$(conf_notuser snappy)
$(conf_notuser spice)
$(conf_notuser ssh libssh)
$(conf_notuser udev libudev)
$(conf_notuser usb libusb)
$(conf_notuser usbredir usb-redir)
$(conf_notuser vde)
$(conf_notuser vhost-net)
$(conf_notuser virgl virglrenderer)
$(conf_softmmu virtfs)
$(conf_notuser vnc)
$(conf_notuser vte)
$(conf_notuser xen)
$(conf_notuser xen xen-pci-passthrough)
# use prebuilt keymaps, bug #759604
--disable-xkbcommon
$(conf_notuser zstd)
)
if [[ ! ${buildtype} == "user" ]] ; then
# audio options
local audio_opts=(
# Note: backend order matters here: #716202
# We iterate from higher-level to lower level.
$(usex pulseaudio pa "")
$(usev jack)
$(usev sdl)
$(usev alsa)
$(usev oss)
)
conf_opts+=(
--audio-drv-list=$(IFS=,; echo "${audio_opts[*]}")
)
fi
case ${buildtype} in
user)
conf_opts+=(
--enable-linux-user
--disable-system
--disable-tools
--disable-cap-ng
--disable-seccomp
)
local static_flag="static-user"
;;
softmmu)
conf_opts+=(
--disable-linux-user
--enable-system
--disable-tools
--enable-cap-ng
--enable-seccomp
)
local static_flag="none"
;;
tools)
conf_opts+=(
--disable-linux-user
--disable-system
--enable-tools
--enable-cap-ng
)
local static_flag="none"
;;
esac
local targets="${buildtype}_targets"
[[ -n ${targets} ]] && conf_opts+=( --target-list="${!targets}" )
# Add support for SystemTAP
use systemtap && conf_opts+=( --enable-trace-backends="dtrace" )
# We always want to attempt to build with PIE support as it results
# in a more secure binary. But it doesn't work with static or if
# the current GCC doesn't have PIE support.
if [[ ${static_flag} != "none" ]] && use ${static_flag}; then
conf_opts+=( --static --disable-pie )
else
tc-enables-pie && conf_opts+=( --enable-pie )
fi
# Meson will not use a cross-file unless cross_prefix is set.
tc-is-cross-compiler && conf_opts+=( --cross-prefix="${CHOST}-" )
# Plumb through equivalent of EXTRA_ECONF to allow experiments
# like bug #747928.
conf_opts+=( ${EXTRA_CONF_QEMU} )
echo "../configure ${conf_opts[*]}"
cd "${builddir}"
../configure "${conf_opts[@]}" || die "configure failed"
}
src_configure() {
local target
python_setup
softmmu_targets= softmmu_bins=()
user_targets= user_bins=()
for target in ${IUSE_SOFTMMU_TARGETS} ; do
if use "qemu_softmmu_targets_${target}"; then
softmmu_targets+=",${target}-softmmu"
softmmu_bins+=( "qemu-system-${target}" )
fi
done
for target in ${IUSE_USER_TARGETS} ; do
if use "qemu_user_targets_${target}"; then
user_targets+=",${target}-linux-user"
user_bins+=( "qemu-${target}" )
fi
done
softmmu_targets=${softmmu_targets#,}
user_targets=${user_targets#,}
[[ -n ${softmmu_targets} ]] && qemu_src_configure "softmmu"
[[ -n ${user_targets} ]] && qemu_src_configure "user"
qemu_src_configure "tools"
}
src_compile() {
if [[ -n ${user_targets} ]]; then
cd "${S}/user-build" || die
default
fi
if [[ -n ${softmmu_targets} ]]; then
cd "${S}/softmmu-build" || die
default
fi
cd "${S}/tools-build" || die
default
}
src_test() {
if [[ -n ${softmmu_targets} ]]; then
cd "${S}/softmmu-build" || die
pax-mark m */qemu-system-* #515550
emake check
fi
}
qemu_python_install() {
python_domodule "${S}/python/qemu"
python_doscript "${S}/scripts/kvm/vmxcap"
python_doscript "${S}/scripts/qmp/qmp-shell"
python_doscript "${S}/scripts/qmp/qemu-ga-client"
}
# Generate binfmt support files.
# - /etc/init.d/qemu-binfmt script which registers the user handlers (openrc)
# - /usr/share/qemu/binfmt.d/qemu.conf (for use with systemd-binfmt)
generate_initd() {
local out="${T}/qemu-binfmt"
local out_systemd="${T}/qemu.conf"
local d="${T}/binfmt.d"
einfo "Generating qemu binfmt scripts and configuration files"
# Generate the debian fragments first.
mkdir -p "${d}"
"${S}"/scripts/qemu-binfmt-conf.sh \
--debian \
--exportdir "${d}" \
--qemu-path "${EPREFIX}/usr/bin" \
|| die
# Then turn the fragments into a shell script we can source.
sed -E -i \
-e 's:^([^ ]+) (.*)$:\1="\2":' \
"${d}"/* || die
# Generate the init.d script by assembling the fragments from above.
local f qcpu package interpreter magic mask
cat "${FILESDIR}"/qemu-binfmt.initd.head >"${out}" || die
for f in "${d}"/qemu-* ; do
source "${f}"
# Normalize the cpu logic like we do in the init.d for the native cpu.
qcpu=${package#qemu-}
case ${qcpu} in
arm*) qcpu="arm";;
mips*) qcpu="mips";;
ppc*) qcpu="ppc";;
s390*) qcpu="s390";;
sh*) qcpu="sh";;
sparc*) qcpu="sparc";;
esac
# we use 'printf' here to be portable across 'sh'
# implementations: #679168
cat <<EOF >>"${out}"
if [ "\${cpu}" != "${qcpu}" -a -x "${interpreter}" ] ; then
printf '%s\n' ':${package}:M::${magic}:${mask}:${interpreter}:'"\${QEMU_BINFMT_FLAGS}" >/proc/sys/fs/binfmt_misc/register
fi
EOF
echo ":${package}:M::${magic}:${mask}:${interpreter}:OC" >>"${out_systemd}"
done
cat "${FILESDIR}"/qemu-binfmt.initd.tail >>"${out}" || die
}
src_install() {
if [[ -n ${user_targets} ]]; then
cd "${S}/user-build"
emake DESTDIR="${ED}" install
# Install binfmt handler init script for user targets.
generate_initd
doinitd "${T}/qemu-binfmt"
# Install binfmt/qemu.conf.
insinto "/usr/share/qemu/binfmt.d"
doins "${T}/qemu.conf"
fi
if [[ -n ${softmmu_targets} ]]; then
cd "${S}/softmmu-build"
emake DESTDIR="${ED}" install
# This might not exist if the test failed. #512010
[[ -e check-report.html ]] && dodoc check-report.html
if use kernel_linux; then
udev_newrules "${FILESDIR}"/65-kvm.rules-r2 65-kvm.rules
fi
if use python; then
python_foreach_impl qemu_python_install
fi
fi
cd "${S}/tools-build" || die
emake DESTDIR="${ED}" install
# If USE=doc, there'll be newly generated docs which we install instead.
if ! use doc && [[ ${QEMU_DOCS_PREBUILT} == 1 ]] ; then
doman "${WORKDIR}"/${PN}-${QEMU_DOCS_VERSION}-docs/docs/*.[0-8]
fi
# Disable mprotect on the qemu binaries as they use JITs to be fast #459348
pushd "${ED}"/usr/bin >/dev/null || die
pax-mark mr "${softmmu_bins[@]}" "${user_bins[@]}" # bug 575594
popd >/dev/null || die
# Install config file example for qemu-bridge-helper
insinto "/etc/qemu"
doins "${FILESDIR}/bridge.conf"
cd "${S}" || die
dodoc MAINTAINERS docs/specs/pci-ids.txt
newdoc pc-bios/README README.pc-bios
# Disallow stripping of prebuilt firmware files.
dostrip -x ${QA_PREBUILT}
if [[ -n ${softmmu_targets} ]]; then
# Remove SeaBIOS since we're using the SeaBIOS packaged one
if use qemu_softmmu_targets_x86_64 || use qemu_softmmu_targets_i386; then
dosym ../seabios/bios-256k.bin /usr/share/qemu/bios-256k.bin
fi
# Remove vgabios since we're using the seavgabios packaged one
rm "${ED}/usr/share/qemu/vgabios.bin"
rm "${ED}/usr/share/qemu/vgabios-cirrus.bin"
rm "${ED}/usr/share/qemu/vgabios-qxl.bin"
rm "${ED}/usr/share/qemu/vgabios-stdvga.bin"
rm "${ED}/usr/share/qemu/vgabios-virtio.bin"
rm "${ED}/usr/share/qemu/vgabios-vmware.bin"
# PPC/PPC64 loads vgabios-stdvga
if use qemu_softmmu_targets_x86_64 || use qemu_softmmu_targets_i386 || use qemu_softmmu_targets_ppc || use qemu_softmmu_targets_ppc64; then
dosym ../seavgabios/vgabios-isavga.bin /usr/share/qemu/vgabios.bin
dosym ../seavgabios/vgabios-cirrus.bin /usr/share/qemu/vgabios-cirrus.bin
dosym ../seavgabios/vgabios-qxl.bin /usr/share/qemu/vgabios-qxl.bin
dosym ../seavgabios/vgabios-stdvga.bin /usr/share/qemu/vgabios-stdvga.bin
dosym ../seavgabios/vgabios-virtio.bin /usr/share/qemu/vgabios-virtio.bin
dosym ../seavgabios/vgabios-vmware.bin /usr/share/qemu/vgabios-vmware.bin
fi
# Remove sgabios since we're using the sgabios packaged one
if use qemu_softmmu_targets_x86_64 || use qemu_softmmu_targets_i386; then
dosym ../sgabios/sgabios.bin /usr/share/qemu/sgabios.bin
fi
# Remove iPXE since we're using the iPXE packaged one
if use qemu_softmmu_targets_x86_64 || use qemu_softmmu_targets_i386; then
dosym ../ipxe/8086100e.rom /usr/share/qemu/pxe-e1000.rom
dosym ../ipxe/80861209.rom /usr/share/qemu/pxe-eepro100.rom
dosym ../ipxe/10500940.rom /usr/share/qemu/pxe-ne2k_pci.rom
dosym ../ipxe/10222000.rom /usr/share/qemu/pxe-pcnet.rom
dosym ../ipxe/10ec8139.rom /usr/share/qemu/pxe-rtl8139.rom
dosym ../ipxe/1af41000.rom /usr/share/qemu/pxe-virtio.rom
fi
fi
DISABLE_AUTOFORMATTING=true
readme.gentoo_create_doc
}
firmware_abi_change() {
local pv
for pv in ${REPLACING_VERSIONS}; do
if ver_test ${pv} -lt ${FIRMWARE_ABI_VERSION}; then
return 0
fi
done
return 1
}
pkg_postinst() {
if [[ -n ${softmmu_targets} ]] && use kernel_linux; then
udev_reload
fi
xdg_icon_cache_update
[[ -z ${EPREFIX} ]] && [[ -f ${EROOT}/usr/libexec/qemu-bridge-helper ]] && \
fcaps cap_net_admin "${EROOT}"/usr/libexec/qemu-bridge-helper
DISABLE_AUTOFORMATTING=true
readme.gentoo_print_elog
if use pin-upstream-blobs && firmware_abi_change; then
ewarn "This version of qemu pins new versions of firmware blobs:"
if has_version 'sys-firmware/edk2-ovmf-bin'; then
ewarn " $(best_version sys-firmware/edk2-ovmf-bin)"
else
ewarn " $(best_version sys-firmware/edk2-ovmf)"
fi
if has_version 'sys-firmware/seabios-bin'; then
ewarn " $(best_version sys-firmware/seabios-bin)"
else
ewarn " $(best_version sys-firmware/seabios)"
fi
ewarn " $(best_version sys-firmware/ipxe)"
ewarn " $(best_version sys-firmware/sgabios)"
ewarn "This might break resume of hibernated guests (started with a different"
ewarn "firmware version) and live migration to/from qemu versions with different"
ewarn "firmware. Please (cold) restart all running guests. For functional"
ewarn "guest migration ensure that all"
ewarn "hosts run at least"
ewarn " app-emulation/qemu-${FIRMWARE_ABI_VERSION}."
fi
}
pkg_info() {
echo "Using:"
echo " $(best_version app-emulation/spice-protocol)"
if has_version 'sys-firmware/edk2-ovmf-bin'; then
echo " $(best_version sys-firmware/edk2-ovmf-bin)"
else
echo " $(best_version sys-firmware/edk2-ovmf)"
fi
if has_version 'sys-firmware/seabios-bin'; then
echo " $(best_version sys-firmware/seabios-bin)"
else
echo " $(best_version sys-firmware/seabios)"
fi
echo " $(best_version sys-firmware/ipxe)"
echo " $(best_version sys-firmware/sgabios)"
}
pkg_postrm() {
xdg_icon_cache_update
udev_reload
}

@ -0,0 +1,967 @@
# Copyright 1999-2023 Gentoo Authors
# Distributed under the terms of the GNU General Public License v2
EAPI=8
# Generate using https://github.com/thesamesam/sam-gentoo-scripts/blob/main/niche/generate-qemu-docs
# Set to 1 if prebuilt, 0 if not
# (the construct below is to allow overriding from env for script)
QEMU_DOCS_PREBUILT=${QEMU_DOCS_PREBUILT:-1}
QEMU_DOCS_PREBUILT_DEV=sam
#QEMU_DOCS_VERSION=$(ver_cut 1-3)
QEMU_DOCS_VERSION=8.1.0
# Default to generating docs (inc. man pages) if no prebuilt; overridden later
# bug #830088
QEMU_DOC_USEFLAG="+doc"
PYTHON_COMPAT=( python3_{10..12} )
PYTHON_REQ_USE="ncurses,readline"
FIRMWARE_ABI_VERSION="7.2.0"
inherit linux-info toolchain-funcs python-r1 udev fcaps readme.gentoo-r1 \
pax-utils xdg-utils
if [[ ${PV} == *9999* ]]; then
QEMU_DOCS_PREBUILT=0
EGIT_REPO_URI="https://gitlab.com/qemu-project/qemu.git/"
EGIT_SUBMODULES=(
tests/fp/berkeley-softfloat-3
tests/fp/berkeley-testfloat-3
subprojects/keycodemapdb
)
inherit git-r3
SRC_URI=""
else
MY_P="${PN}-${PV/_rc/-rc}"
SRC_URI="https://download.qemu.org/${MY_P}.tar.xz"
if [[ ${QEMU_DOCS_PREBUILT} == 1 ]] ; then
SRC_URI+=" !doc? ( https://dev.gentoo.org/~${QEMU_DOCS_PREBUILT_DEV}/distfiles/${CATEGORY}/${PN}/${PN}-${QEMU_DOCS_VERSION}-docs.tar.xz )"
fi
S="${WORKDIR}/${MY_P}"
[[ "${PV}" != *_rc* ]] && KEYWORDS="~amd64 ~arm ~arm64 ~loong ~ppc ~ppc64 ~riscv ~x86"
fi
DESCRIPTION="QEMU + Kernel-based Virtual Machine userland tools"
HOMEPAGE="https://www.qemu.org https://www.linux-kvm.org"
LICENSE="GPL-2 LGPL-2 BSD-2"
SLOT="0"
[[ ${QEMU_DOCS_PREBUILT} == 1 ]] && QEMU_DOC_USEFLAG="doc"
IUSE="accessibility +aio alsa bpf bzip2 capstone +curl debug ${QEMU_DOC_USEFLAG}
+fdt fuse glusterfs +gnutls gtk infiniband iscsi io-uring
jack jemalloc +jpeg
lzo multipath
ncurses nfs nls numa opengl +oss pam +pin-upstream-blobs pipewire
plugins +png pulseaudio python rbd sasl +seccomp sdl sdl-image selinux
+slirp
smartcard snappy spice ssh static-user systemtap test udev usb
usbredir vde +vhost-net virgl virtfs +vnc vte xattr xen
zstd"
COMMON_TARGETS="
aarch64
alpha
arm
cris
hppa
i386
loongarch64
m68k
microblaze
microblazeel
mips
mips64
mips64el
mipsel
nios2
or1k
ppc
ppc64
riscv32
riscv64
s390x
sh4
sh4eb
sparc
sparc64
x86_64
xtensa
xtensaeb
"
IUSE_SOFTMMU_TARGETS="
${COMMON_TARGETS}
avr
rx
tricore
"
IUSE_USER_TARGETS="
${COMMON_TARGETS}
aarch64_be
armeb
hexagon
mipsn32
mipsn32el
ppc64le
sparc32plus
"
use_softmmu_targets=$(printf ' qemu_softmmu_targets_%s' ${IUSE_SOFTMMU_TARGETS})
use_user_targets=$(printf ' qemu_user_targets_%s' ${IUSE_USER_TARGETS})
IUSE+=" ${use_softmmu_targets} ${use_user_targets}"
RESTRICT="!test? ( test )"
# Allow no targets to be built so that people can get a tools-only build.
# Block USE flag configurations known to not work.
REQUIRED_USE="
${PYTHON_REQUIRED_USE}
qemu_softmmu_targets_arm? ( fdt )
qemu_softmmu_targets_microblaze? ( fdt )
qemu_softmmu_targets_mips64el? ( fdt )
qemu_softmmu_targets_ppc64? ( fdt )
qemu_softmmu_targets_ppc? ( fdt )
qemu_softmmu_targets_riscv32? ( fdt )
qemu_softmmu_targets_riscv64? ( fdt )
qemu_softmmu_targets_x86_64? ( fdt )
sdl-image? ( sdl )
static-user? ( !plugins )
virgl? ( opengl )
virtfs? ( xattr )
vnc? ( gnutls )
vte? ( gtk )
multipath? ( udev )
plugins? ( !static-user )
"
for smname in ${IUSE_SOFTMMU_TARGETS} ; do
REQUIRED_USE+=" qemu_softmmu_targets_${smname}? ( kernel_linux? ( seccomp ) )"
done
# Dependencies required for qemu tools (qemu-nbd, qemu-img, qemu-io, ...)
# and user/softmmu targets (qemu-*, qemu-system-*).
#
# Yep, you need both libcap and libcap-ng since virtfs only uses libcap.
#
# The attr lib isn't always linked in (although the USE flag is always
# respected). This is because qemu supports using the C library's API
# when available rather than always using the external library.
ALL_DEPEND="
dev-libs/glib:2[static-libs(+)]
sys-libs/zlib[static-libs(+)]
python? ( ${PYTHON_DEPS} )
systemtap? ( dev-util/systemtap )
xattr? ( sys-apps/attr[static-libs(+)] )
"
# Dependencies required for qemu tools (qemu-nbd, qemu-img, qemu-io, ...)
# softmmu targets (qemu-system-*).
SOFTMMU_TOOLS_DEPEND="
>=x11-libs/pixman-0.28.0[static-libs(+)]
accessibility? (
app-accessibility/brltty[api]
app-accessibility/brltty[static-libs(+)]
)
aio? ( dev-libs/libaio[static-libs(+)] )
alsa? ( >=media-libs/alsa-lib-1.0.13 )
bpf? ( dev-libs/libbpf:= )
bzip2? ( app-arch/bzip2[static-libs(+)] )
capstone? ( dev-libs/capstone:=[static-libs(+)] )
curl? ( >=net-misc/curl-7.15.4[static-libs(+)] )
fdt? ( >=sys-apps/dtc-1.5.1[static-libs(+)] )
fuse? ( >=sys-fs/fuse-3.1:3[static-libs(+)] )
glusterfs? ( >=sys-cluster/glusterfs-3.4.0[static-libs(+)] )
gnutls? (
>=net-libs/gnutls-3.0:=[static-libs(+)]
dev-libs/nettle:=[static-libs(+)]
)
gtk? (
x11-libs/gtk+:3
vte? ( x11-libs/vte:2.91 )
)
infiniband? ( sys-cluster/rdma-core[static-libs(+)] )
iscsi? ( net-libs/libiscsi )
io-uring? ( sys-libs/liburing:=[static-libs(+)] )
jack? ( virtual/jack )
jemalloc? ( dev-libs/jemalloc )
jpeg? ( media-libs/libjpeg-turbo:=[static-libs(+)] )
kernel_linux? ( sys-libs/libcap-ng[static-libs(+)] )
lzo? ( dev-libs/lzo:2[static-libs(+)] )
multipath? ( sys-fs/multipath-tools )
ncurses? (
sys-libs/ncurses:=[unicode(+)]
sys-libs/ncurses:=[static-libs(+)]
)
nfs? ( >=net-fs/libnfs-1.9.3:=[static-libs(+)] )
numa? ( sys-process/numactl[static-libs(+)] )
opengl? (
virtual/opengl
media-libs/libepoxy[static-libs(+)]
media-libs/mesa[static-libs(+)]
media-libs/mesa[egl(+),gbm(+)]
)
pam? ( sys-libs/pam )
pipewire? ( >=media-video/pipewire-0.3.60 )
png? ( >=media-libs/libpng-1.6.34:=[static-libs(+)] )
pulseaudio? ( media-libs/libpulse )
rbd? ( sys-cluster/ceph )
sasl? ( dev-libs/cyrus-sasl[static-libs(+)] )
sdl? (
media-libs/libsdl2[video]
media-libs/libsdl2[static-libs(+)]
)
sdl-image? ( media-libs/sdl2-image[static-libs(+)] )
seccomp? ( >=sys-libs/libseccomp-2.1.0[static-libs(+)] )
slirp? ( net-libs/libslirp[static-libs(+)] )
smartcard? ( >=app-emulation/libcacard-2.5.0[static-libs(+)] )
snappy? ( app-arch/snappy:= )
spice? (
>=app-emulation/spice-protocol-0.14.0
>=app-emulation/spice-0.14.0[static-libs(+)]
)
ssh? ( >=net-libs/libssh-0.8.6[static-libs(+)] )
udev? ( virtual/libudev:= )
usb? ( >=virtual/libusb-1-r2:1[static-libs(+)] )
usbredir? ( >=sys-apps/usbredir-0.6[static-libs(+)] )
vde? ( net-misc/vde[static-libs(+)] )
virgl? ( media-libs/virglrenderer[static-libs(+)] )
virtfs? ( sys-libs/libcap )
xen? ( app-emulation/xen-tools:= )
zstd? ( >=app-arch/zstd-1.4.0[static-libs(+)] )
"
EDK2_OVMF_VERSION="202202"
SEABIOS_VERSION="1.16.0"
X86_FIRMWARE_DEPEND="
pin-upstream-blobs? (
~sys-firmware/edk2-ovmf-bin-${EDK2_OVMF_VERSION}
~sys-firmware/ipxe-1.21.1[binary,qemu]
~sys-firmware/seabios-bin-${SEABIOS_VERSION}
~sys-firmware/sgabios-0.1_pre10[binary]
)
!pin-upstream-blobs? (
|| (
>=sys-firmware/edk2-ovmf-${EDK2_OVMF_VERSION}
>=sys-firmware/edk2-ovmf-bin-${EDK2_OVMF_VERSION}
)
sys-firmware/ipxe[qemu]
|| (
>=sys-firmware/seabios-${SEABIOS_VERSION}[seavgabios]
>=sys-firmware/seabios-bin-${SEABIOS_VERSION}
)
sys-firmware/sgabios
)
"
PPC_FIRMWARE_DEPEND="
pin-upstream-blobs? (
~sys-firmware/seabios-bin-${SEABIOS_VERSION}
)
!pin-upstream-blobs? (
|| (
>=sys-firmware/seabios-${SEABIOS_VERSION}[seavgabios]
>=sys-firmware/seabios-bin-${SEABIOS_VERSION}
)
)
"
# See bug #913084 for pip dep
BDEPEND="
$(python_gen_impl_dep)
dev-lang/perl
>=dev-util/meson-0.63.0
dev-python/pip[${PYTHON_USEDEP}]
virtual/pkgconfig
doc? (
>=dev-python/sphinx-1.6.0[${PYTHON_USEDEP}]
dev-python/sphinx-rtd-theme[${PYTHON_USEDEP}]
)
gtk? ( nls? ( sys-devel/gettext ) )
test? (
dev-libs/glib[utils]
sys-devel/bc
)
"
CDEPEND="
${ALL_DEPEND//\[static-libs(+)]}
${SOFTMMU_TOOLS_DEPEND//\[static-libs(+)]}
qemu_softmmu_targets_i386? ( ${X86_FIRMWARE_DEPEND} )
qemu_softmmu_targets_x86_64? ( ${X86_FIRMWARE_DEPEND} )
qemu_softmmu_targets_ppc? ( ${PPC_FIRMWARE_DEPEND} )
qemu_softmmu_targets_ppc64? ( ${PPC_FIRMWARE_DEPEND} )
"
DEPEND="
${CDEPEND}
kernel_linux? ( >=sys-kernel/linux-headers-2.6.35 )
static-user? ( ${ALL_DEPEND} )
"
RDEPEND="
${CDEPEND}
acct-group/kvm
selinux? (
sec-policy/selinux-qemu
sys-libs/libselinux
)
"
PATCHES=(
"${FILESDIR}"/${PN}-8.0.0-disable-keymap.patch
"${FILESDIR}"/${PN}-7.1.0-capstone-include-path.patch
"${FILESDIR}"/${PN}-8.1.0-also-build-virtfs-proxy-helper.patch
"${FILESDIR}"/${PN}-8.1.0-skip-tests.patch
"${FILESDIR}"/${PN}-8.1.0-find-sphinx.patch
)
QA_PREBUILT="
usr/share/qemu/hppa-firmware.img
usr/share/qemu/openbios-ppc
usr/share/qemu/openbios-sparc64
usr/share/qemu/openbios-sparc32
usr/share/qemu/opensbi-riscv64-generic-fw_dynamic.elf
usr/share/qemu/opensbi-riscv32-generic-fw_dynamic.elf
usr/share/qemu/palcode-clipper
usr/share/qemu/s390-ccw.img
usr/share/qemu/s390-netboot.img
usr/share/qemu/u-boot.e500
"
QA_WX_LOAD="
usr/bin/qemu-i386
usr/bin/qemu-x86_64
usr/bin/qemu-alpha
usr/bin/qemu-arm
usr/bin/qemu-cris
usr/bin/qemu-m68k
usr/bin/qemu-microblaze
usr/bin/qemu-microblazeel
usr/bin/qemu-mips
usr/bin/qemu-mipsel
usr/bin/qemu-or1k
usr/bin/qemu-ppc
usr/bin/qemu-ppc64
usr/bin/qemu-sh4
usr/bin/qemu-sh4eb
usr/bin/qemu-sparc
usr/bin/qemu-sparc64
usr/bin/qemu-armeb
usr/bin/qemu-sparc32plus
usr/bin/qemu-s390x
usr/bin/qemu-unicore32
"
DOC_CONTENTS="If you don't have kvm compiled into the kernel, make sure you have the
kernel module loaded before running kvm. The easiest way to ensure that the
kernel module is loaded is to load it on boot.
For AMD CPUs the module is called 'kvm-amd'.
For Intel CPUs the module is called 'kvm-intel'.
Please review /etc/conf.d/modules for how to load these.
Make sure your user is in the 'kvm' group. Just run
$ gpasswd -a <USER> kvm
then have <USER> re-login.
For brand new installs, the default permissions on /dev/kvm might not let
you access it. You can tell udev to reset ownership/perms:
$ udevadm trigger -c add /dev/kvm
If you want to register binfmt handlers for qemu user targets:
For openrc:
# rc-update add qemu-binfmt
For systemd:
# ln -s /usr/share/qemu/binfmt.d/qemu.conf /etc/binfmt.d/qemu.conf"
pkg_pretend() {
if use kernel_linux && kernel_is lt 2 6 25; then
eerror "This version of KVM requires a host kernel of 2.6.25 or higher."
elif use kernel_linux; then
if ! linux_config_exists; then
eerror "Unable to check your kernel for KVM support"
else
CONFIG_CHECK="~KVM ~TUN ~BRIDGE"
ERROR_KVM="You must enable KVM in your kernel to continue"
ERROR_KVM_AMD="If you have an AMD CPU, you must enable KVM_AMD in"
ERROR_KVM_AMD+=" your kernel configuration."
ERROR_KVM_INTEL="If you have an Intel CPU, you must enable"
ERROR_KVM_INTEL+=" KVM_INTEL in your kernel configuration."
ERROR_TUN="You will need the Universal TUN/TAP driver compiled"
ERROR_TUN+=" into your kernel or loaded as a module to use the"
ERROR_TUN+=" virtual network device if using -net tap."
ERROR_BRIDGE="You will also need support for 802.1d"
ERROR_BRIDGE+=" Ethernet Bridging for some network configurations."
use vhost-net && CONFIG_CHECK+=" ~VHOST_NET"
ERROR_VHOST_NET="You must enable VHOST_NET to have vhost-net"
ERROR_VHOST_NET+=" support"
if use amd64 || use x86 || use amd64-linux || use x86-linux; then
if grep -q AuthenticAMD /proc/cpuinfo; then
CONFIG_CHECK+=" ~KVM_AMD"
elif grep -q GenuineIntel /proc/cpuinfo; then
CONFIG_CHECK+=" ~KVM_INTEL"
fi
fi
use python && CONFIG_CHECK+=" ~DEBUG_FS"
ERROR_DEBUG_FS="debugFS support required for kvm_stat"
# Now do the actual checks setup above
check_extra_config
fi
fi
if grep -qs '/usr/bin/qemu-kvm' "${EROOT}"/etc/libvirt/qemu/*.xml; then
eerror "The kvm/qemu-kvm wrappers no longer exist, but your libvirt"
eerror "instances are still pointing to it. Please update your"
eerror "configs in /etc/libvirt/qemu/ to use the -enable-kvm flag"
eerror "and the right system binary (e.g. qemu-system-x86_64)."
die "update your virt configs to not use qemu-kvm"
fi
}
# Sanity check to make sure target lists are kept up-to-date.
check_targets() {
local var=$1 mak=$2
local detected sorted
pushd "${S}"/configs/targets/ >/dev/null || die
# Force C locale until glibc is updated. #564936
detected=$(echo $(printf '%s\n' *-${mak}.mak | sed "s:-${mak}.mak::" | LC_COLLATE=C sort -u))
sorted=$(echo $(printf '%s\n' ${!var} | LC_COLLATE=C sort -u))
if [[ ${sorted} != "${detected}" ]] ; then
eerror "The ebuild needs to be kept in sync."
eerror "${var}: ${sorted}"
eerror "$(printf '%-*s' ${#var} configure): ${detected}"
die "sync ${var} to the list of targets"
fi
popd >/dev/null
}
src_prepare() {
check_targets IUSE_SOFTMMU_TARGETS softmmu
check_targets IUSE_USER_TARGETS linux-user
default
# Use correct toolchain to fix cross-compiling
tc-export AR AS LD NM OBJCOPY PKG_CONFIG RANLIB STRINGS
export WINDRES=${CHOST}-windres
# Verbose builds
MAKEOPTS+=" V=1"
# Remove bundled modules
rm -r subprojects/dtc roms/*/ || die
}
##
# configures qemu based on the build directory and the build type
# we are using.
#
qemu_src_configure() {
debug-print-function ${FUNCNAME} "$@"
local buildtype=$1
local builddir="${S}/${buildtype}-build"
mkdir "${builddir}" || die
local conf_opts=(
--prefix=/usr
--sysconfdir=/etc
--bindir=/usr/bin
--libdir=/usr/$(get_libdir)
--datadir=/usr/share
--docdir=/usr/share/doc/${PF}/html
--mandir=/usr/share/man
--localstatedir=/var
--disable-bsd-user
--disable-containers # bug #732972
--disable-guest-agent
--disable-strip
--disable-download
# bug #746752: TCG interpreter has a few limitations:
# - it does not support FPU
# - it's generally slower on non-self-modifying code
# It's advantage is support for host architectures
# where native codegeneration is not implemented.
# Gentoo has qemu keyworded only on targets with
# native code generation available. Avoid the interpreter.
--disable-tcg-interpreter
--disable-werror
# We support gnutls/nettle for crypto operations. It is possible
# to use gcrypt when gnutls/nettle are disabled (but not when they
# are enabled), but it's not really worth the hassle. Disable it
# all the time to avoid automatically detecting it. #568856
--disable-gcrypt
--cc="$(tc-getCC)"
--cxx="$(tc-getCXX)"
--objcc="$(tc-getCC)"
--host-cc="$(tc-getBUILD_CC)"
$(use_enable alsa)
$(use_enable debug debug-info)
$(use_enable debug debug-tcg)
$(use_enable jack)
$(use_enable nls gettext)
$(use_enable oss)
$(use_enable pipewire)
$(use_enable plugins)
$(use_enable pulseaudio pa)
$(use_enable selinux)
$(use_enable xattr attr)
)
# Disable options not used by user targets. This simplifies building
# static user targets (USE=static-user) considerably.
conf_notuser() {
if [[ ${buildtype} == "user" ]] ; then
echo "--disable-${2:-$1}"
else
use_enable "$@"
fi
}
# Enable option only for softmmu build, but not 'user' or 'tools'
conf_softmmu() {
if [[ ${buildtype} == "softmmu" ]] ; then
use_enable "$@"
else
echo "--disable-${2:-$1}"
fi
}
# Enable option only for tools build, but not 'user' or 'softmmu'
conf_tools() {
if [[ ${buildtype} == "tools" ]] ; then
use_enable "$@"
else
echo "--disable-${2:-$1}"
fi
}
# Special case for the malloc flag, because the --disable flag does
# not exist and trying like above will break configuring.
conf_malloc() {
if [[ ! ${buildtype} == "user" ]] ; then
usex "${1}" "--enable-malloc=${1}" ""
fi
}
conf_opts+=(
$(conf_notuser accessibility brlapi)
$(conf_notuser aio linux-aio)
$(conf_softmmu bpf)
$(conf_notuser bzip2)
$(conf_notuser capstone)
$(conf_notuser curl)
$(conf_tools doc docs)
$(conf_notuser fdt)
$(conf_notuser fuse)
$(conf_notuser glusterfs)
$(conf_notuser gnutls)
$(conf_notuser gnutls nettle)
$(conf_notuser gtk)
$(conf_notuser infiniband rdma)
$(conf_notuser iscsi libiscsi)
$(conf_notuser io-uring linux-io-uring)
$(conf_malloc jemalloc)
$(conf_notuser jpeg vnc-jpeg)
$(conf_notuser kernel_linux kvm)
$(conf_notuser lzo)
$(conf_notuser multipath mpath)
$(conf_notuser ncurses curses)
$(conf_notuser nfs libnfs)
$(conf_notuser numa)
$(conf_notuser opengl)
$(conf_notuser pam auth-pam)
$(conf_notuser png)
$(conf_notuser rbd)
$(conf_notuser sasl vnc-sasl)
$(conf_notuser sdl)
$(conf_softmmu sdl-image)
$(conf_notuser seccomp)
$(conf_notuser slirp)
$(conf_notuser smartcard)
$(conf_notuser snappy)
$(conf_notuser spice)
$(conf_notuser ssh libssh)
$(conf_notuser udev libudev)
$(conf_notuser usb libusb)
$(conf_notuser usbredir usb-redir)
$(conf_notuser vde)
$(conf_notuser vhost-net)
$(conf_notuser virgl virglrenderer)
$(conf_softmmu virtfs)
$(conf_notuser vnc)
$(conf_notuser vte)
$(conf_notuser xen)
$(conf_notuser xen xen-pci-passthrough)
# use prebuilt keymaps, bug #759604
--disable-xkbcommon
$(conf_notuser zstd)
)
if [[ ! ${buildtype} == "user" ]] ; then
# audio options
local audio_opts=(
# Note: backend order matters here: #716202
# We iterate from higher-level to lower level.
$(usex pulseaudio pa "")
$(usev pipewire)
$(usev jack)
$(usev sdl)
$(usev alsa)
$(usev oss)
)
conf_opts+=(
--audio-drv-list=$(IFS=,; echo "${audio_opts[*]}")
)
fi
case ${buildtype} in
user)
conf_opts+=(
--enable-linux-user
--disable-system
--disable-tools
--disable-cap-ng
--disable-seccomp
)
local static_flag="static-user"
;;
softmmu)
conf_opts+=(
--disable-linux-user
--enable-system
--disable-tools
--enable-cap-ng
--enable-seccomp
)
local static_flag="none"
;;
tools)
conf_opts+=(
--disable-linux-user
--disable-system
--enable-tools
--enable-cap-ng
)
local static_flag="none"
;;
esac
local targets="${buildtype}_targets"
[[ -n ${targets} ]] && conf_opts+=( --target-list="${!targets}" )
# Add support for SystemTAP
use systemtap && conf_opts+=( --enable-trace-backends="dtrace" )
# We always want to attempt to build with PIE support as it results
# in a more secure binary. But it doesn't work with static or if
# the current GCC doesn't have PIE support.
if [[ ${static_flag} != "none" ]] && use ${static_flag}; then
conf_opts+=( --static --disable-pie )
else
tc-enables-pie && conf_opts+=( --enable-pie )
fi
# Meson will not use a cross-file unless cross_prefix is set.
tc-is-cross-compiler && conf_opts+=( --cross-prefix="${CHOST}-" )
# Plumb through equivalent of EXTRA_ECONF to allow experiments
# like bug #747928.
conf_opts+=( ${EXTRA_CONF_QEMU} )
echo "../configure ${conf_opts[*]}"
cd "${builddir}"
../configure "${conf_opts[@]}" || die "configure failed"
}
src_configure() {
local target
python_setup
softmmu_targets= softmmu_bins=()
user_targets= user_bins=()
for target in ${IUSE_SOFTMMU_TARGETS} ; do
if use "qemu_softmmu_targets_${target}"; then
softmmu_targets+=",${target}-softmmu"
softmmu_bins+=( "qemu-system-${target}" )
fi
done
for target in ${IUSE_USER_TARGETS} ; do
if use "qemu_user_targets_${target}"; then
user_targets+=",${target}-linux-user"
user_bins+=( "qemu-${target}" )
fi
done
softmmu_targets=${softmmu_targets#,}
user_targets=${user_targets#,}
[[ -n ${softmmu_targets} ]] && qemu_src_configure "softmmu"
[[ -n ${user_targets} ]] && qemu_src_configure "user"
qemu_src_configure "tools"
}
src_compile() {
if [[ -n ${user_targets} ]]; then
cd "${S}/user-build" || die
default
fi
if [[ -n ${softmmu_targets} ]]; then
cd "${S}/softmmu-build" || die
default
fi
cd "${S}/tools-build" || die
default
}
src_test() {
if [[ -n ${softmmu_targets} ]]; then
cd "${S}/softmmu-build" || die
pax-mark m */qemu-system-* #515550
emake check
fi
}
qemu_python_install() {
python_domodule "${S}/python/qemu"
python_doscript "${S}/scripts/kvm/vmxcap"
python_doscript "${S}/scripts/qmp/qmp-shell"
python_doscript "${S}/scripts/qmp/qemu-ga-client"
}
# Generate binfmt support files.
# - /etc/init.d/qemu-binfmt script which registers the user handlers (openrc)
# - /usr/share/qemu/binfmt.d/qemu.conf (for use with systemd-binfmt)
generate_initd() {
local out="${T}/qemu-binfmt"
local out_systemd="${T}/qemu.conf"
local d="${T}/binfmt.d"
einfo "Generating qemu binfmt scripts and configuration files"
# Generate the debian fragments first.
mkdir -p "${d}"
"${S}"/scripts/qemu-binfmt-conf.sh \
--debian \
--exportdir "${d}" \
--qemu-path "${EPREFIX}/usr/bin" \
|| die
# Then turn the fragments into a shell script we can source.
sed -E -i \
-e 's:^([^ ]+) (.*)$:\1="\2":' \
"${d}"/* || die
# Generate the init.d script by assembling the fragments from above.
local f qcpu package interpreter magic mask
cat "${FILESDIR}"/qemu-binfmt.initd.head >"${out}" || die
for f in "${d}"/qemu-* ; do
source "${f}"
# Normalize the cpu logic like we do in the init.d for the native cpu.
qcpu=${package#qemu-}
case ${qcpu} in
arm*) qcpu="arm";;
mips*) qcpu="mips";;
ppc*) qcpu="ppc";;
s390*) qcpu="s390";;
sh*) qcpu="sh";;
sparc*) qcpu="sparc";;
esac
# we use 'printf' here to be portable across 'sh'
# implementations: #679168
cat <<EOF >>"${out}"
if [ "\${cpu}" != "${qcpu}" -a -x "${interpreter}" ] ; then
printf '%s\n' ':${package}:M::${magic}:${mask}:${interpreter}:'"\${QEMU_BINFMT_FLAGS}" >/proc/sys/fs/binfmt_misc/register
fi
EOF
echo ":${package}:M::${magic}:${mask}:${interpreter}:OC" >>"${out_systemd}"
done
cat "${FILESDIR}"/qemu-binfmt.initd.tail >>"${out}" || die
}
src_install() {
if [[ -n ${user_targets} ]]; then
cd "${S}/user-build"
emake DESTDIR="${ED}" install
# Install binfmt handler init script for user targets.
generate_initd
doinitd "${T}/qemu-binfmt"
# Install binfmt/qemu.conf.
insinto "/usr/share/qemu/binfmt.d"
doins "${T}/qemu.conf"
fi
if [[ -n ${softmmu_targets} ]]; then
cd "${S}/softmmu-build"
emake DESTDIR="${ED}" install
# This might not exist if the test failed. #512010
[[ -e check-report.html ]] && dodoc check-report.html
if use kernel_linux; then
udev_newrules "${FILESDIR}"/65-kvm.rules-r2 65-kvm.rules
fi
if use python; then
python_foreach_impl qemu_python_install
fi
fi
cd "${S}/tools-build" || die
emake DESTDIR="${ED}" install
# If USE=doc, there'll be newly generated docs which we install instead.
if ! use doc && [[ ${QEMU_DOCS_PREBUILT} == 1 ]] ; then
doman "${WORKDIR}"/${PN}-${QEMU_DOCS_VERSION}-docs/docs/*.[0-8]
fi
# Disable mprotect on the qemu binaries as they use JITs to be fast #459348
pushd "${ED}"/usr/bin >/dev/null || die
pax-mark mr "${softmmu_bins[@]}" "${user_bins[@]}" # bug 575594
popd >/dev/null || die
# Install config file example for qemu-bridge-helper
insinto "/etc/qemu"
doins "${FILESDIR}/bridge.conf"
cd "${S}" || die
dodoc MAINTAINERS
newdoc pc-bios/README README.pc-bios
# Disallow stripping of prebuilt firmware files.
dostrip -x ${QA_PREBUILT}
if [[ -n ${softmmu_targets} ]]; then
# Remove SeaBIOS since we're using the SeaBIOS packaged one
if use qemu_softmmu_targets_x86_64 || use qemu_softmmu_targets_i386; then
dosym ../seabios/bios-256k.bin /usr/share/qemu/bios-256k.bin
fi
# Remove vgabios since we're using the seavgabios packaged one
rm "${ED}/usr/share/qemu/vgabios.bin"
rm "${ED}/usr/share/qemu/vgabios-cirrus.bin"
rm "${ED}/usr/share/qemu/vgabios-qxl.bin"
rm "${ED}/usr/share/qemu/vgabios-stdvga.bin"
rm "${ED}/usr/share/qemu/vgabios-virtio.bin"
rm "${ED}/usr/share/qemu/vgabios-vmware.bin"
# PPC/PPC64 loads vgabios-stdvga
if use qemu_softmmu_targets_x86_64 || use qemu_softmmu_targets_i386 || use qemu_softmmu_targets_ppc || use qemu_softmmu_targets_ppc64; then
dosym ../seavgabios/vgabios-isavga.bin /usr/share/qemu/vgabios.bin
dosym ../seavgabios/vgabios-cirrus.bin /usr/share/qemu/vgabios-cirrus.bin
dosym ../seavgabios/vgabios-qxl.bin /usr/share/qemu/vgabios-qxl.bin
dosym ../seavgabios/vgabios-stdvga.bin /usr/share/qemu/vgabios-stdvga.bin
dosym ../seavgabios/vgabios-virtio.bin /usr/share/qemu/vgabios-virtio.bin
dosym ../seavgabios/vgabios-vmware.bin /usr/share/qemu/vgabios-vmware.bin
fi
# Remove sgabios since we're using the sgabios packaged one
if use qemu_softmmu_targets_x86_64 || use qemu_softmmu_targets_i386; then
dosym ../sgabios/sgabios.bin /usr/share/qemu/sgabios.bin
fi
# Remove iPXE since we're using the iPXE packaged one
if use qemu_softmmu_targets_x86_64 || use qemu_softmmu_targets_i386; then
dosym ../ipxe/8086100e.rom /usr/share/qemu/pxe-e1000.rom
dosym ../ipxe/80861209.rom /usr/share/qemu/pxe-eepro100.rom
dosym ../ipxe/10500940.rom /usr/share/qemu/pxe-ne2k_pci.rom
dosym ../ipxe/10222000.rom /usr/share/qemu/pxe-pcnet.rom
dosym ../ipxe/10ec8139.rom /usr/share/qemu/pxe-rtl8139.rom
dosym ../ipxe/1af41000.rom /usr/share/qemu/pxe-virtio.rom
fi
fi
DISABLE_AUTOFORMATTING=true
readme.gentoo_create_doc
}
firmware_abi_change() {
local pv
for pv in ${REPLACING_VERSIONS}; do
if ver_test ${pv} -lt ${FIRMWARE_ABI_VERSION}; then
return 0
fi
done
return 1
}
pkg_postinst() {
if [[ -n ${softmmu_targets} ]] && use kernel_linux; then
udev_reload
fi
xdg_icon_cache_update
[[ -z ${EPREFIX} ]] && [[ -f ${EROOT}/usr/libexec/qemu-bridge-helper ]] && \
fcaps cap_net_admin "${EROOT}"/usr/libexec/qemu-bridge-helper
DISABLE_AUTOFORMATTING=true
readme.gentoo_print_elog
if use pin-upstream-blobs && firmware_abi_change; then
ewarn "This version of qemu pins new versions of firmware blobs:"
if has_version 'sys-firmware/edk2-ovmf-bin'; then
ewarn " $(best_version sys-firmware/edk2-ovmf-bin)"
else
ewarn " $(best_version sys-firmware/edk2-ovmf)"
fi
if has_version 'sys-firmware/seabios-bin'; then
ewarn " $(best_version sys-firmware/seabios-bin)"
else
ewarn " $(best_version sys-firmware/seabios)"
fi
ewarn " $(best_version sys-firmware/ipxe)"
ewarn " $(best_version sys-firmware/sgabios)"
ewarn "This might break resume of hibernated guests (started with a different"
ewarn "firmware version) and live migration to/from qemu versions with different"
ewarn "firmware. Please (cold) restart all running guests. For functional"
ewarn "guest migration ensure that all"
ewarn "hosts run at least"
ewarn " app-emulation/qemu-${FIRMWARE_ABI_VERSION}."
fi
}
pkg_info() {
echo "Using:"
echo " $(best_version app-emulation/spice-protocol)"
if has_version 'sys-firmware/edk2-ovmf-bin'; then
echo " $(best_version sys-firmware/edk2-ovmf-bin)"
else
echo " $(best_version sys-firmware/edk2-ovmf)"
fi
if has_version 'sys-firmware/seabios-bin'; then
echo " $(best_version sys-firmware/seabios-bin)"
else
echo " $(best_version sys-firmware/seabios)"
fi
echo " $(best_version sys-firmware/ipxe)"
echo " $(best_version sys-firmware/sgabios)"
}
pkg_postrm() {
xdg_icon_cache_update
udev_reload
}

@ -0,0 +1,148 @@
Subject: [PATCH] fix declarations with type mismatches
Type mismatches between declarations prevent the compile from using LTO
Bug: https://bugs.gentoo.org/854534
Upstream: https://sourceforge.net/p/softgun/patches/5/
# Pascal Jäger <pascal.jaeger@leimstift.de> (2023-09-21)
--- a/m16c/idecode_m16c.c
+++ b/m16c/idecode_m16c.c
@@ -9,7 +9,7 @@
#include "sglib.h"
M16C_InstructionProc **iProcTab;
-M16C_Instruction **iTab;
+M16C_Instruction **iTabM16C;
static M16C_Instruction instrlist[] = {
{0xfef0,0x76f0,"abs.size_dst",2 ,m16c_abs_size_dst},
@@ -308,7 +308,7 @@ M16C_IDecoderNew()
int i,j;
int onecount1,onecount2;
iProcTab=(M16C_InstructionProc**)sg_calloc(0x10000*sizeof(M16C_InstructionProc*));
- iTab=sg_calloc(0x10000*sizeof(M16C_Instruction*));
+ iTabM16C=sg_calloc(0x10000*sizeof(M16C_Instruction*));
fprintf(stderr,"Allocated M16C Instruction decoder table\n");
for(j=0;instrlist[j].proc;j++) {
M16C_Instruction *instr = &instrlist[j];
@@ -327,8 +327,8 @@ M16C_IDecoderNew()
}
#endif
if((i & instr->mask) == instr->icode) {
- if(iTab[i]) {
- M16C_Instruction *instr2 = iTab[i];
+ if(iTabM16C[i]) {
+ M16C_Instruction *instr2 = iTabM16C[i];
specmask1 = instr->mask;
specmask2 = instr2->mask;
onecount1 = SGLib_OnecountU32(instr->mask);
@@ -336,18 +336,18 @@ M16C_IDecoderNew()
fprintf(stderr,"Collission %s, %s\n",instr->name,instr2->name);
#if 0
if(instr->len > instr2->len) {
- iTab[i] = instr;
+ iTabM16C[i] = instr;
iProcTab[i] = instr->proc;
} else if(instr2->len > instr->len) {
- iTab[i] = instr2;
+ iTabM16C[i] = instr2;
iProcTab[i] = instr2->proc;
} else
#endif
if(onecount1 > onecount2) {
- iTab[i] = instr;
+ iTabM16C[i] = instr;
iProcTab[i] = instr->proc;
} else if(onecount2 > onecount1) {
- iTab[i] = instr2;
+ iTabM16C[i] = instr2;
iProcTab[i] = instr2->proc;
} else {
fprintf(stderr,"Can not decide %s, %s\n",instr->name,instr2->name);
@@ -360,10 +360,10 @@ M16C_IDecoderNew()
specmask2 |= 0xff00;
}
if((specmask2 & specmask1) == specmask1) {
- iTab[i] = instr2;
+ iTabM16C[i] = instr2;
iProcTab[i] = instr2->proc;
} else if((specmask2 & specmask1) == specmask2) {
- iTab[i] = instr;
+ iTabM16C[i] = instr;
iProcTab[i] = instr->proc;
} else {
fprintf(stdout,"%04x: no instruction is more specific %s %s %04x %04x %d %d\n",i,instr->name,instr2->name,instr->icode,instr2->icode,instr->len,instr2->len);
@@ -371,13 +371,13 @@ M16C_IDecoderNew()
}
#endif
} else {
- iTab[i] = instr;
+ iTabM16C[i] = instr;
iProcTab[i] = instr->proc;
}
}
}
- if(iTab[i] == NULL) {
- iTab[i] = &undefined_instr;
+ if(iTabM16C[i] == NULL) {
+ iTabM16C[i] = &undefined_instr;
iProcTab[i] = (&undefined_instr)->proc;
}
}
--- a/m16c/idecode_m16c.h
+++ b/m16c/idecode_m16c.h
@@ -11,14 +11,14 @@ typedef struct M16C_Instruction {
} M16C_Instruction;
extern M16C_InstructionProc **iProcTab;
-extern M16C_Instruction **iTab;
+extern M16C_Instruction **iTabM16C;
void M16C_IDecoderNew(void);
static inline M16C_Instruction *
M16C_InstructionFind(uint16_t icode)
{
- return iTab[icode];
+ return iTabM16C[icode];
}
static inline M16C_InstructionProc *
M16C_InstructionProcFind(uint16_t icode)
--- a/m16c/instructions_m16c.h
+++ b/m16c/instructions_m16c.h
@@ -160,7 +160,7 @@ void m16c_smovb_size(void);
void m16c_smovf_size(void);
void m16c_sstr_size(void);
void m16c_stc_srcdst(void);
-void m16c_stc_pcdst(void);
+void m16c_stc_pcdst(uint16_t icode);
void m16c_stctx_abs16abs20(void);
void m16c_ste_size_srcabs20(void);
void m16c_ste_size_srcdsp20(void);
--- a/ppc/mmu_ppc.c
+++ b/ppc/mmu_ppc.c
@@ -587,7 +587,7 @@ PPCMMU_Read8(uint32_t va) {
}
void
-PPCMMU_Write64(uint32_t value,uint32_t va) {
+PPCMMU_Write64(uint64_t value,uint32_t va) {
uint32_t pa=translate_data(va);
Bus_Write64(value,pa);
}
--- a/printer/decompress.c
+++ b/printer/decompress.c
@@ -55,7 +55,7 @@ enum
eeCachedColor = 0x60
};
-inline uint32_t get3pixel (uint8_t* src)
+static inline uint32_t get3pixel (uint8_t* src)
{
return (src[0] << 16) | (src[1] << 8) | (src[2]);
}
--
2.41.0

@ -0,0 +1,33 @@
Subject: [PATCH] fix implicit int declarations in function params
Clang16 does not allow implicit integer declarations by default.
Bug: https://bugs.gentoo.org/882583
Upstream: https://sourceforge.net/p/softgun/patches/5/
# Pascal Jäger <pascal.jaeger@leimstift.de> (2023-09-21)
--- a/arm/arm9cpu.h
+++ b/arm/arm9cpu.h
@@ -356,7 +356,7 @@ ARM_PostRestartIdecoder() {
}
static inline void
-ARM_SigDebugMode(value) {
+ARM_SigDebugMode(uint32_t value) {
if(value) {
gcpu.signals_raw |= ARM_SIG_DEBUGMODE;
} else {
--- a/m32c/idecode_m32c.h
+++ b/m32c/idecode_m32c.h
@@ -84,7 +84,7 @@ M32C_InstructionProcFind(uint16_t icode)
#endif
static inline int
-M32C_InstructionLen(icode) {
+M32C_InstructionLen(uint32_t icode) {
M32C_Instruction *instr = M32C_InstructionFind(icode);
return instr->len;
}
--
2.41.0

@ -0,0 +1,38 @@
# Copyright 1999-2023 Gentoo Authors
# Distributed under the terms of the GNU General Public License v2
EAPI=8
inherit flag-o-matic toolchain-funcs
DESCRIPTION="ARM software emulator"
HOMEPAGE="https://softgun.sourceforge.net/"
SRC_URI="mirror://sourceforge/${PN}/${P}.tgz"
LICENSE="GPL-2"
SLOT="0"
KEYWORDS="~amd64 ~ppc ~x86"
DEPEND="media-libs/alsa-lib"
RDEPEND="${DEPEND}"
PATCHES=(
"${FILESDIR}"/${PN}-0.22-make.patch
"${FILESDIR}"/${PN}-0.22-fix-implicit-int.patch
"${FILESDIR}"/${PN}-0.22-fix-declarations-with-type-mismatches.patch
)
src_configure() {
append-cflags -fcommon
default
}
src_compile() {
emake CC="$(tc-getCC)"
}
src_install() {
dodir /usr/bin
emake install prefix="${D}/usr"
dodoc README configs/*.sg
}

@ -1 +1,2 @@
DIST vkd3d-1.8.tar.xz 829648 BLAKE2B 0e7bb53e3eb9003ea76ee523dfa317b6ab95fd1c2decb453d650f0cf046d5b802a32e40c4e6f6464748903143ef9352e70fdf8ca7fa8e9b9909e0f15235d2b01 SHA512 43d65bf4aa60750e08653226197f40c97bc88d56dc5513b70182b5fe289ab56a225682c96400776cd625ad5a8f76644bf4b46bd3ed54aa8496f538f6854d680a
DIST vkd3d-1.9.tar.xz 902300 BLAKE2B 62c71b98912e66d86a2d2d934f6bd4c252cced68d3ad96c23b7404dbe346e7a11e43affb1959b389cfc90b53f32b2011ceeca6d066bcae876d24ff0822719d2b SHA512 7fe931fca4bc2e13bd59f2068d758581797aa15530fb811d71323e3cd83a0f12ec3a00e2951f38033fccf8eabfca45e06dad79d80ccc164e047e13cbfc960d0e

@ -0,0 +1,8 @@
Dirty quick fix for implicit function check, VKD3D_CHECK_FUNC ideally
needs to be adjusted to be able to pass headers.
--- a/configure
+++ b/configure
@@ -18656,2 +18656,3 @@
/* end confdefs.h. */
+#include <unistd.h>
int main(void) { return gettid(); }

@ -0,0 +1,51 @@
# Copyright 1999-2023 Gentoo Authors
# Distributed under the terms of the GNU General Public License v2
EAPI=8
inherit multilib-minimal
DESCRIPTION="D3D12 to Vulkan translation library"
HOMEPAGE="https://gitlab.winehq.org/wine/vkd3d/"
SRC_URI="https://dl.winehq.org/vkd3d/source/${P}.tar.xz"
LICENSE="LGPL-2.1+"
SLOT="0"
KEYWORDS="~amd64 ~x86"
IUSE="ncurses spirv-tools"
RESTRICT="test" #838655
RDEPEND="
media-libs/vulkan-loader[${MULTILIB_USEDEP}]
ncurses? ( sys-libs/ncurses:= )
spirv-tools? ( dev-util/spirv-tools[${MULTILIB_USEDEP}] )
"
DEPEND="
${RDEPEND}
dev-util/spirv-headers
dev-util/vulkan-headers
"
BDEPEND="
sys-devel/flex
sys-devel/bison
virtual/pkgconfig
"
PATCHES=(
"${FILESDIR}"/${PN}-1.9-implicit-gettid.patch
)
multilib_src_configure() {
local conf=(
$(multilib_native_use_with ncurses)
$(use_with spirv-tools)
--disable-doxygen-pdf
--without-xcb
)
ECONF_SOURCE=${S} econf "${conf[@]}"
}
multilib_src_install_all() {
find "${ED}" -type f -name '*.la' -delete || die
}

Binary file not shown.

@ -13,7 +13,7 @@ SRC_URI="http://foremost.sourceforge.net/pkg/${P}.tar.gz"
LICENSE="public-domain"
SLOT="0"
KEYWORDS="~amd64 ~ppc ~x86 ~arm64-macos ~x64-macos"
KEYWORDS="amd64 ~ppc x86 ~arm64-macos ~x64-macos"
IUSE=""
src_prepare() {

Binary file not shown.

@ -1 +1,2 @@
DIST asciinema-2.2.0.gh.tar.gz 88566 BLAKE2B c96eac56714a4519d462bdf24f3fcc0ec367af94182e6710d4744113c5ac3ec9304fbda30f3489b84bc4b645e43ea44d633230128d79a576d4bcbe7dad528ba8 SHA512 bed0b6a3228b973dddb2f03d0b0e16af0afd6e1c4c8c1379999d49b22ed658fed325f902f462156745631f98b51675565b7ea0011512c95c8b0b3bb09552bddc
DIST asciinema-2.3.0.gh.tar.gz 91464 BLAKE2B ff2f38715a9c69ec15ad8dfdfa282a49c32075e6be43ce2f568d188678d6fee1351f36f8dd2a272052f43087cf222e2b14d37ed26a42ba11396074523391efc5 SHA512 09951d96938faaf71a5b71f5a514ffacb32be224883691aec7fb549ad5dd4d0eb0a83c06ec23f81c36224fa028f0351decb7d82288b716a6453cbf00ad373845

@ -0,0 +1,27 @@
# Copyright 1999-2023 Gentoo Authors
# Distributed under the terms of the GNU General Public License v2
EAPI=8
PYTHON_COMPAT=( python3_{9..12} )
DISTUTILS_USE_PEP517=setuptools
inherit distutils-r1
DESCRIPTION="Command line recorder for asciinema.org service"
HOMEPAGE="https://asciinema.org/ https://pypi.org/project/asciinema/"
SRC_URI="https://github.com/${PN}/${PN}/archive/v${PV}.tar.gz -> ${P}.gh.tar.gz"
LICENSE="GPL-3+"
SLOT="0"
KEYWORDS="~amd64 ~ppc64 ~riscv ~x86"
PATCHES=(
"${FILESDIR}/asciinema-2.2.0-setup.patch"
)
distutils_enable_tests pytest
python_prepare_all() {
distutils-r1_python_prepare_all
sed -i -e "s|share/doc/asciinema|&-${PVR}|" setup.cfg || die
}

Some files were not shown because too many files have changed in this diff Show More

Loading…
Cancel
Save