parent
a7daebd2a4
commit
b0b374de5f
Binary file not shown.
Binary file not shown.
@ -0,0 +1,8 @@
|
|||||||
|
<?xml version="1.0" encoding="UTF-8"?>
|
||||||
|
<!DOCTYPE pkgmetadata SYSTEM "http://www.gentoo.org/dtd/metadata.dtd">
|
||||||
|
<pkgmetadata>
|
||||||
|
<maintainer type="project">
|
||||||
|
<email>pgsql-bugs@gentoo.org</email>
|
||||||
|
<name>PostgreSQL and Related Package Development</name>
|
||||||
|
</maintainer>
|
||||||
|
</pkgmetadata>
|
@ -0,0 +1,12 @@
|
|||||||
|
# Copyright 2020 Gentoo Authors
|
||||||
|
# Distributed under the terms of the GNU General Public License v2
|
||||||
|
|
||||||
|
EAPI=7
|
||||||
|
|
||||||
|
inherit acct-user
|
||||||
|
|
||||||
|
DESCRIPTION="PgBouncer program user"
|
||||||
|
ACCT_USER_ID=463
|
||||||
|
ACCT_USER_GROUPS=( postgres )
|
||||||
|
acct-user_add_deps
|
||||||
|
SLOT="0"
|
Binary file not shown.
@ -1,8 +1,15 @@
|
|||||||
<?xml version="1.0" encoding="UTF-8"?>
|
<?xml version="1.0" encoding="UTF-8"?>
|
||||||
<!DOCTYPE pkgmetadata SYSTEM "http://www.gentoo.org/dtd/metadata.dtd">
|
<!DOCTYPE pkgmetadata SYSTEM "http://www.gentoo.org/dtd/metadata.dtd">
|
||||||
<pkgmetadata>
|
<pkgmetadata>
|
||||||
<!-- maintainer-needed -->
|
<maintainer type="person">
|
||||||
<upstream>
|
<email>jakov.smolic@sartura.hr</email>
|
||||||
<remote-id type="github">yandex/gixy</remote-id>
|
<name>Jakov Smolic</name>
|
||||||
</upstream>
|
</maintainer>
|
||||||
|
<maintainer type="project">
|
||||||
|
<email>proxy-maint@gentoo.org</email>
|
||||||
|
<name>Proxy Maintainers</name>
|
||||||
|
</maintainer>
|
||||||
|
<upstream>
|
||||||
|
<remote-id type="github">yandex/gixy</remote-id>
|
||||||
|
</upstream>
|
||||||
</pkgmetadata>
|
</pkgmetadata>
|
||||||
|
@ -1,2 +1,3 @@
|
|||||||
DIST restart-services-0.15.2.tgz 23688 BLAKE2B e043b872d55109ad176a6437006cf581a993e72e460bb034625ed612f9ceca85ef91a20e90f23bcecc964caa527cfa4bc39d97c52487b7bf92eec21dc2e35c48 SHA512 afe7c96aabf61d664460d5d68447df09b3d9a54098887727db796821220f5ddd5a3b5030d995d5a6c3128e4a2b8494b9a0a3b86b5c805d56c0e201058ad04327
|
DIST restart-services-0.15.2.tgz 23688 BLAKE2B e043b872d55109ad176a6437006cf581a993e72e460bb034625ed612f9ceca85ef91a20e90f23bcecc964caa527cfa4bc39d97c52487b7bf92eec21dc2e35c48 SHA512 afe7c96aabf61d664460d5d68447df09b3d9a54098887727db796821220f5ddd5a3b5030d995d5a6c3128e4a2b8494b9a0a3b86b5c805d56c0e201058ad04327
|
||||||
DIST restart-services-0.16.0.tgz 24531 BLAKE2B fea233755d214a502096551226078a7fe15a75ccf937bbf8a75c78b7a294b5977da453f54f37e3d7e65f131e49e018bf08bec6245a3aa46ec6c3bec94019f5ad SHA512 57b3514132c02839cafbfd9152445a6482cf3591e22d18436a4d894061b59d2495863a912a87495559e9945a39715e7e798dca44dafd52c26b5412d749f37cc2
|
DIST restart-services-0.16.0.tgz 24531 BLAKE2B fea233755d214a502096551226078a7fe15a75ccf937bbf8a75c78b7a294b5977da453f54f37e3d7e65f131e49e018bf08bec6245a3aa46ec6c3bec94019f5ad SHA512 57b3514132c02839cafbfd9152445a6482cf3591e22d18436a4d894061b59d2495863a912a87495559e9945a39715e7e798dca44dafd52c26b5412d749f37cc2
|
||||||
|
DIST restart-services-0.16.1.tgz 24569 BLAKE2B 210ffebf321d9524ee3176ac8d56e2579c9e1686bd11d484be02600aab70347c522d5e7f8826b103ebd37f3e21c11130e0717f033ac0af3e938c4cece1a036bb SHA512 d4657120860ec26a2d9e6cdd935d720dac2bff50131fc9e8efd69b4768a5fd9afa4ee24b367a002122f3e1b335e9c99cc6b41c801c0285252e6f5e701d027de1
|
||||||
|
@ -0,0 +1,63 @@
|
|||||||
|
# Copyright 1999-2020 Gentoo Authors
|
||||||
|
# Distributed under the terms of the GNU General Public License v2
|
||||||
|
|
||||||
|
EAPI=6
|
||||||
|
|
||||||
|
DESCRIPTION="Tool to manage OpenRC services that need to be restarted"
|
||||||
|
HOMEPAGE="https://dev.gentoo.org/~mschiff/restart-services/"
|
||||||
|
SRC_URI="https://dev.gentoo.org/~mschiff/src/${PN}/${P}.tgz"
|
||||||
|
|
||||||
|
LICENSE="GPL-3"
|
||||||
|
SLOT="0"
|
||||||
|
KEYWORDS="~amd64 ~x86"
|
||||||
|
IUSE=""
|
||||||
|
|
||||||
|
DEPEND=""
|
||||||
|
RDEPEND="
|
||||||
|
app-admin/lib_users
|
||||||
|
sys-apps/openrc
|
||||||
|
app-portage/portage-utils
|
||||||
|
"
|
||||||
|
|
||||||
|
src_install() {
|
||||||
|
dosbin restart-services
|
||||||
|
doman restart-services.1
|
||||||
|
keepdir /etc/restart-services.d
|
||||||
|
insinto /etc
|
||||||
|
doins restart-services.conf
|
||||||
|
dodoc README CHANGES
|
||||||
|
|
||||||
|
sed -i 's/^#include/include/' "${D}"/etc/restart-services.conf
|
||||||
|
cat>"${D}"/etc/restart-services.d/00-local.conf<<-EOF
|
||||||
|
# You may put your local changes here or in any other *.conf file
|
||||||
|
# in this directory so you can leave /etc/restart-services.conf as is.
|
||||||
|
# Example:
|
||||||
|
# *extend* SV_ALWAYS to match 'myservice'
|
||||||
|
# SV_ALWAYS+=( myservice )
|
||||||
|
EOF
|
||||||
|
}
|
||||||
|
|
||||||
|
pkg_postinst() {
|
||||||
|
local MAJOR MINOR
|
||||||
|
# migrate config data for versions < 0.13.2
|
||||||
|
if [[ $REPLACING_VERSIONS ]]; then
|
||||||
|
MAJOR=${REPLACING_VERSIONS%%.*}
|
||||||
|
MINOR=${REPLACING_VERSIONS%.*}
|
||||||
|
MINOR=${MINOR#*.}
|
||||||
|
|
||||||
|
if [[ $MAJOR -eq 0 && $MINOR -lt 14 ]]; then
|
||||||
|
einfo "Checking for old config"
|
||||||
|
if [[ -f /etc/restart_services.conf ]]; then
|
||||||
|
ewarn "Old config file found: /etc/restart_services.conf"
|
||||||
|
ewarn "It will be ignored so please migrate settings to a file in"
|
||||||
|
ewarn "/etc/restart-services.d/ and/or remove /etc/restart_services.conf"
|
||||||
|
fi
|
||||||
|
if [[ -d /etc/restart_services.d ]]; then
|
||||||
|
ewarn "Old config directory found: /etc/restart_services.d"
|
||||||
|
ewarn "It will be ignored so please migrate files to /etc/restart-services.d"
|
||||||
|
ewarn "and/or remove /etc/restart_services.d"
|
||||||
|
fi
|
||||||
|
einfo "done"
|
||||||
|
fi
|
||||||
|
fi
|
||||||
|
}
|
Binary file not shown.
@ -1,3 +1,2 @@
|
|||||||
DIST rdiff-backup-2.0.0.tar.gz 408352 BLAKE2B c2a7ae90ea147398d648142e20761e3caf4f08948dcd0a3de22254a13857d3e99cb2801c83084dd13dd84764cebc7651b42a70a788553c67925521e2ed123953 SHA512 0bf06d4eefffd41e86224d798e6ac6852ca0fd356be73d651ffaf63c37aaa043a6d22f8025619ab4a86e54f6e98e61f445ab68a6f87f4f2f48e635507ea110ec
|
DIST rdiff-backup-2.0.0.tar.gz 408352 BLAKE2B c2a7ae90ea147398d648142e20761e3caf4f08948dcd0a3de22254a13857d3e99cb2801c83084dd13dd84764cebc7651b42a70a788553c67925521e2ed123953 SHA512 0bf06d4eefffd41e86224d798e6ac6852ca0fd356be73d651ffaf63c37aaa043a6d22f8025619ab4a86e54f6e98e61f445ab68a6f87f4f2f48e635507ea110ec
|
||||||
DIST rdiff-backup-2.0.3.tar.gz 422823 BLAKE2B 0d4f3165abb8893dfe0619ae80f4c93e676012c4cc763c28cd1aac4eee84e6f8ae2717b5b9722c1b89a9599f3ce487580eac6780799e028f269ea1ce4a40deea SHA512 a4d517182ba1521195f46abde67e7963c7b44722b37d20a7f9afb446a1b90095deba1da9aaa940d174d5cf8dd01948619846d689e5675326b271141b355831fb
|
|
||||||
DIST rdiff-backup-2.0.5.tar.gz 456115 BLAKE2B 9cd51644e11af3320fa5aca7864388da4b1165a1fc9e660265445d861eb356ba32e3b148a1d8de8e702bd9a6f0276ec3a4453c85ec702d80be5839661a1a679f SHA512 59482e6d78bc887fc99efd4b4779e9b41c7e4b0427e51b80b18a550d0051e4213a0c200296154759d1734f511f7abe3175d171f018c59c55e5abdfd0a890cfbd
|
DIST rdiff-backup-2.0.5.tar.gz 456115 BLAKE2B 9cd51644e11af3320fa5aca7864388da4b1165a1fc9e660265445d861eb356ba32e3b148a1d8de8e702bd9a6f0276ec3a4453c85ec702d80be5839661a1a679f SHA512 59482e6d78bc887fc99efd4b4779e9b41c7e4b0427e51b80b18a550d0051e4213a0c200296154759d1734f511f7abe3175d171f018c59c55e5abdfd0a890cfbd
|
||||||
|
Binary file not shown.
@ -1,2 +1,3 @@
|
|||||||
DIST certbot-1.7.0.tar.gz 1416764 BLAKE2B de678a222e8c8e3e7834470f87763763671bfae37a5c8320a4c1a2552ec979b5391094713e7e13526f73fdf8cd32f70f8c4350f422505892c4fdd0ae77742c80 SHA512 f81242e68b7e261bbb6294ffe92e47bc1687128344816d71a495a94a2646e209e46c147bc76eedce0c477cc140dc6ae0fba76d2d5d01b828fce78875f5a2886a
|
DIST certbot-1.7.0.tar.gz 1416764 BLAKE2B de678a222e8c8e3e7834470f87763763671bfae37a5c8320a4c1a2552ec979b5391094713e7e13526f73fdf8cd32f70f8c4350f422505892c4fdd0ae77742c80 SHA512 f81242e68b7e261bbb6294ffe92e47bc1687128344816d71a495a94a2646e209e46c147bc76eedce0c477cc140dc6ae0fba76d2d5d01b828fce78875f5a2886a
|
||||||
DIST certbot-1.8.0.tar.gz 1425620 BLAKE2B 9cc0443fd067bf594f02a79c99defa250e656dbee00cd2717a4a747abfe80511ffcb800b6ac63e484a918192dad9465dc45335f358267fa998af16e966b8e2a6 SHA512 c6559fe1e5db6269942bda3738c00b1b550ec448288eaf911ba9c3967c7e949b34bdd8b77742398f0a512ce07929fa2f227c1202e40900151762f1db6ff9de56
|
DIST certbot-1.8.0.tar.gz 1425620 BLAKE2B 9cc0443fd067bf594f02a79c99defa250e656dbee00cd2717a4a747abfe80511ffcb800b6ac63e484a918192dad9465dc45335f358267fa998af16e966b8e2a6 SHA512 c6559fe1e5db6269942bda3738c00b1b550ec448288eaf911ba9c3967c7e949b34bdd8b77742398f0a512ce07929fa2f227c1202e40900151762f1db6ff9de56
|
||||||
|
DIST certbot-1.9.0.tar.gz 1425703 BLAKE2B 9bf78824649870b3e1fc3175aae551cbfaa675a8930a89f35ba2330647d86798e4fc43011c617be2d278ab20c43dd05b02e8e61956dd7f9d10d444181874346e SHA512 098d8c077f5760c1f40f7d673820488ad7643c8b9c12561a58921cd95f60ae76515cefc19f822747f3385a68eba6f49fe5484b20142994ef67a26b0b16293ce8
|
||||||
|
@ -0,0 +1,69 @@
|
|||||||
|
# Copyright 1999-2020 Gentoo Authors
|
||||||
|
# Distributed under the terms of the GNU General Public License v2
|
||||||
|
|
||||||
|
EAPI=7
|
||||||
|
PYTHON_COMPAT=(python{3_6,3_7,3_8})
|
||||||
|
DISTUTILS_USE_SETUPTOOLS=rdepend
|
||||||
|
|
||||||
|
if [[ ${PV} == 9999* ]]; then
|
||||||
|
EGIT_REPO_URI="https://github.com/certbot/certbot.git"
|
||||||
|
inherit git-r3
|
||||||
|
S=${WORKDIR}/${P}/${PN}
|
||||||
|
else
|
||||||
|
SRC_URI="https://github.com/certbot/certbot/archive/v${PV}.tar.gz -> certbot-${PV}.tar.gz"
|
||||||
|
KEYWORDS="~amd64 ~arm ~arm64 ~ppc64 ~x86"
|
||||||
|
S=${WORKDIR}/certbot-${PV}/acme
|
||||||
|
fi
|
||||||
|
|
||||||
|
inherit distutils-r1
|
||||||
|
|
||||||
|
DESCRIPTION="An implementation of the ACME protocol"
|
||||||
|
HOMEPAGE="https://github.com/certbot/certbot https://letsencrypt.org/"
|
||||||
|
|
||||||
|
LICENSE="Apache-2.0"
|
||||||
|
SLOT="0"
|
||||||
|
IUSE="doc test"
|
||||||
|
RESTRICT="!test? ( test )"
|
||||||
|
|
||||||
|
RDEPEND="
|
||||||
|
>=dev-python/cryptography-1.3.4[${PYTHON_USEDEP}]
|
||||||
|
>=dev-python/idna-2.0.0[${PYTHON_USEDEP}]
|
||||||
|
>=dev-python/josepy-1.1.0[${PYTHON_USEDEP}]
|
||||||
|
>=dev-python/pyopenssl-0.15.1[${PYTHON_USEDEP}]
|
||||||
|
dev-python/pyrfc3339[${PYTHON_USEDEP}]
|
||||||
|
dev-python/pytz[${PYTHON_USEDEP}]
|
||||||
|
>=dev-python/requests-2.10[${PYTHON_USEDEP}]
|
||||||
|
>=dev-python/requests-toolbelt-0.3.0[${PYTHON_USEDEP}]
|
||||||
|
>=dev-python/six-1.9.0[${PYTHON_USEDEP}]
|
||||||
|
"
|
||||||
|
DEPEND="
|
||||||
|
doc? (
|
||||||
|
dev-python/sphinx[${PYTHON_USEDEP}]
|
||||||
|
dev-python/sphinx_rtd_theme[${PYTHON_USEDEP}]
|
||||||
|
)
|
||||||
|
test? (
|
||||||
|
${RDEPEND}
|
||||||
|
dev-python/nose[${PYTHON_USEDEP}]
|
||||||
|
dev-python/pytest[${PYTHON_USEDEP}]
|
||||||
|
dev-python/pytest-xdist[${PYTHON_USEDEP}]
|
||||||
|
)
|
||||||
|
"
|
||||||
|
|
||||||
|
src_compile() {
|
||||||
|
python_foreach_impl run_in_build_dir default
|
||||||
|
distutils-r1_src_compile
|
||||||
|
if use doc ; then
|
||||||
|
cd docs || die
|
||||||
|
sphinx-build -b html -d _build/doctrees . _build/html
|
||||||
|
fi
|
||||||
|
}
|
||||||
|
|
||||||
|
python_test() {
|
||||||
|
nosetests -w ${PN} || die
|
||||||
|
}
|
||||||
|
|
||||||
|
python_install_all() {
|
||||||
|
use doc && local HTML_DOCS=( docs/_build/html/. )
|
||||||
|
|
||||||
|
distutils-r1_python_install_all
|
||||||
|
}
|
@ -1,2 +1,3 @@
|
|||||||
DIST certbot-1.7.0.tar.gz 1416764 BLAKE2B de678a222e8c8e3e7834470f87763763671bfae37a5c8320a4c1a2552ec979b5391094713e7e13526f73fdf8cd32f70f8c4350f422505892c4fdd0ae77742c80 SHA512 f81242e68b7e261bbb6294ffe92e47bc1687128344816d71a495a94a2646e209e46c147bc76eedce0c477cc140dc6ae0fba76d2d5d01b828fce78875f5a2886a
|
DIST certbot-1.7.0.tar.gz 1416764 BLAKE2B de678a222e8c8e3e7834470f87763763671bfae37a5c8320a4c1a2552ec979b5391094713e7e13526f73fdf8cd32f70f8c4350f422505892c4fdd0ae77742c80 SHA512 f81242e68b7e261bbb6294ffe92e47bc1687128344816d71a495a94a2646e209e46c147bc76eedce0c477cc140dc6ae0fba76d2d5d01b828fce78875f5a2886a
|
||||||
DIST certbot-1.8.0.tar.gz 1425620 BLAKE2B 9cc0443fd067bf594f02a79c99defa250e656dbee00cd2717a4a747abfe80511ffcb800b6ac63e484a918192dad9465dc45335f358267fa998af16e966b8e2a6 SHA512 c6559fe1e5db6269942bda3738c00b1b550ec448288eaf911ba9c3967c7e949b34bdd8b77742398f0a512ce07929fa2f227c1202e40900151762f1db6ff9de56
|
DIST certbot-1.8.0.tar.gz 1425620 BLAKE2B 9cc0443fd067bf594f02a79c99defa250e656dbee00cd2717a4a747abfe80511ffcb800b6ac63e484a918192dad9465dc45335f358267fa998af16e966b8e2a6 SHA512 c6559fe1e5db6269942bda3738c00b1b550ec448288eaf911ba9c3967c7e949b34bdd8b77742398f0a512ce07929fa2f227c1202e40900151762f1db6ff9de56
|
||||||
|
DIST certbot-1.9.0.tar.gz 1425703 BLAKE2B 9bf78824649870b3e1fc3175aae551cbfaa675a8930a89f35ba2330647d86798e4fc43011c617be2d278ab20c43dd05b02e8e61956dd7f9d10d444181874346e SHA512 098d8c077f5760c1f40f7d673820488ad7643c8b9c12561a58921cd95f60ae76515cefc19f822747f3385a68eba6f49fe5484b20142994ef67a26b0b16293ce8
|
||||||
|
@ -0,0 +1,30 @@
|
|||||||
|
# Copyright 1999-2020 Gentoo Authors
|
||||||
|
# Distributed under the terms of the GNU General Public License v2
|
||||||
|
|
||||||
|
EAPI=7
|
||||||
|
PYTHON_COMPAT=(python{3_6,3_7,3_8})
|
||||||
|
DISTUTILS_USE_SETUPTOOLS=rdepend
|
||||||
|
|
||||||
|
if [[ ${PV} == 9999* ]]; then
|
||||||
|
EGIT_REPO_URI="https://github.com/certbot/certbot.git"
|
||||||
|
inherit git-r3
|
||||||
|
S=${WORKDIR}/${P}/${PN}
|
||||||
|
else
|
||||||
|
SRC_URI="https://github.com/${PN%-apache}/${PN%-apache}/archive/v${PV}.tar.gz -> ${PN%-apache}-${PV}.tar.gz"
|
||||||
|
KEYWORDS="~amd64 ~arm64 ~x86"
|
||||||
|
S=${WORKDIR}/${PN%-apache}-${PV}/${PN}
|
||||||
|
fi
|
||||||
|
|
||||||
|
inherit distutils-r1
|
||||||
|
|
||||||
|
DESCRIPTION="Apache plugin for certbot (Let's Encrypt Client)"
|
||||||
|
HOMEPAGE="https://github.com/certbot/certbot https://letsencrypt.org/"
|
||||||
|
|
||||||
|
LICENSE="Apache-2.0"
|
||||||
|
SLOT="0"
|
||||||
|
|
||||||
|
RDEPEND=">=app-crypt/acme-0.29.0[${PYTHON_USEDEP}]
|
||||||
|
>=app-crypt/certbot-1.6.0[${PYTHON_USEDEP}]
|
||||||
|
dev-python/python-augeas[${PYTHON_USEDEP}]
|
||||||
|
dev-python/zope-component[${PYTHON_USEDEP}]
|
||||||
|
dev-python/zope-interface[${PYTHON_USEDEP}]"
|
@ -1,2 +1,3 @@
|
|||||||
DIST certbot-1.7.0.tar.gz 1416764 BLAKE2B de678a222e8c8e3e7834470f87763763671bfae37a5c8320a4c1a2552ec979b5391094713e7e13526f73fdf8cd32f70f8c4350f422505892c4fdd0ae77742c80 SHA512 f81242e68b7e261bbb6294ffe92e47bc1687128344816d71a495a94a2646e209e46c147bc76eedce0c477cc140dc6ae0fba76d2d5d01b828fce78875f5a2886a
|
DIST certbot-1.7.0.tar.gz 1416764 BLAKE2B de678a222e8c8e3e7834470f87763763671bfae37a5c8320a4c1a2552ec979b5391094713e7e13526f73fdf8cd32f70f8c4350f422505892c4fdd0ae77742c80 SHA512 f81242e68b7e261bbb6294ffe92e47bc1687128344816d71a495a94a2646e209e46c147bc76eedce0c477cc140dc6ae0fba76d2d5d01b828fce78875f5a2886a
|
||||||
DIST certbot-1.8.0.tar.gz 1425620 BLAKE2B 9cc0443fd067bf594f02a79c99defa250e656dbee00cd2717a4a747abfe80511ffcb800b6ac63e484a918192dad9465dc45335f358267fa998af16e966b8e2a6 SHA512 c6559fe1e5db6269942bda3738c00b1b550ec448288eaf911ba9c3967c7e949b34bdd8b77742398f0a512ce07929fa2f227c1202e40900151762f1db6ff9de56
|
DIST certbot-1.8.0.tar.gz 1425620 BLAKE2B 9cc0443fd067bf594f02a79c99defa250e656dbee00cd2717a4a747abfe80511ffcb800b6ac63e484a918192dad9465dc45335f358267fa998af16e966b8e2a6 SHA512 c6559fe1e5db6269942bda3738c00b1b550ec448288eaf911ba9c3967c7e949b34bdd8b77742398f0a512ce07929fa2f227c1202e40900151762f1db6ff9de56
|
||||||
|
DIST certbot-1.9.0.tar.gz 1425703 BLAKE2B 9bf78824649870b3e1fc3175aae551cbfaa675a8930a89f35ba2330647d86798e4fc43011c617be2d278ab20c43dd05b02e8e61956dd7f9d10d444181874346e SHA512 098d8c077f5760c1f40f7d673820488ad7643c8b9c12561a58921cd95f60ae76515cefc19f822747f3385a68eba6f49fe5484b20142994ef67a26b0b16293ce8
|
||||||
|
@ -0,0 +1,32 @@
|
|||||||
|
# Copyright 1999-2020 Gentoo Authors
|
||||||
|
# Distributed under the terms of the GNU General Public License v2
|
||||||
|
|
||||||
|
EAPI=7
|
||||||
|
PYTHON_COMPAT=(python{3_6,3_7,3_8})
|
||||||
|
DISTUTILS_USE_SETUPTOOLS=rdepend
|
||||||
|
|
||||||
|
if [[ ${PV} == 9999* ]]; then
|
||||||
|
EGIT_REPO_URI="https://github.com/certbot/certbot.git"
|
||||||
|
inherit git-r3
|
||||||
|
S=${WORKDIR}/${P}/${PN}
|
||||||
|
else
|
||||||
|
SRC_URI="https://github.com/${PN%-nginx}/${PN%-nginx}/archive/v${PV}.tar.gz -> ${PN%-nginx}-${PV}.tar.gz"
|
||||||
|
KEYWORDS="~amd64 ~arm ~arm64 ~x86"
|
||||||
|
S=${WORKDIR}/${PN%-nginx}-${PV}/${PN}
|
||||||
|
fi
|
||||||
|
|
||||||
|
inherit distutils-r1
|
||||||
|
|
||||||
|
DESCRIPTION="Nginx plugin for certbot (Let's Encrypt Client)"
|
||||||
|
HOMEPAGE="https://github.com/certbot/certbot https://letsencrypt.org/"
|
||||||
|
|
||||||
|
LICENSE="Apache-2.0"
|
||||||
|
SLOT="0"
|
||||||
|
IUSE=""
|
||||||
|
|
||||||
|
RDEPEND="
|
||||||
|
>=app-crypt/acme-1.4.0[${PYTHON_USEDEP}]
|
||||||
|
>=app-crypt/certbot-1.6.0[${PYTHON_USEDEP}]
|
||||||
|
dev-python/pyopenssl[${PYTHON_USEDEP}]
|
||||||
|
>=dev-python/pyparsing-1.5.5[${PYTHON_USEDEP}]
|
||||||
|
dev-python/zope-interface[${PYTHON_USEDEP}]"
|
@ -1,2 +1,3 @@
|
|||||||
DIST certbot-1.7.0.tar.gz 1416764 BLAKE2B de678a222e8c8e3e7834470f87763763671bfae37a5c8320a4c1a2552ec979b5391094713e7e13526f73fdf8cd32f70f8c4350f422505892c4fdd0ae77742c80 SHA512 f81242e68b7e261bbb6294ffe92e47bc1687128344816d71a495a94a2646e209e46c147bc76eedce0c477cc140dc6ae0fba76d2d5d01b828fce78875f5a2886a
|
DIST certbot-1.7.0.tar.gz 1416764 BLAKE2B de678a222e8c8e3e7834470f87763763671bfae37a5c8320a4c1a2552ec979b5391094713e7e13526f73fdf8cd32f70f8c4350f422505892c4fdd0ae77742c80 SHA512 f81242e68b7e261bbb6294ffe92e47bc1687128344816d71a495a94a2646e209e46c147bc76eedce0c477cc140dc6ae0fba76d2d5d01b828fce78875f5a2886a
|
||||||
DIST certbot-1.8.0.tar.gz 1425620 BLAKE2B 9cc0443fd067bf594f02a79c99defa250e656dbee00cd2717a4a747abfe80511ffcb800b6ac63e484a918192dad9465dc45335f358267fa998af16e966b8e2a6 SHA512 c6559fe1e5db6269942bda3738c00b1b550ec448288eaf911ba9c3967c7e949b34bdd8b77742398f0a512ce07929fa2f227c1202e40900151762f1db6ff9de56
|
DIST certbot-1.8.0.tar.gz 1425620 BLAKE2B 9cc0443fd067bf594f02a79c99defa250e656dbee00cd2717a4a747abfe80511ffcb800b6ac63e484a918192dad9465dc45335f358267fa998af16e966b8e2a6 SHA512 c6559fe1e5db6269942bda3738c00b1b550ec448288eaf911ba9c3967c7e949b34bdd8b77742398f0a512ce07929fa2f227c1202e40900151762f1db6ff9de56
|
||||||
|
DIST certbot-1.9.0.tar.gz 1425703 BLAKE2B 9bf78824649870b3e1fc3175aae551cbfaa675a8930a89f35ba2330647d86798e4fc43011c617be2d278ab20c43dd05b02e8e61956dd7f9d10d444181874346e SHA512 098d8c077f5760c1f40f7d673820488ad7643c8b9c12561a58921cd95f60ae76515cefc19f822747f3385a68eba6f49fe5484b20142994ef67a26b0b16293ce8
|
||||||
|
@ -0,0 +1,36 @@
|
|||||||
|
# Copyright 1999-2020 Gentoo Authors
|
||||||
|
# Distributed under the terms of the GNU General Public License v2
|
||||||
|
|
||||||
|
EAPI=7
|
||||||
|
PYTHON_COMPAT=(python{3_6,3_7,3_8})
|
||||||
|
DISTUTILS_USE_SETUPTOOLS=rdepend
|
||||||
|
|
||||||
|
if [[ ${PV} == 9999* ]]; then
|
||||||
|
EGIT_REPO_URI="https://github.com/certbot/certbot.git"
|
||||||
|
inherit git-r3
|
||||||
|
else
|
||||||
|
SRC_URI="https://github.com/${PN}/${PN}/archive/v${PV}.tar.gz -> ${P}.tar.gz"
|
||||||
|
KEYWORDS="~amd64 ~arm ~arm64 ~ppc64 ~x86"
|
||||||
|
fi
|
||||||
|
S=${WORKDIR}/${P}/${PN}
|
||||||
|
|
||||||
|
inherit distutils-r1
|
||||||
|
|
||||||
|
DESCRIPTION="Let's encrypt client to automate deployment of X.509 certificates"
|
||||||
|
HOMEPAGE="https://github.com/certbot/certbot https://letsencrypt.org/"
|
||||||
|
|
||||||
|
LICENSE="Apache-2.0"
|
||||||
|
SLOT="0"
|
||||||
|
|
||||||
|
RDEPEND="
|
||||||
|
>=app-crypt/acme-1.8.0[${PYTHON_USEDEP}]
|
||||||
|
>=dev-python/configargparse-0.9.3[${PYTHON_USEDEP}]
|
||||||
|
dev-python/configobj[${PYTHON_USEDEP}]
|
||||||
|
>=dev-python/cryptography-2.8[${PYTHON_USEDEP}]
|
||||||
|
>=dev-python/distro-1.0.1[${PYTHON_USEDEP}]
|
||||||
|
>=dev-python/josepy-1.1.0[${PYTHON_USEDEP}]
|
||||||
|
>=dev-python/parsedatetime-1.3[${PYTHON_USEDEP}]
|
||||||
|
dev-python/pyrfc3339[${PYTHON_USEDEP}]
|
||||||
|
dev-python/pytz[${PYTHON_USEDEP}]
|
||||||
|
dev-python/zope-component[${PYTHON_USEDEP}]
|
||||||
|
dev-python/zope-interface[${PYTHON_USEDEP}]"
|
@ -1 +1 @@
|
|||||||
DIST nwipe-0.25.tar.gz 49608 BLAKE2B 3506093c3e93b4aa982dffdd2f922f525404b397d7b3469f9ccdbf6708f824e9d3a2e34590a34cb4e0411bb3a8a4555a1f5940b826d39d39c10c75b668a10d1d SHA512 1051f2565ad7acaac7c289e2db91aa4dee40c3bb9a9dda97b2dec047e94cd91e7d59fd61603806628cabeb009932f011e734638fc9191c22bb812d7b4b661b46
|
DIST nwipe-0.28.tar.gz 849147 BLAKE2B de81c526edc9ce106d48297796e1d42689bafae20be8ac20f6a8eb6474c8202dffdfbad2f91c8282bf5f747921b90402a3a84e411d8a8b2adb0c2e785bfaf315 SHA512 2b6cb6dbcbb51960f726d8ec6c1629fb4675af4b3f7b39ee1fc91244fc9391f4ea23bae5c8794cc92a675ce202be60df900658b6d9a95b5bb399c0e6f009ce69
|
||||||
|
@ -1,8 +1,15 @@
|
|||||||
<?xml version="1.0" encoding="UTF-8"?>
|
<?xml version="1.0" encoding="UTF-8"?>
|
||||||
<!DOCTYPE pkgmetadata SYSTEM "http://www.gentoo.org/dtd/metadata.dtd">
|
<!DOCTYPE pkgmetadata SYSTEM "http://www.gentoo.org/dtd/metadata.dtd">
|
||||||
<pkgmetadata>
|
<pkgmetadata>
|
||||||
<!-- maintainer-needed -->
|
<maintainer type="person">
|
||||||
<upstream>
|
<email>jakov.smolic@sartura.hr</email>
|
||||||
<remote-id type="sourceforge">nwipe</remote-id>
|
<name>Jakov Smolic</name>
|
||||||
</upstream>
|
</maintainer>
|
||||||
|
<maintainer type="project">
|
||||||
|
<email>proxy-maint@gentoo.org</email>
|
||||||
|
<name>Proxy Maintainers</name>
|
||||||
|
</maintainer>
|
||||||
|
<upstream>
|
||||||
|
<remote-id type="github">martijnvanbrummelen/nwipe</remote-id>
|
||||||
|
</upstream>
|
||||||
</pkgmetadata>
|
</pkgmetadata>
|
||||||
|
@ -1 +1,2 @@
|
|||||||
DIST rainbowcrack-1.7-linux64.zip 208726 BLAKE2B 842e0a3ee74a8576a5331cc86259178b382e82f465f3093e7d1fa1b44907c1c30a73f53c2f7f527e052bc6266ceffd350c42b9b80b1298072a02c0cbd25e660d SHA512 068fe9d31004e08c0fcbe5a11500bd6248eca2f204a8d99a7343824ebc1dd847a01eb459f28d77fdd84eae98b05169a69e10b8893b9b5dd027381965c19b7bdb
|
DIST rainbowcrack-1.7-linux64.zip 208726 BLAKE2B 842e0a3ee74a8576a5331cc86259178b382e82f465f3093e7d1fa1b44907c1c30a73f53c2f7f527e052bc6266ceffd350c42b9b80b1298072a02c0cbd25e660d SHA512 068fe9d31004e08c0fcbe5a11500bd6248eca2f204a8d99a7343824ebc1dd847a01eb459f28d77fdd84eae98b05169a69e10b8893b9b5dd027381965c19b7bdb
|
||||||
|
DIST rainbowcrack-1.8-linux64.zip 220109 BLAKE2B 164894ccb07490756a0c9b297b1497d6305fade66b31fd712914261219dd957632cd285ab2e7ad7a683dd3c0a425eb1969676ea23136abf7d688fcde9e445e74 SHA512 84dbf3431605fb5dcc8e7cd305a43e9b239ebd6e5ef120edd951a3180c38498fe3a26157e3b55d114c6630f8ac1382a610d8e6230779c5b12cbc42c04e9aff57
|
||||||
|
@ -0,0 +1,70 @@
|
|||||||
|
# Copyright 1999-2020 Gentoo Authors
|
||||||
|
# Distributed under the terms of the GNU General Public License v2
|
||||||
|
|
||||||
|
EAPI=7
|
||||||
|
|
||||||
|
inherit wrapper
|
||||||
|
|
||||||
|
DESCRIPTION="Hash cracker that precomputes plaintext - ciphertext pairs in advance"
|
||||||
|
HOMEPAGE="https://project-rainbowcrack.com/"
|
||||||
|
SRC_URI="https://project-${PN}.com/${P}-linux64.zip"
|
||||||
|
|
||||||
|
LICENSE="all-rights-reserved"
|
||||||
|
SLOT="0"
|
||||||
|
KEYWORDS="-* ~amd64"
|
||||||
|
IUSE=""
|
||||||
|
|
||||||
|
RESTRICT="bindist mirror" #444426
|
||||||
|
|
||||||
|
RAINBOW_DESTDIR="opt/${PN}"
|
||||||
|
|
||||||
|
QA_FLAGS_IGNORED="${RAINBOW_DESTDIR}/.*"
|
||||||
|
QA_PRESTRIPPED="${RAINBOW_DESTDIR}/.*"
|
||||||
|
|
||||||
|
DEPEND="app-arch/unzip"
|
||||||
|
|
||||||
|
DOCS=(
|
||||||
|
readme.txt
|
||||||
|
)
|
||||||
|
|
||||||
|
S="${WORKDIR}"/${P}-linux64
|
||||||
|
|
||||||
|
# rainbowcrack-1.8 zipfiles, including the ones for Linux, use backslashes as path separators.
|
||||||
|
# unzip handles it just fine but produces a warning, the side effect of which is that it exits
|
||||||
|
# with code 1 rather than 0.
|
||||||
|
# Don't bother with iterating over A, we already assume the file to be a .zip so we might as well
|
||||||
|
# assume there is only one.
|
||||||
|
src_unpack() {
|
||||||
|
unzip -qo "${DISTDIR}/${A}"
|
||||||
|
local unzip_retval="${?}"
|
||||||
|
case "${unzip_retval}" in
|
||||||
|
0|1)
|
||||||
|
;;
|
||||||
|
*)
|
||||||
|
die "Failed to unpack the source archive"
|
||||||
|
;;
|
||||||
|
esac
|
||||||
|
}
|
||||||
|
|
||||||
|
src_install() {
|
||||||
|
einstalldocs
|
||||||
|
|
||||||
|
local bin bins="
|
||||||
|
rcrack
|
||||||
|
rt2rtc
|
||||||
|
rtc2rt
|
||||||
|
rtgen
|
||||||
|
rtmerge
|
||||||
|
rtsort
|
||||||
|
"
|
||||||
|
|
||||||
|
exeinto "/${RAINBOW_DESTDIR}"
|
||||||
|
doexe alglib0.so ${bins}
|
||||||
|
|
||||||
|
for bin in ${bins}; do
|
||||||
|
make_wrapper ${bin} ./${bin} "/${RAINBOW_DESTDIR}" "/${RAINBOW_DESTDIR}"
|
||||||
|
done
|
||||||
|
|
||||||
|
insinto "/${RAINBOW_DESTDIR}"
|
||||||
|
doins charset.txt
|
||||||
|
}
|
@ -1,10 +0,0 @@
|
|||||||
--- rotix.c 2002-04-02 14:48:42.000000000 -0500
|
|
||||||
+++ rotix.c.mine 2010-07-15 14:54:45.000000000 -0400
|
|
||||||
@@ -38,6 +38,7 @@
|
|
||||||
/* I18N */
|
|
||||||
#ifdef I18N
|
|
||||||
#include <libintl.h>
|
|
||||||
+#include <locale.h>
|
|
||||||
#define _(String) gettext (String)
|
|
||||||
#else
|
|
||||||
#define _(String) String
|
|
@ -0,0 +1,12 @@
|
|||||||
|
diff --git a/configure.ac b/configure.ac
|
||||||
|
index 3088817..d789ce9 100644
|
||||||
|
--- a/configure.ac
|
||||||
|
+++ b/configure.ac
|
||||||
|
@@ -460,7 +460,6 @@ AS_IF([test x"$enable_hardening" != xno], [
|
||||||
|
|
||||||
|
add_hardened_c_flag([-Wall])
|
||||||
|
add_hardened_c_flag([-Wextra])
|
||||||
|
- add_hardened_c_flag([-Werror])
|
||||||
|
|
||||||
|
add_hardened_c_flag([-Wformat])
|
||||||
|
add_hardened_c_flag([-Wformat-security])
|
@ -1 +1 @@
|
|||||||
DIST tpm2-tools-4.2.1.tar.gz 879294 BLAKE2B 7619f72f0fe39360f111822b4ec7a0bb90156f295977115c4612efac33059dd786abfa5d5f46a8fcc134fce11d099b03cb7f9ee01aa3addf5a3bb2455e1eb2d4 SHA512 4da103e70880d72a9aa402dea39ea439a0657729af22f08ac7275022c475ab46cb3dd6123d6846669d9b7f8f9af7b3e3df7c3b1d33cd0149b649b7941c84c339
|
DIST tpm2-tools-4.3.0.tar.gz 881544 BLAKE2B 0415f30845658e84e97a964abebc3082e45fb880c10bec405cd89c7bfa373ace10b669c4af78e7e47f2d2bb62fc7cc34b2e54e392a95c8f9b8956b8c92af6aee SHA512 4e622bbc8642ba7fd93a7343900560fe3779cba03e363d16f391fc8929724a11913d238e3986de06982cbced27c3c2ca8c7e73d75796407b8646c101ccf393a8
|
||||||
|
@ -0,0 +1,12 @@
|
|||||||
|
diff --git a/configure.ac b/configure.ac
|
||||||
|
index 7b5c2196..d07d5433 100644
|
||||||
|
--- a/configure.ac
|
||||||
|
+++ b/configure.ac
|
||||||
|
@@ -210,7 +210,6 @@ AS_IF([test x"$enable_hardening" != x"no"], [
|
||||||
|
|
||||||
|
add_hardened_c_flag([-Wall])
|
||||||
|
add_hardened_c_flag([-Wextra])
|
||||||
|
- add_hardened_c_flag([-Werror])
|
||||||
|
|
||||||
|
add_hardened_c_flag([-Wformat])
|
||||||
|
add_hardened_c_flag([-Wformat-security])
|
Binary file not shown.
@ -1,4 +1,3 @@
|
|||||||
DIST nano-4.9.3.tar.gz 2999198 BLAKE2B a96f707936934a965a9a41dfe13ac1ebbe1a5e38db714df6d219b2c6539f24924d4c4f0451508718f66259854806032b84dc89850a7fd55d157f28ae23531d0e SHA512 233e6ed103441bd2c85ed21c50547f85dc0838cc750a5e9b16ecfb393e3b7b978e971af4a4164062c7c267c98895ecb696c02cbd2e4c2eb1ceee657fd026c30a
|
DIST nano-4.9.3.tar.gz 2999198 BLAKE2B a96f707936934a965a9a41dfe13ac1ebbe1a5e38db714df6d219b2c6539f24924d4c4f0451508718f66259854806032b84dc89850a7fd55d157f28ae23531d0e SHA512 233e6ed103441bd2c85ed21c50547f85dc0838cc750a5e9b16ecfb393e3b7b978e971af4a4164062c7c267c98895ecb696c02cbd2e4c2eb1ceee657fd026c30a
|
||||||
DIST nano-5.0.tar.gz 3034734 BLAKE2B 03ea59c97c0e421ed92f588a2e6991f968b2f341761db66fda077ab827d00b9eb13930f08011f0028010e2005bb912ead723928b482a0532e924f85757a75569 SHA512 7e650676a15a185a9695eb49ae5cf441e3d42ae13817a9d3e64cb347c795840712778ac464fd5c578cc6464132206ee06dba52a06a218bcc865485ce3502a4bb
|
|
||||||
DIST nano-5.1.tar.gz 2861977 BLAKE2B c826782683d26b4c27ffb82e8c4dabad543fe93f53d942bc6ad57b8acb7959595986216a1936d69b0a63b72da101de2c886995421db93c76ee842313799de78d SHA512 8007f40f27a1235d59f5559b6629a3a5a1a579a2356c8825dfef121f4ba7e6c5196e4cedea441c7e856f9add1e9739b14b4142a0a14dab90841110218149df11
|
|
||||||
DIST nano-5.2.tar.gz 2865091 BLAKE2B 3822b3fd8dede897d698401a06ea0b4b49bf39f48d16c750e273007b1795a8adfc71654eadc08039a5c6999973ff7e70148b4c720b32a8f361424404e3c2ff3f SHA512 4c77bcfdf704a7882e944cb6d4cd571b698447500255e5701d30990def56cec0c396a33c761b8149f3cc4208a8dcd0f39372804d54cbe6bc2db9244f4a2259b3
|
DIST nano-5.2.tar.gz 2865091 BLAKE2B 3822b3fd8dede897d698401a06ea0b4b49bf39f48d16c750e273007b1795a8adfc71654eadc08039a5c6999973ff7e70148b4c720b32a8f361424404e3c2ff3f SHA512 4c77bcfdf704a7882e944cb6d4cd571b698447500255e5701d30990def56cec0c396a33c761b8149f3cc4208a8dcd0f39372804d54cbe6bc2db9244f4a2259b3
|
||||||
|
DIST nano-5.3.tar.gz 2874796 BLAKE2B d266018f2508153369e10c6f9cf4c53eaeafdf0efe88da6de19efd76ef13fedebe4b9339ae594b751a12cf18a8c4dcd57466ceedfabf61406f63b69c75fceff1 SHA512 019b58779f5a7d9a9472b415715876d0daac313a02b794900339469ee0b5a27ce202e397c00ad6396b7e26a7c303e52c28d981fff85cf774c79a5a8a9835836d
|
||||||
|
@ -1,89 +0,0 @@
|
|||||||
# Copyright 1999-2020 Gentoo Authors
|
|
||||||
# Distributed under the terms of the GNU General Public License v2
|
|
||||||
|
|
||||||
EAPI=7
|
|
||||||
|
|
||||||
inherit flag-o-matic
|
|
||||||
if [[ ${PV} == "9999" ]] ; then
|
|
||||||
EGIT_REPO_URI="git://git.sv.gnu.org/nano.git"
|
|
||||||
inherit git-r3 autotools
|
|
||||||
else
|
|
||||||
MY_P="${PN}-${PV/_}"
|
|
||||||
SRC_URI="https://www.nano-editor.org/dist/v${PV:0:1}/${MY_P}.tar.gz"
|
|
||||||
KEYWORDS="~alpha ~amd64 ~arm ~arm64 ~hppa ~ia64 ~m68k ~mips ~ppc ~ppc64 ~riscv ~s390 ~sparc ~x86 ~ppc-aix ~amd64-linux ~x86-linux ~ppc-macos ~x64-macos ~x86-macos ~m68k-mint ~sparc-solaris ~sparc64-solaris ~x64-solaris ~x86-solaris"
|
|
||||||
fi
|
|
||||||
|
|
||||||
DESCRIPTION="GNU GPL'd Pico clone with more functionality"
|
|
||||||
HOMEPAGE="https://www.nano-editor.org/ https://wiki.gentoo.org/wiki/Nano/Basics_Guide"
|
|
||||||
|
|
||||||
LICENSE="GPL-3"
|
|
||||||
SLOT="0"
|
|
||||||
IUSE="debug justify +magic minimal ncurses nls slang +spell +split-usr static unicode"
|
|
||||||
|
|
||||||
LIB_DEPEND=">=sys-libs/ncurses-5.9-r1:0=[unicode?]
|
|
||||||
sys-libs/ncurses:0=[static-libs(+)]
|
|
||||||
magic? ( sys-apps/file[static-libs(+)] )
|
|
||||||
nls? ( virtual/libintl )
|
|
||||||
!ncurses? ( slang? ( sys-libs/slang[static-libs(+)] ) )"
|
|
||||||
RDEPEND="!static? ( ${LIB_DEPEND//\[static-libs(+)]} )"
|
|
||||||
DEPEND="${RDEPEND}
|
|
||||||
static? ( ${LIB_DEPEND} )"
|
|
||||||
BDEPEND="
|
|
||||||
nls? ( sys-devel/gettext )
|
|
||||||
virtual/pkgconfig
|
|
||||||
"
|
|
||||||
|
|
||||||
REQUIRED_USE="!ncurses? ( slang? ( minimal ) )"
|
|
||||||
|
|
||||||
src_prepare() {
|
|
||||||
default
|
|
||||||
if [[ ${PV} == "9999" ]] ; then
|
|
||||||
eautoreconf
|
|
||||||
fi
|
|
||||||
}
|
|
||||||
|
|
||||||
src_configure() {
|
|
||||||
use static && append-ldflags -static
|
|
||||||
local myconf=(
|
|
||||||
--bindir="${EPREFIX}"/bin
|
|
||||||
--htmldir=/trash
|
|
||||||
$(use_enable !minimal color)
|
|
||||||
$(use_enable !minimal multibuffer)
|
|
||||||
$(use_enable !minimal nanorc)
|
|
||||||
$(use_enable magic libmagic)
|
|
||||||
$(use_enable spell speller)
|
|
||||||
$(use_enable justify)
|
|
||||||
$(use_enable debug)
|
|
||||||
$(use_enable nls)
|
|
||||||
$(use_enable unicode utf8)
|
|
||||||
$(use_enable minimal tiny)
|
|
||||||
$(usex ncurses --without-slang $(use_with slang))
|
|
||||||
)
|
|
||||||
econf "${myconf[@]}"
|
|
||||||
}
|
|
||||||
|
|
||||||
src_install() {
|
|
||||||
default
|
|
||||||
# don't use "${ED}" here or things break (#654534)
|
|
||||||
rm -r "${D}"/trash || die
|
|
||||||
|
|
||||||
dodoc doc/sample.nanorc
|
|
||||||
docinto html
|
|
||||||
dodoc doc/faq.html
|
|
||||||
insinto /etc
|
|
||||||
newins doc/sample.nanorc nanorc
|
|
||||||
if ! use minimal ; then
|
|
||||||
# Enable colorization by default.
|
|
||||||
sed -i \
|
|
||||||
-e '/^# include /s:# *::' \
|
|
||||||
"${ED}"/etc/nanorc || die
|
|
||||||
|
|
||||||
# Since nano-5.0 these are no longer being "enabled" by default
|
|
||||||
# (bug #736848)
|
|
||||||
local rcdir="/usr/share/nano"
|
|
||||||
mv "${ED}"${rcdir}/extra/* "${ED}"/${rcdir}/ || die
|
|
||||||
rmdir "${ED}"${rcdir}/extra || die
|
|
||||||
fi
|
|
||||||
|
|
||||||
use split-usr && dosym ../../bin/nano /usr/bin/nano
|
|
||||||
}
|
|
Binary file not shown.
@ -1,5 +1,3 @@
|
|||||||
DIST free42-nologo-2.0.20.tgz 7390214 BLAKE2B 306f3378bcbb44fa7982c5d9c29bfbea62e915ca50ca5e5216f46fbf483f110a1288d4800991a74622a042517496ff8dd94c3fa3249e8bb4181957e6b23d5ea3 SHA512 9b540fbc50df2f94b135b5e778354f330df77a54ef2ad99b257b5b91d1e3e8d1241e8a834522fc46fe33571ea2695ad8889b427dbcf653870672e89cd56d60f5
|
DIST free42-nologo-2.0.20.tgz 7390214 BLAKE2B 306f3378bcbb44fa7982c5d9c29bfbea62e915ca50ca5e5216f46fbf483f110a1288d4800991a74622a042517496ff8dd94c3fa3249e8bb4181957e6b23d5ea3 SHA512 9b540fbc50df2f94b135b5e778354f330df77a54ef2ad99b257b5b91d1e3e8d1241e8a834522fc46fe33571ea2695ad8889b427dbcf653870672e89cd56d60f5
|
||||||
DIST free42-nologo-2.5.14.tgz 7410951 BLAKE2B 5d8087269da86a2c8c00378a3bc51d2f85e2458283ab84dbee3f6d84a373423581b983faef184e794f3c2effd3bde568a4df627a29720d8cb3970e27ddc9c3ca SHA512 0e2ed3f13448d0ea60255d5e45831fcf14efef831f7c2fef59348bd15e1e4b0c42d1b24693de4e35d350367057bc14995767e8e099eb3ed46320c6f6ba97fe69
|
|
||||||
DIST free42-nologo-2.5.16.tgz 7412652 BLAKE2B bdea95adca140eecbb192706a5e611c1ad5d248b47aa609ac2733eb018ea74e7661a1797acf9458aa07b6015df7376b3ef329685cff984d364c2f5e26f7d213b SHA512 5adfe5ce09e3aecae7f05d3880234eb903eb48b36ee10e88be87a8941752323f97067b97cb85699fc03591fc355024eb6cd621f64c31e6e5c6dd4d5027f1ba34
|
|
||||||
DIST free42-nologo-2.5.17.tgz 7412893 BLAKE2B ce8a06d290d4fcc12fd9b98c9bb80e12b3dc0a8d53b87cba874bce5798812d667c9e61ac4d990ace9828b10bf223adb1e32274ca11837ec50b4b0559fe8d92ac SHA512 64efdb93a33780095360eb987ca5fa192336b285dcf785a268db59fa4aa8cf2c8ce91b8242c9b4d5efa9c4556f5d688894f60056117e1c0774147894e59d32c9
|
|
||||||
DIST free42-nologo-2.5.18.tgz 7413195 BLAKE2B c3d7d92c2f9b527fb6932f46644cb306217ab103bde1ecfd52a2659a1a71eaef199abeda8b24977e338757bfd57c824c31bc3bf9aa396e3372629b04737e6232 SHA512 3543d0a0cc4dff9c96c1121f221dded40f2574fffbd4747ef179b0d5cf75a003f49bc548df554fb46504af787d9d2fdb434c23a420f4b3592c838f4d00ac7140
|
DIST free42-nologo-2.5.18.tgz 7413195 BLAKE2B c3d7d92c2f9b527fb6932f46644cb306217ab103bde1ecfd52a2659a1a71eaef199abeda8b24977e338757bfd57c824c31bc3bf9aa396e3372629b04737e6232 SHA512 3543d0a0cc4dff9c96c1121f221dded40f2574fffbd4747ef179b0d5cf75a003f49bc548df554fb46504af787d9d2fdb434c23a420f4b3592c838f4d00ac7140
|
||||||
|
DIST free42-nologo-2.5.20.tgz 7414358 BLAKE2B f1e0963e6a808121efc4d9bd82863d8c7898f65504d4c59f6a6beadc0c4e5c1335ce4c65d25550a3f4d5c080e1933ad30f6325661af4a513f69941c48adda1a5 SHA512 04a01f29ed5a3c9374de98ead6c54191dbde6b0e3d9923b5c89f18f868630b50235711820e751e4a1e3efc0600b1a7a105e8800f660d67124458a8f2826c840f
|
||||||
|
@ -1,45 +0,0 @@
|
|||||||
diff -Naur free42-nologo-2.5.12.orig/gtk/Makefile free42-nologo-2.5.12/gtk/Makefile
|
|
||||||
--- free42-nologo-2.5.12.orig/gtk/Makefile 2019-11-28 20:11:51.000000000 +0100
|
|
||||||
+++ free42-nologo-2.5.12/gtk/Makefile 2019-11-29 17:59:58.292516949 +0100
|
|
||||||
@@ -15,7 +15,7 @@
|
|
||||||
# along with this program; if not, see http://www.gnu.org/licenses/.
|
|
||||||
###############################################################################
|
|
||||||
|
|
||||||
-CFLAGS = -MMD \
|
|
||||||
+CFLAGS := -MMD \
|
|
||||||
-Wall \
|
|
||||||
-Wno-parentheses \
|
|
||||||
-Wno-write-strings \
|
|
||||||
@@ -34,7 +34,8 @@
|
|
||||||
-DDECIMAL_GLOBAL_ROUNDING=1 \
|
|
||||||
-DDECIMAL_GLOBAL_ROUNDING_ACCESS_FUNCTIONS=1 \
|
|
||||||
-DDECIMAL_GLOBAL_EXCEPTION_FLAGS=1 \
|
|
||||||
- -DDECIMAL_GLOBAL_EXCEPTION_FLAGS_ACCESS_FUNCTIONS=1
|
|
||||||
+ -DDECIMAL_GLOBAL_EXCEPTION_FLAGS_ACCESS_FUNCTIONS=1 \
|
|
||||||
+ ${CFLAGS}
|
|
||||||
|
|
||||||
###############################################################################
|
|
||||||
### Note that there are deprecation warnings while compiling shell_main.cc ###
|
|
||||||
@@ -46,10 +47,11 @@
|
|
||||||
### GTK+ 3.22 for testing. ###
|
|
||||||
###############################################################################
|
|
||||||
|
|
||||||
-CXXFLAGS = $(CFLAGS) \
|
|
||||||
+CXXFLAGS := $(CFLAGS) \
|
|
||||||
-fno-exceptions \
|
|
||||||
-fno-rtti \
|
|
||||||
- -D_WCHAR_T_DEFINED
|
|
||||||
+ -D_WCHAR_T_DEFINED \
|
|
||||||
+ ${CFLAGS}
|
|
||||||
|
|
||||||
LIBS = gcc111libbid.a $(shell pkg-config --libs gtk+-3.0)
|
|
||||||
|
|
||||||
@@ -125,7 +127,7 @@
|
|
||||||
|
|
||||||
symlinks:
|
|
||||||
for fn in `cd ../common; /bin/ls`; do ln -s ../common/$$fn; done
|
|
||||||
- sh ./build-intel-lib.sh
|
|
||||||
+ +sh ./build-intel-lib.sh
|
|
||||||
ln -s IntelRDFPMathLib20U1/TESTS/readtest.c
|
|
||||||
touch symlinks
|
|
||||||
|
|
@ -1,50 +0,0 @@
|
|||||||
# Copyright 1999-2020 Gentoo Authors
|
|
||||||
# Distributed under the terms of the GNU General Public License v2
|
|
||||||
|
|
||||||
EAPI=7
|
|
||||||
|
|
||||||
inherit toolchain-funcs
|
|
||||||
|
|
||||||
MY_PV="${PN}-nologo-${PV}"
|
|
||||||
|
|
||||||
DESCRIPTION="An HP-42S Calculator Simulator"
|
|
||||||
HOMEPAGE="https://thomasokken.com/free42/"
|
|
||||||
SRC_URI="https://thomasokken.com/free42/upstream/${MY_PV}.tgz"
|
|
||||||
|
|
||||||
LICENSE="GPL-2"
|
|
||||||
SLOT="0"
|
|
||||||
KEYWORDS="~amd64 ~x86"
|
|
||||||
IUSE="+alsa"
|
|
||||||
|
|
||||||
DEPEND="dev-libs/atk
|
|
||||||
x11-libs/cairo
|
|
||||||
x11-libs/gdk-pixbuf
|
|
||||||
x11-libs/gtk+:3
|
|
||||||
alsa? ( media-libs/alsa-lib )"
|
|
||||||
|
|
||||||
RDEPEND="${DEPEND}"
|
|
||||||
|
|
||||||
DOCS=( CREDITS HISTORY README )
|
|
||||||
S="${WORKDIR}/${MY_PV}"
|
|
||||||
|
|
||||||
PATCHES=(
|
|
||||||
"${FILESDIR}/${PN}-2.5.12-fix-makefile.patch"
|
|
||||||
"${FILESDIR}/${PN}-2.5.3-fix-build-intel-lib.patch"
|
|
||||||
)
|
|
||||||
|
|
||||||
src_prepare() {
|
|
||||||
default
|
|
||||||
}
|
|
||||||
|
|
||||||
src_compile() {
|
|
||||||
local myconf
|
|
||||||
use alsa && myconf="AUDIO_ALSA=yes"
|
|
||||||
emake CC="$(tc-getCC)" CXX="$(tc-getCXX)" ${myconf} -C gtk
|
|
||||||
emake -C gtk clean
|
|
||||||
emake CC="$(tc-getCC)" CXX="$(tc-getCXX)" BCD_MATH=1 ${myconf} -C gtk
|
|
||||||
}
|
|
||||||
|
|
||||||
src_install() {
|
|
||||||
default
|
|
||||||
dobin gtk/free42bin gtk/free42dec
|
|
||||||
}
|
|
@ -1,50 +0,0 @@
|
|||||||
# Copyright 1999-2020 Gentoo Authors
|
|
||||||
# Distributed under the terms of the GNU General Public License v2
|
|
||||||
|
|
||||||
EAPI=7
|
|
||||||
|
|
||||||
inherit toolchain-funcs
|
|
||||||
|
|
||||||
MY_PV="${PN}-nologo-${PV}"
|
|
||||||
|
|
||||||
DESCRIPTION="An HP-42S Calculator Simulator"
|
|
||||||
HOMEPAGE="https://thomasokken.com/free42/"
|
|
||||||
SRC_URI="https://thomasokken.com/free42/upstream/${MY_PV}.tgz"
|
|
||||||
|
|
||||||
LICENSE="GPL-2"
|
|
||||||
SLOT="0"
|
|
||||||
KEYWORDS="~amd64 ~x86"
|
|
||||||
IUSE="+alsa"
|
|
||||||
|
|
||||||
DEPEND="dev-libs/atk
|
|
||||||
x11-libs/cairo
|
|
||||||
x11-libs/gdk-pixbuf
|
|
||||||
x11-libs/gtk+:3
|
|
||||||
alsa? ( media-libs/alsa-lib )"
|
|
||||||
|
|
||||||
RDEPEND="${DEPEND}"
|
|
||||||
|
|
||||||
DOCS=( CREDITS HISTORY README )
|
|
||||||
S="${WORKDIR}/${MY_PV}"
|
|
||||||
|
|
||||||
PATCHES=(
|
|
||||||
"${FILESDIR}/${PN}-2.5.16-fix-makefile.patch"
|
|
||||||
"${FILESDIR}/${PN}-2.5.3-fix-build-intel-lib.patch"
|
|
||||||
)
|
|
||||||
|
|
||||||
src_prepare() {
|
|
||||||
default
|
|
||||||
}
|
|
||||||
|
|
||||||
src_compile() {
|
|
||||||
local myconf
|
|
||||||
use alsa && myconf="AUDIO_ALSA=yes"
|
|
||||||
emake CC="$(tc-getCC)" CXX="$(tc-getCXX)" ${myconf} -C gtk
|
|
||||||
emake -C gtk clean
|
|
||||||
emake CC="$(tc-getCC)" CXX="$(tc-getCXX)" BCD_MATH=1 ${myconf} -C gtk
|
|
||||||
}
|
|
||||||
|
|
||||||
src_install() {
|
|
||||||
default
|
|
||||||
dobin gtk/free42bin gtk/free42dec
|
|
||||||
}
|
|
@ -1,4 +1,2 @@
|
|||||||
DIST libvirt-6.2.0.tar.xz 8307248 BLAKE2B 9d449e041fc548a688f974d0801e625cf023ef0df49c40028e486e88fcf14181869e0dfd87f0eabcdd184df67dda5b5fbdc0c2375832f1534faff531779255dd SHA512 96bef701fd73aef93d1490f0bc331901a0ff6250a4f36a3e4844f76cc262dc0ae4cce8686a603c2a9c575ce489d8d5ed1521ebd22b92aff8301efdb74dee91e4
|
|
||||||
DIST libvirt-6.5.0.tar.xz 9407160 BLAKE2B 592aace555a3b72311cb430784587180fa7dbf74f75509cd8373a046339b9c4c0707bf530dd2d06146d78a85f8af3dba5d0b146ecec180d3cc4d3bf78c19da61 SHA512 30a032270304b97945ff2c5087c72c2f5510634186f2eaf7c3d834a72cddcaec97bbe5ccc86802728a59f4c80b5bb54757400683df5f20175757cfe07ce67453
|
|
||||||
DIST libvirt-6.7.0.tar.xz 8362140 BLAKE2B d0afe33fcdaab3cc0f2ea8c552e7550bcece018b049a3b58e5c05ee85b39e2b3ebf42fa1b70ddb1d2a541d1114b6b49734f23a889b3589397a30a672f27a3a56 SHA512 cabfb6aa65a3a1412b0111654ad3a7d0a6dfc63399a892c540ca39ab4e56f87626a067037e4480bb55418a371d2b5e9ac74862c92a3cdea69822ec3d158d769f
|
DIST libvirt-6.7.0.tar.xz 8362140 BLAKE2B d0afe33fcdaab3cc0f2ea8c552e7550bcece018b049a3b58e5c05ee85b39e2b3ebf42fa1b70ddb1d2a541d1114b6b49734f23a889b3589397a30a672f27a3a56 SHA512 cabfb6aa65a3a1412b0111654ad3a7d0a6dfc63399a892c540ca39ab4e56f87626a067037e4480bb55418a371d2b5e9ac74862c92a3cdea69822ec3d158d769f
|
||||||
DIST libvirt-6.8.0.tar.xz 8412092 BLAKE2B c118ca6b263054bb6941c62f3d1415f7ed1a3f29a35294272d04bc726643247ee5691e0310a1bf013faeba856d7aadd00a90fe8dbdca6ff4c7eb480e94d92fa2 SHA512 9b69f3dcceb5e40470a78908654faf51b643f6793e556f3115daa4bfe08743af290882dd51f15eb27c38d589eb210d495de7c44a40b363420ab4f4d3a6393cc9
|
DIST libvirt-6.8.0.tar.xz 8412092 BLAKE2B c118ca6b263054bb6941c62f3d1415f7ed1a3f29a35294272d04bc726643247ee5691e0310a1bf013faeba856d7aadd00a90fe8dbdca6ff4c7eb480e94d92fa2 SHA512 9b69f3dcceb5e40470a78908654faf51b643f6793e556f3115daa4bfe08743af290882dd51f15eb27c38d589eb210d495de7c44a40b363420ab4f4d3a6393cc9
|
||||||
|
@ -1,150 +0,0 @@
|
|||||||
diff --git a/src/Makefile.am b/src/Makefile.am
|
|
||||||
index c9b5eeb..423a201 100644
|
|
||||||
--- a/src/Makefile.am
|
|
||||||
+++ b/src/Makefile.am
|
|
||||||
@@ -533,23 +533,6 @@ EXTRA_DIST += \
|
|
||||||
$(SYSCONF_FILES) \
|
|
||||||
$(OPENRC_CONF_FILES)
|
|
||||||
|
|
||||||
-install-sysconfig:
|
|
||||||
- $(MKDIR_P) $(DESTDIR)$(sysconfdir)/sysconfig
|
|
||||||
- for f in $(SYSCONF_FILES:%.sysconf=%) ; \
|
|
||||||
- do \
|
|
||||||
- tgt=`basename $$f`; \
|
|
||||||
- $(INSTALL_DATA) $(srcdir)/$$f.sysconf \
|
|
||||||
- $(DESTDIR)$(sysconfdir)/sysconfig/$$tgt; \
|
|
||||||
- done
|
|
||||||
-
|
|
||||||
-uninstall-sysconfig:
|
|
||||||
- for f in $(SYSCONF_FILES:%.sysconf=%) ; \
|
|
||||||
- do \
|
|
||||||
- tgt=`basename $$f`; \
|
|
||||||
- rm -f $(DESTDIR)$(sysconfdir)/sysconfig/$$tgt; \
|
|
||||||
- done
|
|
||||||
- rmdir $(DESTDIR)$(sysconfdir)/sysconfig || :
|
|
||||||
-
|
|
||||||
OPENRC_CONF_DIR = $(sysconfdir)/conf.d
|
|
||||||
|
|
||||||
install-openrc-conf:
|
|
||||||
@@ -615,14 +598,14 @@ SYSTEMD_UNIT_DIR = $(prefix)/lib/systemd/system
|
|
||||||
BUILT_SOURCES += $(SYSTEMD_UNIT_FILES)
|
|
||||||
DISTCLEANFILES += $(SYSTEMD_UNIT_FILES)
|
|
||||||
|
|
||||||
-install-systemd: $(SYSTEMD_UNIT_FILES) install-sysconfig
|
|
||||||
+install-systemd: $(SYSTEMD_UNIT_FILES)
|
|
||||||
$(MKDIR_P) $(DESTDIR)$(SYSTEMD_UNIT_DIR)
|
|
||||||
for f in $(SYSTEMD_UNIT_FILES); \
|
|
||||||
do \
|
|
||||||
$(INSTALL_DATA) $$f $(DESTDIR)$(SYSTEMD_UNIT_DIR)/ ; \
|
|
||||||
done
|
|
||||||
|
|
||||||
-uninstall-systemd: uninstall-sysconfig
|
|
||||||
+uninstall-systemd:
|
|
||||||
rm -f $(SYSTEMD_UNIT_FILES:%=$(DESTDIR)$(SYSTEMD_UNIT_DIR)/%)
|
|
||||||
rmdir $(DESTDIR)$(SYSTEMD_UNIT_DIR) || :
|
|
||||||
|
|
||||||
diff --git a/src/locking/virtlockd.service.in b/src/locking/virtlockd.service.in
|
|
||||||
index e7f8057..2449b20 100644
|
|
||||||
--- a/src/locking/virtlockd.service.in
|
|
||||||
+++ b/src/locking/virtlockd.service.in
|
|
||||||
@@ -7,8 +7,7 @@ Documentation=man:virtlockd(8)
|
|
||||||
Documentation=https://libvirt.org
|
|
||||||
|
|
||||||
[Service]
|
|
||||||
-EnvironmentFile=-@sysconfdir@/sysconfig/virtlockd
|
|
||||||
-ExecStart=@sbindir@/virtlockd $VIRTLOCKD_ARGS
|
|
||||||
+ExecStart=@sbindir@/virtlockd
|
|
||||||
ExecReload=/bin/kill -USR1 $MAINPID
|
|
||||||
# Loosing the locks is a really bad thing that will
|
|
||||||
# cause the machine to be fenced (rebooted), so make
|
|
||||||
diff --git a/src/logging/virtlogd.service.in b/src/logging/virtlogd.service.in
|
|
||||||
index daff48e..4373619 100644
|
|
||||||
--- a/src/logging/virtlogd.service.in
|
|
||||||
+++ b/src/logging/virtlogd.service.in
|
|
||||||
@@ -7,8 +7,7 @@ Documentation=man:virtlogd(8)
|
|
||||||
Documentation=https://libvirt.org
|
|
||||||
|
|
||||||
[Service]
|
|
||||||
-EnvironmentFile=-@sysconfdir@/sysconfig/virtlogd
|
|
||||||
-ExecStart=@sbindir@/virtlogd $VIRTLOGD_ARGS
|
|
||||||
+ExecStart=@sbindir@/virtlogd
|
|
||||||
ExecReload=/bin/kill -USR1 $MAINPID
|
|
||||||
# Loosing the logs is a really bad thing that will
|
|
||||||
# cause the machine to be fenced (rebooted), so make
|
|
||||||
diff --git a/src/remote/libvirtd.service.in b/src/remote/libvirtd.service.in
|
|
||||||
index 9c8c54a..a042280 100644
|
|
||||||
--- a/src/remote/libvirtd.service.in
|
|
||||||
+++ b/src/remote/libvirtd.service.in
|
|
||||||
@@ -25,8 +25,7 @@ Documentation=https://libvirt.org
|
|
||||||
|
|
||||||
[Service]
|
|
||||||
Type=notify
|
|
||||||
-EnvironmentFile=-@sysconfdir@/sysconfig/libvirtd
|
|
||||||
-ExecStart=@sbindir@/libvirtd $LIBVIRTD_ARGS
|
|
||||||
+ExecStart=@sbindir@/libvirtd
|
|
||||||
ExecReload=/bin/kill -HUP $MAINPID
|
|
||||||
KillMode=process
|
|
||||||
Restart=on-failure
|
|
||||||
diff --git a/tools/Makefile.am b/tools/Makefile.am
|
|
||||||
index 426a6ba..a65c91a 100644
|
|
||||||
--- a/tools/Makefile.am
|
|
||||||
+++ b/tools/Makefile.am
|
|
||||||
@@ -297,15 +297,6 @@ install-data-local: install-systemd install-nss \
|
|
||||||
uninstall-local: uninstall-systemd uninstall-nss \
|
|
||||||
uninstall-bash-completion
|
|
||||||
|
|
||||||
-install-sysconfig:
|
|
||||||
- $(MKDIR_P) $(DESTDIR)$(sysconfdir)/sysconfig
|
|
||||||
- $(INSTALL_DATA) $(srcdir)/libvirt-guests.sysconf \
|
|
||||||
- $(DESTDIR)$(sysconfdir)/sysconfig/libvirt-guests
|
|
||||||
-
|
|
||||||
-uninstall-sysconfig:
|
|
||||||
- rm -f $(DESTDIR)$(sysconfdir)/sysconfig/libvirt-guests
|
|
||||||
- rmdir $(DESTDIR)$(sysconfdir)/sysconfig ||:
|
|
||||||
-
|
|
||||||
EXTRA_DIST += libvirt-guests.sh.in
|
|
||||||
|
|
||||||
libvirt-guests.sh: libvirt-guests.sh.in $(top_builddir)/config.status
|
|
||||||
@@ -325,12 +316,12 @@ EXTRA_DIST += libvirt-guests.service.in
|
|
||||||
SYSTEMD_UNIT_DIR = $(prefix)/lib/systemd/system
|
|
||||||
|
|
||||||
if LIBVIRT_INIT_SCRIPT_SYSTEMD
|
|
||||||
-install-systemd: libvirt-guests.service install-sysconfig libvirt-guests.sh
|
|
||||||
+install-systemd: libvirt-guests.service libvirt-guests.sh
|
|
||||||
$(MKDIR_P) $(DESTDIR)$(SYSTEMD_UNIT_DIR)
|
|
||||||
$(INSTALL_DATA) libvirt-guests.service \
|
|
||||||
$(DESTDIR)$(SYSTEMD_UNIT_DIR)/libvirt-guests.service
|
|
||||||
|
|
||||||
-uninstall-systemd: uninstall-sysconfig
|
|
||||||
+uninstall-systemd:
|
|
||||||
rm -f $(DESTDIR)$(SYSTEMD_UNIT_DIR)/libvirt-guests.service
|
|
||||||
rmdir $(DESTDIR)$(SYSTEMD_UNIT_DIR) ||:
|
|
||||||
|
|
||||||
diff --git a/tools/libvirt-guests.service.in b/tools/libvirt-guests.service.in
|
|
||||||
index 10c6640..f0f417b 100644
|
|
||||||
--- a/tools/libvirt-guests.service.in
|
|
||||||
+++ b/tools/libvirt-guests.service.in
|
|
||||||
@@ -10,7 +10,7 @@ Documentation=man:libvirtd(8)
|
|
||||||
Documentation=https://libvirt.org
|
|
||||||
|
|
||||||
[Service]
|
|
||||||
-EnvironmentFile=-@sysconfdir@/sysconfig/libvirt-guests
|
|
||||||
+EnvironmentFile=-/etc/libvirt/libvirt-guests.conf
|
|
||||||
# Hack just call traditional service until we factor
|
|
||||||
# out the code
|
|
||||||
ExecStart=@libexecdir@/libvirt-guests.sh start
|
|
||||||
diff --git a/tools/libvirt-guests.sysconf b/tools/libvirt-guests.sysconf
|
|
||||||
index 669b046..45b0b9e 100644
|
|
||||||
--- a/tools/libvirt-guests.sysconf
|
|
||||||
+++ b/tools/libvirt-guests.sysconf
|
|
||||||
@@ -1,3 +1,10 @@
|
|
||||||
+#
|
|
||||||
+# Warning: This configuration file is only sourced by the systemd
|
|
||||||
+# libvirt-guests.service unit. The coresponding openrc facility is in
|
|
||||||
+# /etc/init.d/libvirtd and /etc/conf.d/libvirtd
|
|
||||||
+#
|
|
||||||
+
|
|
||||||
+
|
|
||||||
# URIs to check for running guests
|
|
||||||
# example: URIS='default xen:///system vbox+tcp://host/system lxc:///system'
|
|
||||||
#URIS=default
|
|
@ -1,70 +0,0 @@
|
|||||||
diff --git a/src/Makefile.in b/src/Makefile.in
|
|
||||||
index 36bd280..07cebdf 100644
|
|
||||||
--- a/src/Makefile.in
|
|
||||||
+++ b/src/Makefile.in
|
|
||||||
@@ -4473,7 +4473,7 @@ SECURITY_DRIVER_APPARMOR_SOURCES = \
|
|
||||||
$(NULL)
|
|
||||||
|
|
||||||
SECURITY_DRIVER_APPARMOR_GENERATED_PROFILES_IN = \
|
|
||||||
- security/apparmor/usr.lib.libvirt.virt-aa-helper.in \
|
|
||||||
+ security/apparmor/usr.libexec.virt-aa-helper.in \
|
|
||||||
security/apparmor/usr.sbin.libvirtd.in \
|
|
||||||
$(NULL)
|
|
||||||
|
|
||||||
@@ -13821,11 +13821,11 @@ security/apparmor/%: $(srcdir)/security/apparmor/%.in
|
|
||||||
@WITH_APPARMOR_PROFILES_TRUE@install-apparmor-local: $(SECURITY_DRIVER_APPARMOR_GENERATED_PROFILES)
|
|
||||||
@WITH_APPARMOR_PROFILES_TRUE@ $(MKDIR_P) "$(APPARMOR_LOCAL_DIR)"
|
|
||||||
@WITH_APPARMOR_PROFILES_TRUE@ echo "# Site-specific additions and overrides for \
|
|
||||||
-@WITH_APPARMOR_PROFILES_TRUE@ 'usr.lib.libvirt.virt-aa-helper'" \
|
|
||||||
-@WITH_APPARMOR_PROFILES_TRUE@ >"$(APPARMOR_LOCAL_DIR)/usr.lib.libvirt.virt-aa-helper"
|
|
||||||
+@WITH_APPARMOR_PROFILES_TRUE@ 'usr.libexec.virt-aa-helper'" \
|
|
||||||
+@WITH_APPARMOR_PROFILES_TRUE@ >"$(APPARMOR_LOCAL_DIR)/usr.libexec.virt-aa-helper"
|
|
||||||
|
|
||||||
@WITH_APPARMOR_PROFILES_TRUE@uninstall-apparmor-local:
|
|
||||||
-@WITH_APPARMOR_PROFILES_TRUE@ rm -f "$(APPARMOR_LOCAL_DIR)/usr.lib.libvirt.virt-aa-helper"
|
|
||||||
+@WITH_APPARMOR_PROFILES_TRUE@ rm -f "$(APPARMOR_LOCAL_DIR)/usr.libexec.virt-aa-helper"
|
|
||||||
@WITH_APPARMOR_PROFILES_TRUE@ rmdir "$(APPARMOR_LOCAL_DIR)" || :
|
|
||||||
|
|
||||||
$(ACCESS_DRIVER_POLKIT_POLICY): $(srcdir)/access/viraccessperm.h \
|
|
||||||
diff --git a/src/security/Makefile.inc.am b/src/security/Makefile.inc.am
|
|
||||||
index 5f2f4c8..d457cc6 100644
|
|
||||||
--- a/src/security/Makefile.inc.am
|
|
||||||
+++ b/src/security/Makefile.inc.am
|
|
||||||
@@ -31,7 +31,7 @@ SECURITY_DRIVER_APPARMOR_SOURCES = \
|
|
||||||
$(NULL)
|
|
||||||
|
|
||||||
SECURITY_DRIVER_APPARMOR_GENERATED_PROFILES_IN = \
|
|
||||||
- security/apparmor/usr.lib.libvirt.virt-aa-helper.in \
|
|
||||||
+ security/apparmor/usr.libexec.virt-aa-helper.in \
|
|
||||||
security/apparmor/usr.sbin.libvirtd.in \
|
|
||||||
$(NULL)
|
|
||||||
|
|
||||||
@@ -130,11 +130,11 @@ APPARMOR_LOCAL_DIR = "$(DESTDIR)$(apparmordir)/local"
|
|
||||||
install-apparmor-local: $(SECURITY_DRIVER_APPARMOR_GENERATED_PROFILES)
|
|
||||||
$(MKDIR_P) "$(APPARMOR_LOCAL_DIR)"
|
|
||||||
echo "# Site-specific additions and overrides for \
|
|
||||||
- 'usr.lib.libvirt.virt-aa-helper'" \
|
|
||||||
- >"$(APPARMOR_LOCAL_DIR)/usr.lib.libvirt.virt-aa-helper"
|
|
||||||
+ 'usr.libexec.virt-aa-helper'" \
|
|
||||||
+ >"$(APPARMOR_LOCAL_DIR)/usr.libexec.virt-aa-helper"
|
|
||||||
|
|
||||||
uninstall-apparmor-local:
|
|
||||||
- rm -f "$(APPARMOR_LOCAL_DIR)/usr.lib.libvirt.virt-aa-helper"
|
|
||||||
+ rm -f "$(APPARMOR_LOCAL_DIR)/usr.libexec.virt-aa-helper"
|
|
||||||
rmdir "$(APPARMOR_LOCAL_DIR)" || :
|
|
||||||
|
|
||||||
INSTALL_DATA_LOCAL += install-apparmor-local
|
|
||||||
diff --git a/src/security/apparmor/usr.lib.libvirt.virt-aa-helper.in b/src/security/apparmor/usr.libexec.virt-aa-helper.in
|
|
||||||
similarity index 97%
|
|
||||||
rename from src/security/apparmor/usr.lib.libvirt.virt-aa-helper.in
|
|
||||||
rename to src/security/apparmor/usr.libexec.virt-aa-helper.in
|
|
||||||
index dd18c8a..d06f9cb 100644
|
|
||||||
--- a/src/security/apparmor/usr.lib.libvirt.virt-aa-helper.in
|
|
||||||
+++ b/src/security/apparmor/usr.libexec.virt-aa-helper.in
|
|
||||||
@@ -69,5 +69,5 @@ profile virt-aa-helper @libexecdir@/virt-aa-helper {
|
|
||||||
/**.[iI][sS][oO] r,
|
|
||||||
/**/disk{,.*} r,
|
|
||||||
|
|
||||||
- #include <local/usr.lib.libvirt.virt-aa-helper>
|
|
||||||
+ #include <local/usr.libexec.virt-aa-helper>
|
|
||||||
}
|
|
@ -1,245 +0,0 @@
|
|||||||
--- a/src/Makefile.am
|
|
||||||
+++ b/src/Makefile.am
|
|
||||||
@@ -522,23 +522,6 @@
|
|
||||||
$(SYSCONF_FILES) \
|
|
||||||
$(OPENRC_CONF_FILES)
|
|
||||||
|
|
||||||
-install-sysconfig:
|
|
||||||
- $(MKDIR_P) $(DESTDIR)$(sysconfdir)/sysconfig
|
|
||||||
- for f in $(SYSCONF_FILES:%.sysconf=%) ; \
|
|
||||||
- do \
|
|
||||||
- tgt=`basename $$f`; \
|
|
||||||
- $(INSTALL_DATA) $(srcdir)/$$f.sysconf \
|
|
||||||
- $(DESTDIR)$(sysconfdir)/sysconfig/$$tgt; \
|
|
||||||
- done
|
|
||||||
-
|
|
||||||
-uninstall-sysconfig:
|
|
||||||
- for f in $(SYSCONF_FILES:%.sysconf=%) ; \
|
|
||||||
- do \
|
|
||||||
- tgt=`basename $$f`; \
|
|
||||||
- rm -f $(DESTDIR)$(sysconfdir)/sysconfig/$$tgt; \
|
|
||||||
- done
|
|
||||||
- rmdir $(DESTDIR)$(sysconfdir)/sysconfig || :
|
|
||||||
-
|
|
||||||
OPENRC_CONF_DIR = $(sysconfdir)/conf.d
|
|
||||||
|
|
||||||
install-openrc-conf:
|
|
||||||
@@ -604,14 +587,14 @@
|
|
||||||
BUILT_SOURCES += $(SYSTEMD_UNIT_FILES)
|
|
||||||
DISTCLEANFILES += $(SYSTEMD_UNIT_FILES)
|
|
||||||
|
|
||||||
-install-systemd: $(SYSTEMD_UNIT_FILES) install-sysconfig
|
|
||||||
+install-systemd: $(SYSTEMD_UNIT_FILES)
|
|
||||||
$(MKDIR_P) $(DESTDIR)$(SYSTEMD_UNIT_DIR)
|
|
||||||
for f in $(SYSTEMD_UNIT_FILES); \
|
|
||||||
do \
|
|
||||||
$(INSTALL_DATA) $$f $(DESTDIR)$(SYSTEMD_UNIT_DIR)/ ; \
|
|
||||||
done
|
|
||||||
|
|
||||||
-uninstall-systemd: uninstall-sysconfig
|
|
||||||
+uninstall-systemd:
|
|
||||||
rm -f $(SYSTEMD_UNIT_FILES:%=$(DESTDIR)$(SYSTEMD_UNIT_DIR)/%)
|
|
||||||
rmdir $(DESTDIR)$(SYSTEMD_UNIT_DIR) || :
|
|
||||||
|
|
||||||
--- a/src/interface/virtinterfaced.service.in
|
|
||||||
+++ b/src/interface/virtinterfaced.service.in
|
|
||||||
@@ -13,7 +13,6 @@
|
|
||||||
|
|
||||||
[Service]
|
|
||||||
Type=notify
|
|
||||||
-EnvironmentFile=-@sysconfdir@/sysconfig/virtinterfaced
|
|
||||||
ExecStart=@sbindir@/virtinterfaced $VIRTINTERFACED_ARGS
|
|
||||||
ExecReload=/bin/kill -HUP $MAINPID
|
|
||||||
Restart=on-failure
|
|
||||||
--- a/src/libxl/virtxend.service.in
|
|
||||||
+++ b/src/libxl/virtxend.service.in
|
|
||||||
@@ -17,7 +17,6 @@
|
|
||||||
|
|
||||||
[Service]
|
|
||||||
Type=notify
|
|
||||||
-EnvironmentFile=-@sysconfdir@/sysconfig/virtxend
|
|
||||||
ExecStart=@sbindir@/virtxend $VIRTXEND_ARGS
|
|
||||||
ExecReload=/bin/kill -HUP $MAINPID
|
|
||||||
Restart=on-failure
|
|
||||||
--- a/src/locking/virtlockd.service.in
|
|
||||||
+++ b/src/locking/virtlockd.service.in
|
|
||||||
@@ -7,8 +7,7 @@
|
|
||||||
Documentation=https://libvirt.org
|
|
||||||
|
|
||||||
[Service]
|
|
||||||
-EnvironmentFile=-@sysconfdir@/sysconfig/virtlockd
|
|
||||||
-ExecStart=@sbindir@/virtlockd $VIRTLOCKD_ARGS
|
|
||||||
+ExecStart=@sbindir@/virtlockd
|
|
||||||
ExecReload=/bin/kill -USR1 $MAINPID
|
|
||||||
# Loosing the locks is a really bad thing that will
|
|
||||||
# cause the machine to be fenced (rebooted), so make
|
|
||||||
--- a/src/logging/virtlogd.service.in
|
|
||||||
+++ b/src/logging/virtlogd.service.in
|
|
||||||
@@ -7,8 +7,7 @@
|
|
||||||
Documentation=https://libvirt.org
|
|
||||||
|
|
||||||
[Service]
|
|
||||||
-EnvironmentFile=-@sysconfdir@/sysconfig/virtlogd
|
|
||||||
-ExecStart=@sbindir@/virtlogd $VIRTLOGD_ARGS
|
|
||||||
+ExecStart=@sbindir@/virtlogd
|
|
||||||
ExecReload=/bin/kill -USR1 $MAINPID
|
|
||||||
# Loosing the logs is a really bad thing that will
|
|
||||||
# cause the machine to be fenced (rebooted), so make
|
|
||||||
--- a/src/lxc/virtlxcd.service.in
|
|
||||||
+++ b/src/lxc/virtlxcd.service.in
|
|
||||||
@@ -18,7 +18,6 @@
|
|
||||||
|
|
||||||
[Service]
|
|
||||||
Type=notify
|
|
||||||
-EnvironmentFile=-@sysconfdir@/sysconfig/virtlxcd
|
|
||||||
ExecStart=@sbindir@/virtlxcd $VIRTLXCD_ARGS
|
|
||||||
ExecReload=/bin/kill -HUP $MAINPID
|
|
||||||
KillMode=process
|
|
||||||
--- a/src/network/virtnetworkd.service.in
|
|
||||||
+++ b/src/network/virtnetworkd.service.in
|
|
||||||
@@ -16,7 +16,6 @@
|
|
||||||
|
|
||||||
[Service]
|
|
||||||
Type=notify
|
|
||||||
-EnvironmentFile=-@sysconfdir@/sysconfig/virtnetworkd
|
|
||||||
ExecStart=@sbindir@/virtnetworkd $VIRTNETWORKD_ARGS
|
|
||||||
ExecReload=/bin/kill -HUP $MAINPID
|
|
||||||
Restart=on-failure
|
|
||||||
--- a/src/node_device/virtnodedevd.service.in
|
|
||||||
+++ b/src/node_device/virtnodedevd.service.in
|
|
||||||
@@ -13,7 +13,6 @@
|
|
||||||
|
|
||||||
[Service]
|
|
||||||
Type=notify
|
|
||||||
-EnvironmentFile=-@sysconfdir@/sysconfig/virtnodedevd
|
|
||||||
ExecStart=@sbindir@/virtnodedevd $VIRTNODEDEVD_ARGS
|
|
||||||
ExecReload=/bin/kill -HUP $MAINPID
|
|
||||||
Restart=on-failure
|
|
||||||
--- a/src/nwfilter/virtnwfilterd.service.in
|
|
||||||
+++ b/src/nwfilter/virtnwfilterd.service.in
|
|
||||||
@@ -13,7 +13,6 @@
|
|
||||||
|
|
||||||
[Service]
|
|
||||||
Type=notify
|
|
||||||
-EnvironmentFile=-@sysconfdir@/sysconfig/virtnwfilterd
|
|
||||||
ExecStart=@sbindir@/virtnwfilterd $VIRTNWFILTERD_ARGS
|
|
||||||
ExecReload=/bin/kill -HUP $MAINPID
|
|
||||||
Restart=on-failure
|
|
||||||
--- a/src/qemu/virtqemud.service.in
|
|
||||||
+++ b/src/qemu/virtqemud.service.in
|
|
||||||
@@ -18,7 +18,6 @@
|
|
||||||
|
|
||||||
[Service]
|
|
||||||
Type=notify
|
|
||||||
-EnvironmentFile=-@sysconfdir@/sysconfig/virtqemud
|
|
||||||
ExecStart=@sbindir@/virtqemud $VIRTQEMUD_ARGS
|
|
||||||
ExecReload=/bin/kill -HUP $MAINPID
|
|
||||||
KillMode=process
|
|
||||||
--- a/src/remote/libvirtd.service.in
|
|
||||||
+++ b/src/remote/libvirtd.service.in
|
|
||||||
@@ -28,8 +28,7 @@
|
|
||||||
|
|
||||||
[Service]
|
|
||||||
Type=notify
|
|
||||||
-EnvironmentFile=-@sysconfdir@/sysconfig/libvirtd
|
|
||||||
-ExecStart=@sbindir@/libvirtd $LIBVIRTD_ARGS
|
|
||||||
+ExecStart=@sbindir@/libvirtd
|
|
||||||
ExecReload=/bin/kill -HUP $MAINPID
|
|
||||||
KillMode=process
|
|
||||||
Restart=on-failure
|
|
||||||
--- a/src/remote/virtproxyd.service.in
|
|
||||||
+++ b/src/remote/virtproxyd.service.in
|
|
||||||
@@ -13,7 +13,6 @@
|
|
||||||
|
|
||||||
[Service]
|
|
||||||
Type=notify
|
|
||||||
-EnvironmentFile=-@sysconfdir@/sysconfig/virtproxyd
|
|
||||||
ExecStart=@sbindir@/virtproxyd $VIRTPROXYD_ARGS
|
|
||||||
ExecReload=/bin/kill -HUP $MAINPID
|
|
||||||
Restart=on-failure
|
|
||||||
--- a/src/secret/virtsecretd.service.in
|
|
||||||
+++ b/src/secret/virtsecretd.service.in
|
|
||||||
@@ -13,7 +13,6 @@
|
|
||||||
|
|
||||||
[Service]
|
|
||||||
Type=notify
|
|
||||||
-EnvironmentFile=-@sysconfdir@/sysconfig/virtsecretd
|
|
||||||
ExecStart=@sbindir@/virtsecretd $VIRTSECRETD_ARGS
|
|
||||||
ExecReload=/bin/kill -HUP $MAINPID
|
|
||||||
Restart=on-failure
|
|
||||||
--- a/src/storage/virtstoraged.service.in
|
|
||||||
+++ b/src/storage/virtstoraged.service.in
|
|
||||||
@@ -15,7 +15,6 @@
|
|
||||||
|
|
||||||
[Service]
|
|
||||||
Type=notify
|
|
||||||
-EnvironmentFile=-@sysconfdir@/sysconfig/virtstoraged
|
|
||||||
ExecStart=@sbindir@/virtstoraged $VIRTSTORAGED_ARGS
|
|
||||||
ExecReload=/bin/kill -HUP $MAINPID
|
|
||||||
Restart=on-failure
|
|
||||||
--- a/src/vbox/virtvboxd.service.in
|
|
||||||
+++ b/src/vbox/virtvboxd.service.in
|
|
||||||
@@ -14,7 +14,6 @@
|
|
||||||
|
|
||||||
[Service]
|
|
||||||
Type=notify
|
|
||||||
-EnvironmentFile=-@sysconfdir@/sysconfig/virtvboxd
|
|
||||||
ExecStart=@sbindir@/virtvboxd $VIRTVBOXD_ARGS
|
|
||||||
ExecReload=/bin/kill -HUP $MAINPID
|
|
||||||
Restart=on-failure
|
|
||||||
--- a/tools/Makefile.am
|
|
||||||
+++ b/tools/Makefile.am
|
|
||||||
@@ -294,15 +294,6 @@
|
|
||||||
uninstall-local: uninstall-systemd uninstall-nss \
|
|
||||||
uninstall-bash-completion
|
|
||||||
|
|
||||||
-install-sysconfig:
|
|
||||||
- $(MKDIR_P) $(DESTDIR)$(sysconfdir)/sysconfig
|
|
||||||
- $(INSTALL_DATA) $(srcdir)/libvirt-guests.sysconf \
|
|
||||||
- $(DESTDIR)$(sysconfdir)/sysconfig/libvirt-guests
|
|
||||||
-
|
|
||||||
-uninstall-sysconfig:
|
|
||||||
- rm -f $(DESTDIR)$(sysconfdir)/sysconfig/libvirt-guests
|
|
||||||
- rmdir $(DESTDIR)$(sysconfdir)/sysconfig ||:
|
|
||||||
-
|
|
||||||
EXTRA_DIST += libvirt-guests.sh.in
|
|
||||||
|
|
||||||
libvirt-guests.sh: libvirt-guests.sh.in $(top_builddir)/config.status
|
|
||||||
@@ -322,12 +313,12 @@
|
|
||||||
SYSTEMD_UNIT_DIR = $(prefix)/lib/systemd/system
|
|
||||||
|
|
||||||
if LIBVIRT_INIT_SCRIPT_SYSTEMD
|
|
||||||
-install-systemd: libvirt-guests.service install-sysconfig libvirt-guests.sh
|
|
||||||
+install-systemd: libvirt-guests.service libvirt-guests.sh
|
|
||||||
$(MKDIR_P) $(DESTDIR)$(SYSTEMD_UNIT_DIR)
|
|
||||||
$(INSTALL_DATA) libvirt-guests.service \
|
|
||||||
$(DESTDIR)$(SYSTEMD_UNIT_DIR)/libvirt-guests.service
|
|
||||||
|
|
||||||
-uninstall-systemd: uninstall-sysconfig
|
|
||||||
+uninstall-systemd:
|
|
||||||
rm -f $(DESTDIR)$(SYSTEMD_UNIT_DIR)/libvirt-guests.service
|
|
||||||
rmdir $(DESTDIR)$(SYSTEMD_UNIT_DIR) ||:
|
|
||||||
|
|
||||||
--- a/tools/libvirt-guests.service.in
|
|
||||||
+++ b/tools/libvirt-guests.service.in
|
|
||||||
@@ -10,7 +10,7 @@
|
|
||||||
Documentation=https://libvirt.org
|
|
||||||
|
|
||||||
[Service]
|
|
||||||
-EnvironmentFile=-@sysconfdir@/sysconfig/libvirt-guests
|
|
||||||
+EnvironmentFile=-/etc/libvirt/libvirt-guests.conf
|
|
||||||
# Hack just call traditional service until we factor
|
|
||||||
# out the code
|
|
||||||
ExecStart=@libexecdir@/libvirt-guests.sh start
|
|
||||||
--- a/tools/libvirt-guests.sysconf
|
|
||||||
+++ b/tools/libvirt-guests.sysconf
|
|
||||||
@@ -1,3 +1,9 @@
|
|
||||||
+#
|
|
||||||
+# Warning: This configuration file is only sourced by the systemd
|
|
||||||
+# libvirt-guests.service unit. The coresponding openrc facility is in
|
|
||||||
+# /etc/init.d/libvirtd and /etc/conf.d/libvirtd
|
|
||||||
+#
|
|
||||||
+
|
|
||||||
# Customizations for the libvirt-guests.service systemd unit
|
|
||||||
|
|
||||||
# URIs to check for running guests
|
|
@ -1,82 +0,0 @@
|
|||||||
diff --git a/src/Makefile.in b/src/Makefile.in
|
|
||||||
index 36bd280..07cebdf 100644
|
|
||||||
--- a/src/Makefile.in
|
|
||||||
+++ b/src/Makefile.in
|
|
||||||
@@ -4473,7 +4473,7 @@ SECURITY_DRIVER_APPARMOR_SOURCES = \
|
|
||||||
$(NULL)
|
|
||||||
|
|
||||||
SECURITY_DRIVER_APPARMOR_GENERATED_PROFILES_IN = \
|
|
||||||
- security/apparmor/usr.lib.libvirt.virt-aa-helper.in \
|
|
||||||
+ security/apparmor/usr.libexec.virt-aa-helper.in \
|
|
||||||
security/apparmor/usr.sbin.libvirtd.in \
|
|
||||||
$(NULL)
|
|
||||||
|
|
||||||
@@ -13821,11 +13821,11 @@ security/apparmor/%: $(srcdir)/security/apparmor/%.in
|
|
||||||
@WITH_APPARMOR_PROFILES_TRUE@install-apparmor-local: $(SECURITY_DRIVER_APPARMOR_GENERATED_PROFILES)
|
|
||||||
@WITH_APPARMOR_PROFILES_TRUE@ $(MKDIR_P) "$(APPARMOR_LOCAL_DIR)"
|
|
||||||
@WITH_APPARMOR_PROFILES_TRUE@ echo "# Site-specific additions and overrides for \
|
|
||||||
-@WITH_APPARMOR_PROFILES_TRUE@ 'usr.lib.libvirt.virt-aa-helper'" \
|
|
||||||
-@WITH_APPARMOR_PROFILES_TRUE@ >"$(APPARMOR_LOCAL_DIR)/usr.lib.libvirt.virt-aa-helper"
|
|
||||||
+@WITH_APPARMOR_PROFILES_TRUE@ 'usr.libexec.virt-aa-helper'" \
|
|
||||||
+@WITH_APPARMOR_PROFILES_TRUE@ >"$(APPARMOR_LOCAL_DIR)/usr.libexec.virt-aa-helper"
|
|
||||||
|
|
||||||
@WITH_APPARMOR_PROFILES_TRUE@uninstall-apparmor-local:
|
|
||||||
-@WITH_APPARMOR_PROFILES_TRUE@ rm -f "$(APPARMOR_LOCAL_DIR)/usr.lib.libvirt.virt-aa-helper"
|
|
||||||
+@WITH_APPARMOR_PROFILES_TRUE@ rm -f "$(APPARMOR_LOCAL_DIR)/usr.libexec.virt-aa-helper"
|
|
||||||
@WITH_APPARMOR_PROFILES_TRUE@ rmdir "$(APPARMOR_LOCAL_DIR)" || :
|
|
||||||
|
|
||||||
$(ACCESS_DRIVER_POLKIT_POLICY): $(srcdir)/access/viraccessperm.h \
|
|
||||||
diff --git a/src/security/Makefile.inc.am b/src/security/Makefile.inc.am
|
|
||||||
index 5f2f4c8..d457cc6 100644
|
|
||||||
--- a/src/security/Makefile.inc.am
|
|
||||||
+++ b/src/security/Makefile.inc.am
|
|
||||||
@@ -31,7 +31,7 @@ SECURITY_DRIVER_APPARMOR_SOURCES = \
|
|
||||||
$(NULL)
|
|
||||||
|
|
||||||
SECURITY_DRIVER_APPARMOR_GENERATED_PROFILES_IN = \
|
|
||||||
- security/apparmor/usr.lib.libvirt.virt-aa-helper.in \
|
|
||||||
+ security/apparmor/usr.libexec.virt-aa-helper.in \
|
|
||||||
security/apparmor/usr.sbin.libvirtd.in \
|
|
||||||
$(NULL)
|
|
||||||
|
|
||||||
@@ -130,11 +130,11 @@ APPARMOR_LOCAL_DIR = "$(DESTDIR)$(apparmordir)/local"
|
|
||||||
install-apparmor-local: $(SECURITY_DRIVER_APPARMOR_GENERATED_PROFILES)
|
|
||||||
$(MKDIR_P) "$(APPARMOR_LOCAL_DIR)"
|
|
||||||
echo "# Site-specific additions and overrides for \
|
|
||||||
- 'usr.lib.libvirt.virt-aa-helper'" \
|
|
||||||
- >"$(APPARMOR_LOCAL_DIR)/usr.lib.libvirt.virt-aa-helper"
|
|
||||||
+ 'usr.libexec.virt-aa-helper'" \
|
|
||||||
+ >"$(APPARMOR_LOCAL_DIR)/usr.libexec.virt-aa-helper"
|
|
||||||
|
|
||||||
uninstall-apparmor-local:
|
|
||||||
- rm -f "$(APPARMOR_LOCAL_DIR)/usr.lib.libvirt.virt-aa-helper"
|
|
||||||
+ rm -f "$(APPARMOR_LOCAL_DIR)/usr.libexec.virt-aa-helper"
|
|
||||||
rmdir "$(APPARMOR_LOCAL_DIR)" || :
|
|
||||||
|
|
||||||
INSTALL_DATA_LOCAL += install-apparmor-local
|
|
||||||
diff --git a/src/security/apparmor/libvirt-qemu b/src/security/apparmor/libvirt-qemu
|
|
||||||
index 80986ae..d550d8c 100644
|
|
||||||
--- a/src/security/apparmor/libvirt-qemu
|
|
||||||
+++ b/src/security/apparmor/libvirt-qemu
|
|
||||||
@@ -88,6 +88,7 @@
|
|
||||||
/usr/share/sgabios/** r,
|
|
||||||
/usr/share/slof/** r,
|
|
||||||
/usr/share/vgabios/** r,
|
|
||||||
+ /usr/share/seavgabios/** r,
|
|
||||||
|
|
||||||
# pki for libvirt-vnc and libvirt-spice (LP: #901272, #1690140)
|
|
||||||
/etc/pki/CA/ r,
|
|
||||||
diff --git a/src/security/apparmor/usr.lib.libvirt.virt-aa-helper.in b/src/security/apparmor/usr.libexec.virt-aa-helper.in
|
|
||||||
similarity index 97%
|
|
||||||
rename from src/security/apparmor/usr.lib.libvirt.virt-aa-helper.in
|
|
||||||
rename to src/security/apparmor/usr.libexec.virt-aa-helper.in
|
|
||||||
index dd18c8a..d06f9cb 100644
|
|
||||||
--- a/src/security/apparmor/usr.lib.libvirt.virt-aa-helper.in
|
|
||||||
+++ b/src/security/apparmor/usr.libexec.virt-aa-helper.in
|
|
||||||
@@ -69,5 +69,5 @@ profile virt-aa-helper @libexecdir@/virt-aa-helper {
|
|
||||||
/**.[iI][sS][oO] r,
|
|
||||||
/**/disk{,.*} r,
|
|
||||||
|
|
||||||
- #include <local/usr.lib.libvirt.virt-aa-helper>
|
|
||||||
+ #include <local/usr.libexec.virt-aa-helper>
|
|
||||||
}
|
|
@ -1,356 +0,0 @@
|
|||||||
# Copyright 1999-2020 Gentoo Authors
|
|
||||||
# Distributed under the terms of the GNU General Public License v2
|
|
||||||
|
|
||||||
EAPI=7
|
|
||||||
|
|
||||||
PYTHON_COMPAT=( python3_{6,7,8,9} )
|
|
||||||
|
|
||||||
inherit autotools out-of-source bash-completion-r1 eutils linux-info python-any-r1 readme.gentoo-r1 systemd
|
|
||||||
|
|
||||||
if [[ ${PV} = *9999* ]]; then
|
|
||||||
inherit git-r3
|
|
||||||
EGIT_REPO_URI="https://libvirt.org/git/libvirt.git"
|
|
||||||
SRC_URI=""
|
|
||||||
SLOT="0"
|
|
||||||
else
|
|
||||||
SRC_URI="https://libvirt.org/sources/${P}.tar.xz"
|
|
||||||
KEYWORDS="amd64 ~arm64 ~ppc64 x86"
|
|
||||||
SLOT="0/${PV}"
|
|
||||||
fi
|
|
||||||
|
|
||||||
DESCRIPTION="C toolkit to manipulate virtual machines"
|
|
||||||
HOMEPAGE="http://www.libvirt.org/"
|
|
||||||
LICENSE="LGPL-2.1"
|
|
||||||
IUSE="
|
|
||||||
apparmor audit +caps +dbus dtrace firewalld fuse glusterfs iscsi
|
|
||||||
iscsi-direct +libvirtd lvm libssh lxc +macvtap nfs nls numa openvz
|
|
||||||
parted pcap policykit +qemu rbd sasl selinux +udev +vepa
|
|
||||||
virtualbox virt-network wireshark-plugins xen zfs
|
|
||||||
"
|
|
||||||
|
|
||||||
REQUIRED_USE="
|
|
||||||
firewalld? ( virt-network )
|
|
||||||
libvirtd? ( || ( lxc openvz qemu virtualbox xen ) )
|
|
||||||
lxc? ( caps libvirtd )
|
|
||||||
openvz? ( libvirtd )
|
|
||||||
policykit? ( dbus )
|
|
||||||
qemu? ( libvirtd )
|
|
||||||
vepa? ( macvtap )
|
|
||||||
virt-network? ( libvirtd )
|
|
||||||
virtualbox? ( libvirtd )
|
|
||||||
xen? ( libvirtd )"
|
|
||||||
|
|
||||||
# gettext.sh command is used by the libvirt command wrappers, and it's
|
|
||||||
# non-optional, so put it into RDEPEND.
|
|
||||||
# We can use both libnl:1.1 and libnl:3, but if you have both installed, the
|
|
||||||
# package will use 3 by default. Since we don't have slot pinning in an API,
|
|
||||||
# we must go with the most recent
|
|
||||||
RDEPEND="
|
|
||||||
acct-user/qemu
|
|
||||||
policykit? ( acct-group/libvirt )
|
|
||||||
app-misc/scrub
|
|
||||||
>=dev-libs/glib-2.48.0
|
|
||||||
dev-libs/libgcrypt:0
|
|
||||||
dev-libs/libnl:3
|
|
||||||
>=dev-libs/libxml2-2.7.6
|
|
||||||
>=net-analyzer/openbsd-netcat-1.105-r1
|
|
||||||
>=net-libs/gnutls-1.0.25:0=
|
|
||||||
net-libs/libssh2
|
|
||||||
net-libs/libtirpc
|
|
||||||
net-libs/rpcsvc-proto
|
|
||||||
>=net-misc/curl-7.18.0
|
|
||||||
sys-apps/dmidecode
|
|
||||||
>=sys-apps/util-linux-2.17
|
|
||||||
sys-devel/gettext
|
|
||||||
sys-libs/ncurses:0=
|
|
||||||
sys-libs/readline:=
|
|
||||||
apparmor? ( sys-libs/libapparmor )
|
|
||||||
audit? ( sys-process/audit )
|
|
||||||
caps? ( sys-libs/libcap-ng )
|
|
||||||
dbus? ( sys-apps/dbus )
|
|
||||||
dtrace? ( dev-util/systemtap )
|
|
||||||
firewalld? ( >=net-firewall/firewalld-0.6.3 )
|
|
||||||
fuse? ( sys-fs/fuse:0= )
|
|
||||||
glusterfs? ( >=sys-cluster/glusterfs-3.4.1 )
|
|
||||||
iscsi? ( sys-block/open-iscsi )
|
|
||||||
iscsi-direct? ( >=net-libs/libiscsi-1.18.0 )
|
|
||||||
libssh? ( net-libs/libssh )
|
|
||||||
lvm? ( >=sys-fs/lvm2-2.02.48-r2[-device-mapper-only(-)] )
|
|
||||||
nfs? ( net-fs/nfs-utils )
|
|
||||||
numa? (
|
|
||||||
>sys-process/numactl-2.0.2
|
|
||||||
sys-process/numad
|
|
||||||
)
|
|
||||||
parted? (
|
|
||||||
>=sys-block/parted-1.8[device-mapper]
|
|
||||||
sys-fs/lvm2[-device-mapper-only(-)]
|
|
||||||
)
|
|
||||||
pcap? ( >=net-libs/libpcap-1.0.0 )
|
|
||||||
policykit? ( >=sys-auth/polkit-0.9 )
|
|
||||||
qemu? (
|
|
||||||
>=app-emulation/qemu-1.5.0
|
|
||||||
dev-libs/yajl
|
|
||||||
)
|
|
||||||
rbd? ( sys-cluster/ceph )
|
|
||||||
sasl? ( dev-libs/cyrus-sasl )
|
|
||||||
selinux? ( >=sys-libs/libselinux-2.0.85 )
|
|
||||||
virt-network? (
|
|
||||||
net-dns/dnsmasq[script]
|
|
||||||
net-firewall/ebtables
|
|
||||||
>=net-firewall/iptables-1.4.10[ipv6]
|
|
||||||
net-misc/radvd
|
|
||||||
sys-apps/iproute2[-minimal]
|
|
||||||
)
|
|
||||||
virtualbox? ( || ( app-emulation/virtualbox >=app-emulation/virtualbox-bin-2.2.0 ) )
|
|
||||||
wireshark-plugins? ( net-analyzer/wireshark:= )
|
|
||||||
xen? (
|
|
||||||
>=app-emulation/xen-4.6.0
|
|
||||||
app-emulation/xen-tools:=
|
|
||||||
)
|
|
||||||
udev? (
|
|
||||||
virtual/udev
|
|
||||||
>=x11-libs/libpciaccess-0.10.9
|
|
||||||
)
|
|
||||||
zfs? ( sys-fs/zfs )"
|
|
||||||
|
|
||||||
DEPEND="${RDEPEND}
|
|
||||||
${PYTHON_DEPS}
|
|
||||||
app-text/xhtml1
|
|
||||||
dev-lang/perl
|
|
||||||
dev-libs/libxslt
|
|
||||||
dev-perl/XML-XPath
|
|
||||||
dev-python/docutils
|
|
||||||
virtual/pkgconfig"
|
|
||||||
|
|
||||||
PATCHES=(
|
|
||||||
"${FILESDIR}"/${PN}-6.0.0-do-not-use-sysconf.patch
|
|
||||||
"${FILESDIR}"/${PN}-6.0.0-fix_paths_in_libvirt-guests_sh.patch
|
|
||||||
"${FILESDIR}"/${PN}-6.1.0-fix-paths-for-apparmor.patch
|
|
||||||
)
|
|
||||||
|
|
||||||
pkg_setup() {
|
|
||||||
# Check kernel configuration:
|
|
||||||
CONFIG_CHECK=""
|
|
||||||
use fuse && CONFIG_CHECK+="
|
|
||||||
~FUSE_FS"
|
|
||||||
|
|
||||||
use lvm && CONFIG_CHECK+="
|
|
||||||
~BLK_DEV_DM
|
|
||||||
~DM_MULTIPATH
|
|
||||||
~DM_SNAPSHOT"
|
|
||||||
|
|
||||||
use lxc && CONFIG_CHECK+="
|
|
||||||
~BLK_CGROUP
|
|
||||||
~CGROUP_CPUACCT
|
|
||||||
~CGROUP_DEVICE
|
|
||||||
~CGROUP_FREEZER
|
|
||||||
~CGROUP_NET_PRIO
|
|
||||||
~CGROUP_PERF
|
|
||||||
~CGROUPS
|
|
||||||
~CGROUP_SCHED
|
|
||||||
~CPUSETS
|
|
||||||
~IPC_NS
|
|
||||||
~MACVLAN
|
|
||||||
~NAMESPACES
|
|
||||||
~NET_CLS_CGROUP
|
|
||||||
~NET_NS
|
|
||||||
~PID_NS
|
|
||||||
~POSIX_MQUEUE
|
|
||||||
~SECURITYFS
|
|
||||||
~USER_NS
|
|
||||||
~UTS_NS
|
|
||||||
~VETH
|
|
||||||
~!GRKERNSEC_CHROOT_MOUNT
|
|
||||||
~!GRKERNSEC_CHROOT_DOUBLE
|
|
||||||
~!GRKERNSEC_CHROOT_PIVOT
|
|
||||||
~!GRKERNSEC_CHROOT_CHMOD
|
|
||||||
~!GRKERNSEC_CHROOT_CAPS"
|
|
||||||
|
|
||||||
kernel_is lt 4 7 && use lxc && CONFIG_CHECK+="
|
|
||||||
~DEVPTS_MULTIPLE_INSTANCES"
|
|
||||||
|
|
||||||
use macvtap && CONFIG_CHECK+="
|
|
||||||
~MACVTAP"
|
|
||||||
|
|
||||||
use virt-network && CONFIG_CHECK+="
|
|
||||||
~BRIDGE_EBT_MARK_T
|
|
||||||
~BRIDGE_NF_EBTABLES
|
|
||||||
~NETFILTER_ADVANCED
|
|
||||||
~NETFILTER_XT_CONNMARK
|
|
||||||
~NETFILTER_XT_MARK
|
|
||||||
~NETFILTER_XT_TARGET_CHECKSUM
|
|
||||||
~IP_NF_FILTER
|
|
||||||
~IP_NF_MANGLE
|
|
||||||
~IP_NF_NAT
|
|
||||||
~IP_NF_TARGET_MASQUERADE
|
|
||||||
~IP6_NF_FILTER
|
|
||||||
~IP6_NF_MANGLE
|
|
||||||
~IP6_NF_NAT"
|
|
||||||
# Bandwidth Limiting Support
|
|
||||||
use virt-network && CONFIG_CHECK+="
|
|
||||||
~BRIDGE_EBT_T_NAT
|
|
||||||
~IP_NF_TARGET_REJECT
|
|
||||||
~NET_ACT_POLICE
|
|
||||||
~NET_CLS_FW
|
|
||||||
~NET_CLS_U32
|
|
||||||
~NET_SCH_HTB
|
|
||||||
~NET_SCH_INGRESS
|
|
||||||
~NET_SCH_SFQ"
|
|
||||||
|
|
||||||
# Handle specific kernel versions for different features
|
|
||||||
kernel_is lt 3 6 && CONFIG_CHECK+=" ~CGROUP_MEM_RES_CTLR"
|
|
||||||
if kernel_is ge 3 6; then
|
|
||||||
CONFIG_CHECK+=" ~MEMCG ~MEMCG_SWAP "
|
|
||||||
kernel_is lt 4 5 && CONFIG_CHECK+=" ~MEMCG_KMEM "
|
|
||||||
fi
|
|
||||||
|
|
||||||
ERROR_USER_NS="Optional depending on LXC configuration."
|
|
||||||
|
|
||||||
if [[ -n ${CONFIG_CHECK} ]]; then
|
|
||||||
linux-info_pkg_setup
|
|
||||||
fi
|
|
||||||
}
|
|
||||||
|
|
||||||
src_prepare() {
|
|
||||||
touch "${S}/.mailmap"
|
|
||||||
|
|
||||||
default
|
|
||||||
|
|
||||||
# Tweak the init script:
|
|
||||||
cp "${FILESDIR}/libvirtd.init-r19" "${S}/libvirtd.init" || die
|
|
||||||
sed -e "s/USE_FLAG_FIREWALLD/$(usex firewalld 'need firewalld' '')/" \
|
|
||||||
-i "${S}/libvirtd.init" || die "sed failed"
|
|
||||||
|
|
||||||
eautoreconf
|
|
||||||
}
|
|
||||||
|
|
||||||
my_src_configure() {
|
|
||||||
local myeconfargs=(
|
|
||||||
$(use_with apparmor)
|
|
||||||
$(use_with apparmor apparmor-profiles)
|
|
||||||
$(use_with audit)
|
|
||||||
$(use_with caps capng)
|
|
||||||
$(use_with dbus)
|
|
||||||
$(use_with dtrace)
|
|
||||||
$(use_with firewalld)
|
|
||||||
$(use_with fuse)
|
|
||||||
$(use_with glusterfs)
|
|
||||||
$(use_with glusterfs storage-gluster)
|
|
||||||
$(use_with iscsi storage-iscsi)
|
|
||||||
$(use_with iscsi-direct storage-iscsi-direct)
|
|
||||||
$(use_with libvirtd)
|
|
||||||
$(use_with libssh)
|
|
||||||
$(use_with lvm storage-lvm)
|
|
||||||
$(use_with lvm storage-mpath)
|
|
||||||
$(use_with lxc)
|
|
||||||
$(use_with macvtap)
|
|
||||||
$(use_enable nls)
|
|
||||||
$(use_with numa numactl)
|
|
||||||
$(use_with numa numad)
|
|
||||||
$(use_with openvz)
|
|
||||||
$(use_with parted storage-disk)
|
|
||||||
$(use_with pcap libpcap)
|
|
||||||
$(use_with policykit polkit)
|
|
||||||
$(use_with qemu)
|
|
||||||
$(use_with qemu yajl)
|
|
||||||
$(use_with rbd storage-rbd)
|
|
||||||
$(use_with sasl)
|
|
||||||
$(use_with selinux)
|
|
||||||
$(use_with udev)
|
|
||||||
$(use_with vepa virtualport)
|
|
||||||
$(use_with virt-network network)
|
|
||||||
$(use_with wireshark-plugins wireshark-dissector)
|
|
||||||
$(use_with xen libxl)
|
|
||||||
$(use_with zfs storage-zfs)
|
|
||||||
|
|
||||||
--without-hal
|
|
||||||
--without-netcf
|
|
||||||
--without-sanlock
|
|
||||||
|
|
||||||
--with-esx
|
|
||||||
--with-init-script=systemd
|
|
||||||
--with-qemu-group=$(usex caps qemu root)
|
|
||||||
--with-qemu-user=$(usex caps qemu root)
|
|
||||||
--with-remote
|
|
||||||
--with-storage-fs
|
|
||||||
--with-vmware
|
|
||||||
|
|
||||||
--disable-static
|
|
||||||
--disable-werror
|
|
||||||
|
|
||||||
--localstatedir=/var
|
|
||||||
--with-runstatedir=/run
|
|
||||||
--enable-dependency-tracking
|
|
||||||
)
|
|
||||||
|
|
||||||
if use virtualbox && has_version app-emulation/virtualbox-ose; then
|
|
||||||
myeconfargs+=( --with-vbox=/usr/lib/virtualbox-ose/ )
|
|
||||||
else
|
|
||||||
myeconfargs+=( $(use_with virtualbox vbox) )
|
|
||||||
fi
|
|
||||||
|
|
||||||
econf "${myeconfargs[@]}"
|
|
||||||
}
|
|
||||||
|
|
||||||
my_src_test() {
|
|
||||||
# remove problematic tests, bug #591416, bug #591418
|
|
||||||
sed -i -e 's#commandtest$(EXEEXT) # #' \
|
|
||||||
-e 's#virfirewalltest$(EXEEXT) # #' \
|
|
||||||
-e 's#nwfilterebiptablestest$(EXEEXT) # #' \
|
|
||||||
-e 's#nwfilterxml2firewalltest$(EXEEXT)$##' \
|
|
||||||
tests/Makefile
|
|
||||||
|
|
||||||
export VIR_TEST_DEBUG=1
|
|
||||||
HOME="${T}" emake check
|
|
||||||
}
|
|
||||||
|
|
||||||
my_src_install() {
|
|
||||||
emake DESTDIR="${D}" \
|
|
||||||
SYSTEMD_UNIT_DIR="$(systemd_get_systemunitdir)" install
|
|
||||||
|
|
||||||
find "${D}" -name '*.la' -delete || die
|
|
||||||
|
|
||||||
# Remove bogus, empty directories. They are either not used, or
|
|
||||||
# libvirtd is able to create them on demand
|
|
||||||
rm -rf "${D}"/etc/sysconfig
|
|
||||||
rm -rf "${D}"/var
|
|
||||||
rm -rf "${D}"/run
|
|
||||||
|
|
||||||
newbashcomp "${S}/tools/bash-completion/vsh" virsh
|
|
||||||
bashcomp_alias virsh virt-admin
|
|
||||||
|
|
||||||
use libvirtd || return 0
|
|
||||||
# From here, only libvirtd-related instructions, be warned!
|
|
||||||
|
|
||||||
systemd_newtmpfilesd "${FILESDIR}"/libvirtd.tmpfiles.conf libvirtd.conf
|
|
||||||
|
|
||||||
newinitd "${S}/libvirtd.init" libvirtd
|
|
||||||
newinitd "${FILESDIR}/libvirt-guests.init-r4" libvirt-guests
|
|
||||||
newinitd "${FILESDIR}/virtlockd.init-r2" virtlockd
|
|
||||||
newinitd "${FILESDIR}/virtlogd.init-r2" virtlogd
|
|
||||||
|
|
||||||
newconfd "${FILESDIR}/libvirtd.confd-r5" libvirtd
|
|
||||||
newconfd "${FILESDIR}/libvirt-guests.confd" libvirt-guests
|
|
||||||
|
|
||||||
DOC_CONTENTS=$(<"${FILESDIR}/README.gentoo-r3")
|
|
||||||
DISABLE_AUTOFORMATTING=true
|
|
||||||
readme.gentoo_create_doc
|
|
||||||
}
|
|
||||||
|
|
||||||
pkg_preinst() {
|
|
||||||
# we only ever want to generate this once
|
|
||||||
if [[ -e "${ROOT}"/etc/libvirt/qemu/networks/default.xml ]]; then
|
|
||||||
rm -rf "${D}"/etc/libvirt/qemu/networks/default.xml
|
|
||||||
fi
|
|
||||||
}
|
|
||||||
|
|
||||||
pkg_postinst() {
|
|
||||||
if [[ -e "${ROOT}"/etc/libvirt/qemu/networks/default.xml ]]; then
|
|
||||||
touch "${ROOT}"/etc/libvirt/qemu/networks/default.xml
|
|
||||||
fi
|
|
||||||
|
|
||||||
use libvirtd || return 0
|
|
||||||
# From here, only libvirtd-related instructions, be warned!
|
|
||||||
|
|
||||||
readme.gentoo_print_elog
|
|
||||||
}
|
|
@ -1,355 +0,0 @@
|
|||||||
# Copyright 1999-2020 Gentoo Authors
|
|
||||||
# Distributed under the terms of the GNU General Public License v2
|
|
||||||
|
|
||||||
EAPI=7
|
|
||||||
|
|
||||||
PYTHON_COMPAT=( python3_{6,7,8,9} )
|
|
||||||
|
|
||||||
inherit autotools out-of-source bash-completion-r1 eutils linux-info python-any-r1 readme.gentoo-r1 systemd
|
|
||||||
|
|
||||||
if [[ ${PV} = *9999* ]]; then
|
|
||||||
inherit git-r3
|
|
||||||
EGIT_REPO_URI="https://libvirt.org/git/libvirt.git"
|
|
||||||
SLOT="0"
|
|
||||||
else
|
|
||||||
SRC_URI="https://libvirt.org/sources/${P}.tar.xz"
|
|
||||||
KEYWORDS="~amd64 ~arm64 ~ppc64 ~x86"
|
|
||||||
SLOT="0/${PV}"
|
|
||||||
fi
|
|
||||||
|
|
||||||
DESCRIPTION="C toolkit to manipulate virtual machines"
|
|
||||||
HOMEPAGE="https://www.libvirt.org/"
|
|
||||||
LICENSE="LGPL-2.1"
|
|
||||||
IUSE="
|
|
||||||
apparmor audit +caps +dbus dtrace firewalld fuse glusterfs iscsi
|
|
||||||
iscsi-direct +libvirtd lvm libssh lxc +macvtap nfs nls numa openvz
|
|
||||||
parted pcap policykit +qemu rbd sasl selinux +udev +vepa
|
|
||||||
virtualbox virt-network wireshark-plugins xen zfs
|
|
||||||
"
|
|
||||||
|
|
||||||
REQUIRED_USE="
|
|
||||||
firewalld? ( virt-network )
|
|
||||||
libvirtd? ( || ( lxc openvz qemu virtualbox xen ) )
|
|
||||||
lxc? ( caps libvirtd )
|
|
||||||
openvz? ( libvirtd )
|
|
||||||
policykit? ( dbus )
|
|
||||||
qemu? ( libvirtd )
|
|
||||||
vepa? ( macvtap )
|
|
||||||
virt-network? ( libvirtd )
|
|
||||||
virtualbox? ( libvirtd )
|
|
||||||
xen? ( libvirtd )"
|
|
||||||
|
|
||||||
# gettext.sh command is used by the libvirt command wrappers, and it's
|
|
||||||
# non-optional, so put it into RDEPEND.
|
|
||||||
# We can use both libnl:1.1 and libnl:3, but if you have both installed, the
|
|
||||||
# package will use 3 by default. Since we don't have slot pinning in an API,
|
|
||||||
# we must go with the most recent
|
|
||||||
RDEPEND="
|
|
||||||
acct-user/qemu
|
|
||||||
policykit? ( acct-group/libvirt )
|
|
||||||
app-misc/scrub
|
|
||||||
>=dev-libs/glib-2.48.0
|
|
||||||
dev-libs/libgcrypt:0
|
|
||||||
dev-libs/libnl:3
|
|
||||||
>=dev-libs/libxml2-2.7.6
|
|
||||||
>=net-analyzer/openbsd-netcat-1.105-r1
|
|
||||||
>=net-libs/gnutls-1.0.25:0=
|
|
||||||
net-libs/libssh2
|
|
||||||
net-libs/libtirpc
|
|
||||||
net-libs/rpcsvc-proto
|
|
||||||
>=net-misc/curl-7.18.0
|
|
||||||
sys-apps/dmidecode
|
|
||||||
>=sys-apps/util-linux-2.17
|
|
||||||
sys-devel/gettext
|
|
||||||
sys-libs/ncurses:0=
|
|
||||||
sys-libs/readline:=
|
|
||||||
apparmor? ( sys-libs/libapparmor )
|
|
||||||
audit? ( sys-process/audit )
|
|
||||||
caps? ( sys-libs/libcap-ng )
|
|
||||||
dbus? ( sys-apps/dbus )
|
|
||||||
dtrace? ( dev-util/systemtap )
|
|
||||||
firewalld? ( >=net-firewall/firewalld-0.6.3 )
|
|
||||||
fuse? ( sys-fs/fuse:0= )
|
|
||||||
glusterfs? ( >=sys-cluster/glusterfs-3.4.1 )
|
|
||||||
iscsi? ( sys-block/open-iscsi )
|
|
||||||
iscsi-direct? ( >=net-libs/libiscsi-1.18.0 )
|
|
||||||
libssh? ( net-libs/libssh )
|
|
||||||
lvm? ( >=sys-fs/lvm2-2.02.48-r2[-device-mapper-only(-)] )
|
|
||||||
nfs? ( net-fs/nfs-utils )
|
|
||||||
numa? (
|
|
||||||
>sys-process/numactl-2.0.2
|
|
||||||
sys-process/numad
|
|
||||||
)
|
|
||||||
parted? (
|
|
||||||
>=sys-block/parted-1.8[device-mapper]
|
|
||||||
sys-fs/lvm2[-device-mapper-only(-)]
|
|
||||||
)
|
|
||||||
pcap? ( >=net-libs/libpcap-1.0.0 )
|
|
||||||
policykit? ( >=sys-auth/polkit-0.9 )
|
|
||||||
qemu? (
|
|
||||||
>=app-emulation/qemu-1.5.0
|
|
||||||
dev-libs/yajl
|
|
||||||
)
|
|
||||||
rbd? ( sys-cluster/ceph )
|
|
||||||
sasl? ( dev-libs/cyrus-sasl )
|
|
||||||
selinux? ( >=sys-libs/libselinux-2.0.85 )
|
|
||||||
virt-network? (
|
|
||||||
net-dns/dnsmasq[script]
|
|
||||||
net-firewall/ebtables
|
|
||||||
>=net-firewall/iptables-1.4.10[ipv6]
|
|
||||||
net-misc/radvd
|
|
||||||
sys-apps/iproute2[-minimal]
|
|
||||||
)
|
|
||||||
virtualbox? ( || ( app-emulation/virtualbox >=app-emulation/virtualbox-bin-2.2.0 ) )
|
|
||||||
wireshark-plugins? ( net-analyzer/wireshark:= )
|
|
||||||
xen? (
|
|
||||||
>=app-emulation/xen-4.6.0
|
|
||||||
app-emulation/xen-tools:=
|
|
||||||
)
|
|
||||||
udev? (
|
|
||||||
virtual/udev
|
|
||||||
>=x11-libs/libpciaccess-0.10.9
|
|
||||||
)
|
|
||||||
zfs? ( sys-fs/zfs )"
|
|
||||||
|
|
||||||
DEPEND="${RDEPEND}
|
|
||||||
${PYTHON_DEPS}
|
|
||||||
app-text/xhtml1
|
|
||||||
dev-lang/perl
|
|
||||||
dev-libs/libxslt
|
|
||||||
dev-perl/XML-XPath
|
|
||||||
dev-python/docutils
|
|
||||||
virtual/pkgconfig"
|
|
||||||
|
|
||||||
PATCHES=(
|
|
||||||
"${FILESDIR}"/${PN}-6.0.0-fix_paths_in_libvirt-guests_sh.patch
|
|
||||||
"${FILESDIR}"/${PN}-6.5.0-fix-paths-for-apparmor.patch
|
|
||||||
"${FILESDIR}"/${PN}-6.5.0-do-not-use-sysconfig.patch
|
|
||||||
)
|
|
||||||
|
|
||||||
pkg_setup() {
|
|
||||||
# Check kernel configuration:
|
|
||||||
CONFIG_CHECK=""
|
|
||||||
use fuse && CONFIG_CHECK+="
|
|
||||||
~FUSE_FS"
|
|
||||||
|
|
||||||
use lvm && CONFIG_CHECK+="
|
|
||||||
~BLK_DEV_DM
|
|
||||||
~DM_MULTIPATH
|
|
||||||
~DM_SNAPSHOT"
|
|
||||||
|
|
||||||
use lxc && CONFIG_CHECK+="
|
|
||||||
~BLK_CGROUP
|
|
||||||
~CGROUP_CPUACCT
|
|
||||||
~CGROUP_DEVICE
|
|
||||||
~CGROUP_FREEZER
|
|
||||||
~CGROUP_NET_PRIO
|
|
||||||
~CGROUP_PERF
|
|
||||||
~CGROUPS
|
|
||||||
~CGROUP_SCHED
|
|
||||||
~CPUSETS
|
|
||||||
~IPC_NS
|
|
||||||
~MACVLAN
|
|
||||||
~NAMESPACES
|
|
||||||
~NET_CLS_CGROUP
|
|
||||||
~NET_NS
|
|
||||||
~PID_NS
|
|
||||||
~POSIX_MQUEUE
|
|
||||||
~SECURITYFS
|
|
||||||
~USER_NS
|
|
||||||
~UTS_NS
|
|
||||||
~VETH
|
|
||||||
~!GRKERNSEC_CHROOT_MOUNT
|
|
||||||
~!GRKERNSEC_CHROOT_DOUBLE
|
|
||||||
~!GRKERNSEC_CHROOT_PIVOT
|
|
||||||
~!GRKERNSEC_CHROOT_CHMOD
|
|
||||||
~!GRKERNSEC_CHROOT_CAPS"
|
|
||||||
|
|
||||||
kernel_is lt 4 7 && use lxc && CONFIG_CHECK+="
|
|
||||||
~DEVPTS_MULTIPLE_INSTANCES"
|
|
||||||
|
|
||||||
use macvtap && CONFIG_CHECK+="
|
|
||||||
~MACVTAP"
|
|
||||||
|
|
||||||
use virt-network && CONFIG_CHECK+="
|
|
||||||
~BRIDGE_EBT_MARK_T
|
|
||||||
~BRIDGE_NF_EBTABLES
|
|
||||||
~NETFILTER_ADVANCED
|
|
||||||
~NETFILTER_XT_CONNMARK
|
|
||||||
~NETFILTER_XT_MARK
|
|
||||||
~NETFILTER_XT_TARGET_CHECKSUM
|
|
||||||
~IP_NF_FILTER
|
|
||||||
~IP_NF_MANGLE
|
|
||||||
~IP_NF_NAT
|
|
||||||
~IP_NF_TARGET_MASQUERADE
|
|
||||||
~IP6_NF_FILTER
|
|
||||||
~IP6_NF_MANGLE
|
|
||||||
~IP6_NF_NAT"
|
|
||||||
# Bandwidth Limiting Support
|
|
||||||
use virt-network && CONFIG_CHECK+="
|
|
||||||
~BRIDGE_EBT_T_NAT
|
|
||||||
~IP_NF_TARGET_REJECT
|
|
||||||
~NET_ACT_POLICE
|
|
||||||
~NET_CLS_FW
|
|
||||||
~NET_CLS_U32
|
|
||||||
~NET_SCH_HTB
|
|
||||||
~NET_SCH_INGRESS
|
|
||||||
~NET_SCH_SFQ"
|
|
||||||
|
|
||||||
# Handle specific kernel versions for different features
|
|
||||||
kernel_is lt 3 6 && CONFIG_CHECK+=" ~CGROUP_MEM_RES_CTLR"
|
|
||||||
if kernel_is ge 3 6; then
|
|
||||||
CONFIG_CHECK+=" ~MEMCG ~MEMCG_SWAP "
|
|
||||||
kernel_is lt 4 5 && CONFIG_CHECK+=" ~MEMCG_KMEM "
|
|
||||||
fi
|
|
||||||
|
|
||||||
ERROR_USER_NS="Optional depending on LXC configuration."
|
|
||||||
|
|
||||||
if [[ -n ${CONFIG_CHECK} ]]; then
|
|
||||||
linux-info_pkg_setup
|
|
||||||
fi
|
|
||||||
}
|
|
||||||
|
|
||||||
src_prepare() {
|
|
||||||
touch "${S}/.mailmap"
|
|
||||||
|
|
||||||
default
|
|
||||||
|
|
||||||
# Tweak the init script:
|
|
||||||
cp "${FILESDIR}/libvirtd.init-r19" "${S}/libvirtd.init" || die
|
|
||||||
sed -e "s/USE_FLAG_FIREWALLD/$(usex firewalld 'need firewalld' '')/" \
|
|
||||||
-i "${S}/libvirtd.init" || die "sed failed"
|
|
||||||
|
|
||||||
eautoreconf
|
|
||||||
}
|
|
||||||
|
|
||||||
my_src_configure() {
|
|
||||||
local myeconfargs=(
|
|
||||||
$(use_with apparmor)
|
|
||||||
$(use_with apparmor apparmor-profiles)
|
|
||||||
$(use_with audit)
|
|
||||||
$(use_with caps capng)
|
|
||||||
$(use_with dbus)
|
|
||||||
$(use_with dtrace)
|
|
||||||
$(use_with firewalld)
|
|
||||||
$(use_with fuse)
|
|
||||||
$(use_with glusterfs)
|
|
||||||
$(use_with glusterfs storage-gluster)
|
|
||||||
$(use_with iscsi storage-iscsi)
|
|
||||||
$(use_with iscsi-direct storage-iscsi-direct)
|
|
||||||
$(use_with libvirtd)
|
|
||||||
$(use_with libssh)
|
|
||||||
$(use_with lvm storage-lvm)
|
|
||||||
$(use_with lvm storage-mpath)
|
|
||||||
$(use_with lxc)
|
|
||||||
$(use_with macvtap)
|
|
||||||
$(use_enable nls)
|
|
||||||
$(use_with numa numactl)
|
|
||||||
$(use_with numa numad)
|
|
||||||
$(use_with openvz)
|
|
||||||
$(use_with parted storage-disk)
|
|
||||||
$(use_with pcap libpcap)
|
|
||||||
$(use_with policykit polkit)
|
|
||||||
$(use_with qemu)
|
|
||||||
$(use_with qemu yajl)
|
|
||||||
$(use_with rbd storage-rbd)
|
|
||||||
$(use_with sasl)
|
|
||||||
$(use_with selinux)
|
|
||||||
$(use_with udev)
|
|
||||||
$(use_with vepa virtualport)
|
|
||||||
$(use_with virt-network network)
|
|
||||||
$(use_with wireshark-plugins wireshark-dissector)
|
|
||||||
$(use_with xen libxl)
|
|
||||||
$(use_with zfs storage-zfs)
|
|
||||||
|
|
||||||
--without-hal
|
|
||||||
--without-netcf
|
|
||||||
--without-sanlock
|
|
||||||
|
|
||||||
--with-esx
|
|
||||||
--with-init-script=systemd
|
|
||||||
--with-qemu-group=$(usex caps qemu root)
|
|
||||||
--with-qemu-user=$(usex caps qemu root)
|
|
||||||
--with-remote
|
|
||||||
--with-storage-fs
|
|
||||||
--with-vmware
|
|
||||||
|
|
||||||
--disable-static
|
|
||||||
--disable-werror
|
|
||||||
|
|
||||||
--localstatedir=/var
|
|
||||||
--with-runstatedir=/run
|
|
||||||
--enable-dependency-tracking
|
|
||||||
)
|
|
||||||
|
|
||||||
if use virtualbox && has_version app-emulation/virtualbox-ose; then
|
|
||||||
myeconfargs+=( --with-vbox=/usr/lib/virtualbox-ose/ )
|
|
||||||
else
|
|
||||||
myeconfargs+=( $(use_with virtualbox vbox) )
|
|
||||||
fi
|
|
||||||
|
|
||||||
econf "${myeconfargs[@]}"
|
|
||||||
}
|
|
||||||
|
|
||||||
my_src_test() {
|
|
||||||
# remove problematic tests, bug #591416, bug #591418
|
|
||||||
sed -i -e 's#commandtest$(EXEEXT) # #' \
|
|
||||||
-e 's#virfirewalltest$(EXEEXT) # #' \
|
|
||||||
-e 's#nwfilterebiptablestest$(EXEEXT) # #' \
|
|
||||||
-e 's#nwfilterxml2firewalltest$(EXEEXT)$##' \
|
|
||||||
tests/Makefile
|
|
||||||
|
|
||||||
export VIR_TEST_DEBUG=1
|
|
||||||
HOME="${T}" emake check
|
|
||||||
}
|
|
||||||
|
|
||||||
my_src_install() {
|
|
||||||
emake DESTDIR="${D}" \
|
|
||||||
SYSTEMD_UNIT_DIR="$(systemd_get_systemunitdir)" install
|
|
||||||
|
|
||||||
find "${D}" -name '*.la' -delete || die
|
|
||||||
|
|
||||||
# Remove bogus, empty directories. They are either not used, or
|
|
||||||
# libvirtd is able to create them on demand
|
|
||||||
rm -rf "${D}"/etc/sysconfig
|
|
||||||
rm -rf "${D}"/var
|
|
||||||
rm -rf "${D}"/run
|
|
||||||
|
|
||||||
newbashcomp "${S}/tools/bash-completion/vsh" virsh
|
|
||||||
bashcomp_alias virsh virt-admin
|
|
||||||
|
|
||||||
use libvirtd || return 0
|
|
||||||
# From here, only libvirtd-related instructions, be warned!
|
|
||||||
|
|
||||||
systemd_newtmpfilesd "${FILESDIR}"/libvirtd.tmpfiles.conf libvirtd.conf
|
|
||||||
|
|
||||||
newinitd "${S}/libvirtd.init" libvirtd
|
|
||||||
newinitd "${FILESDIR}/libvirt-guests.init-r4" libvirt-guests
|
|
||||||
newinitd "${FILESDIR}/virtlockd.init-r2" virtlockd
|
|
||||||
newinitd "${FILESDIR}/virtlogd.init-r2" virtlogd
|
|
||||||
|
|
||||||
newconfd "${FILESDIR}/libvirtd.confd-r5" libvirtd
|
|
||||||
newconfd "${FILESDIR}/libvirt-guests.confd" libvirt-guests
|
|
||||||
|
|
||||||
DOC_CONTENTS=$(<"${FILESDIR}/README.gentoo-r3")
|
|
||||||
DISABLE_AUTOFORMATTING=true
|
|
||||||
readme.gentoo_create_doc
|
|
||||||
}
|
|
||||||
|
|
||||||
pkg_preinst() {
|
|
||||||
# we only ever want to generate this once
|
|
||||||
if [[ -e "${ROOT}"/etc/libvirt/qemu/networks/default.xml ]]; then
|
|
||||||
rm -rf "${D}"/etc/libvirt/qemu/networks/default.xml
|
|
||||||
fi
|
|
||||||
}
|
|
||||||
|
|
||||||
pkg_postinst() {
|
|
||||||
if [[ -e "${ROOT}"/etc/libvirt/qemu/networks/default.xml ]]; then
|
|
||||||
touch "${ROOT}"/etc/libvirt/qemu/networks/default.xml
|
|
||||||
fi
|
|
||||||
|
|
||||||
use libvirtd || return 0
|
|
||||||
# From here, only libvirtd-related instructions, be warned!
|
|
||||||
|
|
||||||
readme.gentoo_print_elog
|
|
||||||
}
|
|
@ -1,854 +0,0 @@
|
|||||||
# Copyright 1999-2020 Gentoo Authors
|
|
||||||
# Distributed under the terms of the GNU General Public License v2
|
|
||||||
|
|
||||||
EAPI="7"
|
|
||||||
|
|
||||||
PYTHON_COMPAT=( python{3_6,3_7,3_8} )
|
|
||||||
PYTHON_REQ_USE="ncurses,readline"
|
|
||||||
|
|
||||||
PLOCALES="bg de_DE fr_FR hu it sv tr zh_CN"
|
|
||||||
|
|
||||||
FIRMWARE_ABI_VERSION="4.0.0-r50"
|
|
||||||
|
|
||||||
inherit eutils linux-info toolchain-funcs multilib python-r1 \
|
|
||||||
udev fcaps readme.gentoo-r1 pax-utils l10n xdg-utils
|
|
||||||
|
|
||||||
if [[ ${PV} = *9999* ]]; then
|
|
||||||
EGIT_REPO_URI="https://git.qemu.org/git/qemu.git"
|
|
||||||
EGIT_SUBMODULES=(
|
|
||||||
tests/fp/berkeley-{test,soft}float-3
|
|
||||||
ui/keycodemapdb
|
|
||||||
)
|
|
||||||
inherit git-r3
|
|
||||||
SRC_URI=""
|
|
||||||
else
|
|
||||||
SRC_URI="https://download.qemu.org/${P}.tar.xz"
|
|
||||||
KEYWORDS="amd64 arm64 ~ppc ~ppc64 x86"
|
|
||||||
fi
|
|
||||||
|
|
||||||
DESCRIPTION="QEMU + Kernel-based Virtual Machine userland tools"
|
|
||||||
HOMEPAGE="http://www.qemu.org http://www.linux-kvm.org"
|
|
||||||
|
|
||||||
LICENSE="GPL-2 LGPL-2 BSD-2"
|
|
||||||
SLOT="0"
|
|
||||||
|
|
||||||
IUSE="accessibility +aio alsa bzip2 capstone +caps +curl debug doc
|
|
||||||
+fdt glusterfs gnutls gtk infiniband iscsi io-uring
|
|
||||||
jack jemalloc +jpeg kernel_linux
|
|
||||||
kernel_FreeBSD lzo multipath
|
|
||||||
ncurses nfs nls numa opengl +oss +pin-upstream-blobs
|
|
||||||
plugins +png pulseaudio python rbd sasl +seccomp sdl sdl-image selinux
|
|
||||||
+slirp
|
|
||||||
smartcard snappy spice ssh static static-user systemtap test usb
|
|
||||||
usbredir vde +vhost-net vhost-user-fs virgl virtfs +vnc vte xattr xen
|
|
||||||
xfs +xkb zstd"
|
|
||||||
|
|
||||||
COMMON_TARGETS="aarch64 alpha arm cris hppa i386 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 lm32 moxie rx tricore unicore32"
|
|
||||||
IUSE_USER_TARGETS="${COMMON_TARGETS}
|
|
||||||
aarch64_be armeb mipsn32 mipsn32el ppc64abi32 ppc64le sparc32plus
|
|
||||||
tilegx"
|
|
||||||
|
|
||||||
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 )
|
|
||||||
static? ( static-user !alsa !gtk !jack !opengl !pulseaudio !plugins !rbd !snappy )
|
|
||||||
static-user? ( !plugins )
|
|
||||||
virtfs? ( caps xattr )
|
|
||||||
vte? ( gtk )
|
|
||||||
plugins? ( !static !static-user )
|
|
||||||
"
|
|
||||||
|
|
||||||
# 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.0[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="
|
|
||||||
dev-libs/libxml2[static-libs(+)]
|
|
||||||
xkb? ( x11-libs/libxkbcommon[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 )
|
|
||||||
bzip2? ( app-arch/bzip2[static-libs(+)] )
|
|
||||||
capstone? ( dev-libs/capstone:= )
|
|
||||||
caps? ( sys-libs/libcap-ng[static-libs(+)] )
|
|
||||||
curl? ( >=net-misc/curl-7.15.4[static-libs(+)] )
|
|
||||||
fdt? ( >=sys-apps/dtc-1.5.0[static-libs(+)] )
|
|
||||||
glusterfs? ( >=sys-cluster/glusterfs-3.4.0[static-libs(+)] )
|
|
||||||
gnutls? (
|
|
||||||
dev-libs/nettle:=[static-libs(+)]
|
|
||||||
>=net-libs/gnutls-3.0:=[static-libs(+)]
|
|
||||||
)
|
|
||||||
gtk? (
|
|
||||||
x11-libs/gtk+:3
|
|
||||||
vte? ( x11-libs/vte:2.91 )
|
|
||||||
)
|
|
||||||
infiniband? (
|
|
||||||
sys-fabric/libibumad:=[static-libs(+)]
|
|
||||||
sys-fabric/libibverbs:=[static-libs(+)]
|
|
||||||
sys-fabric/librdmacm:=[static-libs(+)]
|
|
||||||
)
|
|
||||||
iscsi? ( net-libs/libiscsi )
|
|
||||||
io-uring? ( sys-libs/liburing[static-libs(+)] )
|
|
||||||
jack? ( virtual/jack )
|
|
||||||
jemalloc? ( dev-libs/jemalloc )
|
|
||||||
jpeg? ( virtual/jpeg:0=[static-libs(+)] )
|
|
||||||
lzo? ( dev-libs/lzo:2[static-libs(+)] )
|
|
||||||
multipath? ( sys-fs/multipath-tools )
|
|
||||||
ncurses? (
|
|
||||||
sys-libs/ncurses:0=[unicode]
|
|
||||||
sys-libs/ncurses:0=[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]
|
|
||||||
)
|
|
||||||
png? ( media-libs/libpng:0=[static-libs(+)] )
|
|
||||||
pulseaudio? ( media-sound/pulseaudio )
|
|
||||||
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(+)] )
|
|
||||||
usb? ( >=virtual/libusb-1-r2[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:= )
|
|
||||||
xfs? ( sys-fs/xfsprogs[static-libs(+)] )
|
|
||||||
zstd? ( >=app-arch/zstd-1.4.0[static-libs(+)] )
|
|
||||||
"
|
|
||||||
|
|
||||||
X86_FIRMWARE_DEPEND="
|
|
||||||
pin-upstream-blobs? (
|
|
||||||
~sys-firmware/edk2-ovmf-201905[binary]
|
|
||||||
~sys-firmware/ipxe-1.0.0_p20190728[binary]
|
|
||||||
~sys-firmware/seabios-1.12.0[binary,seavgabios]
|
|
||||||
~sys-firmware/sgabios-0.1_pre8[binary]
|
|
||||||
)
|
|
||||||
!pin-upstream-blobs? (
|
|
||||||
sys-firmware/edk2-ovmf
|
|
||||||
sys-firmware/ipxe
|
|
||||||
>=sys-firmware/seabios-1.10.2[seavgabios]
|
|
||||||
sys-firmware/sgabios
|
|
||||||
)"
|
|
||||||
PPC64_FIRMWARE_DEPEND="
|
|
||||||
pin-upstream-blobs? (
|
|
||||||
~sys-firmware/seabios-1.12.0[binary,seavgabios]
|
|
||||||
)
|
|
||||||
!pin-upstream-blobs? (
|
|
||||||
>=sys-firmware/seabios-1.10.2[seavgabios]
|
|
||||||
)
|
|
||||||
"
|
|
||||||
|
|
||||||
BDEPEND="
|
|
||||||
$(python_gen_impl_dep)
|
|
||||||
dev-lang/perl
|
|
||||||
sys-apps/texinfo
|
|
||||||
virtual/pkgconfig
|
|
||||||
doc? ( dev-python/sphinx )
|
|
||||||
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_ppc64? ( ${PPC64_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 )"
|
|
||||||
|
|
||||||
PATCHES=(
|
|
||||||
"${FILESDIR}"/${PN}-2.11.1-capstone_include_path.patch
|
|
||||||
"${FILESDIR}"/${PN}-4.0.0-mkdir_systemtap.patch #684902
|
|
||||||
"${FILESDIR}"/${PN}-4.2.0-cflags.patch
|
|
||||||
"${FILESDIR}"/${PN}-5.1.0-pixman-for-vhost-user-gpu.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/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-ppc64abi32
|
|
||||||
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}"/default-configs >/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
|
|
||||||
}
|
|
||||||
|
|
||||||
handle_locales() {
|
|
||||||
# Make sure locale list is kept up-to-date.
|
|
||||||
local detected sorted
|
|
||||||
detected=$(echo $(cd po && printf '%s\n' *.po | grep -v messages.po | sed 's:.po$::' | sort -u))
|
|
||||||
sorted=$(echo $(printf '%s\n' ${PLOCALES} | sort -u))
|
|
||||||
if [[ ${sorted} != "${detected}" ]] ; then
|
|
||||||
eerror "The ebuild needs to be kept in sync."
|
|
||||||
eerror "PLOCALES: ${sorted}"
|
|
||||||
eerror " po/*.po: ${detected}"
|
|
||||||
die "sync PLOCALES"
|
|
||||||
fi
|
|
||||||
|
|
||||||
# Deal with selective install of locales.
|
|
||||||
if use nls ; then
|
|
||||||
# Delete locales the user does not want. #577814
|
|
||||||
rm_loc() { rm po/$1.po || die; }
|
|
||||||
l10n_for_each_disabled_locale_do rm_loc
|
|
||||||
else
|
|
||||||
# Cheap hack to disable gettext .mo generation.
|
|
||||||
rm -f po/*.po
|
|
||||||
fi
|
|
||||||
}
|
|
||||||
|
|
||||||
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
|
|
||||||
export WINDRES=${CHOST}-windres
|
|
||||||
|
|
||||||
# Verbose builds
|
|
||||||
MAKEOPTS+=" V=1"
|
|
||||||
|
|
||||||
# Run after we've applied all patches.
|
|
||||||
handle_locales
|
|
||||||
|
|
||||||
# Remove bundled copy of libfdt
|
|
||||||
rm -r dtc || 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}"
|
|
||||||
|
|
||||||
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
|
|
||||||
--with-confsuffix=/qemu
|
|
||||||
--localstatedir=/var
|
|
||||||
--disable-bsd-user
|
|
||||||
--disable-containers # bug #732972
|
|
||||||
--disable-guest-agent
|
|
||||||
--disable-strip
|
|
||||||
|
|
||||||
# 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
|
|
||||||
--python="${PYTHON}"
|
|
||||||
--cc="$(tc-getCC)"
|
|
||||||
--cxx="$(tc-getCXX)"
|
|
||||||
--host-cc="$(tc-getBUILD_CC)"
|
|
||||||
$(use_enable debug debug-info)
|
|
||||||
$(use_enable debug debug-tcg)
|
|
||||||
$(use_enable doc docs)
|
|
||||||
$(use_enable plugins)
|
|
||||||
$(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
|
|
||||||
}
|
|
||||||
conf_opts+=(
|
|
||||||
$(conf_notuser accessibility brlapi)
|
|
||||||
$(conf_notuser aio linux-aio)
|
|
||||||
$(conf_notuser bzip2)
|
|
||||||
$(conf_notuser capstone)
|
|
||||||
$(conf_notuser caps cap-ng)
|
|
||||||
$(conf_notuser curl)
|
|
||||||
$(conf_notuser fdt)
|
|
||||||
$(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_notuser jemalloc 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 png vnc-png)
|
|
||||||
$(conf_notuser rbd)
|
|
||||||
$(conf_notuser sasl vnc-sasl)
|
|
||||||
$(conf_notuser sdl)
|
|
||||||
$(conf_notuser sdl-image)
|
|
||||||
$(conf_notuser seccomp)
|
|
||||||
$(conf_notuser slirp slirp system)
|
|
||||||
$(conf_notuser smartcard)
|
|
||||||
$(conf_notuser snappy)
|
|
||||||
$(conf_notuser spice)
|
|
||||||
$(conf_notuser ssh libssh)
|
|
||||||
$(conf_notuser usb libusb)
|
|
||||||
$(conf_notuser usbredir usb-redir)
|
|
||||||
$(conf_notuser vde)
|
|
||||||
$(conf_notuser vhost-net)
|
|
||||||
$(conf_notuser vhost-user-fs)
|
|
||||||
$(conf_notuser virgl virglrenderer)
|
|
||||||
$(conf_notuser virtfs)
|
|
||||||
$(conf_notuser vnc)
|
|
||||||
$(conf_notuser vte)
|
|
||||||
$(conf_notuser xen)
|
|
||||||
$(conf_notuser xen xen-pci-passthrough)
|
|
||||||
$(conf_notuser xfs xfsctl)
|
|
||||||
$(conf_notuser xkb xkbcommon)
|
|
||||||
$(conf_notuser zstd)
|
|
||||||
)
|
|
||||||
|
|
||||||
if [[ ${buildtype} == "user" ]] ; then
|
|
||||||
conf_opts+=( --disable-libxml2 )
|
|
||||||
else
|
|
||||||
conf_opts+=( --enable-libxml2 )
|
|
||||||
fi
|
|
||||||
|
|
||||||
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=$(printf "%s," "${audio_opts[@]}")
|
|
||||||
)
|
|
||||||
fi
|
|
||||||
|
|
||||||
case ${buildtype} in
|
|
||||||
user)
|
|
||||||
conf_opts+=(
|
|
||||||
--enable-linux-user
|
|
||||||
--disable-system
|
|
||||||
--disable-blobs
|
|
||||||
--disable-tools
|
|
||||||
)
|
|
||||||
local static_flag="static-user"
|
|
||||||
;;
|
|
||||||
softmmu)
|
|
||||||
conf_opts+=(
|
|
||||||
--disable-linux-user
|
|
||||||
--enable-system
|
|
||||||
--disable-tools
|
|
||||||
)
|
|
||||||
local static_flag="static"
|
|
||||||
;;
|
|
||||||
tools)
|
|
||||||
conf_opts+=(
|
|
||||||
--disable-linux-user
|
|
||||||
--disable-system
|
|
||||||
--disable-blobs
|
|
||||||
--enable-tools
|
|
||||||
)
|
|
||||||
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
|
|
||||||
|
|
||||||
echo "../configure ${conf_opts[*]}"
|
|
||||||
cd "${builddir}"
|
|
||||||
../configure "${conf_opts[@]}" || die "configure failed"
|
|
||||||
|
|
||||||
# FreeBSD's kernel does not support QEMU assigning/grabbing
|
|
||||||
# host USB devices yet
|
|
||||||
use kernel_FreeBSD && \
|
|
||||||
sed -i -E -e "s|^(HOST_USB=)bsd|\1stub|" "${S}"/config-host.mak
|
|
||||||
}
|
|
||||||
|
|
||||||
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"
|
|
||||||
default
|
|
||||||
fi
|
|
||||||
|
|
||||||
if [[ -n ${softmmu_targets} ]]; then
|
|
||||||
cd "${S}/softmmu-build"
|
|
||||||
default
|
|
||||||
fi
|
|
||||||
|
|
||||||
cd "${S}/tools-build"
|
|
||||||
default
|
|
||||||
}
|
|
||||||
|
|
||||||
src_test() {
|
|
||||||
if [[ -n ${softmmu_targets} ]]; then
|
|
||||||
cd "${S}/softmmu-build"
|
|
||||||
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-r1 65-kvm.rules
|
|
||||||
fi
|
|
||||||
|
|
||||||
if use python; then
|
|
||||||
python_foreach_impl qemu_python_install
|
|
||||||
fi
|
|
||||||
fi
|
|
||||||
|
|
||||||
cd "${S}/tools-build"
|
|
||||||
emake DESTDIR="${ED}" install
|
|
||||||
|
|
||||||
# Disable mprotect on the qemu binaries as they use JITs to be fast #459348
|
|
||||||
pushd "${ED}"/usr/bin >/dev/null
|
|
||||||
pax-mark mr "${softmmu_bins[@]}" "${user_bins[@]}" # bug 575594
|
|
||||||
popd >/dev/null
|
|
||||||
|
|
||||||
# Install config file example for qemu-bridge-helper
|
|
||||||
insinto "/etc/qemu"
|
|
||||||
doins "${FILESDIR}/bridge.conf"
|
|
||||||
|
|
||||||
cd "${S}"
|
|
||||||
dodoc Changelog 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
|
|
||||||
rm "${ED}/usr/share/qemu/bios.bin"
|
|
||||||
rm "${ED}/usr/share/qemu/bios-256k.bin"
|
|
||||||
if use qemu_softmmu_targets_x86_64 || use qemu_softmmu_targets_i386; then
|
|
||||||
dosym ../seabios/bios.bin /usr/share/qemu/bios.bin
|
|
||||||
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"
|
|
||||||
# PPC64 loads vgabios-stdvga
|
|
||||||
if use qemu_softmmu_targets_x86_64 || use qemu_softmmu_targets_i386 || 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
|
|
||||||
rm "${ED}/usr/share/qemu/sgabios.bin"
|
|
||||||
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
|
|
||||||
rm "${ED}"/usr/share/qemu/pxe-*.rom
|
|
||||||
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:"
|
|
||||||
ewarn " $(best_version sys-firmware/edk2-ovmf)"
|
|
||||||
ewarn " $(best_version sys-firmware/ipxe)"
|
|
||||||
ewarn " $(best_version sys-firmware/seabios)"
|
|
||||||
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)"
|
|
||||||
echo " $(best_version sys-firmware/edk2-ovmf)"
|
|
||||||
if has_version 'sys-firmware/edk2-ovmf[binary]'; then
|
|
||||||
echo " USE=binary"
|
|
||||||
else
|
|
||||||
echo " USE=''"
|
|
||||||
fi
|
|
||||||
echo " $(best_version sys-firmware/ipxe)"
|
|
||||||
echo " $(best_version sys-firmware/seabios)"
|
|
||||||
if has_version 'sys-firmware/seabios[binary]'; then
|
|
||||||
echo " USE=binary"
|
|
||||||
else
|
|
||||||
echo " USE=''"
|
|
||||||
fi
|
|
||||||
echo " $(best_version sys-firmware/sgabios)"
|
|
||||||
}
|
|
||||||
|
|
||||||
pkg_postrm() {
|
|
||||||
xdg_icon_cache_update
|
|
||||||
}
|
|
Binary file not shown.
@ -0,0 +1,135 @@
|
|||||||
|
# Copyright 1999-2019 Gentoo Authors
|
||||||
|
# Distributed under the terms of the GNU General Public License v2
|
||||||
|
|
||||||
|
EAPI=7
|
||||||
|
|
||||||
|
# bash-completion-r1 can be added once we can generate completion scripts
|
||||||
|
inherit go-module
|
||||||
|
|
||||||
|
DESCRIPTION="A simple JIRA commandline client in Go"
|
||||||
|
HOMEPAGE="https://github.com/Netflix-Skunkworks/go-jira"
|
||||||
|
|
||||||
|
EGO_SUM=(
|
||||||
|
"github.com/Masterminds/goutils v1.1.0"
|
||||||
|
"github.com/Masterminds/goutils v1.1.0/go.mod"
|
||||||
|
"github.com/Masterminds/semver v1.5.0"
|
||||||
|
"github.com/Masterminds/semver v1.5.0/go.mod"
|
||||||
|
"github.com/Masterminds/sprig v2.21.0+incompatible"
|
||||||
|
"github.com/Masterminds/sprig v2.21.0+incompatible/go.mod"
|
||||||
|
"github.com/Netflix/go-expect v0.0.0-20180928190340-9d1f4485533b"
|
||||||
|
"github.com/Netflix/go-expect v0.0.0-20180928190340-9d1f4485533b/go.mod"
|
||||||
|
"github.com/alecthomas/template v0.0.0-20160405071501-a0175ee3bccc"
|
||||||
|
"github.com/alecthomas/template v0.0.0-20160405071501-a0175ee3bccc/go.mod"
|
||||||
|
"github.com/alecthomas/units v0.0.0-20151022065526-2efee857e7cf"
|
||||||
|
"github.com/alecthomas/units v0.0.0-20151022065526-2efee857e7cf/go.mod"
|
||||||
|
"github.com/cheekybits/genny v1.0.0"
|
||||||
|
"github.com/cheekybits/genny v1.0.0/go.mod"
|
||||||
|
"github.com/coryb/figtree v0.0.0-20180728224503-071d1ef303df"
|
||||||
|
"github.com/coryb/figtree v0.0.0-20180728224503-071d1ef303df/go.mod"
|
||||||
|
"github.com/coryb/figtree v1.0.1-0.20190907170512-58176d03ef0d"
|
||||||
|
"github.com/coryb/figtree v1.0.1-0.20190907170512-58176d03ef0d/go.mod"
|
||||||
|
"github.com/coryb/kingpeon v0.0.0-20180107011214-9a669f143f2e"
|
||||||
|
"github.com/coryb/kingpeon v0.0.0-20180107011214-9a669f143f2e/go.mod"
|
||||||
|
"github.com/coryb/oreo v0.0.0-20180804211640-3e1b88fc08f1"
|
||||||
|
"github.com/coryb/oreo v0.0.0-20180804211640-3e1b88fc08f1/go.mod"
|
||||||
|
"github.com/davecgh/go-spew v1.1.0"
|
||||||
|
"github.com/davecgh/go-spew v1.1.0/go.mod"
|
||||||
|
"github.com/fatih/camelcase v1.0.0"
|
||||||
|
"github.com/fatih/camelcase v1.0.0/go.mod"
|
||||||
|
"github.com/google/go-cmp v0.5.2"
|
||||||
|
"github.com/google/go-cmp v0.5.2/go.mod"
|
||||||
|
"github.com/google/uuid v1.1.1"
|
||||||
|
"github.com/google/uuid v1.1.1/go.mod"
|
||||||
|
"github.com/guelfey/go.dbus v0.0.0-20131113121618-f6a3a2366cc3"
|
||||||
|
"github.com/guelfey/go.dbus v0.0.0-20131113121618-f6a3a2366cc3/go.mod"
|
||||||
|
"github.com/hinshun/vt10x v0.0.0-20180809195222-d55458df857c"
|
||||||
|
"github.com/hinshun/vt10x v0.0.0-20180809195222-d55458df857c/go.mod"
|
||||||
|
"github.com/huandu/xstrings v1.2.0"
|
||||||
|
"github.com/huandu/xstrings v1.2.0/go.mod"
|
||||||
|
"github.com/imdario/mergo v0.3.7"
|
||||||
|
"github.com/imdario/mergo v0.3.7/go.mod"
|
||||||
|
"github.com/jinzhu/copier v0.0.0-20180308034124-7e38e58719c3"
|
||||||
|
"github.com/jinzhu/copier v0.0.0-20180308034124-7e38e58719c3/go.mod"
|
||||||
|
"github.com/kballard/go-shellquote v0.0.0-20180428030007-95032a82bc51"
|
||||||
|
"github.com/kballard/go-shellquote v0.0.0-20180428030007-95032a82bc51/go.mod"
|
||||||
|
"github.com/kr/pretty v0.1.0"
|
||||||
|
"github.com/kr/pretty v0.1.0/go.mod"
|
||||||
|
"github.com/kr/pty v1.1.1/go.mod"
|
||||||
|
"github.com/kr/pty v1.1.4"
|
||||||
|
"github.com/kr/pty v1.1.4/go.mod"
|
||||||
|
"github.com/kr/text v0.1.0"
|
||||||
|
"github.com/kr/text v0.1.0/go.mod"
|
||||||
|
"github.com/mattn/go-colorable v0.0.9"
|
||||||
|
"github.com/mattn/go-colorable v0.0.9/go.mod"
|
||||||
|
"github.com/mattn/go-isatty v0.0.3"
|
||||||
|
"github.com/mattn/go-isatty v0.0.3/go.mod"
|
||||||
|
"github.com/mattn/go-runewidth v0.0.6"
|
||||||
|
"github.com/mattn/go-runewidth v0.0.6/go.mod"
|
||||||
|
"github.com/mgutz/ansi v0.0.0-20170206155736-9520e82c474b"
|
||||||
|
"github.com/mgutz/ansi v0.0.0-20170206155736-9520e82c474b/go.mod"
|
||||||
|
"github.com/mitchellh/go-wordwrap v1.0.1"
|
||||||
|
"github.com/mitchellh/go-wordwrap v1.0.1/go.mod"
|
||||||
|
"github.com/olekukonko/tablewriter v0.0.3"
|
||||||
|
"github.com/olekukonko/tablewriter v0.0.3/go.mod"
|
||||||
|
"github.com/pkg/browser v0.0.0-20170505125900-c90ca0c84f15"
|
||||||
|
"github.com/pkg/browser v0.0.0-20170505125900-c90ca0c84f15/go.mod"
|
||||||
|
"github.com/pkg/errors v0.8.0"
|
||||||
|
"github.com/pkg/errors v0.8.0/go.mod"
|
||||||
|
"github.com/pmezard/go-difflib v1.0.0"
|
||||||
|
"github.com/pmezard/go-difflib v1.0.0/go.mod"
|
||||||
|
"github.com/stretchr/testify v1.2.2"
|
||||||
|
"github.com/stretchr/testify v1.2.2/go.mod"
|
||||||
|
"github.com/theckman/go-flock v0.4.0"
|
||||||
|
"github.com/theckman/go-flock v0.4.0/go.mod"
|
||||||
|
"github.com/tidwall/gjson v0.0.0-20180711011033-ba784d767ac7"
|
||||||
|
"github.com/tidwall/gjson v0.0.0-20180711011033-ba784d767ac7/go.mod"
|
||||||
|
"github.com/tidwall/match v1.0.0"
|
||||||
|
"github.com/tidwall/match v1.0.0/go.mod"
|
||||||
|
"github.com/tmc/keyring v0.0.0-20171121202319-839169085ae1"
|
||||||
|
"github.com/tmc/keyring v0.0.0-20171121202319-839169085ae1/go.mod"
|
||||||
|
"golang.org/x/crypto v0.0.0-20180723164146-c126467f60eb"
|
||||||
|
"golang.org/x/crypto v0.0.0-20180723164146-c126467f60eb/go.mod"
|
||||||
|
"golang.org/x/net v0.0.0-20171102191033-01c190206fbd"
|
||||||
|
"golang.org/x/net v0.0.0-20171102191033-01c190206fbd/go.mod"
|
||||||
|
"golang.org/x/sys v0.0.0-20180727230415-bd9dbc187b6e"
|
||||||
|
"golang.org/x/sys v0.0.0-20180727230415-bd9dbc187b6e/go.mod"
|
||||||
|
"golang.org/x/xerrors v0.0.0-20191204190536-9bdfabe68543/go.mod"
|
||||||
|
"gopkg.in/AlecAivazis/survey.v1 v1.6.1"
|
||||||
|
"gopkg.in/AlecAivazis/survey.v1 v1.6.1/go.mod"
|
||||||
|
"gopkg.in/alecthomas/kingpin.v2 v2.2.6"
|
||||||
|
"gopkg.in/alecthomas/kingpin.v2 v2.2.6/go.mod"
|
||||||
|
"gopkg.in/check.v1 v0.0.0-20161208181325-20d25e280405/go.mod"
|
||||||
|
"gopkg.in/check.v1 v1.0.0-20180628173108-788fd7840127"
|
||||||
|
"gopkg.in/check.v1 v1.0.0-20180628173108-788fd7840127/go.mod"
|
||||||
|
"gopkg.in/coryb/yaml.v2 v2.0.0-20180616071044-0e40e46f7153"
|
||||||
|
"gopkg.in/coryb/yaml.v2 v2.0.0-20180616071044-0e40e46f7153/go.mod"
|
||||||
|
"gopkg.in/op/go-logging.v1 v1.0.0-20160211212156-b2cb9fa56473"
|
||||||
|
"gopkg.in/op/go-logging.v1 v1.0.0-20160211212156-b2cb9fa56473/go.mod"
|
||||||
|
"gopkg.in/yaml.v2 v2.2.2"
|
||||||
|
"gopkg.in/yaml.v2 v2.2.2/go.mod"
|
||||||
|
)
|
||||||
|
go-module_set_globals
|
||||||
|
SRC_URI="https://github.com/go-jira/jira/archive/v${PV}.tar.gz -> ${P}.tar.gz
|
||||||
|
${EGO_SUM_SRC_URI}"
|
||||||
|
|
||||||
|
LICENSE="Apache-2.0 BSD-2 BSD ISC MIT MIT-with-advertising"
|
||||||
|
SLOT="0"
|
||||||
|
KEYWORDS="~amd64"
|
||||||
|
|
||||||
|
S="${WORKDIR}/jira-${PV}"
|
||||||
|
|
||||||
|
src_compile() {
|
||||||
|
go build -o jira cmd/jira/main.go || die
|
||||||
|
# these cause failures.
|
||||||
|
# ./jira --completion-script-bash > jira.bash || die
|
||||||
|
# ./jira --completion-script-zsh > jira.zsh || die
|
||||||
|
}
|
||||||
|
|
||||||
|
src_install() {
|
||||||
|
dobin jira
|
||||||
|
dodoc {CHANGELOG,README}.md
|
||||||
|
# This can be uncommented once we can generate completion scripts
|
||||||
|
# newbashcomp jira.bash jira
|
||||||
|
# insinto /usr/share/zsh/site-functions
|
||||||
|
# newins jira.zsh _jira
|
||||||
|
}
|
Binary file not shown.
Binary file not shown.
@ -0,0 +1,31 @@
|
|||||||
|
# Copyright 1999-2020 Gentoo Authors
|
||||||
|
# Distributed under the terms of the GNU General Public License v2
|
||||||
|
|
||||||
|
EAPI=7
|
||||||
|
DISTUTILS_USE_SETUPTOOLS=rdepend
|
||||||
|
PYTHON_COMPAT=( python3_{6,7,8} )
|
||||||
|
|
||||||
|
inherit distutils-r1
|
||||||
|
|
||||||
|
DESCRIPTION="Backend part of Paperwork (Python API, no UI)"
|
||||||
|
HOMEPAGE="https://gitlab.gnome.org/World/OpenPaperwork"
|
||||||
|
SRC_URI="mirror://pypi/${PN:0:1}/${PN}/${P}.tar.gz"
|
||||||
|
|
||||||
|
LICENSE="GPL-3"
|
||||||
|
SLOT="0"
|
||||||
|
KEYWORDS="~amd64 ~x86"
|
||||||
|
IUSE=""
|
||||||
|
|
||||||
|
RDEPEND="app-text/poppler[introspection]
|
||||||
|
dev-python/distro[${PYTHON_USEDEP}]
|
||||||
|
dev-python/natsort[${PYTHON_USEDEP}]
|
||||||
|
dev-python/pillow[${PYTHON_USEDEP}]
|
||||||
|
dev-python/pycairo[${PYTHON_USEDEP}]
|
||||||
|
dev-python/pycountry[${PYTHON_USEDEP}]
|
||||||
|
dev-python/pyenchant[${PYTHON_USEDEP}]
|
||||||
|
dev-python/pygobject:3[${PYTHON_USEDEP}]
|
||||||
|
dev-python/python-levenshtein[${PYTHON_USEDEP}]
|
||||||
|
dev-python/simplebayes[${PYTHON_USEDEP}]
|
||||||
|
dev-python/termcolor[${PYTHON_USEDEP}]
|
||||||
|
dev-python/whoosh[${PYTHON_USEDEP}]"
|
||||||
|
DEPEND="${RDEPEND}"
|
Binary file not shown.
@ -1 +1,2 @@
|
|||||||
|
DIST prometheus-cpp-0.10.0.tar.gz 49694 BLAKE2B f14232e1dad0376ea8e90c89079c4a6d8f2e9f5661a399d38d6f5001506db6c628cb42a934b40139cbb0d904a63c4b4483e6ed92452f5393365ed4209a236247 SHA512 18938b30143ed29985ee56943fd69e0a221f9d25f04fc611554050ee2786e96d968f7db251cccefcbd0017b61bcd8a7ea05af8f217c8aacd9f0694a4702ddcff
|
||||||
DIST prometheus-cpp-0.9.0.tar.gz 43924 BLAKE2B e2b26b257e44c63ae5bc2a703d0ee9247fd8f093ef58a3b00dec022af9cb56b18d20b74ccdb91899e2385b036c332b62d9959b9258082ca420fecf48926139d5 SHA512 d9d5fbbd8c8aad5dd6a5e872275324d689a0c57199e4158d74e13ea62b286fa71dee01bb4197b906b79792bf1ca4e67a46b5c04621d7070241ac32876f6de891
|
DIST prometheus-cpp-0.9.0.tar.gz 43924 BLAKE2B e2b26b257e44c63ae5bc2a703d0ee9247fd8f093ef58a3b00dec022af9cb56b18d20b74ccdb91899e2385b036c332b62d9959b9258082ca420fecf48926139d5 SHA512 d9d5fbbd8c8aad5dd6a5e872275324d689a0c57199e4158d74e13ea62b286fa71dee01bb4197b906b79792bf1ca4e67a46b5c04621d7070241ac32876f6de891
|
||||||
|
@ -0,0 +1,39 @@
|
|||||||
|
# Copyright 1999-2020 Gentoo Authors
|
||||||
|
# Distributed under the terms of the GNU General Public License v2
|
||||||
|
|
||||||
|
EAPI=7
|
||||||
|
|
||||||
|
inherit cmake
|
||||||
|
|
||||||
|
DESCRIPTION="Prometheus Client Library for Modern C++"
|
||||||
|
HOMEPAGE="https://github.com/jupp0r/prometheus-cpp"
|
||||||
|
SRC_URI="https://github.com/jupp0r/${PN}/archive/v${PV}.tar.gz -> ${P}.tar.gz"
|
||||||
|
|
||||||
|
LICENSE="MIT"
|
||||||
|
SLOT="0"
|
||||||
|
KEYWORDS="~amd64 ~x86"
|
||||||
|
IUSE="test zlib"
|
||||||
|
RESTRICT="!test? ( test )"
|
||||||
|
|
||||||
|
RDEPEND="
|
||||||
|
dev-libs/cppcodec
|
||||||
|
net-misc/curl
|
||||||
|
sys-libs/zlib
|
||||||
|
www-servers/civetweb[cxx]"
|
||||||
|
DEPEND="${RDEPEND}
|
||||||
|
test? (
|
||||||
|
dev-cpp/benchmark
|
||||||
|
dev-cpp/gtest
|
||||||
|
)"
|
||||||
|
|
||||||
|
src_configure() {
|
||||||
|
local mycmakeargs=(
|
||||||
|
-DENABLE_PULL=yes
|
||||||
|
-DENABLE_PUSH=yes
|
||||||
|
-DENABLE_COMPRESSION=$(usex zlib)
|
||||||
|
-DENABLE_TESTING=$(usex test)
|
||||||
|
-DUSE_THIRDPARTY_LIBRARIES=OFF
|
||||||
|
)
|
||||||
|
|
||||||
|
cmake_src_configure
|
||||||
|
}
|
Binary file not shown.
@ -1,23 +1,20 @@
|
|||||||
DIST mariadb-10.1.38.tar.gz 63535685 BLAKE2B c179ea2f60287c2bc1c0d1c47ae989ac2653a24063e8344cef2f3062fc6798e18b969e8f9aa8287104ce2518e6c644cb8d3a4650b5a0bc5dfde973e76e618955 SHA512 184582f3a902a989ba3d9c4d21288c014c8b469adbbb4cbabc621c5006022cef29baed8c1140ed4476b124da83b76dfa414295ed0c3374be826e75aca953a77b
|
|
||||||
DIST mariadb-10.1.45-patches-04.tar.xz 8808 BLAKE2B 79b6ad86665b6ceea990813c1b60937283ccfd572e5aef095df9951fac0a35e10b7cab002a18adcdb4b643a4d881c57ed468a15fc2fe8f0b9755dc07c2c81fc6 SHA512 eba4c39a275a27faec01dcefd36635fb8ed4f9d651e244420ce0856932378196b9daa98c9de339dc84c3e07fb77fda27c2aa46930c741a1c4c53057b4f9b86c6
|
|
||||||
DIST mariadb-10.1.45.tar.gz 63673824 BLAKE2B 002aedf61282244905256757fe18eebe67f8a05d45496eee4804e5fba9edf58ece15188d6537ed45245b9342bc514376727c91261ec3f3a3d809c569c84a63de SHA512 708daf6cf98a914ca378e3461f3431f13d6274e20ef37de239e5d90db58215c50bfbc450e6b3b00d847cc819ab9de2bc780831009581e43db38d63397a417ace
|
|
||||||
DIST mariadb-10.1.46-patches-01.tar.xz 8824 BLAKE2B b30d1c6625d87605fc934007ebfbd449f327969b1f65bb22a1d432691a3927a3f20c55f646f9a4e8cbdcdcadf16a2518e05441ab0088bac876a81f87bb62b925 SHA512 93ef056f697d83ced4d585c31558dded94667447fc6785ed79b15dbbde4df4a3667cefec1f2007649dd0fed3c1cf86cfe5cf626588678d2a851f8c5f7b3d4092
|
DIST mariadb-10.1.46-patches-01.tar.xz 8824 BLAKE2B b30d1c6625d87605fc934007ebfbd449f327969b1f65bb22a1d432691a3927a3f20c55f646f9a4e8cbdcdcadf16a2518e05441ab0088bac876a81f87bb62b925 SHA512 93ef056f697d83ced4d585c31558dded94667447fc6785ed79b15dbbde4df4a3667cefec1f2007649dd0fed3c1cf86cfe5cf626588678d2a851f8c5f7b3d4092
|
||||||
DIST mariadb-10.1.46.tar.gz 63741294 BLAKE2B 5a2ca06b7ac14896f874bb18a38dcfb2336d0b77160d3295e9a268ffaa6feec2319a5d4e5985851327f1122fa7650749a09c384eeba5ab9369fce993464702f8 SHA512 a45816edfcfb7f33fc4e316cd19d777069358b7cd0968be23922ffee886e9db8600568425e4d81a0e033a255b6c46441fefa4f5bc5da96579527b481a10a7213
|
DIST mariadb-10.1.47.tar.gz 63751492 BLAKE2B 4e01a641e1c387c4d61b3fc8747685ce549628304da7ec4375a5dd3ec1e1b5ec67e501eff2f12c47d73e84cc8a6b78bb79a7b326951e3f58131d918495c55039 SHA512 68ca6471a3dca91b7c8cdb1fb19b5387d3ef29a3598eeae70428373dc319eab9371d73cc5d06582f8d14f53ee9c0d7c6969b379f3961c8960308717fa6070349
|
||||||
DIST mariadb-10.2.22.tar.gz 71907765 BLAKE2B e7781a9e1bb0becca543ebb0b9e03912fbafa9de45bbd5c7232f92d29b934148dd124ad462bf8aa5aec2e4ee0bf75a03fae5e5fe97a77e1d93095052a577c14b SHA512 cd61d0c2d528b23b975e6ea142560d9b9ebff7ecda6fa9b3659b25b3406e8cc925918f4c3bb0e200ddb8d0520bcaa4d4f70d245b4731896f9ba2f1bdf0a817b2
|
DIST mariadb-10.2.22.tar.gz 71907765 BLAKE2B e7781a9e1bb0becca543ebb0b9e03912fbafa9de45bbd5c7232f92d29b934148dd124ad462bf8aa5aec2e4ee0bf75a03fae5e5fe97a77e1d93095052a577c14b SHA512 cd61d0c2d528b23b975e6ea142560d9b9ebff7ecda6fa9b3659b25b3406e8cc925918f4c3bb0e200ddb8d0520bcaa4d4f70d245b4731896f9ba2f1bdf0a817b2
|
||||||
DIST mariadb-10.2.32-patches-03.tar.xz 6048 BLAKE2B a6f8f25ec23d1d86d228d719927daa9131779239917b86eab9f82086744294c0a4f03b1a73a3baa599e367775457d6c345fa0820b89063b2e6379c0fb7076ad0 SHA512 324804f13f59593d26cc5fd8c1cdeac2f16cf55012ca65b0a7223512920e1ea94619991fdcb3d19184b6428e4a627fec75532c88ae8297f9b8398fcf730058a9
|
DIST mariadb-10.2.32-patches-03.tar.xz 6048 BLAKE2B a6f8f25ec23d1d86d228d719927daa9131779239917b86eab9f82086744294c0a4f03b1a73a3baa599e367775457d6c345fa0820b89063b2e6379c0fb7076ad0 SHA512 324804f13f59593d26cc5fd8c1cdeac2f16cf55012ca65b0a7223512920e1ea94619991fdcb3d19184b6428e4a627fec75532c88ae8297f9b8398fcf730058a9
|
||||||
DIST mariadb-10.2.32.tar.gz 73646729 BLAKE2B 581906d67f0aada9e85aec7bfee03ed8927a4e836f0639fa5f31576f5df70ce2b6ed3da0b96ad616f5ed71d7717531a073cb911c6d92274f6724911e086104af SHA512 824aa94724b639337a5b4c2e86a1f5ceaeaa940eb234f852df1ba0aafd64e269335e2aca0b05d52164e090cfd6f7d14477df9e096473aa5d9286d47944a765b4
|
DIST mariadb-10.2.32.tar.gz 73646729 BLAKE2B 581906d67f0aada9e85aec7bfee03ed8927a4e836f0639fa5f31576f5df70ce2b6ed3da0b96ad616f5ed71d7717531a073cb911c6d92274f6724911e086104af SHA512 824aa94724b639337a5b4c2e86a1f5ceaeaa940eb234f852df1ba0aafd64e269335e2aca0b05d52164e090cfd6f7d14477df9e096473aa5d9286d47944a765b4
|
||||||
DIST mariadb-10.2.33-patches-01.tar.xz 6024 BLAKE2B cb4283a36b303b1422d53c454bc6390ce80f3a88c9f9cd459468cf9bff792a1af197a5e5b3f7e45376024ef78bc6049cecafd8654e1b767f741f35129624ab12 SHA512 ebe9c1295089c04e869516f3ef278673986c1227b92bb9cd96cc561b0392f22870200cf58db91fdfe7e113b04b5b6d66c904b2d1353011cbd89723a8ce83fec2
|
DIST mariadb-10.2.33-patches-01.tar.xz 6024 BLAKE2B cb4283a36b303b1422d53c454bc6390ce80f3a88c9f9cd459468cf9bff792a1af197a5e5b3f7e45376024ef78bc6049cecafd8654e1b767f741f35129624ab12 SHA512 ebe9c1295089c04e869516f3ef278673986c1227b92bb9cd96cc561b0392f22870200cf58db91fdfe7e113b04b5b6d66c904b2d1353011cbd89723a8ce83fec2
|
||||||
DIST mariadb-10.2.33.tar.gz 73769891 BLAKE2B d5d564e6c51a6460247b999ae1d58433f15f5c7a4ffe7c676845857036c766aaf24e66cbbbaebc12cc55be97a22a4dec4916551bde65eac043cc036fc9e731b6 SHA512 336184931688beba5733d510db00d05eceb3909f8fcdf198189ea1fa96af6a401aa4f0b9e13e3fb0211f7be6c14aba8d0a9b245bd3c2a173e5b1f930a7a18460
|
DIST mariadb-10.2.34.tar.gz 73758617 BLAKE2B e25e4a6ef9916e6ff88d445bb729a5d1a33913a8aef1ecae3d701917f91d091f6f831bf428ab99d9ff7360f600bb98fad57fbc4f053632ba5c33e7cfbc333264 SHA512 ace6132ec5d02c4857e8b30b11697eb9a8ca007d11843d0288a1d5b519c3203658b8b0a01620fdd20297474c577be3f967828077012e5e13e6ee63c30bb4e8b7
|
||||||
DIST mariadb-10.3.23-patches-03.tar.xz 5520 BLAKE2B 30bc247ed6d97aefaa1ed48f379fc9aab3df3409aa9a108728313c7c69ab0641b69ccb0289eda9539df367f85b2db494473d3836807dfbf60df1e0c832e57369 SHA512 64bff196d1651348d303571fd551a5666d9514c1ee17cd9296b9d420c4b3d7d9b339644a1cad029bae3c35a666b405d471a37846138f2551f3b1b88d99b80844
|
DIST mariadb-10.3.23-patches-03.tar.xz 5520 BLAKE2B 30bc247ed6d97aefaa1ed48f379fc9aab3df3409aa9a108728313c7c69ab0641b69ccb0289eda9539df367f85b2db494473d3836807dfbf60df1e0c832e57369 SHA512 64bff196d1651348d303571fd551a5666d9514c1ee17cd9296b9d420c4b3d7d9b339644a1cad029bae3c35a666b405d471a37846138f2551f3b1b88d99b80844
|
||||||
DIST mariadb-10.3.23.tar.gz 72582611 BLAKE2B 493605519f714cbe87b938f6ca3243d29189adbfcbb33c4e10a4a3f01b08d875f18b96b647dc92566b785c2cef9862ebacfd55954d13ab0a7a745606e40fb6e9 SHA512 535cd2ce80a95b6c0a1aa559cc3275dfcd559c3a4f958fab3382923190a16e6bc5b4ad79acaa518244512ff618568c239c0edef8a701d958362ede19a29c2986
|
DIST mariadb-10.3.23.tar.gz 72582611 BLAKE2B 493605519f714cbe87b938f6ca3243d29189adbfcbb33c4e10a4a3f01b08d875f18b96b647dc92566b785c2cef9862ebacfd55954d13ab0a7a745606e40fb6e9 SHA512 535cd2ce80a95b6c0a1aa559cc3275dfcd559c3a4f958fab3382923190a16e6bc5b4ad79acaa518244512ff618568c239c0edef8a701d958362ede19a29c2986
|
||||||
DIST mariadb-10.3.24-patches-01.tar.xz 5508 BLAKE2B c3b75205ecec0b73c85696a3382dd9271d495389f05d1bff66548f5f316f6d5f2ee7204020f265a6dd7ee7c28e1a010d74b056b9c9ab244651ba417e496fb1a9 SHA512 d9d408e6ba08a8a321b9a6e72a6347c4317652e91ade0056ff8621dafbbaf398e33d6b15247e89a2d60b731021d30cba9611356ced2cf848d1807cb3d376c378
|
DIST mariadb-10.3.24-patches-01.tar.xz 5508 BLAKE2B c3b75205ecec0b73c85696a3382dd9271d495389f05d1bff66548f5f316f6d5f2ee7204020f265a6dd7ee7c28e1a010d74b056b9c9ab244651ba417e496fb1a9 SHA512 d9d408e6ba08a8a321b9a6e72a6347c4317652e91ade0056ff8621dafbbaf398e33d6b15247e89a2d60b731021d30cba9611356ced2cf848d1807cb3d376c378
|
||||||
DIST mariadb-10.3.24.tar.gz 72714002 BLAKE2B c25a1546369e8996dea2a4d00022a8a5a4f11727866cb3d377aa534b617b76540fe49871c92d38487b667db68885e7aabe22a7400015f513394f18fdd2899bcd SHA512 cfd0154d984ddc344554cd3df1d02b0811f8e35c90caf745532491688850736d079c67d40e9414daba83f2bd0c06569bfc99213d5280c63cf051c68abd7c56b5
|
DIST mariadb-10.3.25.tar.gz 72710424 BLAKE2B 95029946e2ed04368beadf33b42121c612fa9d146e648fd584078e4df88e3c93f6373e1e996817644e06f3b2713a257e3079167434e9227db01dc1a2ad08aad0 SHA512 9504e401db3b65b2b2bd4d3c91a468d357e82fdafbf90d54539a291e46570c2bed66ae047b17b9da95e925f8970fa048d329ba06c2dd6de7d46d5a0f2aad1f4d
|
||||||
DIST mariadb-10.4.13-patches-03.tar.xz 5520 BLAKE2B 949b7f6ee5a9a6077424264e53d2b7af8ceb56cb38b204800e1c3ec93fc929d57b201e075f8ed735364b5421a3b922ba45fc94ba006f1e6d94494efa17b521ef SHA512 042c3ca8a75ebbb1c2baa508603d4248a178f87b7126b439ef6894eaab979f01c47cd8fbea3c106cce2a951e9308c76e72b4e444dcbee09a991cb524f2b9fac8
|
DIST mariadb-10.4.13-patches-03.tar.xz 5520 BLAKE2B 949b7f6ee5a9a6077424264e53d2b7af8ceb56cb38b204800e1c3ec93fc929d57b201e075f8ed735364b5421a3b922ba45fc94ba006f1e6d94494efa17b521ef SHA512 042c3ca8a75ebbb1c2baa508603d4248a178f87b7126b439ef6894eaab979f01c47cd8fbea3c106cce2a951e9308c76e72b4e444dcbee09a991cb524f2b9fac8
|
||||||
DIST mariadb-10.4.13.tar.gz 80608459 BLAKE2B e9ada14da6ec7492311068549a5b6e5a66e1177312013b25472c084a21fbace543ec43b47f2e12190d45432648d508f311198521f42359561f8d75ea60f98205 SHA512 68919ceffb3d4afdd0d94daa77439a954c82ce4e08fbe06044fc397940eeb88a39ec75932cbd08ff26ef3cf7636fdb779947cda5b2764aa1fd888be19c44b566
|
DIST mariadb-10.4.13.tar.gz 80608459 BLAKE2B e9ada14da6ec7492311068549a5b6e5a66e1177312013b25472c084a21fbace543ec43b47f2e12190d45432648d508f311198521f42359561f8d75ea60f98205 SHA512 68919ceffb3d4afdd0d94daa77439a954c82ce4e08fbe06044fc397940eeb88a39ec75932cbd08ff26ef3cf7636fdb779947cda5b2764aa1fd888be19c44b566
|
||||||
DIST mariadb-10.4.14-patches-01.tar.xz 5512 BLAKE2B f32e1d383ffd99de431bc34c36101c71c5e631344527e96b80ca6bd0a68015b45a4c33d6f0518cb4aa2bcfd493b64b6607671450ca045243404c0d65ebbc66fd SHA512 201fe82cbcca705dba52b32405d463b5569d97a5ffd9fd2967ec7fc3c3ff305011b3d2c3c0e9f7c19aaac57b26661bd361f3b6da6f3812f25934ec18856c7051
|
DIST mariadb-10.4.14-patches-01.tar.xz 5512 BLAKE2B f32e1d383ffd99de431bc34c36101c71c5e631344527e96b80ca6bd0a68015b45a4c33d6f0518cb4aa2bcfd493b64b6607671450ca045243404c0d65ebbc66fd SHA512 201fe82cbcca705dba52b32405d463b5569d97a5ffd9fd2967ec7fc3c3ff305011b3d2c3c0e9f7c19aaac57b26661bd361f3b6da6f3812f25934ec18856c7051
|
||||||
DIST mariadb-10.4.14.tar.gz 80789865 BLAKE2B fed455e906af9fe105f52cc7180a6b8d8839fdbffac079f2ced265741c2ab8010c78c0e75ff77740d45a2bd02a15c379bdb3a0237152848a0ce1a7aaac4cbf32 SHA512 c09817c1dd7962132bcf2886c97ad17ce43c00ee687724028e5f39f6a6a93877ae8695c2c795abba6a4f3bc40674f93a53d6d43f46788a4a8a42c4a65a22c91c
|
DIST mariadb-10.4.15.tar.gz 80777094 BLAKE2B 576e06c1d62b399851e13fe0ac55ea94c462889bbd16ec25a2358e174e2822521008ad0dc021d742b1a12c5b22424208b6df92c2c0fb698a083b6a67a771bd64 SHA512 d7090e9e2a2b6fc5611fe498c44b00dbcd02e04456aaff3dc4cef7ef8cd284523776d01511f6f25f717306f6c49fca3f914d298f80e1c920cb6f9f87abebc0ca
|
||||||
DIST mariadb-10.5.5-patches-02.tar.xz 6060 BLAKE2B 185a2016836721f76c19228ca39c1c7610c34210e23b42f254e4c4fde34c74d9c77bb0d1a441175c14938ecafea3e9575fa3b7349db826aef63e7d7e7a21901a SHA512 8a26bdbec19d45739ef7accd3cea999bde465714141532d999500df2ebd93bb98a00b8b86b1e855ea4f0cba6984b21ff09beee75372f840282a91f5dc95db432
|
DIST mariadb-10.5.5-patches-02.tar.xz 6060 BLAKE2B 185a2016836721f76c19228ca39c1c7610c34210e23b42f254e4c4fde34c74d9c77bb0d1a441175c14938ecafea3e9575fa3b7349db826aef63e7d7e7a21901a SHA512 8a26bdbec19d45739ef7accd3cea999bde465714141532d999500df2ebd93bb98a00b8b86b1e855ea4f0cba6984b21ff09beee75372f840282a91f5dc95db432
|
||||||
DIST mariadb-10.5.5.tar.gz 86880268 BLAKE2B 58430dd4e7199d674bbd4f7381a56129e067ed1bb30c171545fe9fac3a83f7db2c57cc1b577ef242deb99dd69e17a1d3cbf756031711d27b04c97a7e93e14c60 SHA512 09bed291b39142f8e2f40eabbb443f6f384368b331406a09fd92d3d27ecc75644219066850d89495ed65c6f0d3ac32d51e29e65375331dcc2de4801313178d45
|
DIST mariadb-10.5.6.tar.gz 86884252 BLAKE2B b0230acf43d54e976c4e757139dbaa2bb6ed992b0d056728142fc7fa41bd62539be22eae5aac614ea49acf220646ee57ecc67ff1373c6aa142434e6743a4d174 SHA512 c62bd6278d389baf179962bc6f617693cf3ba748382e96963b1ef5bbee8d1c9f0964025cf00fb7ff5de088a79362b65657ed30a8adbb61fe524bfd0d8d753421
|
||||||
DIST mariadb-5.5.68.tar.gz 45969389 BLAKE2B 5b3a647649c614825adccbc83faa40ba330dae0a1f8005b2297cc6a44fbc00bf817f2d854af315f995e1065bd4d14a2f21a9cec44b5c78402524467d876d8157 SHA512 3419790aa88a7e2a5d80e56ca94683d22ca2d5d817dfe19904d11454f34cfc3b9d55e603295ea58580a3c9fe96a6c6f9b650e1058c4e8f2f2e82f09165436865
|
DIST mariadb-5.5.68.tar.gz 45969389 BLAKE2B 5b3a647649c614825adccbc83faa40ba330dae0a1f8005b2297cc6a44fbc00bf817f2d854af315f995e1065bd4d14a2f21a9cec44b5c78402524467d876d8157 SHA512 3419790aa88a7e2a5d80e56ca94683d22ca2d5d817dfe19904d11454f34cfc3b9d55e603295ea58580a3c9fe96a6c6f9b650e1058c4e8f2f2e82f09165436865
|
||||||
DIST mysql-extras-20190305-2052Z.tar.bz2 331304 BLAKE2B 1d2c35a961159fa5ce9ee6699fce943f5a5b5cf60b11c9bb4bcccee4943f4508a9eb6d01050c642353ac592ce1a6b421abf2a1bebc706c44c4c8a36aa698ec43 SHA512 ae63403320e010acbb92f8aec6da8ed4f267cef0bad37147d594076fd94571de7f98bfc2afbe94af5d716f58d57696fd958b1e13e20e87052f252ed4a188cd3c
|
DIST mysql-extras-20190305-2052Z.tar.bz2 331304 BLAKE2B 1d2c35a961159fa5ce9ee6699fce943f5a5b5cf60b11c9bb4bcccee4943f4508a9eb6d01050c642353ac592ce1a6b421abf2a1bebc706c44c4c8a36aa698ec43 SHA512 ae63403320e010acbb92f8aec6da8ed4f267cef0bad37147d594076fd94571de7f98bfc2afbe94af5d716f58d57696fd958b1e13e20e87052f252ed4a188cd3c
|
||||||
DIST mysql-extras-20200523-1221Z.tar.bz2 345015 BLAKE2B 3ad0da663c31831d3b511b88df34b6a28bb781cfd88fd4479b43273aa15946e63c7ae43d5497207edc6cc53a72bd42b8ce2e2058dfb236afd940bd0282190e98 SHA512 8f7b39017efb08e1ae98c4c68728bc86f8427b88b2a22688abf6975c6706122086dc93289beb511bbaf17cd5a790c76406e81315a11830829efe9170ce4f6a42
|
DIST mysql-extras-20200523-1221Z.tar.bz2 345015 BLAKE2B 3ad0da663c31831d3b511b88df34b6a28bb781cfd88fd4479b43273aa15946e63c7ae43d5497207edc6cc53a72bd42b8ce2e2058dfb236afd940bd0282190e98 SHA512 8f7b39017efb08e1ae98c4c68728bc86f8427b88b2a22688abf6975c6706122086dc93289beb511bbaf17cd5a790c76406e81315a11830829efe9170ce4f6a42
|
||||||
|
@ -0,0 +1,75 @@
|
|||||||
|
https://github.com/MariaDB/server/commit/418850b2df4256da5a722288c2657650dc228842
|
||||||
|
|
||||||
|
--- a/sql/wsrep_sst.cc
|
||||||
|
+++ b/sql/wsrep_sst.cc
|
||||||
|
@@ -1726,24 +1726,65 @@ static int sst_donate_other (const char* method,
|
||||||
|
return arg.err;
|
||||||
|
}
|
||||||
|
|
||||||
|
+/* return true if character can be a part of a filename */
|
||||||
|
+static bool filename_char(int const c)
|
||||||
|
+{
|
||||||
|
+ return isalnum(c) || (c == '-') || (c == '_') || (c == '.');
|
||||||
|
+}
|
||||||
|
+
|
||||||
|
+/* return true if character can be a part of an address string */
|
||||||
|
+static bool address_char(int const c)
|
||||||
|
+{
|
||||||
|
+ return filename_char(c) ||
|
||||||
|
+ (c == ':') || (c == '[') || (c == ']') || (c == '/');
|
||||||
|
+}
|
||||||
|
+
|
||||||
|
+static bool check_request_str(const char* const str,
|
||||||
|
+ bool (*check) (int c))
|
||||||
|
+{
|
||||||
|
+ for (size_t i(0); str[i] != '\0'; ++i)
|
||||||
|
+ {
|
||||||
|
+ if (!check(str[i]))
|
||||||
|
+ {
|
||||||
|
+ WSREP_WARN("Illegal character in state transfer request: %i (%c).",
|
||||||
|
+ str[i], str[i]);
|
||||||
|
+ return true;
|
||||||
|
+ }
|
||||||
|
+ }
|
||||||
|
+
|
||||||
|
+ return false;
|
||||||
|
+}
|
||||||
|
+
|
||||||
|
wsrep_cb_status_t wsrep_sst_donate_cb (void* app_ctx, void* recv_ctx,
|
||||||
|
const void* msg, size_t msg_len,
|
||||||
|
const wsrep_gtid_t* current_gtid,
|
||||||
|
const char* state, size_t state_len,
|
||||||
|
bool bypass)
|
||||||
|
{
|
||||||
|
- /* This will be reset when sync callback is called.
|
||||||
|
- * Should we set wsrep_ready to FALSE here too? */
|
||||||
|
-
|
||||||
|
- wsrep_config_state->set(WSREP_MEMBER_DONOR);
|
||||||
|
-
|
||||||
|
const char* method = (char*)msg;
|
||||||
|
size_t method_len = strlen (method);
|
||||||
|
+
|
||||||
|
+ if (check_request_str(method, filename_char))
|
||||||
|
+ {
|
||||||
|
+ WSREP_ERROR("Bad SST method name. SST canceled.");
|
||||||
|
+ return WSREP_CB_FAILURE;
|
||||||
|
+ }
|
||||||
|
+
|
||||||
|
const char* data = method + method_len + 1;
|
||||||
|
|
||||||
|
+ if (check_request_str(data, address_char))
|
||||||
|
+ {
|
||||||
|
+ WSREP_ERROR("Bad SST address string. SST canceled.");
|
||||||
|
+ return WSREP_CB_FAILURE;
|
||||||
|
+ }
|
||||||
|
+
|
||||||
|
char uuid_str[37];
|
||||||
|
wsrep_uuid_print (¤t_gtid->uuid, uuid_str, sizeof(uuid_str));
|
||||||
|
|
||||||
|
+ /* This will be reset when sync callback is called.
|
||||||
|
+ * Should we set wsrep_ready to FALSE here too? */
|
||||||
|
+ wsrep_config_state->set(WSREP_MEMBER_DONOR);
|
||||||
|
+
|
||||||
|
wsp::env env(NULL);
|
||||||
|
if (env.error())
|
||||||
|
{
|
@ -0,0 +1,62 @@
|
|||||||
|
https://github.com/MariaDB/server/commit/418850b2df4256da5a722288c2657650dc228842
|
||||||
|
|
||||||
|
--- a/sql/wsrep_sst.cc
|
||||||
|
+++ b/sql/wsrep_sst.cc
|
||||||
|
@@ -1822,6 +1822,35 @@ static int sst_donate_other (const char* method,
|
||||||
|
return arg.err;
|
||||||
|
}
|
||||||
|
|
||||||
|
+/* return true if character can be a part of a filename */
|
||||||
|
+static bool filename_char(int const c)
|
||||||
|
+{
|
||||||
|
+ return isalnum(c) || (c == '-') || (c == '_') || (c == '.');
|
||||||
|
+}
|
||||||
|
+
|
||||||
|
+/* return true if character can be a part of an address string */
|
||||||
|
+static bool address_char(int const c)
|
||||||
|
+{
|
||||||
|
+ return filename_char(c) ||
|
||||||
|
+ (c == ':') || (c == '[') || (c == ']') || (c == '/');
|
||||||
|
+}
|
||||||
|
+
|
||||||
|
+static bool check_request_str(const char* const str,
|
||||||
|
+ bool (*check) (int c))
|
||||||
|
+{
|
||||||
|
+ for (size_t i(0); str[i] != '\0'; ++i)
|
||||||
|
+ {
|
||||||
|
+ if (!check(str[i]))
|
||||||
|
+ {
|
||||||
|
+ WSREP_WARN("Illegal character in state transfer request: %i (%c).",
|
||||||
|
+ str[i], str[i]);
|
||||||
|
+ return true;
|
||||||
|
+ }
|
||||||
|
+ }
|
||||||
|
+
|
||||||
|
+ return false;
|
||||||
|
+}
|
||||||
|
+
|
||||||
|
int wsrep_sst_donate(const std::string& msg,
|
||||||
|
const wsrep::gtid& current_gtid,
|
||||||
|
const bool bypass)
|
||||||
|
@@ -1833,8 +1862,21 @@ int wsrep_sst_donate(const std::string& msg,
|
||||||
|
|
||||||
|
const char* method= msg.data();
|
||||||
|
size_t method_len= strlen (method);
|
||||||
|
+
|
||||||
|
+ if (check_request_str(method, filename_char))
|
||||||
|
+ {
|
||||||
|
+ WSREP_ERROR("Bad SST method name. SST canceled.");
|
||||||
|
+ return WSREP_CB_FAILURE;
|
||||||
|
+ }
|
||||||
|
+
|
||||||
|
const char* data= method + method_len + 1;
|
||||||
|
|
||||||
|
+ if (check_request_str(data, address_char))
|
||||||
|
+ {
|
||||||
|
+ WSREP_ERROR("Bad SST address string. SST canceled.");
|
||||||
|
+ return WSREP_CB_FAILURE;
|
||||||
|
+ }
|
||||||
|
+
|
||||||
|
wsp::env env(NULL);
|
||||||
|
if (env.error())
|
||||||
|
{
|
@ -1,892 +0,0 @@
|
|||||||
# Copyright 1999-2020 Gentoo Authors
|
|
||||||
# Distributed under the terms of the GNU General Public License v2
|
|
||||||
|
|
||||||
EAPI="6"
|
|
||||||
MY_EXTRAS_VER="20190305-2052Z"
|
|
||||||
SUBSLOT="18"
|
|
||||||
|
|
||||||
JAVA_PKG_OPT_USE="jdbc"
|
|
||||||
|
|
||||||
# Keeping eutils in EAPI=6 for emktemp in pkg_config
|
|
||||||
|
|
||||||
inherit eutils systemd flag-o-matic prefix toolchain-funcs java-pkg-opt-2 user cmake-utils multilib-build
|
|
||||||
|
|
||||||
SRC_URI="https://downloads.mariadb.org/interstitial/${P}/source/${P}.tar.gz "
|
|
||||||
|
|
||||||
# Gentoo patches to MySQL
|
|
||||||
if [[ "${MY_EXTRAS_VER}" != "live" && "${MY_EXTRAS_VER}" != "none" ]]; then
|
|
||||||
SRC_URI="${SRC_URI}
|
|
||||||
mirror://gentoo/mysql-extras-${MY_EXTRAS_VER}.tar.bz2
|
|
||||||
https://gitweb.gentoo.org/proj/mysql-extras.git/snapshot/mysql-extras-${MY_EXTRAS_VER}.tar.bz2
|
|
||||||
https://dev.gentoo.org/~grknight/distfiles/mysql-extras-${MY_EXTRAS_VER}.tar.bz2
|
|
||||||
https://dev.gentoo.org/~robbat2/distfiles/mysql-extras-${MY_EXTRAS_VER}.tar.bz2
|
|
||||||
https://dev.gentoo.org/~jmbsvicetto/distfiles/mysql-extras-${MY_EXTRAS_VER}.tar.bz2"
|
|
||||||
fi
|
|
||||||
|
|
||||||
HOMEPAGE="https://mariadb.org/"
|
|
||||||
DESCRIPTION="An enhanced, drop-in replacement for MySQL"
|
|
||||||
LICENSE="GPL-2"
|
|
||||||
SLOT="10.1/${SUBSLOT:-0}"
|
|
||||||
IUSE="+backup bindist client-libs cracklib debug extraengine galera jdbc jemalloc kerberos
|
|
||||||
innodb-lz4 innodb-lzo innodb-snappy latin1 libressl mroonga numa odbc oqgraph pam
|
|
||||||
+perl profiling selinux +server sphinx sst-rsync sst-mariabackup sst-xtrabackup
|
|
||||||
systemd systemtap static static-libs tcmalloc test tokudb xml yassl"
|
|
||||||
|
|
||||||
# Tests always fail when libressl is enabled due to hard-coded ciphers in the tests
|
|
||||||
RESTRICT="!bindist? ( bindist ) !test? ( test ) libressl? ( test )"
|
|
||||||
|
|
||||||
REQUIRED_USE="jdbc? ( extraengine server !static )
|
|
||||||
server? ( tokudb? ( jemalloc !tcmalloc ) )
|
|
||||||
?? ( tcmalloc jemalloc )
|
|
||||||
static? ( yassl !pam )"
|
|
||||||
|
|
||||||
KEYWORDS="ppc ppc64"
|
|
||||||
|
|
||||||
# Shorten the path because the socket path length must be shorter than 107 chars
|
|
||||||
# and we will run a mysql server during test phase
|
|
||||||
S="${WORKDIR}/mysql"
|
|
||||||
|
|
||||||
if [[ "${MY_EXTRAS_VER}" == "live" ]] ; then
|
|
||||||
MY_PATCH_DIR="${WORKDIR%/}/mysql-extras"
|
|
||||||
inherit git-r3
|
|
||||||
EGIT_REPO_URI="git://anongit.gentoo.org/proj/mysql-extras.git"
|
|
||||||
EGIT_CHECKOUT_DIR="${WORKDIR%/}/mysql-extras"
|
|
||||||
EGIT_CLONE_TYPE=shallow
|
|
||||||
else
|
|
||||||
MY_PATCH_DIR="${WORKDIR%/}/mysql-extras-${MY_EXTRAS_VER}"
|
|
||||||
fi
|
|
||||||
|
|
||||||
PATCHES=(
|
|
||||||
"${MY_PATCH_DIR}"/20006_all_cmake_elib-mariadb-10.1.27.patch
|
|
||||||
"${MY_PATCH_DIR}"/20009_all_mariadb_myodbc_symbol_fix-5.5.38.patch
|
|
||||||
"${MY_PATCH_DIR}"/20015_all_mariadb-pkgconfig-location.patch
|
|
||||||
"${MY_PATCH_DIR}"/20018_all_mariadb-10.1.16-without-clientlibs-tools.patch
|
|
||||||
"${MY_PATCH_DIR}"/20025_all_mariadb-10.1.26-gssapi-detect.patch
|
|
||||||
"${MY_PATCH_DIR}"/20029_all_mariadb-10.1.37-enable-numa.patch
|
|
||||||
"${MY_PATCH_DIR}"/20035_all_mariadb-10.1-atomic-detection.patch
|
|
||||||
)
|
|
||||||
|
|
||||||
# Be warned, *DEPEND are version-dependant
|
|
||||||
# These are used for both runtime and compiletime
|
|
||||||
COMMON_DEPEND="
|
|
||||||
kernel_linux? (
|
|
||||||
sys-process/procps:0=
|
|
||||||
dev-libs/libaio:0=
|
|
||||||
)
|
|
||||||
>=sys-apps/sed-4
|
|
||||||
>=sys-apps/texinfo-4.7-r1
|
|
||||||
jemalloc? ( dev-libs/jemalloc:0= )
|
|
||||||
tcmalloc? ( dev-util/google-perftools:0= )
|
|
||||||
systemtap? ( >=dev-util/systemtap-1.3:0= )
|
|
||||||
!yassl? (
|
|
||||||
!libressl? ( dev-libs/openssl:0= !>=dev-libs/openssl-1.1 )
|
|
||||||
libressl? ( dev-libs/libressl:0= )
|
|
||||||
)
|
|
||||||
>=sys-libs/zlib-1.2.3:0=
|
|
||||||
sys-libs/ncurses:0=
|
|
||||||
!bindist? (
|
|
||||||
sys-libs/binutils-libs:0=
|
|
||||||
>=sys-libs/readline-4.1:0=
|
|
||||||
)
|
|
||||||
server? (
|
|
||||||
backup? ( app-arch/libarchive:0= )
|
|
||||||
cracklib? ( sys-libs/cracklib:0= )
|
|
||||||
extraengine? (
|
|
||||||
odbc? ( dev-db/unixODBC:0= )
|
|
||||||
xml? ( dev-libs/libxml2:2= )
|
|
||||||
sys-libs/zlib[minizip]
|
|
||||||
)
|
|
||||||
innodb-lz4? ( app-arch/lz4 )
|
|
||||||
innodb-lzo? ( dev-libs/lzo )
|
|
||||||
innodb-snappy? ( app-arch/snappy )
|
|
||||||
kerberos? ( virtual/krb5 )
|
|
||||||
mroonga? ( app-text/groonga-normalizer-mysql >=app-text/groonga-7.0.4 )
|
|
||||||
numa? ( sys-process/numactl )
|
|
||||||
oqgraph? ( >=dev-libs/boost-1.40.0:0= dev-libs/judy:0= )
|
|
||||||
pam? ( sys-libs/pam:0= )
|
|
||||||
systemd? ( sys-apps/systemd:= )
|
|
||||||
tokudb? ( app-arch/snappy )
|
|
||||||
)
|
|
||||||
!yassl? ( !libressl? ( !>=dev-libs/openssl-1.1.0 ) )
|
|
||||||
>=dev-libs/libpcre-8.41-r1:3=
|
|
||||||
!client-libs? ( dev-db/mysql-connector-c[${MULTILIB_USEDEP},static-libs?] )
|
|
||||||
"
|
|
||||||
DEPEND="virtual/yacc
|
|
||||||
static? ( sys-libs/ncurses[static-libs] )
|
|
||||||
|| ( >=sys-devel/gcc-3.4.6 >=sys-devel/gcc-apple-4.0 )
|
|
||||||
server? ( extraengine? ( jdbc? ( >=virtual/jdk-1.6 ) ) )
|
|
||||||
${COMMON_DEPEND}"
|
|
||||||
RDEPEND="selinux? ( sec-policy/selinux-mysql )
|
|
||||||
client-libs? ( !dev-db/mariadb-connector-c[mysqlcompat] !dev-db/mysql-connector-c )
|
|
||||||
!dev-db/mysql !dev-db/mariadb-galera !dev-db/percona-server !dev-db/mysql-cluster
|
|
||||||
!dev-db/mariadb:0
|
|
||||||
!dev-db/mariadb:5.5
|
|
||||||
!dev-db/mariadb:10.2
|
|
||||||
!dev-db/mariadb:10.3
|
|
||||||
!dev-db/mariadb:10.4
|
|
||||||
!dev-db/mariadb:10.5
|
|
||||||
server? ( !prefix? ( dev-db/mysql-init-scripts ) )
|
|
||||||
${COMMON_DEPEND}
|
|
||||||
server? ( galera? (
|
|
||||||
sys-apps/iproute2
|
|
||||||
=sys-cluster/galera-25*
|
|
||||||
sst-rsync? ( sys-process/lsof )
|
|
||||||
sst-mariabackup? ( net-misc/socat[ssl] )
|
|
||||||
sst-xtrabackup? ( net-misc/socat[ssl] )
|
|
||||||
) )
|
|
||||||
perl? ( !dev-db/mytop
|
|
||||||
virtual/perl-Getopt-Long
|
|
||||||
dev-perl/TermReadKey
|
|
||||||
virtual/perl-Term-ANSIColor
|
|
||||||
virtual/perl-Time-HiRes )
|
|
||||||
server? ( extraengine? ( jdbc? ( >=virtual/jre-1.6 ) ) )
|
|
||||||
"
|
|
||||||
# For other stuff to bring us in
|
|
||||||
# dev-perl/DBD-mysql is needed by some scripts installed by MySQL
|
|
||||||
# percona-xtrabackup-bin causes a circular dependency if DBD-mysql is not already installed
|
|
||||||
PDEPEND="perl? ( >=dev-perl/DBD-mysql-2.9004 )
|
|
||||||
server? ( galera? ( sst-xtrabackup? ( || ( >=dev-db/percona-xtrabackup-bin-2.2.4 dev-db/percona-xtrabackup ) ) ) )"
|
|
||||||
|
|
||||||
pkg_setup() {
|
|
||||||
if [[ ${MERGE_TYPE} != binary ]] ; then
|
|
||||||
local GCC_MAJOR_SET=$(gcc-major-version)
|
|
||||||
local GCC_MINOR_SET=$(gcc-minor-version)
|
|
||||||
if use tokudb && [[ ${GCC_MAJOR_SET} -lt 4 || \
|
|
||||||
${GCC_MAJOR_SET} -eq 4 && ${GCC_MINOR_SET} -lt 7 ]] ; then
|
|
||||||
eerror "${PN} with tokudb needs to be built with gcc-4.7 or later."
|
|
||||||
eerror "Please use gcc-config to switch to gcc-4.7 or later version."
|
|
||||||
die
|
|
||||||
fi
|
|
||||||
# Bug 565584. InnoDB now requires atomic functions introduced with gcc-4.7 on
|
|
||||||
# non x86{,_64} arches
|
|
||||||
if ! use amd64 && ! use x86 && [[ ${GCC_MAJOR_SET} -lt 4 || \
|
|
||||||
${GCC_MAJOR_SET} -eq 4 && ${GCC_MINOR_SET} -lt 7 ]] ; then
|
|
||||||
eerror "${PN} needs to be built with gcc-4.7 or later."
|
|
||||||
eerror "Please use gcc-config to switch to gcc-4.7 or later version."
|
|
||||||
die
|
|
||||||
fi
|
|
||||||
fi
|
|
||||||
java-pkg-opt-2_pkg_setup
|
|
||||||
if has test ${FEATURES} && \
|
|
||||||
use server && ! has userpriv ${FEATURES} ; then
|
|
||||||
eerror "Testing with FEATURES=-userpriv is no longer supported by upstream. Tests MUST be run as non-root."
|
|
||||||
fi
|
|
||||||
|
|
||||||
# This should come after all of the die statements
|
|
||||||
enewgroup mysql 60 || die "problem adding 'mysql' group"
|
|
||||||
enewuser mysql 60 -1 /dev/null mysql || die "problem adding 'mysql' user"
|
|
||||||
}
|
|
||||||
|
|
||||||
pkg_preinst() {
|
|
||||||
java-pkg-opt-2_pkg_preinst
|
|
||||||
}
|
|
||||||
|
|
||||||
pkg_postinst() {
|
|
||||||
# Make sure the vars are correctly initialized
|
|
||||||
mysql_init_vars
|
|
||||||
|
|
||||||
# Create log directory securely if it does not exist
|
|
||||||
[[ -d "${ROOT}${MY_LOGDIR}" ]] || install -d -m0750 -o mysql -g mysql "${ROOT}${MY_LOGDIR}"
|
|
||||||
|
|
||||||
if use server ; then
|
|
||||||
if use pam; then
|
|
||||||
einfo
|
|
||||||
elog "This install includes the PAM authentication plugin."
|
|
||||||
elog "To activate and configure the PAM plugin, please read:"
|
|
||||||
elog "https://mariadb.com/kb/en/mariadb/pam-authentication-plugin/"
|
|
||||||
einfo
|
|
||||||
fi
|
|
||||||
|
|
||||||
if [[ -z "${REPLACING_VERSIONS}" ]] ; then
|
|
||||||
einfo
|
|
||||||
elog "You might want to run:"
|
|
||||||
elog "\"emerge --config =${CATEGORY}/${PF}\""
|
|
||||||
elog "if this is a new install."
|
|
||||||
elog
|
|
||||||
elog "If you are switching server implentations, you should run the"
|
|
||||||
elog "mysql_upgrade tool."
|
|
||||||
einfo
|
|
||||||
else
|
|
||||||
einfo
|
|
||||||
elog "If you are upgrading major versions, you should run the"
|
|
||||||
elog "mysql_upgrade tool."
|
|
||||||
einfo
|
|
||||||
fi
|
|
||||||
|
|
||||||
einfo
|
|
||||||
elog "Be sure to edit the my.cnf file to activate your cluster settings."
|
|
||||||
elog "This should be done after running \"emerge --config =${CATEGORY}/${PF}\""
|
|
||||||
elog "The first time the cluster is activated, you should add"
|
|
||||||
elog "--wsrep-new-cluster to the options in /etc/conf.d/mysql for one node."
|
|
||||||
elog "This option should then be removed for subsequent starts."
|
|
||||||
einfo
|
|
||||||
fi
|
|
||||||
}
|
|
||||||
|
|
||||||
src_unpack() {
|
|
||||||
unpack ${A}
|
|
||||||
# Grab the patches
|
|
||||||
[[ "${MY_EXTRAS_VER}" == "live" ]] && S="${WORKDIR%/}/mysql-extras" git-r3_src_unpack
|
|
||||||
|
|
||||||
mv -f "${WORKDIR%/}/${PN%%-galera}-${PV}" "${S}" || die
|
|
||||||
}
|
|
||||||
|
|
||||||
src_prepare() {
|
|
||||||
_disable_engine() {
|
|
||||||
echo > "${S%/}/storage/${1}/CMakeLists.txt" || die
|
|
||||||
}
|
|
||||||
|
|
||||||
_disable_plugin() {
|
|
||||||
echo > "${S%/}/plugin/${1}/CMakeLists.txt" || die
|
|
||||||
}
|
|
||||||
|
|
||||||
if use tcmalloc; then
|
|
||||||
echo "TARGET_LINK_LIBRARIES(mysqld tcmalloc)" >> "${S%/}/sql/CMakeLists.txt" || die
|
|
||||||
fi
|
|
||||||
|
|
||||||
# Don't build bundled xz-utils for tokudb
|
|
||||||
echo > "${S%/}/storage/tokudb/PerconaFT/cmake_modules/TokuThirdParty.cmake" || die
|
|
||||||
sed -i -e 's/ build_lzma//' -e 's/ build_snappy//' "${S%/}/storage/tokudb/PerconaFT/ft/CMakeLists.txt" || die
|
|
||||||
sed -i -e 's/add_dependencies\(tokuportability_static_conv build_jemalloc\)//' "${S%/}/storage/tokudb/PerconaFT/portability/CMakeLists.txt" || die
|
|
||||||
|
|
||||||
local plugin
|
|
||||||
local server_plugins=( handler_socket auth_socket feedback metadata_lock_info
|
|
||||||
locale_info qc_info server_audit semisync sql_errlog )
|
|
||||||
local test_plugins=( audit_null auth_examples daemon_example fulltext )
|
|
||||||
if ! use server; then # These plugins are for the server
|
|
||||||
for plugin in "${server_plugins[@]}" ; do
|
|
||||||
_disable_plugin "${plugin}"
|
|
||||||
done
|
|
||||||
fi
|
|
||||||
|
|
||||||
if ! use test; then # These plugins are only used during testing
|
|
||||||
for plugin in "${test_plugins[@]}" ; do
|
|
||||||
_disable_plugin "${plugin}"
|
|
||||||
done
|
|
||||||
fi
|
|
||||||
|
|
||||||
# Collides with mariadb-connector-c bug 655980
|
|
||||||
_disable_plugin auth_dialog
|
|
||||||
|
|
||||||
# Avoid useless library checks
|
|
||||||
use mroonga || _disable_engine mroonga
|
|
||||||
use oqgraph || _disable_engine oqgraph
|
|
||||||
_disable_engine example
|
|
||||||
|
|
||||||
cmake-utils_src_prepare
|
|
||||||
java-pkg-opt-2_src_prepare
|
|
||||||
}
|
|
||||||
|
|
||||||
src_configure() {
|
|
||||||
# bug 508724 mariadb cannot use ld.gold
|
|
||||||
tc-ld-disable-gold
|
|
||||||
# Bug #114895, bug #110149
|
|
||||||
filter-flags "-O" "-O[01]"
|
|
||||||
|
|
||||||
append-cxxflags -felide-constructors
|
|
||||||
|
|
||||||
# bug #283926, with GCC4.4, this is required to get correct behavior.
|
|
||||||
append-flags -fno-strict-aliasing
|
|
||||||
|
|
||||||
CMAKE_BUILD_TYPE="RelWithDebInfo"
|
|
||||||
|
|
||||||
# debug hack wrt #497532
|
|
||||||
mycmakeargs=(
|
|
||||||
-DCMAKE_C_FLAGS_RELWITHDEBINFO="$(usex debug '' '-DNDEBUG')"
|
|
||||||
-DCMAKE_CXX_FLAGS_RELWITHDEBINFO="$(usex debug '' '-DNDEBUG')"
|
|
||||||
-DDEFAULT_SYSCONFDIR="${EPREFIX}/etc/mysql"
|
|
||||||
-DINSTALL_BINDIR=bin
|
|
||||||
-DINSTALL_DOCDIR=share/doc/${PF}
|
|
||||||
-DINSTALL_DOCREADMEDIR=share/doc/${PF}
|
|
||||||
-DINSTALL_INCLUDEDIR=include/mysql
|
|
||||||
-DINSTALL_INFODIR=share/info
|
|
||||||
-DINSTALL_LIBDIR=$(get_libdir)
|
|
||||||
-DINSTALL_MANDIR=share/man
|
|
||||||
-DINSTALL_MYSQLSHAREDIR=share/mariadb
|
|
||||||
-DINSTALL_MYSQLTESTDIR=$(usex test 'share/mariadb/mysql-test' '')
|
|
||||||
-DINSTALL_PLUGINDIR=$(get_libdir)/mariadb/plugin
|
|
||||||
-DINSTALL_SCRIPTDIR=share/mariadb/scripts
|
|
||||||
-DINSTALL_MYSQLDATADIR="${EPREFIX}/var/lib/mysql"
|
|
||||||
-DINSTALL_SBINDIR=sbin
|
|
||||||
-DINSTALL_SUPPORTFILESDIR="${EPREFIX}/usr/share/mariadb"
|
|
||||||
-DCOMPILATION_COMMENT="Gentoo Linux ${PF}"
|
|
||||||
-DWITH_UNIT_TESTS=$(usex test ON OFF)
|
|
||||||
-DWITH_ZLIB=system
|
|
||||||
-DENABLED_LOCAL_INFILE=1
|
|
||||||
-DMYSQL_UNIX_ADDR="${EPREFIX}/var/run/mysqld/mysqld.sock"
|
|
||||||
-DINSTALL_UNIX_ADDRDIR="${EPREFIX}/var/run/mysqld/mysqld.sock"
|
|
||||||
-DWITH_DEFAULT_COMPILER_OPTIONS=0
|
|
||||||
-DWITH_DEFAULT_FEATURE_SET=0
|
|
||||||
-DINSTALL_SYSTEMD_UNITDIR="$(systemd_get_systemunitdir)"
|
|
||||||
# The build forces this to be defined when cross-compiling. We pass it
|
|
||||||
# all the time for simplicity and to make sure it is actually correct.
|
|
||||||
-DSTACK_DIRECTION=$(tc-stack-grows-down && echo -1 || echo 1)
|
|
||||||
-DWITHOUT_CLIENTLIBS=YES
|
|
||||||
-DWITH_READLINE=$(usex bindist 1 0)
|
|
||||||
-DNOT_FOR_DISTRIBUTION=$(usex bindist 0 1)
|
|
||||||
-DENABLE_DTRACE=$(usex systemtap)
|
|
||||||
-DWITH_SSL=$(usex yassl bundled system)
|
|
||||||
)
|
|
||||||
|
|
||||||
if use server ; then
|
|
||||||
|
|
||||||
# Federated{,X} must be treated special otherwise they will not be built as plugins
|
|
||||||
if ! use extraengine ; then
|
|
||||||
mycmakeargs+=(
|
|
||||||
-DPLUGIN_FEDERATED=NO
|
|
||||||
-DPLUGIN_FEDERATEDX=NO )
|
|
||||||
fi
|
|
||||||
|
|
||||||
mycmakeargs+=(
|
|
||||||
-DWITH_JEMALLOC=$(usex jemalloc system)
|
|
||||||
-DWITH_PCRE=system
|
|
||||||
-DPLUGIN_OQGRAPH=$(usex oqgraph DYNAMIC NO)
|
|
||||||
-DPLUGIN_SPHINX=$(usex sphinx YES NO)
|
|
||||||
-DPLUGIN_TOKUDB=$(usex tokudb YES NO)
|
|
||||||
-DPLUGIN_AUTH_PAM=$(usex pam YES NO)
|
|
||||||
-DPLUGIN_CRACKLIB_PASSWORD_CHECK=$(usex cracklib YES NO)
|
|
||||||
-DPLUGIN_CASSANDRA=NO
|
|
||||||
-DPLUGIN_SEQUENCE=$(usex extraengine YES NO)
|
|
||||||
-DPLUGIN_SPIDER=$(usex extraengine YES NO)
|
|
||||||
-DPLUGIN_CONNECT=$(usex extraengine YES NO)
|
|
||||||
-DCONNECT_WITH_MYSQL=1
|
|
||||||
-DCONNECT_WITH_LIBXML2=$(usex xml)
|
|
||||||
-DCONNECT_WITH_ODBC=$(usex odbc)
|
|
||||||
-DCONNECT_WITH_JDBC=$(usex jdbc)
|
|
||||||
# Build failure and autodep wrt bug 639144
|
|
||||||
-DCONNECT_WITH_MONGO=OFF
|
|
||||||
-DWITH_WSREP=$(usex galera)
|
|
||||||
-DWITH_INNODB_LZ4=$(usex innodb-lz4 ON OFF)
|
|
||||||
-DWITH_INNODB_LZO=$(usex innodb-lzo ON OFF)
|
|
||||||
-DWITH_INNODB_SNAPPY=$(usex innodb-snappy ON OFF)
|
|
||||||
-DPLUGIN_MROONGA=$(usex mroonga DYNAMIC NO)
|
|
||||||
-DPLUGIN_AUTH_GSSAPI=$(usex kerberos DYNAMIC NO)
|
|
||||||
-DPLUGIN_AUTH_GSSAPI_CLIENT=NO
|
|
||||||
-DWITH_MARIABACKUP=$(usex backup ON OFF)
|
|
||||||
-DWITH_LIBARCHIVE=$(usex backup ON OFF)
|
|
||||||
-DWITH_SYSTEMD=$(usex systemd yes no)
|
|
||||||
-DWITH_NUMA=$(usex numa ON OFF)
|
|
||||||
-DINSTALL_SQLBENCHDIR=''
|
|
||||||
)
|
|
||||||
|
|
||||||
if [[ ( -n ${MYSQL_DEFAULT_CHARSET} ) && ( -n ${MYSQL_DEFAULT_COLLATION} ) ]]; then
|
|
||||||
ewarn "You are using a custom charset of ${MYSQL_DEFAULT_CHARSET}"
|
|
||||||
ewarn "and a collation of ${MYSQL_DEFAULT_COLLATION}."
|
|
||||||
ewarn "You MUST file bugs without these variables set."
|
|
||||||
|
|
||||||
mycmakeargs+=(
|
|
||||||
-DDEFAULT_CHARSET=${MYSQL_DEFAULT_CHARSET}
|
|
||||||
-DDEFAULT_COLLATION=${MYSQL_DEFAULT_COLLATION}
|
|
||||||
)
|
|
||||||
|
|
||||||
elif ! use latin1 ; then
|
|
||||||
mycmakeargs+=(
|
|
||||||
-DDEFAULT_CHARSET=utf8
|
|
||||||
-DDEFAULT_COLLATION=utf8_general_ci
|
|
||||||
)
|
|
||||||
else
|
|
||||||
mycmakeargs+=(
|
|
||||||
-DDEFAULT_CHARSET=latin1
|
|
||||||
-DDEFAULT_COLLATION=latin1_swedish_ci
|
|
||||||
)
|
|
||||||
fi
|
|
||||||
mycmakeargs+=(
|
|
||||||
-DEXTRA_CHARSETS=all
|
|
||||||
-DMYSQL_USER=mysql
|
|
||||||
-DDISABLE_SHARED=$(usex static YES NO)
|
|
||||||
-DWITH_DEBUG=$(usex debug)
|
|
||||||
-DWITH_EMBEDDED_SERVER=OFF
|
|
||||||
-DENABLED_PROFILING=$(usex profiling)
|
|
||||||
)
|
|
||||||
|
|
||||||
if use static; then
|
|
||||||
mycmakeargs+=( -DWITH_PIC=1 )
|
|
||||||
fi
|
|
||||||
|
|
||||||
if use jemalloc || use tcmalloc ; then
|
|
||||||
mycmakeargs+=( -DWITH_SAFEMALLOC=OFF )
|
|
||||||
fi
|
|
||||||
|
|
||||||
# Storage engines
|
|
||||||
mycmakeargs+=(
|
|
||||||
-DWITH_ARCHIVE_STORAGE_ENGINE=1
|
|
||||||
-DWITH_BLACKHOLE_STORAGE_ENGINE=1
|
|
||||||
-DWITH_CSV_STORAGE_ENGINE=1
|
|
||||||
-DWITH_HEAP_STORAGE_ENGINE=1
|
|
||||||
-DWITH_INNOBASE_STORAGE_ENGINE=1
|
|
||||||
-DWITH_MYISAMMRG_STORAGE_ENGINE=1
|
|
||||||
-DWITH_MYISAM_STORAGE_ENGINE=1
|
|
||||||
-DWITH_PARTITION_STORAGE_ENGINE=1
|
|
||||||
)
|
|
||||||
|
|
||||||
else
|
|
||||||
mycmakeargs+=(
|
|
||||||
-DWITHOUT_SERVER=1
|
|
||||||
-DWITH_EMBEDDED_SERVER=OFF
|
|
||||||
-DEXTRA_CHARSETS=none
|
|
||||||
-DINSTALL_SQLBENCHDIR=
|
|
||||||
-DWITH_SYSTEMD=no
|
|
||||||
)
|
|
||||||
fi
|
|
||||||
|
|
||||||
cmake-utils_src_configure
|
|
||||||
}
|
|
||||||
|
|
||||||
src_compile() {
|
|
||||||
cmake-utils_src_compile
|
|
||||||
}
|
|
||||||
|
|
||||||
src_install() {
|
|
||||||
cmake-utils_src_install
|
|
||||||
|
|
||||||
# Remove an unnecessary, private config header which will never match between ABIs and is not meant to be used
|
|
||||||
if [[ -f "${ED}/usr/include/mysql/server/private/config.h" ]] ; then
|
|
||||||
rm "${ED}/usr/include/mysql/server/private/config.h" || die
|
|
||||||
fi
|
|
||||||
|
|
||||||
# Make sure the vars are correctly initialized
|
|
||||||
mysql_init_vars
|
|
||||||
|
|
||||||
# Convenience links
|
|
||||||
einfo "Making Convenience links for mysqlcheck multi-call binary"
|
|
||||||
dosym "mysqlcheck" "/usr/bin/mysqlanalyze"
|
|
||||||
dosym "mysqlcheck" "/usr/bin/mysqlrepair"
|
|
||||||
dosym "mysqlcheck" "/usr/bin/mysqloptimize"
|
|
||||||
|
|
||||||
# INSTALL_LAYOUT=STANDALONE causes cmake to create a /usr/data dir
|
|
||||||
if [[ -d "${ED}/usr/data" ]] ; then
|
|
||||||
rm -Rf "${ED}/usr/data" || die
|
|
||||||
fi
|
|
||||||
|
|
||||||
# Unless they explicitly specific USE=test, then do not install the
|
|
||||||
# testsuite. It DOES have a use to be installed, esp. when you want to do a
|
|
||||||
# validation of your database configuration after tuning it.
|
|
||||||
if ! use test ; then
|
|
||||||
rm -rf "${D}/${MY_SHAREDSTATEDIR}/mysql-test"
|
|
||||||
fi
|
|
||||||
|
|
||||||
# Configuration stuff
|
|
||||||
einfo "Building default configuration ..."
|
|
||||||
insinto "${MY_SYSCONFDIR#${EPREFIX}}"
|
|
||||||
[[ -f "${S}/scripts/mysqlaccess.conf" ]] && doins "${S}"/scripts/mysqlaccess.conf
|
|
||||||
local mycnf_src="my.cnf-5.6-r1"
|
|
||||||
sed -e "s!@DATADIR@!${MY_DATADIR}!g" \
|
|
||||||
"${FILESDIR}/${mycnf_src}" \
|
|
||||||
> "${TMPDIR}/my.cnf.ok" || die
|
|
||||||
use prefix && sed -i -r -e '/^user[[:space:]]*=[[:space:]]*mysql$/d' "${TMPDIR}/my.cnf.ok"
|
|
||||||
if use latin1 ; then
|
|
||||||
sed -i \
|
|
||||||
-e "/character-set/s|utf8|latin1|g" \
|
|
||||||
"${TMPDIR}/my.cnf.ok" || die
|
|
||||||
fi
|
|
||||||
eprefixify "${TMPDIR}/my.cnf.ok"
|
|
||||||
newins "${TMPDIR}/my.cnf.ok" my.cnf
|
|
||||||
|
|
||||||
if use server ; then
|
|
||||||
einfo "Including support files and sample configurations"
|
|
||||||
docinto "support-files"
|
|
||||||
local script
|
|
||||||
for script in \
|
|
||||||
"${S}"/support-files/magic
|
|
||||||
do
|
|
||||||
[[ -f "$script" ]] && dodoc "${script}"
|
|
||||||
done
|
|
||||||
|
|
||||||
docinto "scripts"
|
|
||||||
for script in "${S}"/scripts/mysql* ; do
|
|
||||||
[[ ( -f "$script" ) && ( "${script%.sh}" == "${script}" ) ]] && dodoc "${script}"
|
|
||||||
done
|
|
||||||
# Manually install supporting files that conflict with other packages
|
|
||||||
# but are needed for galera and initial installation
|
|
||||||
exeinto /usr/libexec/mariadb
|
|
||||||
doexe "${BUILD_DIR}/extra/my_print_defaults" "${BUILD_DIR}/extra/perror"
|
|
||||||
fi
|
|
||||||
|
|
||||||
#Remove mytop if perl is not selected
|
|
||||||
[[ -e "${ED}/usr/bin/mytop" ]] && ! use perl && rm -f "${ED}/usr/bin/mytop"
|
|
||||||
}
|
|
||||||
|
|
||||||
# Official test instructions:
|
|
||||||
# USE='extraengine perl server' \
|
|
||||||
# FEATURES='test userpriv -usersandbox' \
|
|
||||||
# ebuild mariadb-X.X.XX.ebuild \
|
|
||||||
# digest clean package
|
|
||||||
src_test() {
|
|
||||||
|
|
||||||
_disable_test() {
|
|
||||||
local rawtestname reason
|
|
||||||
rawtestname="${1}" ; shift
|
|
||||||
reason="${@}"
|
|
||||||
ewarn "test '${rawtestname}' disabled: '${reason}'"
|
|
||||||
echo ${rawtestname} : ${reason} >> "${T}/disabled.def"
|
|
||||||
}
|
|
||||||
|
|
||||||
local TESTDIR="${BUILD_DIR}/mysql-test"
|
|
||||||
local retstatus_unit
|
|
||||||
local retstatus_tests
|
|
||||||
|
|
||||||
if ! use server ; then
|
|
||||||
einfo "Skipping server tests due to minimal build."
|
|
||||||
return 0
|
|
||||||
fi
|
|
||||||
|
|
||||||
# Bug #213475 - MySQL _will_ object strenously if your machine is named
|
|
||||||
# localhost. Also causes weird failures.
|
|
||||||
[[ "${HOSTNAME}" == "localhost" ]] && die "Your machine must NOT be named localhost"
|
|
||||||
|
|
||||||
if [[ $UID -eq 0 ]]; then
|
|
||||||
die "Testing with FEATURES=-userpriv is no longer supported by upstream. Tests MUST be run as non-root."
|
|
||||||
fi
|
|
||||||
has usersandbox $FEATURES && ewarn "Some tests may fail with FEATURES=usersandbox"
|
|
||||||
|
|
||||||
einfo ">>> Test phase [test]: ${CATEGORY}/${PF}"
|
|
||||||
|
|
||||||
# Run CTest (test-units)
|
|
||||||
# cmake-utils_src_test
|
|
||||||
# retstatus_unit=$?
|
|
||||||
|
|
||||||
# Ensure that parallel runs don't die
|
|
||||||
export MTR_BUILD_THREAD="$((${RANDOM} % 100))"
|
|
||||||
# Enable parallel testing, auto will try to detect number of cores
|
|
||||||
# You may set this by hand.
|
|
||||||
# The default maximum is 8 unless MTR_MAX_PARALLEL is increased
|
|
||||||
export MTR_PARALLEL="${MTR_PARALLEL:-auto}"
|
|
||||||
|
|
||||||
# create directories because mysqladmin might run out of order
|
|
||||||
mkdir -p "${T}"/var-tests{,/log} || die
|
|
||||||
|
|
||||||
# Run mysql tests
|
|
||||||
pushd "${TESTDIR}" > /dev/null || die
|
|
||||||
|
|
||||||
touch "${T}/disabled.def"
|
|
||||||
# These are failing in MariaDB 10.0 for now and are believed to be
|
|
||||||
# false positives:
|
|
||||||
#
|
|
||||||
# main.mysql_client_test, main.mysql_client_test_nonblock
|
|
||||||
# main.mysql_client_test_comp:
|
|
||||||
# segfaults at random under Portage only, suspect resource limits.
|
|
||||||
|
|
||||||
local t
|
|
||||||
for t in plugins.cracklib_password_check plugins.two_password_validations ; do
|
|
||||||
_disable_test "$t" "False positive due to varying policies"
|
|
||||||
done
|
|
||||||
|
|
||||||
for t in main.mysql_client_test main.mysql_client_test_nonblock \
|
|
||||||
rpl.rpl_semi_sync_uninstall_plugin \
|
|
||||||
main.mysql_client_test_comp rpl.rpl_extra_col_master_myisam ; do
|
|
||||||
_disable_test "$t" "False positives in Gentoo"
|
|
||||||
done
|
|
||||||
|
|
||||||
if ! use client-libs ; then
|
|
||||||
_disable_test main.plugin_auth "Needs client libraries built"
|
|
||||||
fi
|
|
||||||
|
|
||||||
_disable_test sys_vars.sysvars_server_notembedded "Broken test" # bug #661700 required profiling always on
|
|
||||||
|
|
||||||
# run mysql-test tests
|
|
||||||
perl mysql-test-run.pl --force --vardir="${T}/var-tests" --reorder --skip-test=tokudb --skip-test-list="${T}/disabled.def"
|
|
||||||
retstatus_tests=$?
|
|
||||||
|
|
||||||
popd > /dev/null || die
|
|
||||||
|
|
||||||
# Cleanup is important for these testcases.
|
|
||||||
pkill -9 -f "${S}/ndb" 2>/dev/null
|
|
||||||
pkill -9 -f "${S}/sql" 2>/dev/null
|
|
||||||
|
|
||||||
local failures=""
|
|
||||||
[[ $retstatus_unit -eq 0 ]] || failures="${failures} test-unit"
|
|
||||||
[[ $retstatus_tests -eq 0 ]] || failures="${failures} tests"
|
|
||||||
|
|
||||||
[[ -z "$failures" ]] || die "Test failures: $failures"
|
|
||||||
einfo "Tests successfully completed"
|
|
||||||
}
|
|
||||||
|
|
||||||
mysql_init_vars() {
|
|
||||||
MY_SHAREDSTATEDIR=${MY_SHAREDSTATEDIR="${EPREFIX}/usr/share/mariadb"}
|
|
||||||
MY_SYSCONFDIR=${MY_SYSCONFDIR="${EPREFIX}/etc/mysql"}
|
|
||||||
MY_LOCALSTATEDIR=${MY_LOCALSTATEDIR="${EPREFIX}/var/lib/mysql"}
|
|
||||||
MY_LOGDIR=${MY_LOGDIR="${EPREFIX}/var/log/mysql"}
|
|
||||||
|
|
||||||
if [[ -z "${MY_DATADIR}" ]] ; then
|
|
||||||
MY_DATADIR=""
|
|
||||||
if [[ -f "${MY_SYSCONFDIR}/my.cnf" ]] ; then
|
|
||||||
MY_DATADIR=`"my_print_defaults" mysqld 2>/dev/null \
|
|
||||||
| sed -ne '/datadir/s|^--datadir=||p' \
|
|
||||||
| tail -n1`
|
|
||||||
if [[ -z "${MY_DATADIR}" ]] ; then
|
|
||||||
MY_DATADIR=`grep ^datadir "${MY_SYSCONFDIR}/my.cnf" \
|
|
||||||
| sed -e 's/.*=\s*//' \
|
|
||||||
| tail -n1`
|
|
||||||
fi
|
|
||||||
fi
|
|
||||||
if [[ -z "${MY_DATADIR}" ]] ; then
|
|
||||||
MY_DATADIR="${MY_LOCALSTATEDIR}"
|
|
||||||
einfo "Using default MY_DATADIR"
|
|
||||||
fi
|
|
||||||
elog "MySQL MY_DATADIR is ${MY_DATADIR}"
|
|
||||||
|
|
||||||
if [[ -z "${PREVIOUS_DATADIR}" ]] ; then
|
|
||||||
if [[ -e "${MY_DATADIR}" ]] ; then
|
|
||||||
# If you get this and you're wondering about it, see bug #207636
|
|
||||||
elog "MySQL datadir found in ${MY_DATADIR}"
|
|
||||||
elog "A new one will not be created."
|
|
||||||
PREVIOUS_DATADIR="yes"
|
|
||||||
else
|
|
||||||
PREVIOUS_DATADIR="no"
|
|
||||||
fi
|
|
||||||
export PREVIOUS_DATADIR
|
|
||||||
fi
|
|
||||||
else
|
|
||||||
if [[ ${EBUILD_PHASE} == "config" ]]; then
|
|
||||||
local new_MY_DATADIR
|
|
||||||
new_MY_DATADIR=`"my_print_defaults" mysqld 2>/dev/null \
|
|
||||||
| sed -ne '/datadir/s|^--datadir=||p' \
|
|
||||||
| tail -n1`
|
|
||||||
|
|
||||||
if [[ ( -n "${new_MY_DATADIR}" ) && ( "${new_MY_DATADIR}" != "${MY_DATADIR}" ) ]]; then
|
|
||||||
ewarn "MySQL MY_DATADIR has changed"
|
|
||||||
ewarn "from ${MY_DATADIR}"
|
|
||||||
ewarn "to ${new_MY_DATADIR}"
|
|
||||||
MY_DATADIR="${new_MY_DATADIR}"
|
|
||||||
fi
|
|
||||||
fi
|
|
||||||
fi
|
|
||||||
|
|
||||||
export MY_SHAREDSTATEDIR MY_SYSCONFDIR
|
|
||||||
export MY_LOCALSTATEDIR MY_LOGDIR
|
|
||||||
export MY_DATADIR
|
|
||||||
}
|
|
||||||
|
|
||||||
pkg_config() {
|
|
||||||
_getoptval() {
|
|
||||||
local mypd="${EROOT}"/usr/bin/my_print_defaults
|
|
||||||
local section="$1"
|
|
||||||
local flag="--${2}="
|
|
||||||
local extra_options="${3}"
|
|
||||||
"${mypd}" $extra_options $section | sed -n "/^${flag}/s,${flag},,gp"
|
|
||||||
}
|
|
||||||
local old_MY_DATADIR="${MY_DATADIR}"
|
|
||||||
local old_HOME="${HOME}"
|
|
||||||
# my_print_defaults needs to read stuff in $HOME/.my.cnf
|
|
||||||
export HOME=${EPREFIX}/root
|
|
||||||
|
|
||||||
# Make sure the vars are correctly initialized
|
|
||||||
mysql_init_vars
|
|
||||||
|
|
||||||
[[ -z "${MY_DATADIR}" ]] && die "Sorry, unable to find MY_DATADIR"
|
|
||||||
if [[ ! -x "${EROOT}/usr/sbin/mysqld" ]] ; then
|
|
||||||
die "Minimal builds do NOT include the MySQL server"
|
|
||||||
fi
|
|
||||||
|
|
||||||
if [[ ( -n "${MY_DATADIR}" ) && ( "${MY_DATADIR}" != "${old_MY_DATADIR}" ) ]]; then
|
|
||||||
local MY_DATADIR_s="${ROOT}/${MY_DATADIR}"
|
|
||||||
MY_DATADIR_s="${MY_DATADIR_s%%/}"
|
|
||||||
local old_MY_DATADIR_s="${ROOT}/${old_MY_DATADIR}"
|
|
||||||
old_MY_DATADIR_s="${old_MY_DATADIR_s%%/}"
|
|
||||||
|
|
||||||
if [[ ( -d "${old_MY_DATADIR_s}" ) && ( "${old_MY_DATADIR_s}" != / ) ]]; then
|
|
||||||
if [[ -d "${MY_DATADIR_s}" ]]; then
|
|
||||||
ewarn "Both ${old_MY_DATADIR_s} and ${MY_DATADIR_s} exist"
|
|
||||||
ewarn "Attempting to use ${MY_DATADIR_s} and preserving ${old_MY_DATADIR_s}"
|
|
||||||
else
|
|
||||||
elog "Moving MY_DATADIR from ${old_MY_DATADIR_s} to ${MY_DATADIR_s}"
|
|
||||||
mv --strip-trailing-slashes -T "${old_MY_DATADIR_s}" "${MY_DATADIR_s}" \
|
|
||||||
|| die "Moving MY_DATADIR failed"
|
|
||||||
fi
|
|
||||||
else
|
|
||||||
ewarn "Previous MY_DATADIR (${old_MY_DATADIR_s}) does not exist"
|
|
||||||
if [[ -d "${MY_DATADIR_s}" ]]; then
|
|
||||||
ewarn "Attempting to use ${MY_DATADIR_s}"
|
|
||||||
else
|
|
||||||
eerror "New MY_DATADIR (${MY_DATADIR_s}) does not exist"
|
|
||||||
die "Configuration Failed! Please reinstall ${CATEGORY}/${PN}"
|
|
||||||
fi
|
|
||||||
fi
|
|
||||||
fi
|
|
||||||
|
|
||||||
local pwd1="a"
|
|
||||||
local pwd2="b"
|
|
||||||
local maxtry=15
|
|
||||||
|
|
||||||
if [ -z "${MYSQL_ROOT_PASSWORD}" ]; then
|
|
||||||
local tmp_mysqld_password_source=
|
|
||||||
|
|
||||||
for tmp_mysqld_password_source in mysql client; do
|
|
||||||
einfo "Trying to get password for mysql 'root' user from '${tmp_mysqld_password_source}' section ..."
|
|
||||||
MYSQL_ROOT_PASSWORD="$(_getoptval "${tmp_mysqld_password_source}" password)"
|
|
||||||
if [[ -n "${MYSQL_ROOT_PASSWORD}" ]]; then
|
|
||||||
if [[ ${MYSQL_ROOT_PASSWORD} == *$'\n'* ]]; then
|
|
||||||
ewarn "Ignoring password from '${tmp_mysqld_password_source}' section due to newline character (do you have multiple password options set?)!"
|
|
||||||
MYSQL_ROOT_PASSWORD=
|
|
||||||
continue
|
|
||||||
fi
|
|
||||||
|
|
||||||
einfo "Found password in '${tmp_mysqld_password_source}' section!"
|
|
||||||
break
|
|
||||||
fi
|
|
||||||
done
|
|
||||||
|
|
||||||
# Sometimes --show is required to display passwords in some implementations of my_print_defaults
|
|
||||||
if [[ "${MYSQL_ROOT_PASSWORD}" == '*****' ]]; then
|
|
||||||
MYSQL_ROOT_PASSWORD="$(_getoptval "${tmp_mysqld_password_source}" password --show)"
|
|
||||||
fi
|
|
||||||
|
|
||||||
unset tmp_mysqld_password_source
|
|
||||||
fi
|
|
||||||
MYSQL_TMPDIR="$(_getoptval mysqld tmpdir)"
|
|
||||||
# These are dir+prefix
|
|
||||||
MYSQL_RELAY_LOG="$(_getoptval mysqld relay-log)"
|
|
||||||
MYSQL_RELAY_LOG=${MYSQL_RELAY_LOG%/*}
|
|
||||||
MYSQL_LOG_BIN="$(_getoptval mysqld log-bin)"
|
|
||||||
MYSQL_LOG_BIN=${MYSQL_LOG_BIN%/*}
|
|
||||||
|
|
||||||
if [[ ! -d "${ROOT}/$MYSQL_TMPDIR" ]]; then
|
|
||||||
einfo "Creating MySQL tmpdir $MYSQL_TMPDIR"
|
|
||||||
install -d -m 770 -o mysql -g mysql "${EROOT}/$MYSQL_TMPDIR"
|
|
||||||
fi
|
|
||||||
if [[ ! -d "${ROOT}/$MYSQL_LOG_BIN" ]]; then
|
|
||||||
einfo "Creating MySQL log-bin directory $MYSQL_LOG_BIN"
|
|
||||||
install -d -m 770 -o mysql -g mysql "${EROOT}/$MYSQL_LOG_BIN"
|
|
||||||
fi
|
|
||||||
if [[ ! -d "${EROOT}/$MYSQL_RELAY_LOG" ]]; then
|
|
||||||
einfo "Creating MySQL relay-log directory $MYSQL_RELAY_LOG"
|
|
||||||
install -d -m 770 -o mysql -g mysql "${EROOT}/$MYSQL_RELAY_LOG"
|
|
||||||
fi
|
|
||||||
|
|
||||||
if [[ -d "${ROOT}/${MY_DATADIR}/mysql" ]] ; then
|
|
||||||
ewarn "You have already a MySQL database in place."
|
|
||||||
ewarn "(${ROOT}/${MY_DATADIR}/*)"
|
|
||||||
ewarn "Please rename or delete it if you wish to replace it."
|
|
||||||
die "MySQL database already exists!"
|
|
||||||
fi
|
|
||||||
|
|
||||||
# Bug #213475 - MySQL _will_ object strenously if your machine is named
|
|
||||||
# localhost. Also causes weird failures.
|
|
||||||
[[ "${HOSTNAME}" == "localhost" ]] && die "Your machine must NOT be named localhost"
|
|
||||||
|
|
||||||
if [ -z "${MYSQL_ROOT_PASSWORD}" ]; then
|
|
||||||
|
|
||||||
einfo "Please provide a password for the mysql 'root' user now"
|
|
||||||
einfo "or through the ${HOME}/.my.cnf file."
|
|
||||||
ewarn "Avoid [\"'\\_%] characters in the password"
|
|
||||||
read -rsp " >" pwd1 ; echo
|
|
||||||
|
|
||||||
einfo "Retype the password"
|
|
||||||
read -rsp " >" pwd2 ; echo
|
|
||||||
|
|
||||||
if [[ "x$pwd1" != "x$pwd2" ]] ; then
|
|
||||||
die "Passwords are not the same"
|
|
||||||
fi
|
|
||||||
MYSQL_ROOT_PASSWORD="${pwd1}"
|
|
||||||
unset pwd1 pwd2
|
|
||||||
fi
|
|
||||||
|
|
||||||
local options
|
|
||||||
local sqltmp="$(emktemp)"
|
|
||||||
|
|
||||||
# Fix bug 446200. Don't reference host my.cnf, needs to come first,
|
|
||||||
# see https://bugs.mysql.com/bug.php?id=31312
|
|
||||||
use prefix && options="${options} '--defaults-file=${MY_SYSCONFDIR}/my.cnf'"
|
|
||||||
|
|
||||||
# Figure out which options we need to disable to do the setup
|
|
||||||
local helpfile="${TMPDIR}/mysqld-help"
|
|
||||||
"${EROOT}/usr/sbin/mysqld" --verbose --help >"${helpfile}" 2>/dev/null
|
|
||||||
for opt in grant-tables host-cache name-resolve networking slave-start \
|
|
||||||
federated ssl log-bin relay-log slow-query-log external-locking \
|
|
||||||
log-slave-updates \
|
|
||||||
; do
|
|
||||||
optexp="--(skip-)?${opt}" optfull="--loose-skip-${opt}"
|
|
||||||
egrep -sq -- "${optexp}" "${helpfile}" && options="${options} ${optfull}"
|
|
||||||
done
|
|
||||||
|
|
||||||
einfo "Creating the mysql database and setting proper permissions on it ..."
|
|
||||||
|
|
||||||
# Now that /var/run is a tmpfs mount point, we need to ensure it exists before using it
|
|
||||||
PID_DIR="${EROOT}/var/run/mysqld"
|
|
||||||
if [[ ! -d "${PID_DIR}" ]]; then
|
|
||||||
install -d -m 755 -o mysql -g mysql "${PID_DIR}" || die "Could not create pid directory"
|
|
||||||
fi
|
|
||||||
|
|
||||||
if [[ ! -d "${MY_DATADIR}" ]]; then
|
|
||||||
install -d -m 750 -o mysql -g mysql "${MY_DATADIR}" || die "Could not create data directory"
|
|
||||||
fi
|
|
||||||
|
|
||||||
pushd "${TMPDIR}" &>/dev/null || die
|
|
||||||
|
|
||||||
# Filling timezones, see
|
|
||||||
# https://dev.mysql.com/doc/mysql/en/time-zone-support.html
|
|
||||||
"${EROOT}/usr/bin/mysql_tzinfo_to_sql" "${EROOT}/usr/share/zoneinfo" > "${sqltmp}" 2>/dev/null
|
|
||||||
|
|
||||||
local cmd=( "${EROOT}usr/share/mariadb/scripts/mysql_install_db" )
|
|
||||||
[[ -f "${cmd}" ]] || cmd=( "${EROOT}usr/bin/mysql_install_db" )
|
|
||||||
cmd+=( "--basedir=${EPREFIX}/usr" ${options} "--datadir=${ROOT}/${MY_DATADIR}" "--tmpdir=${ROOT}/${MYSQL_TMPDIR}" )
|
|
||||||
einfo "Command: ${cmd[*]}"
|
|
||||||
su -s /bin/sh -c "${cmd[*]}" mysql \
|
|
||||||
>"${TMPDIR}"/mysql_install_db.log 2>&1
|
|
||||||
if [ $? -ne 0 ]; then
|
|
||||||
grep -B5 -A999 -i "ERROR" "${TMPDIR}"/mysql_install_db.log 1>&2
|
|
||||||
die "Failed to initialize mysqld. Please review ${EPREFIX}/var/log/mysql/mysqld.err AND ${TMPDIR}/mysql_install_db.log"
|
|
||||||
fi
|
|
||||||
popd &>/dev/null || die
|
|
||||||
[[ -f "${ROOT}/${MY_DATADIR}/mysql/user.frm" ]] \
|
|
||||||
|| die "MySQL databases not installed"
|
|
||||||
|
|
||||||
use prefix || options="${options} --user=mysql"
|
|
||||||
|
|
||||||
local socket="${EROOT}/var/run/mysqld/mysqld${RANDOM}.sock"
|
|
||||||
local pidfile="${EROOT}/var/run/mysqld/mysqld${RANDOM}.pid"
|
|
||||||
local mysqld="${EROOT}/usr/sbin/mysqld \
|
|
||||||
${options} \
|
|
||||||
--log-warnings=0 \
|
|
||||||
--basedir=${EROOT}/usr \
|
|
||||||
--datadir=${ROOT}/${MY_DATADIR} \
|
|
||||||
--max_allowed_packet=8M \
|
|
||||||
--net_buffer_length=16K \
|
|
||||||
--socket=${socket} \
|
|
||||||
--pid-file=${pidfile} \
|
|
||||||
--tmpdir=${ROOT}/${MYSQL_TMPDIR}"
|
|
||||||
#einfo "About to start mysqld: ${mysqld}"
|
|
||||||
ebegin "Starting mysqld"
|
|
||||||
einfo "Command ${mysqld}"
|
|
||||||
${mysqld} &
|
|
||||||
rc=$?
|
|
||||||
while ! [[ -S "${socket}" || "${maxtry}" -lt 1 ]] ; do
|
|
||||||
maxtry=$((${maxtry}-1))
|
|
||||||
echo -n "."
|
|
||||||
sleep 1
|
|
||||||
done
|
|
||||||
eend $rc
|
|
||||||
|
|
||||||
if ! [[ -S "${socket}" ]]; then
|
|
||||||
die "Completely failed to start up mysqld with: ${mysqld}"
|
|
||||||
fi
|
|
||||||
|
|
||||||
ebegin "Setting root password"
|
|
||||||
# Do this from memory, as we don't want clear text passwords in temp files
|
|
||||||
local sql="UPDATE mysql.user SET Password = PASSWORD('${MYSQL_ROOT_PASSWORD}') WHERE USER='root'; FLUSH PRIVILEGES"
|
|
||||||
"${EROOT}/usr/bin/mysql" \
|
|
||||||
"--socket=${socket}" \
|
|
||||||
-hlocalhost \
|
|
||||||
-e "${sql}"
|
|
||||||
eend $?
|
|
||||||
|
|
||||||
if [[ -n "${sqltmp}" ]] ; then
|
|
||||||
ebegin "Loading \"zoneinfo\", this step may require a few seconds"
|
|
||||||
"${EROOT}/usr/bin/mysql" \
|
|
||||||
"--socket=${socket}" \
|
|
||||||
-hlocalhost \
|
|
||||||
-uroot \
|
|
||||||
--password="${MYSQL_ROOT_PASSWORD}" \
|
|
||||||
mysql < "${sqltmp}"
|
|
||||||
rc=$?
|
|
||||||
eend $?
|
|
||||||
[[ $rc -ne 0 ]] && ewarn "Failed to load zoneinfo!"
|
|
||||||
fi
|
|
||||||
|
|
||||||
# Stop the server and cleanup
|
|
||||||
einfo "Stopping the server ..."
|
|
||||||
kill $(< "${pidfile}" )
|
|
||||||
rm -f "${sqltmp}"
|
|
||||||
wait %1
|
|
||||||
einfo "Done"
|
|
||||||
}
|
|
@ -1,925 +0,0 @@
|
|||||||
# Copyright 1999-2020 Gentoo Authors
|
|
||||||
# Distributed under the terms of the GNU General Public License v2
|
|
||||||
|
|
||||||
EAPI="6"
|
|
||||||
SUBSLOT="18"
|
|
||||||
|
|
||||||
JAVA_PKG_OPT_USE="jdbc"
|
|
||||||
|
|
||||||
# Keeping eutils in EAPI=6 for emktemp in pkg_config
|
|
||||||
|
|
||||||
inherit eutils systemd flag-o-matic prefix toolchain-funcs \
|
|
||||||
multiprocessing java-pkg-opt-2 cmake-utils multilib-build
|
|
||||||
|
|
||||||
# Patch version
|
|
||||||
PATCH_SET="https://dev.gentoo.org/~whissi/dist/${PN}/${PN}-10.1.45-patches-04.tar.xz"
|
|
||||||
|
|
||||||
SRC_URI="https://downloads.mariadb.org/interstitial/${P}/source/${P}.tar.gz
|
|
||||||
${PATCH_SET}"
|
|
||||||
|
|
||||||
HOMEPAGE="https://mariadb.org/"
|
|
||||||
DESCRIPTION="An enhanced, drop-in replacement for MySQL"
|
|
||||||
LICENSE="GPL-2"
|
|
||||||
SLOT="10.1/${SUBSLOT:-0}"
|
|
||||||
IUSE="+backup bindist client-libs cracklib debug extraengine galera jdbc jemalloc kerberos
|
|
||||||
innodb-lz4 innodb-lzo innodb-snappy latin1 libressl mroonga numa odbc oqgraph pam
|
|
||||||
+perl profiling selinux +server sphinx sst-rsync sst-mariabackup sst-xtrabackup
|
|
||||||
systemd systemtap static static-libs tcmalloc test tokudb xml yassl"
|
|
||||||
|
|
||||||
# Tests always fail when libressl is enabled due to hard-coded ciphers in the tests
|
|
||||||
RESTRICT="!bindist? ( bindist ) libressl? ( test ) !test? ( test )"
|
|
||||||
|
|
||||||
REQUIRED_USE="jdbc? ( extraengine server !static )
|
|
||||||
server? ( tokudb? ( jemalloc !tcmalloc ) )
|
|
||||||
?? ( tcmalloc jemalloc )
|
|
||||||
static? ( yassl !pam )"
|
|
||||||
|
|
||||||
KEYWORDS="~alpha amd64 arm arm64 ~hppa ~ia64 ~mips ~ppc ~ppc64 ~s390 ~sparc x86 ~amd64-linux ~x86-linux ~ppc-macos ~x64-macos ~x86-macos ~x64-solaris ~x86-solaris"
|
|
||||||
|
|
||||||
# Shorten the path because the socket path length must be shorter than 107 chars
|
|
||||||
# and we will run a mysql server during test phase
|
|
||||||
S="${WORKDIR}/mysql"
|
|
||||||
|
|
||||||
# Be warned, *DEPEND are version-dependant
|
|
||||||
# These are used for both runtime and compiletime
|
|
||||||
COMMON_DEPEND="
|
|
||||||
kernel_linux? (
|
|
||||||
sys-process/procps:0=
|
|
||||||
dev-libs/libaio:0=
|
|
||||||
)
|
|
||||||
>=sys-apps/sed-4
|
|
||||||
>=sys-apps/texinfo-4.7-r1
|
|
||||||
jemalloc? ( dev-libs/jemalloc:0= )
|
|
||||||
tcmalloc? ( dev-util/google-perftools:0= )
|
|
||||||
systemtap? ( >=dev-util/systemtap-1.3:0= )
|
|
||||||
!yassl? (
|
|
||||||
!libressl? ( dev-libs/openssl:0= !>=dev-libs/openssl-1.1 )
|
|
||||||
libressl? ( dev-libs/libressl:0= )
|
|
||||||
)
|
|
||||||
>=sys-libs/zlib-1.2.3:0=
|
|
||||||
sys-libs/ncurses:0=
|
|
||||||
!bindist? (
|
|
||||||
sys-libs/binutils-libs:0=
|
|
||||||
>=sys-libs/readline-4.1:0=
|
|
||||||
)
|
|
||||||
server? (
|
|
||||||
backup? ( app-arch/libarchive:0= )
|
|
||||||
cracklib? ( sys-libs/cracklib:0= )
|
|
||||||
extraengine? (
|
|
||||||
odbc? ( dev-db/unixODBC:0= )
|
|
||||||
xml? ( dev-libs/libxml2:2= )
|
|
||||||
sys-libs/zlib[minizip]
|
|
||||||
)
|
|
||||||
innodb-lz4? ( app-arch/lz4 )
|
|
||||||
innodb-lzo? ( dev-libs/lzo )
|
|
||||||
innodb-snappy? ( app-arch/snappy )
|
|
||||||
kerberos? ( virtual/krb5 )
|
|
||||||
mroonga? ( app-text/groonga-normalizer-mysql >=app-text/groonga-7.0.4 )
|
|
||||||
numa? ( sys-process/numactl )
|
|
||||||
oqgraph? ( >=dev-libs/boost-1.40.0:0= dev-libs/judy:0= )
|
|
||||||
pam? ( sys-libs/pam:0= )
|
|
||||||
systemd? ( sys-apps/systemd:= )
|
|
||||||
tokudb? ( app-arch/snappy )
|
|
||||||
)
|
|
||||||
!yassl? ( !libressl? ( !>=dev-libs/openssl-1.1.0 ) )
|
|
||||||
>=dev-libs/libpcre-8.41-r1:3=
|
|
||||||
!client-libs? ( dev-db/mysql-connector-c[${MULTILIB_USEDEP},static-libs?] )
|
|
||||||
"
|
|
||||||
DEPEND="virtual/yacc
|
|
||||||
static? ( sys-libs/ncurses[static-libs] )
|
|
||||||
|| ( >=sys-devel/gcc-3.4.6 >=sys-devel/gcc-apple-4.0 )
|
|
||||||
server? (
|
|
||||||
extraengine? ( jdbc? ( >=virtual/jdk-1.6 ) )
|
|
||||||
test? ( acct-group/mysql acct-user/mysql )
|
|
||||||
)
|
|
||||||
${COMMON_DEPEND}"
|
|
||||||
RDEPEND="selinux? ( sec-policy/selinux-mysql )
|
|
||||||
client-libs? ( !dev-db/mariadb-connector-c[mysqlcompat] !dev-db/mysql-connector-c )
|
|
||||||
!dev-db/mysql !dev-db/mariadb-galera !dev-db/percona-server !dev-db/mysql-cluster
|
|
||||||
!dev-db/mariadb:0
|
|
||||||
!dev-db/mariadb:5.5
|
|
||||||
!dev-db/mariadb:10.2
|
|
||||||
!dev-db/mariadb:10.3
|
|
||||||
!dev-db/mariadb:10.4
|
|
||||||
!dev-db/mariadb:10.5
|
|
||||||
${COMMON_DEPEND}
|
|
||||||
server? (
|
|
||||||
galera? (
|
|
||||||
sys-apps/iproute2
|
|
||||||
=sys-cluster/galera-25*
|
|
||||||
sst-rsync? ( sys-process/lsof )
|
|
||||||
sst-mariabackup? ( net-misc/socat[ssl] )
|
|
||||||
sst-xtrabackup? ( net-misc/socat[ssl] )
|
|
||||||
)
|
|
||||||
!prefix? ( dev-db/mysql-init-scripts acct-group/mysql acct-user/mysql )
|
|
||||||
extraengine? ( jdbc? ( >=virtual/jre-1.6 ) )
|
|
||||||
)
|
|
||||||
perl? (
|
|
||||||
!dev-db/mytop
|
|
||||||
virtual/perl-Getopt-Long
|
|
||||||
dev-perl/TermReadKey
|
|
||||||
virtual/perl-Term-ANSIColor
|
|
||||||
virtual/perl-Time-HiRes
|
|
||||||
)
|
|
||||||
"
|
|
||||||
# For other stuff to bring us in
|
|
||||||
# dev-perl/DBD-mysql is needed by some scripts installed by MySQL
|
|
||||||
# percona-xtrabackup-bin causes a circular dependency if DBD-mysql is not already installed
|
|
||||||
PDEPEND="perl? ( >=dev-perl/DBD-mysql-2.9004 )
|
|
||||||
server? ( galera? ( sst-xtrabackup? ( || ( >=dev-db/percona-xtrabackup-bin-2.2.4 dev-db/percona-xtrabackup ) ) ) )"
|
|
||||||
|
|
||||||
mysql_init_vars() {
|
|
||||||
MY_SHAREDSTATEDIR=${MY_SHAREDSTATEDIR="${EPREFIX}/usr/share/mariadb"}
|
|
||||||
MY_SYSCONFDIR=${MY_SYSCONFDIR="${EPREFIX}/etc/mysql"}
|
|
||||||
MY_LOCALSTATEDIR=${MY_LOCALSTATEDIR="${EPREFIX}/var/lib/mysql"}
|
|
||||||
MY_LOGDIR=${MY_LOGDIR="${EPREFIX}/var/log/mysql"}
|
|
||||||
|
|
||||||
if [[ -z "${MY_DATADIR}" ]] ; then
|
|
||||||
MY_DATADIR=""
|
|
||||||
if [[ -f "${MY_SYSCONFDIR}/my.cnf" ]] ; then
|
|
||||||
MY_DATADIR=$(my_print_defaults mysqld 2>/dev/null \
|
|
||||||
| sed -ne '/datadir/s|^--datadir=||p' \
|
|
||||||
| tail -n1)
|
|
||||||
if [[ -z "${MY_DATADIR}" ]] ; then
|
|
||||||
MY_DATADIR=$(grep ^datadir "${MY_SYSCONFDIR}/my.cnf" \
|
|
||||||
| sed -e 's/.*=\s*//' \
|
|
||||||
| tail -n1)
|
|
||||||
fi
|
|
||||||
fi
|
|
||||||
if [[ -z "${MY_DATADIR}" ]] ; then
|
|
||||||
MY_DATADIR="${MY_LOCALSTATEDIR}"
|
|
||||||
einfo "Using default MY_DATADIR"
|
|
||||||
fi
|
|
||||||
elog "MySQL MY_DATADIR is ${MY_DATADIR}"
|
|
||||||
|
|
||||||
if [[ -z "${PREVIOUS_DATADIR}" ]] ; then
|
|
||||||
if [[ -e "${MY_DATADIR}" ]] ; then
|
|
||||||
# If you get this and you're wondering about it, see bug #207636
|
|
||||||
elog "MySQL datadir found in ${MY_DATADIR}"
|
|
||||||
elog "A new one will not be created."
|
|
||||||
PREVIOUS_DATADIR="yes"
|
|
||||||
else
|
|
||||||
PREVIOUS_DATADIR="no"
|
|
||||||
fi
|
|
||||||
export PREVIOUS_DATADIR
|
|
||||||
fi
|
|
||||||
else
|
|
||||||
if [[ ${EBUILD_PHASE} == "config" ]]; then
|
|
||||||
local new_MY_DATADIR
|
|
||||||
new_MY_DATADIR=$(my_print_defaults mysqld 2>/dev/null \
|
|
||||||
| sed -ne '/datadir/s|^--datadir=||p' \
|
|
||||||
| tail -n1)
|
|
||||||
|
|
||||||
if [[ ( -n "${new_MY_DATADIR}" ) && ( "${new_MY_DATADIR}" != "${MY_DATADIR}" ) ]]; then
|
|
||||||
ewarn "MySQL MY_DATADIR has changed"
|
|
||||||
ewarn "from ${MY_DATADIR}"
|
|
||||||
ewarn "to ${new_MY_DATADIR}"
|
|
||||||
MY_DATADIR="${new_MY_DATADIR}"
|
|
||||||
fi
|
|
||||||
fi
|
|
||||||
fi
|
|
||||||
|
|
||||||
export MY_SHAREDSTATEDIR MY_SYSCONFDIR
|
|
||||||
export MY_LOCALSTATEDIR MY_LOGDIR
|
|
||||||
export MY_DATADIR
|
|
||||||
}
|
|
||||||
|
|
||||||
pkg_setup() {
|
|
||||||
if [[ ${MERGE_TYPE} != binary ]] ; then
|
|
||||||
local GCC_MAJOR_SET=$(gcc-major-version)
|
|
||||||
local GCC_MINOR_SET=$(gcc-minor-version)
|
|
||||||
|
|
||||||
if use tokudb && [[ ${GCC_MAJOR_SET} -lt 4 || \
|
|
||||||
${GCC_MAJOR_SET} -eq 4 && ${GCC_MINOR_SET} -lt 7 ]] ; then
|
|
||||||
eerror "${PN} with tokudb needs to be built with gcc-4.7 or later."
|
|
||||||
eerror "Please use gcc-config to switch to gcc-4.7 or later version."
|
|
||||||
die
|
|
||||||
fi
|
|
||||||
|
|
||||||
# Bug 565584. InnoDB now requires atomic functions introduced with gcc-4.7 on
|
|
||||||
# non x86{,_64} arches
|
|
||||||
if ! use amd64 && ! use x86 && [[ ${GCC_MAJOR_SET} -lt 4 || \
|
|
||||||
${GCC_MAJOR_SET} -eq 4 && ${GCC_MINOR_SET} -lt 7 ]] ; then
|
|
||||||
eerror "${PN} needs to be built with gcc-4.7 or later."
|
|
||||||
eerror "Please use gcc-config to switch to gcc-4.7 or later version."
|
|
||||||
die
|
|
||||||
fi
|
|
||||||
|
|
||||||
if has test ${FEATURES} ; then
|
|
||||||
# Bug #213475 - MySQL _will_ object strenuously if your machine is named
|
|
||||||
# localhost. Also causes weird failures.
|
|
||||||
[[ "${HOSTNAME}" == "localhost" ]] && die "Your machine must NOT be named localhost"
|
|
||||||
|
|
||||||
if ! has userpriv ${FEATURES} ; then
|
|
||||||
die "Testing with FEATURES=-userpriv is no longer supported by upstream. Tests MUST be run as non-root."
|
|
||||||
fi
|
|
||||||
fi
|
|
||||||
fi
|
|
||||||
|
|
||||||
java-pkg-opt-2_pkg_setup
|
|
||||||
}
|
|
||||||
|
|
||||||
src_unpack() {
|
|
||||||
unpack ${A}
|
|
||||||
|
|
||||||
mv -f "${WORKDIR%/}/${PN%%-galera}-${PV}" "${S}" || die
|
|
||||||
}
|
|
||||||
|
|
||||||
src_prepare() {
|
|
||||||
eapply "${WORKDIR}"/mariadb-patches
|
|
||||||
|
|
||||||
eapply_user
|
|
||||||
|
|
||||||
_disable_engine() {
|
|
||||||
echo > "${S%/}/storage/${1}/CMakeLists.txt" || die
|
|
||||||
}
|
|
||||||
|
|
||||||
_disable_plugin() {
|
|
||||||
echo > "${S%/}/plugin/${1}/CMakeLists.txt" || die
|
|
||||||
}
|
|
||||||
|
|
||||||
if use tcmalloc; then
|
|
||||||
echo "TARGET_LINK_LIBRARIES(mysqld tcmalloc)" >> "${S%/}/sql/CMakeLists.txt" || die
|
|
||||||
fi
|
|
||||||
|
|
||||||
# Don't build bundled xz-utils for tokudb
|
|
||||||
echo > "${S%/}/storage/tokudb/PerconaFT/cmake_modules/TokuThirdParty.cmake" || die
|
|
||||||
sed -i -e 's/ build_lzma//' -e 's/ build_snappy//' "${S%/}/storage/tokudb/PerconaFT/ft/CMakeLists.txt" || die
|
|
||||||
sed -i -e 's/add_dependencies\(tokuportability_static_conv build_jemalloc\)//' "${S%/}/storage/tokudb/PerconaFT/portability/CMakeLists.txt" || die
|
|
||||||
|
|
||||||
# Fix -fno-common error
|
|
||||||
sed -i -e '/^datasink_t datasink_buffer;$/d' extra/mariabackup/xbstream.c || die
|
|
||||||
|
|
||||||
local plugin
|
|
||||||
local server_plugins=( handler_socket auth_socket feedback metadata_lock_info
|
|
||||||
locale_info qc_info server_audit semisync sql_errlog )
|
|
||||||
local test_plugins=( audit_null auth_examples daemon_example fulltext )
|
|
||||||
if ! use server; then # These plugins are for the server
|
|
||||||
for plugin in "${server_plugins[@]}" ; do
|
|
||||||
_disable_plugin "${plugin}"
|
|
||||||
done
|
|
||||||
fi
|
|
||||||
|
|
||||||
if ! use test; then # These plugins are only used during testing
|
|
||||||
for plugin in "${test_plugins[@]}" ; do
|
|
||||||
_disable_plugin "${plugin}"
|
|
||||||
done
|
|
||||||
fi
|
|
||||||
|
|
||||||
# Collides with mariadb-connector-c bug 655980
|
|
||||||
_disable_plugin auth_dialog
|
|
||||||
|
|
||||||
# Avoid useless library checks
|
|
||||||
use mroonga || _disable_engine mroonga
|
|
||||||
use oqgraph || _disable_engine oqgraph
|
|
||||||
_disable_engine example
|
|
||||||
|
|
||||||
cmake-utils_src_prepare
|
|
||||||
java-pkg-opt-2_src_prepare
|
|
||||||
}
|
|
||||||
|
|
||||||
src_configure() {
|
|
||||||
# bug 508724 mariadb cannot use ld.gold
|
|
||||||
tc-ld-disable-gold
|
|
||||||
# Bug #114895, bug #110149
|
|
||||||
filter-flags "-O" "-O[01]"
|
|
||||||
|
|
||||||
append-cxxflags -felide-constructors
|
|
||||||
|
|
||||||
# bug #283926, with GCC4.4, this is required to get correct behavior.
|
|
||||||
append-flags -fno-strict-aliasing
|
|
||||||
|
|
||||||
CMAKE_BUILD_TYPE="RelWithDebInfo"
|
|
||||||
|
|
||||||
# debug hack wrt #497532
|
|
||||||
mycmakeargs=(
|
|
||||||
-DCMAKE_C_FLAGS_RELWITHDEBINFO="$(usex debug '' '-DNDEBUG')"
|
|
||||||
-DCMAKE_CXX_FLAGS_RELWITHDEBINFO="$(usex debug '' '-DNDEBUG')"
|
|
||||||
-DDEFAULT_SYSCONFDIR="${EPREFIX}/etc/mysql"
|
|
||||||
-DINSTALL_BINDIR=bin
|
|
||||||
-DINSTALL_DOCDIR=share/doc/${PF}
|
|
||||||
-DINSTALL_DOCREADMEDIR=share/doc/${PF}
|
|
||||||
-DINSTALL_INCLUDEDIR=include/mysql
|
|
||||||
-DINSTALL_INFODIR=share/info
|
|
||||||
-DINSTALL_LIBDIR=$(get_libdir)
|
|
||||||
-DINSTALL_MANDIR=share/man
|
|
||||||
-DINSTALL_MYSQLSHAREDIR=share/mariadb
|
|
||||||
-DINSTALL_MYSQLTESTDIR=$(usex test 'share/mariadb/mysql-test' '')
|
|
||||||
-DINSTALL_PLUGINDIR=$(get_libdir)/mariadb/plugin
|
|
||||||
-DINSTALL_SCRIPTDIR=share/mariadb/scripts
|
|
||||||
-DINSTALL_MYSQLDATADIR="${EPREFIX}/var/lib/mysql"
|
|
||||||
-DINSTALL_SBINDIR=sbin
|
|
||||||
-DINSTALL_SUPPORTFILESDIR="${EPREFIX}/usr/share/mariadb"
|
|
||||||
-DCOMPILATION_COMMENT="Gentoo Linux ${PF}"
|
|
||||||
-DWITH_UNIT_TESTS=$(usex test ON OFF)
|
|
||||||
-DWITH_ZLIB=system
|
|
||||||
-DENABLED_LOCAL_INFILE=1
|
|
||||||
-DMYSQL_UNIX_ADDR="${EPREFIX}/var/run/mysqld/mysqld.sock"
|
|
||||||
-DINSTALL_UNIX_ADDRDIR="${EPREFIX}/var/run/mysqld/mysqld.sock"
|
|
||||||
-DWITH_DEFAULT_COMPILER_OPTIONS=0
|
|
||||||
-DWITH_DEFAULT_FEATURE_SET=0
|
|
||||||
-DINSTALL_SYSTEMD_UNITDIR="$(systemd_get_systemunitdir)"
|
|
||||||
# The build forces this to be defined when cross-compiling. We pass it
|
|
||||||
# all the time for simplicity and to make sure it is actually correct.
|
|
||||||
-DSTACK_DIRECTION=$(tc-stack-grows-down && echo -1 || echo 1)
|
|
||||||
-DWITHOUT_CLIENTLIBS=YES
|
|
||||||
-DWITH_READLINE=$(usex bindist 1 0)
|
|
||||||
-DNOT_FOR_DISTRIBUTION=$(usex bindist 0 1)
|
|
||||||
-DENABLE_DTRACE=$(usex systemtap)
|
|
||||||
-DWITH_SSL=$(usex yassl bundled system)
|
|
||||||
-DPLUGIN_CLIENT_ED25519=NO
|
|
||||||
-DPLUGIN_AUTH_GSSAPI_CLIENT=NO
|
|
||||||
)
|
|
||||||
|
|
||||||
if use server ; then
|
|
||||||
|
|
||||||
# Federated{,X} must be treated special otherwise they will not be built as plugins
|
|
||||||
if ! use extraengine ; then
|
|
||||||
mycmakeargs+=(
|
|
||||||
-DPLUGIN_FEDERATED=NO
|
|
||||||
-DPLUGIN_FEDERATEDX=NO )
|
|
||||||
fi
|
|
||||||
|
|
||||||
mycmakeargs+=(
|
|
||||||
-DWITH_JEMALLOC=$(usex jemalloc system)
|
|
||||||
-DWITH_PCRE=system
|
|
||||||
-DPLUGIN_OQGRAPH=$(usex oqgraph DYNAMIC NO)
|
|
||||||
-DPLUGIN_SPHINX=$(usex sphinx YES NO)
|
|
||||||
-DPLUGIN_TOKUDB=$(usex tokudb YES NO)
|
|
||||||
-DPLUGIN_AUTH_PAM=$(usex pam YES NO)
|
|
||||||
-DPLUGIN_CRACKLIB_PASSWORD_CHECK=$(usex cracklib YES NO)
|
|
||||||
-DPLUGIN_CASSANDRA=NO
|
|
||||||
-DPLUGIN_SEQUENCE=$(usex extraengine YES NO)
|
|
||||||
-DPLUGIN_SPIDER=$(usex extraengine YES NO)
|
|
||||||
-DPLUGIN_CONNECT=$(usex extraengine YES NO)
|
|
||||||
-DCONNECT_WITH_MYSQL=1
|
|
||||||
-DCONNECT_WITH_LIBXML2=$(usex xml)
|
|
||||||
-DCONNECT_WITH_ODBC=$(usex odbc)
|
|
||||||
-DCONNECT_WITH_JDBC=$(usex jdbc)
|
|
||||||
# Build failure and autodep wrt bug 639144
|
|
||||||
-DCONNECT_WITH_MONGO=OFF
|
|
||||||
-DWITH_WSREP=$(usex galera)
|
|
||||||
-DWITH_INNODB_LZ4=$(usex innodb-lz4 ON OFF)
|
|
||||||
-DWITH_INNODB_LZO=$(usex innodb-lzo ON OFF)
|
|
||||||
-DWITH_INNODB_SNAPPY=$(usex innodb-snappy ON OFF)
|
|
||||||
-DPLUGIN_MROONGA=$(usex mroonga DYNAMIC NO)
|
|
||||||
-DPLUGIN_AUTH_GSSAPI=$(usex kerberos DYNAMIC NO)
|
|
||||||
-DPLUGIN_AUTH_GSSAPI_CLIENT=NO
|
|
||||||
-DWITH_MARIABACKUP=$(usex backup ON OFF)
|
|
||||||
-DWITH_LIBARCHIVE=$(usex backup ON OFF)
|
|
||||||
-DWITH_SYSTEMD=$(usex systemd yes no)
|
|
||||||
-DWITH_NUMA=$(usex numa ON OFF)
|
|
||||||
-DINSTALL_SQLBENCHDIR=''
|
|
||||||
)
|
|
||||||
|
|
||||||
if [[ ( -n ${MYSQL_DEFAULT_CHARSET} ) && ( -n ${MYSQL_DEFAULT_COLLATION} ) ]]; then
|
|
||||||
ewarn "You are using a custom charset of ${MYSQL_DEFAULT_CHARSET}"
|
|
||||||
ewarn "and a collation of ${MYSQL_DEFAULT_COLLATION}."
|
|
||||||
ewarn "You MUST file bugs without these variables set."
|
|
||||||
|
|
||||||
mycmakeargs+=(
|
|
||||||
-DDEFAULT_CHARSET=${MYSQL_DEFAULT_CHARSET}
|
|
||||||
-DDEFAULT_COLLATION=${MYSQL_DEFAULT_COLLATION}
|
|
||||||
)
|
|
||||||
|
|
||||||
elif ! use latin1 ; then
|
|
||||||
mycmakeargs+=(
|
|
||||||
-DDEFAULT_CHARSET=utf8
|
|
||||||
-DDEFAULT_COLLATION=utf8_general_ci
|
|
||||||
)
|
|
||||||
else
|
|
||||||
mycmakeargs+=(
|
|
||||||
-DDEFAULT_CHARSET=latin1
|
|
||||||
-DDEFAULT_COLLATION=latin1_swedish_ci
|
|
||||||
)
|
|
||||||
fi
|
|
||||||
mycmakeargs+=(
|
|
||||||
-DEXTRA_CHARSETS=all
|
|
||||||
-DMYSQL_USER=mysql
|
|
||||||
-DDISABLE_SHARED=$(usex static YES NO)
|
|
||||||
-DWITH_DEBUG=$(usex debug)
|
|
||||||
-DWITH_EMBEDDED_SERVER=OFF
|
|
||||||
-DENABLED_PROFILING=$(usex profiling)
|
|
||||||
)
|
|
||||||
|
|
||||||
if use static; then
|
|
||||||
mycmakeargs+=( -DWITH_PIC=1 )
|
|
||||||
fi
|
|
||||||
|
|
||||||
if use jemalloc || use tcmalloc ; then
|
|
||||||
mycmakeargs+=( -DWITH_SAFEMALLOC=OFF )
|
|
||||||
fi
|
|
||||||
|
|
||||||
# Storage engines
|
|
||||||
mycmakeargs+=(
|
|
||||||
-DWITH_ARCHIVE_STORAGE_ENGINE=1
|
|
||||||
-DWITH_BLACKHOLE_STORAGE_ENGINE=1
|
|
||||||
-DWITH_CSV_STORAGE_ENGINE=1
|
|
||||||
-DWITH_HEAP_STORAGE_ENGINE=1
|
|
||||||
-DWITH_INNOBASE_STORAGE_ENGINE=1
|
|
||||||
-DWITH_MYISAMMRG_STORAGE_ENGINE=1
|
|
||||||
-DWITH_MYISAM_STORAGE_ENGINE=1
|
|
||||||
-DWITH_PARTITION_STORAGE_ENGINE=1
|
|
||||||
)
|
|
||||||
|
|
||||||
else
|
|
||||||
mycmakeargs+=(
|
|
||||||
-DWITHOUT_SERVER=1
|
|
||||||
-DWITH_EMBEDDED_SERVER=OFF
|
|
||||||
-DEXTRA_CHARSETS=none
|
|
||||||
-DINSTALL_SQLBENCHDIR=
|
|
||||||
-DWITH_SYSTEMD=no
|
|
||||||
)
|
|
||||||
fi
|
|
||||||
|
|
||||||
cmake-utils_src_configure
|
|
||||||
}
|
|
||||||
|
|
||||||
src_compile() {
|
|
||||||
cmake-utils_src_compile
|
|
||||||
}
|
|
||||||
|
|
||||||
# Official test instructions:
|
|
||||||
# USE='extraengine perl server' \
|
|
||||||
# FEATURES='test userpriv' \
|
|
||||||
# ebuild mariadb-X.X.XX.ebuild \
|
|
||||||
# digest clean package
|
|
||||||
src_test() {
|
|
||||||
_disable_test() {
|
|
||||||
local rawtestname bug reason
|
|
||||||
rawtestname="${1}" ; shift
|
|
||||||
bug="${1}" ; shift
|
|
||||||
reason="${@}"
|
|
||||||
ewarn "test '${rawtestname}' disabled: '${reason}' (BUG#${bug})"
|
|
||||||
echo "${rawtestname} : BUG#${bug} ${reason}" >> "${T}/disabled.def"
|
|
||||||
}
|
|
||||||
|
|
||||||
local TESTDIR="${BUILD_DIR}/mysql-test"
|
|
||||||
local retstatus_unit
|
|
||||||
local retstatus_tests
|
|
||||||
|
|
||||||
if ! use server ; then
|
|
||||||
einfo "Skipping server tests due to minimal build."
|
|
||||||
return 0
|
|
||||||
fi
|
|
||||||
|
|
||||||
einfo ">>> Test phase [test]: ${CATEGORY}/${PF}"
|
|
||||||
|
|
||||||
# Run CTest (test-units)
|
|
||||||
cmake-utils_src_test
|
|
||||||
retstatus_unit=$?
|
|
||||||
|
|
||||||
# Ensure that parallel runs don't die
|
|
||||||
export MTR_BUILD_THREAD="$((${RANDOM} % 100))"
|
|
||||||
|
|
||||||
if [[ -z "${MTR_PARALLEL}" ]] ; then
|
|
||||||
local -x MTR_PARALLEL=$(makeopts_jobs)
|
|
||||||
|
|
||||||
if [[ ${MTR_PARALLEL} -gt 4 ]] ; then
|
|
||||||
# Running multiple tests in parallel usually require higher ulimit
|
|
||||||
# and fs.aio-max-nr setting. In addition, tests like main.multi_update
|
|
||||||
# are known to hit timeout when system is busy.
|
|
||||||
# To avoid test failure we will limit MTR_PARALLEL to 4 instead of
|
|
||||||
# using "auto".
|
|
||||||
local info_msg="Parallel MySQL test suite jobs limited to 4 (MAKEOPTS=${MTR_PARALLEL})"
|
|
||||||
info_msg+=" to avoid test failures. Set MTR_PARALLEL if you know what you are doing!"
|
|
||||||
einfo "${info_msg}"
|
|
||||||
unset info_msg
|
|
||||||
MTR_PARALLEL=4
|
|
||||||
fi
|
|
||||||
else
|
|
||||||
einfo "MTR_PARALLEL is set to '${MTR_PARALLEL}'"
|
|
||||||
fi
|
|
||||||
|
|
||||||
# Try to increase file limits to increase test coverage
|
|
||||||
if ! ulimit -n 16500 1>/dev/null 2>&1 ; then
|
|
||||||
# Upper limit comes from parts.partition_* tests
|
|
||||||
ewarn "For maximum test coverage please raise open file limit to 16500 (ulimit -n 16500) before calling the package manager."
|
|
||||||
|
|
||||||
if ! ulimit -n 4162 1>/dev/null 2>&1 ; then
|
|
||||||
# Medium limit comes from '[Warning] Buffered warning: Could not increase number of max_open_files to more than 3000 (request: 4162)'
|
|
||||||
ewarn "For medium test coverage please raise open file limit to 4162 (ulimit -n 4162) before calling the package manager."
|
|
||||||
|
|
||||||
if ! ulimit -n 3000 1>/dev/null 2>&1 ; then
|
|
||||||
ewarn "For minimum test coverage please raise open file limit to 3000 (ulimit -n 3000) before calling the package manager."
|
|
||||||
else
|
|
||||||
einfo "Will run test suite with open file limit set to 3000 (minimum test coverage)."
|
|
||||||
fi
|
|
||||||
else
|
|
||||||
einfo "Will run test suite with open file limit set to 4162 (medium test coverage)."
|
|
||||||
fi
|
|
||||||
else
|
|
||||||
einfo "Will run test suite with open file limit set to 16500 (best test coverage)."
|
|
||||||
fi
|
|
||||||
|
|
||||||
# create directories because mysqladmin might run out of order
|
|
||||||
mkdir -p "${T}"/var-tests{,/log} || die
|
|
||||||
|
|
||||||
cp "${S}"/mysql-test/unstable-tests "${T}/disabled.def" || die
|
|
||||||
|
|
||||||
local -a disabled_tests
|
|
||||||
disabled_tests+=( "compat/oracle.plugin;0;Needs example plugin which Gentoo disables" )
|
|
||||||
disabled_tests+=( "main.explain_non_select;0;Sporadically failing test" )
|
|
||||||
disabled_tests+=( "main.func_time;0;Dependent on time test was written" )
|
|
||||||
disabled_tests+=( "main.grant;0;Sporadically failing test" )
|
|
||||||
disabled_tests+=( "main.join_cache;0;Sporadically failing test" )
|
|
||||||
disabled_tests+=( "main.plugin_auth;0;Needs client libraries built" )
|
|
||||||
disabled_tests+=( "main.stat_tables;0;Sporadically failing test" )
|
|
||||||
disabled_tests+=( "main.stat_tables_innodb;0;Sporadically failing test" )
|
|
||||||
disabled_tests+=( "mariabackup.*;0;Broken test suite" )
|
|
||||||
disabled_tests+=( "plugins.auth_ed25519;0;Needs client libraries built" )
|
|
||||||
disabled_tests+=( "plugins.cracklib_password_check;0;False positive due to varying policies" )
|
|
||||||
disabled_tests+=( "plugins.two_password_validations;0;False positive due to varying policies" )
|
|
||||||
disabled_tests+=( "roles.acl_statistics;0;False positive due to a user count mismatch caused by previous test" )
|
|
||||||
|
|
||||||
if ! use latin1 ; then
|
|
||||||
disabled_tests+=( "funcs_1.is_columns_mysql;0;Requires USE=latin1" )
|
|
||||||
disabled_tests+=( "main.information_schema;0;Requires USE=latin1" )
|
|
||||||
disabled_tests+=( "main.mysql;0;Requires USE=latin1" )
|
|
||||||
disabled_tests+=( "main.system_mysql_db;0;Requires USE=latin1" )
|
|
||||||
fi
|
|
||||||
|
|
||||||
if ! use profiling ; then
|
|
||||||
disabled_tests+=( "sys_vars.sysvars_server_notembedded;0;Requires USE=profiling" )
|
|
||||||
fi
|
|
||||||
|
|
||||||
local test_infos_str test_infos_arr
|
|
||||||
for test_infos_str in "${disabled_tests[@]}" ; do
|
|
||||||
IFS=';' read -r -a test_infos_arr <<< "${test_infos_str}"
|
|
||||||
|
|
||||||
if [[ ${#test_infos_arr[@]} != 3 ]] ; then
|
|
||||||
die "Invalid test data set, not matching format: ${test_infos_str}"
|
|
||||||
fi
|
|
||||||
|
|
||||||
_disable_test "${test_infos_arr[0]}" "${test_infos_arr[1]}" "${test_infos_arr[2]}"
|
|
||||||
done
|
|
||||||
unset test_infos_str test_infos_arr
|
|
||||||
|
|
||||||
# run mysql-test tests
|
|
||||||
pushd "${TESTDIR}" &>/dev/null || die
|
|
||||||
perl mysql-test-run.pl --force --vardir="${T}/var-tests" --reorder --skip-test=tokudb --skip-test-list="${T}/disabled.def"
|
|
||||||
retstatus_tests=$?
|
|
||||||
|
|
||||||
popd &>/dev/null || die
|
|
||||||
|
|
||||||
# Cleanup is important for these testcases.
|
|
||||||
pkill -9 -f "${S}/ndb" 2>/dev/null
|
|
||||||
pkill -9 -f "${S}/sql" 2>/dev/null
|
|
||||||
|
|
||||||
local failures=""
|
|
||||||
[[ $retstatus_unit -eq 0 ]] || failures="${failures} test-unit"
|
|
||||||
[[ $retstatus_tests -eq 0 ]] || failures="${failures} tests"
|
|
||||||
|
|
||||||
[[ -z "$failures" ]] || die "Test failures: $failures"
|
|
||||||
einfo "Tests successfully completed"
|
|
||||||
}
|
|
||||||
|
|
||||||
src_install() {
|
|
||||||
cmake-utils_src_install
|
|
||||||
|
|
||||||
# Remove an unnecessary, private config header which will never match between ABIs and is not meant to be used
|
|
||||||
if [[ -f "${ED}/usr/include/mysql/server/private/config.h" ]] ; then
|
|
||||||
rm "${ED}/usr/include/mysql/server/private/config.h" || die
|
|
||||||
fi
|
|
||||||
|
|
||||||
# Make sure the vars are correctly initialized
|
|
||||||
mysql_init_vars
|
|
||||||
|
|
||||||
# Convenience links
|
|
||||||
einfo "Making Convenience links for mysqlcheck multi-call binary"
|
|
||||||
dosym "mysqlcheck" "/usr/bin/mysqlanalyze"
|
|
||||||
dosym "mysqlcheck" "/usr/bin/mysqlrepair"
|
|
||||||
dosym "mysqlcheck" "/usr/bin/mysqloptimize"
|
|
||||||
|
|
||||||
# INSTALL_LAYOUT=STANDALONE causes cmake to create a /usr/data dir
|
|
||||||
if [[ -d "${ED}/usr/data" ]] ; then
|
|
||||||
rm -Rf "${ED}/usr/data" || die
|
|
||||||
fi
|
|
||||||
|
|
||||||
# Unless they explicitly specific USE=test, then do not install the
|
|
||||||
# testsuite. It DOES have a use to be installed, esp. when you want to do a
|
|
||||||
# validation of your database configuration after tuning it.
|
|
||||||
if ! use test ; then
|
|
||||||
rm -rf "${D}/${MY_SHAREDSTATEDIR}/mysql-test"
|
|
||||||
fi
|
|
||||||
|
|
||||||
# Configuration stuff
|
|
||||||
einfo "Building default configuration ..."
|
|
||||||
insinto "${MY_SYSCONFDIR#${EPREFIX}}"
|
|
||||||
[[ -f "${S}/scripts/mysqlaccess.conf" ]] && doins "${S}"/scripts/mysqlaccess.conf
|
|
||||||
local mycnf_src="my.cnf-5.6-r1"
|
|
||||||
sed -e "s!@DATADIR@!${MY_DATADIR}!g" \
|
|
||||||
"${FILESDIR}/${mycnf_src}" \
|
|
||||||
> "${TMPDIR}/my.cnf.ok" || die
|
|
||||||
use prefix && sed -i -r -e '/^user[[:space:]]*=[[:space:]]*mysql$/d' "${TMPDIR}/my.cnf.ok"
|
|
||||||
if use latin1 ; then
|
|
||||||
sed -i \
|
|
||||||
-e "/character-set/s|utf8|latin1|g" \
|
|
||||||
"${TMPDIR}/my.cnf.ok" || die
|
|
||||||
fi
|
|
||||||
eprefixify "${TMPDIR}/my.cnf.ok"
|
|
||||||
newins "${TMPDIR}/my.cnf.ok" my.cnf
|
|
||||||
|
|
||||||
if use server ; then
|
|
||||||
einfo "Including support files and sample configurations"
|
|
||||||
docinto "support-files"
|
|
||||||
local script
|
|
||||||
for script in \
|
|
||||||
"${S}"/support-files/magic
|
|
||||||
do
|
|
||||||
[[ -f "$script" ]] && dodoc "${script}"
|
|
||||||
done
|
|
||||||
|
|
||||||
docinto "scripts"
|
|
||||||
for script in "${S}"/scripts/mysql* ; do
|
|
||||||
[[ ( -f "$script" ) && ( "${script%.sh}" == "${script}" ) ]] && dodoc "${script}"
|
|
||||||
done
|
|
||||||
# Manually install supporting files that conflict with other packages
|
|
||||||
# but are needed for galera and initial installation
|
|
||||||
exeinto /usr/libexec/mariadb
|
|
||||||
doexe "${BUILD_DIR}/extra/my_print_defaults" "${BUILD_DIR}/extra/perror"
|
|
||||||
fi
|
|
||||||
|
|
||||||
#Remove mytop if perl is not selected
|
|
||||||
[[ -e "${ED}/usr/bin/mytop" ]] && ! use perl && rm -f "${ED}/usr/bin/mytop"
|
|
||||||
}
|
|
||||||
|
|
||||||
pkg_preinst() {
|
|
||||||
java-pkg-opt-2_pkg_preinst
|
|
||||||
}
|
|
||||||
|
|
||||||
pkg_postinst() {
|
|
||||||
# Make sure the vars are correctly initialized
|
|
||||||
mysql_init_vars
|
|
||||||
|
|
||||||
# Create log directory securely if it does not exist
|
|
||||||
[[ -d "${ROOT}${MY_LOGDIR}" ]] || install -d -m0750 -o mysql -g mysql "${ROOT}${MY_LOGDIR}"
|
|
||||||
|
|
||||||
if use server ; then
|
|
||||||
if use pam; then
|
|
||||||
einfo
|
|
||||||
elog "This install includes the PAM authentication plugin."
|
|
||||||
elog "To activate and configure the PAM plugin, please read:"
|
|
||||||
elog "https://mariadb.com/kb/en/mariadb/pam-authentication-plugin/"
|
|
||||||
einfo
|
|
||||||
fi
|
|
||||||
|
|
||||||
if [[ -z "${REPLACING_VERSIONS}" ]] ; then
|
|
||||||
einfo
|
|
||||||
elog "You might want to run:"
|
|
||||||
elog "\"emerge --config =${CATEGORY}/${PF}\""
|
|
||||||
elog "if this is a new install."
|
|
||||||
elog
|
|
||||||
elog "If you are switching server implentations, you should run the"
|
|
||||||
elog "mysql_upgrade tool."
|
|
||||||
einfo
|
|
||||||
else
|
|
||||||
einfo
|
|
||||||
elog "If you are upgrading major versions, you should run the"
|
|
||||||
elog "mysql_upgrade tool."
|
|
||||||
einfo
|
|
||||||
fi
|
|
||||||
|
|
||||||
einfo
|
|
||||||
elog "Be sure to edit the my.cnf file to activate your cluster settings."
|
|
||||||
elog "This should be done after running \"emerge --config =${CATEGORY}/${PF}\""
|
|
||||||
elog "The first time the cluster is activated, you should add"
|
|
||||||
elog "--wsrep-new-cluster to the options in /etc/conf.d/mysql for one node."
|
|
||||||
elog "This option should then be removed for subsequent starts."
|
|
||||||
einfo
|
|
||||||
fi
|
|
||||||
}
|
|
||||||
|
|
||||||
pkg_config() {
|
|
||||||
_getoptval() {
|
|
||||||
local mypd="${EROOT}"usr/libexec/mariadb/my_print_defaults
|
|
||||||
local section="$1"
|
|
||||||
local flag="--${2}="
|
|
||||||
local extra_options="${3}"
|
|
||||||
"${mypd}" $extra_options $section | sed -n "/^${flag}/s,${flag},,gp"
|
|
||||||
}
|
|
||||||
local old_MY_DATADIR="${MY_DATADIR}"
|
|
||||||
local old_HOME="${HOME}"
|
|
||||||
# my_print_defaults needs to read stuff in $HOME/.my.cnf
|
|
||||||
export HOME=${EPREFIX}/root
|
|
||||||
|
|
||||||
# Make sure the vars are correctly initialized
|
|
||||||
mysql_init_vars
|
|
||||||
|
|
||||||
[[ -z "${MY_DATADIR}" ]] && die "Sorry, unable to find MY_DATADIR"
|
|
||||||
if [[ ! -x "${EROOT}/usr/sbin/mysqld" ]] ; then
|
|
||||||
die "Minimal builds do NOT include the MySQL server"
|
|
||||||
fi
|
|
||||||
|
|
||||||
if [[ ( -n "${MY_DATADIR}" ) && ( "${MY_DATADIR}" != "${old_MY_DATADIR}" ) ]]; then
|
|
||||||
local MY_DATADIR_s="${ROOT}/${MY_DATADIR}"
|
|
||||||
MY_DATADIR_s="${MY_DATADIR_s%%/}"
|
|
||||||
local old_MY_DATADIR_s="${ROOT}/${old_MY_DATADIR}"
|
|
||||||
old_MY_DATADIR_s="${old_MY_DATADIR_s%%/}"
|
|
||||||
|
|
||||||
if [[ ( -d "${old_MY_DATADIR_s}" ) && ( "${old_MY_DATADIR_s}" != / ) ]]; then
|
|
||||||
if [[ -d "${MY_DATADIR_s}" ]]; then
|
|
||||||
ewarn "Both ${old_MY_DATADIR_s} and ${MY_DATADIR_s} exist"
|
|
||||||
ewarn "Attempting to use ${MY_DATADIR_s} and preserving ${old_MY_DATADIR_s}"
|
|
||||||
else
|
|
||||||
elog "Moving MY_DATADIR from ${old_MY_DATADIR_s} to ${MY_DATADIR_s}"
|
|
||||||
mv --strip-trailing-slashes -T "${old_MY_DATADIR_s}" "${MY_DATADIR_s}" \
|
|
||||||
|| die "Moving MY_DATADIR failed"
|
|
||||||
fi
|
|
||||||
else
|
|
||||||
ewarn "Previous MY_DATADIR (${old_MY_DATADIR_s}) does not exist"
|
|
||||||
if [[ -d "${MY_DATADIR_s}" ]]; then
|
|
||||||
ewarn "Attempting to use ${MY_DATADIR_s}"
|
|
||||||
else
|
|
||||||
eerror "New MY_DATADIR (${MY_DATADIR_s}) does not exist"
|
|
||||||
die "Configuration Failed! Please reinstall ${CATEGORY}/${PN}"
|
|
||||||
fi
|
|
||||||
fi
|
|
||||||
fi
|
|
||||||
|
|
||||||
local pwd1="a"
|
|
||||||
local pwd2="b"
|
|
||||||
local maxtry=15
|
|
||||||
|
|
||||||
if [ -z "${MYSQL_ROOT_PASSWORD}" ]; then
|
|
||||||
local tmp_mysqld_password_source=
|
|
||||||
|
|
||||||
for tmp_mysqld_password_source in mysql client; do
|
|
||||||
einfo "Trying to get password for mysql 'root' user from '${tmp_mysqld_password_source}' section ..."
|
|
||||||
MYSQL_ROOT_PASSWORD="$(_getoptval "${tmp_mysqld_password_source}" password)"
|
|
||||||
if [[ -n "${MYSQL_ROOT_PASSWORD}" ]]; then
|
|
||||||
if [[ ${MYSQL_ROOT_PASSWORD} == *$'\n'* ]]; then
|
|
||||||
ewarn "Ignoring password from '${tmp_mysqld_password_source}' section due to newline character (do you have multiple password options set?)!"
|
|
||||||
MYSQL_ROOT_PASSWORD=
|
|
||||||
continue
|
|
||||||
fi
|
|
||||||
|
|
||||||
einfo "Found password in '${tmp_mysqld_password_source}' section!"
|
|
||||||
break
|
|
||||||
fi
|
|
||||||
done
|
|
||||||
|
|
||||||
# Sometimes --show is required to display passwords in some implementations of my_print_defaults
|
|
||||||
if [[ "${MYSQL_ROOT_PASSWORD}" == '*****' ]]; then
|
|
||||||
MYSQL_ROOT_PASSWORD="$(_getoptval "${tmp_mysqld_password_source}" password --show)"
|
|
||||||
fi
|
|
||||||
|
|
||||||
unset tmp_mysqld_password_source
|
|
||||||
fi
|
|
||||||
MYSQL_TMPDIR="$(_getoptval mysqld tmpdir | tail -n1)"
|
|
||||||
# These are dir+prefix
|
|
||||||
MYSQL_RELAY_LOG="$(_getoptval mysqld relay-log | tail -n1)"
|
|
||||||
MYSQL_RELAY_LOG=${MYSQL_RELAY_LOG%/*}
|
|
||||||
MYSQL_LOG_BIN="$(_getoptval mysqld log-bin | tail -n1)"
|
|
||||||
MYSQL_LOG_BIN=${MYSQL_LOG_BIN%/*}
|
|
||||||
|
|
||||||
if [[ ! -d "${ROOT}/$MYSQL_TMPDIR" ]]; then
|
|
||||||
einfo "Creating MySQL tmpdir $MYSQL_TMPDIR"
|
|
||||||
install -d -m 770 -o mysql -g mysql "${EROOT}/$MYSQL_TMPDIR"
|
|
||||||
fi
|
|
||||||
if [[ ! -d "${ROOT}/$MYSQL_LOG_BIN" ]]; then
|
|
||||||
einfo "Creating MySQL log-bin directory $MYSQL_LOG_BIN"
|
|
||||||
install -d -m 770 -o mysql -g mysql "${EROOT}/$MYSQL_LOG_BIN"
|
|
||||||
fi
|
|
||||||
if [[ ! -d "${EROOT}/$MYSQL_RELAY_LOG" ]]; then
|
|
||||||
einfo "Creating MySQL relay-log directory $MYSQL_RELAY_LOG"
|
|
||||||
install -d -m 770 -o mysql -g mysql "${EROOT}/$MYSQL_RELAY_LOG"
|
|
||||||
fi
|
|
||||||
|
|
||||||
if [[ -d "${ROOT}/${MY_DATADIR}/mysql" ]] ; then
|
|
||||||
ewarn "You have already a MySQL database in place."
|
|
||||||
ewarn "(${ROOT}/${MY_DATADIR}/*)"
|
|
||||||
ewarn "Please rename or delete it if you wish to replace it."
|
|
||||||
die "MySQL database already exists!"
|
|
||||||
fi
|
|
||||||
|
|
||||||
# Bug #213475 - MySQL _will_ object strenously if your machine is named
|
|
||||||
# localhost. Also causes weird failures.
|
|
||||||
[[ "${HOSTNAME}" == "localhost" ]] && die "Your machine must NOT be named localhost"
|
|
||||||
|
|
||||||
if [ -z "${MYSQL_ROOT_PASSWORD}" ]; then
|
|
||||||
|
|
||||||
einfo "Please provide a password for the mysql 'root' user now"
|
|
||||||
einfo "or through the ${HOME}/.my.cnf file."
|
|
||||||
ewarn "Avoid [\"'\\_%] characters in the password"
|
|
||||||
read -rsp " >" pwd1 ; echo
|
|
||||||
|
|
||||||
einfo "Retype the password"
|
|
||||||
read -rsp " >" pwd2 ; echo
|
|
||||||
|
|
||||||
if [[ "x$pwd1" != "x$pwd2" ]] ; then
|
|
||||||
die "Passwords are not the same"
|
|
||||||
fi
|
|
||||||
MYSQL_ROOT_PASSWORD="${pwd1}"
|
|
||||||
unset pwd1 pwd2
|
|
||||||
fi
|
|
||||||
|
|
||||||
local options
|
|
||||||
local sqltmp="$(emktemp)"
|
|
||||||
|
|
||||||
# Fix bug 446200. Don't reference host my.cnf, needs to come first,
|
|
||||||
# see https://bugs.mysql.com/bug.php?id=31312
|
|
||||||
use prefix && options="${options} '--defaults-file=${MY_SYSCONFDIR}/my.cnf'"
|
|
||||||
|
|
||||||
# Figure out which options we need to disable to do the setup
|
|
||||||
local helpfile="${TMPDIR}/mysqld-help"
|
|
||||||
"${EROOT}/usr/sbin/mysqld" --verbose --help >"${helpfile}" 2>/dev/null
|
|
||||||
for opt in grant-tables host-cache name-resolve networking slave-start \
|
|
||||||
federated ssl log-bin relay-log slow-query-log external-locking \
|
|
||||||
log-slave-updates \
|
|
||||||
; do
|
|
||||||
optexp="--(skip-)?${opt}" optfull="--loose-skip-${opt}"
|
|
||||||
egrep -sq -- "${optexp}" "${helpfile}" && options="${options} ${optfull}"
|
|
||||||
done
|
|
||||||
|
|
||||||
einfo "Creating the mysql database and setting proper permissions on it ..."
|
|
||||||
|
|
||||||
# Now that /var/run is a tmpfs mount point, we need to ensure it exists before using it
|
|
||||||
PID_DIR="${EROOT}/var/run/mysqld"
|
|
||||||
if [[ ! -d "${PID_DIR}" ]]; then
|
|
||||||
install -d -m 755 -o mysql -g mysql "${PID_DIR}" || die "Could not create pid directory"
|
|
||||||
fi
|
|
||||||
|
|
||||||
if [[ ! -d "${MY_DATADIR}" ]]; then
|
|
||||||
install -d -m 750 -o mysql -g mysql "${MY_DATADIR}" || die "Could not create data directory"
|
|
||||||
fi
|
|
||||||
|
|
||||||
pushd "${TMPDIR}" &>/dev/null || die
|
|
||||||
|
|
||||||
# Filling timezones, see
|
|
||||||
# https://dev.mysql.com/doc/mysql/en/time-zone-support.html
|
|
||||||
"${EROOT}/usr/bin/mysql_tzinfo_to_sql" "${EROOT}/usr/share/zoneinfo" > "${sqltmp}" 2>/dev/null
|
|
||||||
|
|
||||||
local cmd=( "${EROOT}usr/share/mariadb/scripts/mysql_install_db" )
|
|
||||||
[[ -f "${cmd}" ]] || cmd=( "${EROOT}usr/bin/mysql_install_db" )
|
|
||||||
cmd+=( "--basedir=${EPREFIX}/usr" ${options} "--datadir=${ROOT}/${MY_DATADIR}" "--tmpdir=${ROOT}/${MYSQL_TMPDIR}" )
|
|
||||||
einfo "Command: ${cmd[*]}"
|
|
||||||
su -s /bin/sh -c "${cmd[*]}" mysql \
|
|
||||||
>"${TMPDIR}"/mysql_install_db.log 2>&1
|
|
||||||
if [ $? -ne 0 ]; then
|
|
||||||
grep -B5 -A999 -i "ERROR" "${TMPDIR}"/mysql_install_db.log 1>&2
|
|
||||||
die "Failed to initialize mysqld. Please review ${EPREFIX}/var/log/mysql/mysqld.err AND ${TMPDIR}/mysql_install_db.log"
|
|
||||||
fi
|
|
||||||
popd &>/dev/null || die
|
|
||||||
[[ -f "${ROOT}/${MY_DATADIR}/mysql/user.frm" ]] \
|
|
||||||
|| die "MySQL databases not installed"
|
|
||||||
|
|
||||||
use prefix || options="${options} --user=mysql"
|
|
||||||
|
|
||||||
local socket="${EROOT}/var/run/mysqld/mysqld${RANDOM}.sock"
|
|
||||||
local pidfile="${EROOT}/var/run/mysqld/mysqld${RANDOM}.pid"
|
|
||||||
local mysqld="${EROOT}/usr/sbin/mysqld \
|
|
||||||
${options} \
|
|
||||||
--log-warnings=0 \
|
|
||||||
--basedir=${EROOT}/usr \
|
|
||||||
--datadir=${ROOT}/${MY_DATADIR} \
|
|
||||||
--max_allowed_packet=8M \
|
|
||||||
--net_buffer_length=16K \
|
|
||||||
--socket=${socket} \
|
|
||||||
--pid-file=${pidfile} \
|
|
||||||
--tmpdir=${ROOT}/${MYSQL_TMPDIR}"
|
|
||||||
#einfo "About to start mysqld: ${mysqld}"
|
|
||||||
ebegin "Starting mysqld"
|
|
||||||
einfo "Command ${mysqld}"
|
|
||||||
${mysqld} &
|
|
||||||
rc=$?
|
|
||||||
while ! [[ -S "${socket}" || "${maxtry}" -lt 1 ]] ; do
|
|
||||||
maxtry=$((${maxtry}-1))
|
|
||||||
echo -n "."
|
|
||||||
sleep 1
|
|
||||||
done
|
|
||||||
eend $rc
|
|
||||||
|
|
||||||
if ! [[ -S "${socket}" ]]; then
|
|
||||||
die "Completely failed to start up mysqld with: ${mysqld}"
|
|
||||||
fi
|
|
||||||
|
|
||||||
ebegin "Setting root password"
|
|
||||||
# Do this from memory, as we don't want clear text passwords in temp files
|
|
||||||
local sql="UPDATE mysql.user SET Password = PASSWORD('${MYSQL_ROOT_PASSWORD}') WHERE USER='root'; FLUSH PRIVILEGES"
|
|
||||||
"${EROOT}/usr/bin/mysql" \
|
|
||||||
"--socket=${socket}" \
|
|
||||||
-hlocalhost \
|
|
||||||
-e "${sql}"
|
|
||||||
eend $?
|
|
||||||
|
|
||||||
if [[ -n "${sqltmp}" ]] ; then
|
|
||||||
ebegin "Loading \"zoneinfo\", this step may require a few seconds"
|
|
||||||
"${EROOT}/usr/bin/mysql" \
|
|
||||||
"--socket=${socket}" \
|
|
||||||
-hlocalhost \
|
|
||||||
-uroot \
|
|
||||||
--password="${MYSQL_ROOT_PASSWORD}" \
|
|
||||||
mysql < "${sqltmp}"
|
|
||||||
rc=$?
|
|
||||||
eend $?
|
|
||||||
[[ $rc -ne 0 ]] && ewarn "Failed to load zoneinfo!"
|
|
||||||
fi
|
|
||||||
|
|
||||||
# Stop the server and cleanup
|
|
||||||
einfo "Stopping the server ..."
|
|
||||||
kill $(< "${pidfile}" )
|
|
||||||
rm -f "${sqltmp}"
|
|
||||||
wait %1
|
|
||||||
einfo "Done"
|
|
||||||
}
|
|
Binary file not shown.
@ -1 +1 @@
|
|||||||
DIST data-default-0.5.3.tar.gz 1623 BLAKE2B 365de6448edfdaec1b852e89eb31faa323f0ab5f6fc101247f0a16d76680f98fea751c524fa3fe5b697c927eac3cf4c778a37eb5ff0fbcf0daf8bb3ab27f4220 SHA512 57cb632ccc6c9b0973594c7c5944574f4e7e78f980194d4205bb14a6e5aa1bd3e92723f3b80cfeac301ae663b2a22925503a03ecb5311ebc08077fe06022817e
|
DIST data-default-0.7.1.1.tar.gz 1627 BLAKE2B 3d711bbc04c00c1918377d15fefaf394bf69ae877d828f00a17c20b08fa635a6be40582222a5973d2c56b96c81d89175af9f05f66ef3c12bddab29859bb09f88 SHA512 a31260c71178641e41f16fc504620f19ad04a44d2d095c96225b6027184c01ec0bf47effab5344816e438d7c37e34189255a9d3a5d643219b37054dde679d1bd
|
||||||
|
Some files were not shown because too many files have changed in this diff Show More
Loading…
Reference in new issue