parent
aa562479ae
commit
00949a8187
@ -1,2 +1 @@
|
|||||||
DIST entr-3.6.tar.gz 22548 SHA256 a42746d81c548d7e557d500f93422b8ec9731d719309eb2601b8be69ae0dc8eb SHA512 a4f607d69e2222ffaeb50c57532fafa88db550d4ab4c633e57e895a8291bb38f6bdd09e92dba2e6fc70e035b2db050ab4c75fb39cd24d00fbde07ef0c03fff8f WHIRLPOOL fb0e6d16b20a6829478e3a01972b817b73408412ef5a3542b6b087bce02371ae84cd17c8c558ad7565edf73328fe886414478c618e37f409372ed2f48795eb4e
|
|
||||||
DIST entr-3.7.tar.gz 23326 SHA256 94efd50c8f7e9d569060d5deebf366c3565e81e814ab332b973d7298fa8ea22f SHA512 a1687ec2da99f65fba3f668e41345ba76cb8c87cc2343d98c0dcc0ac0dedeb40cd8b5fd9aa3eba1dee8add94585de939864633bf0020cea1043699019dfa15fe WHIRLPOOL 1a9077a3cd8939bcea49c42e2a85eb094840942bdd23f6911c32c9d3184f742d06666e12c3d53c5e99026c82a20612bce8fd9441ccb27eddb68b61196a79fee8
|
DIST entr-3.7.tar.gz 23326 SHA256 94efd50c8f7e9d569060d5deebf366c3565e81e814ab332b973d7298fa8ea22f SHA512 a1687ec2da99f65fba3f668e41345ba76cb8c87cc2343d98c0dcc0ac0dedeb40cd8b5fd9aa3eba1dee8add94585de939864633bf0020cea1043699019dfa15fe WHIRLPOOL 1a9077a3cd8939bcea49c42e2a85eb094840942bdd23f6911c32c9d3184f742d06666e12c3d53c5e99026c82a20612bce8fd9441ccb27eddb68b61196a79fee8
|
||||||
|
@ -1,31 +0,0 @@
|
|||||||
# Copyright 1999-2016 Gentoo Foundation
|
|
||||||
# Distributed under the terms of the GNU General Public License v2
|
|
||||||
|
|
||||||
EAPI=6
|
|
||||||
|
|
||||||
DESCRIPTION="Run arbitrary commands when files change"
|
|
||||||
HOMEPAGE="http://entrproject.org/"
|
|
||||||
SRC_URI="http://entrproject.org/code/${P}.tar.gz"
|
|
||||||
|
|
||||||
LICENSE="ISC"
|
|
||||||
SLOT="0"
|
|
||||||
KEYWORDS="amd64 ppc ppc64 x86"
|
|
||||||
IUSE="test"
|
|
||||||
|
|
||||||
src_unpack() {
|
|
||||||
unpack "${P}.tar.gz"
|
|
||||||
mv eradman-* "${P}" || die
|
|
||||||
}
|
|
||||||
|
|
||||||
src_configure() {
|
|
||||||
sh configure || die
|
|
||||||
sed -i -e 's#\(^PREFIX \).*#\1\?= /usr#' Makefile.bsd || die
|
|
||||||
}
|
|
||||||
|
|
||||||
src_test() {
|
|
||||||
emake test
|
|
||||||
}
|
|
||||||
|
|
||||||
src_install() {
|
|
||||||
emake DESTDIR="${D}" install
|
|
||||||
}
|
|
@ -1,3 +1,2 @@
|
|||||||
DIST supervisor-3.1.3.tar.gz 391529 SHA256 e32c546fe8d2a6e079ec4819c49fd24534d4075a58af39118d04367918b3c282 SHA512 40795bfd1aee3eba9e51b6dc1bfcff20c42c0a42ca7ceecc35c428f7840d5d631303b7f0c4eee85375296fd4e9a48f6b405a87caf038f8ffbfe227b5160e7aa5 WHIRLPOOL da8f41907857c46633e93e1806449babd9230994a528c73946276c10387e380763b7b9fb884bb3376537d6eb55428e5873ed8e9a11cd410a3d6c8d7593907552
|
DIST supervisor-3.1.4.tar.gz 392321 SHA256 82f75089f719a7a3ca87f35c89a03c20fd3c0912552c96eb6fa40274ced6604e SHA512 7182db4169d37aa8f7a2a4e1d57ce40f6dea21759ed73fb49286dd5ffb2bdede0fccdc71344e93c8f8c067a2cbc4e3cb0a9a50b22bacdb1b8bc1378581ed5f07 WHIRLPOOL 64a3b7c46b6c2a2c5d67ebfc44fef0f3382ff98a2468b3c210f03b205a3cbf6d7604788b985c98b093c20a1950b4a343a86cf914713072fa2f28f50f0478f63e
|
||||||
DIST supervisor-3.3.1.tar.gz 415246 SHA256 fc3af22e5a7af2f6c3be787acf055c1c17777f5607cd4dc935fe633ab97061fd SHA512 e67d4e7b01f6f98a595e7524c5318e780b422a7f8f932f205c6a4d74c3c9e058b265b1732e944e5b467daa6ceffde7d1aae1f1af12c2b7c53728739edb10f740 WHIRLPOOL 744fd11df897ac25839138ce12bf194682b4d0576396b692ef2befecdffb658ed9c2a47aa2248793b082c674cb9a3dc39c0c38127e4a2da74028fb8606500336
|
DIST supervisor-3.3.3.tar.gz 418354 SHA256 96287ebfabf9a6923f74123b056c4da39c617fef367980f007cac02fba6527ad SHA512 8285445da8a0ed790fbdf75d988304ab8fcefd9c36975ae6526ec58f511c73cd8707f22b7cff40c3aed5e63f3665d096ed4b5dbc2cc456fe0c5b4547149dbb4a WHIRLPOOL e7d880f76fb6a3eabe6d4c78c19464e1f4880d195e58bdd10d829beb8962f9d8bd39ac5274ec96c6d47ac9478f5f3b80a36131cbbda275bc23b33bd664ca9d2a
|
||||||
DIST supervisor-3.3.2.tar.gz 417348 SHA256 bbb870f5b59c5c4fd79f711553e343158b2c64688997a23a1bcb2ce643f57771 SHA512 959f045d8da5a263a6990fdc4a93154684c74cca5f49aeb733b86da046a8a3a56981062d16f0ab8177c0e0bb41f137c62e1ae6a52582e76bbe0adb2b8185202c WHIRLPOOL 2cd1bae59d187d9623089a4c9bcc11773a7fd371fc8725b34b28cd5b342391ddf92dd1c3d77f7eed53ab0209fd611fd3ce0e9b15e108b422189620d97cb37658
|
|
||||||
|
@ -1,4 +1,4 @@
|
|||||||
# Copyright 1999-2015 Gentoo Foundation
|
# Copyright 1999-2017 Gentoo Foundation
|
||||||
# Distributed under the terms of the GNU General Public License v2
|
# Distributed under the terms of the GNU General Public License v2
|
||||||
|
|
||||||
EAPI="5"
|
EAPI="5"
|
@ -1,50 +0,0 @@
|
|||||||
# Copyright 1999-2016 Gentoo Foundation
|
|
||||||
# Distributed under the terms of the GNU General Public License v2
|
|
||||||
|
|
||||||
EAPI=6
|
|
||||||
|
|
||||||
PYTHON_COMPAT=( python2_7 ) # py2 only
|
|
||||||
# xml.etree.ElementTree module required.
|
|
||||||
PYTHON_REQ_USE="xml"
|
|
||||||
|
|
||||||
inherit distutils-r1
|
|
||||||
|
|
||||||
MY_PV="${PV/_beta/b}"
|
|
||||||
|
|
||||||
DESCRIPTION="A system for controlling process state under UNIX"
|
|
||||||
HOMEPAGE="http://supervisord.org/ https://pypi.python.org/pypi/supervisor"
|
|
||||||
SRC_URI="mirror://pypi/${P:0:1}/${PN}/${PN}-${MY_PV}.tar.gz"
|
|
||||||
|
|
||||||
LICENSE="repoze ZPL BSD HPND GPL-2"
|
|
||||||
SLOT="0"
|
|
||||||
KEYWORDS="~amd64 ~x86"
|
|
||||||
IUSE="doc test"
|
|
||||||
|
|
||||||
RDEPEND="
|
|
||||||
dev-python/meld3[${PYTHON_USEDEP}]
|
|
||||||
"
|
|
||||||
DEPEND="
|
|
||||||
dev-python/setuptools[${PYTHON_USEDEP}]
|
|
||||||
doc? ( dev-python/sphinx[${PYTHON_USEDEP}] )
|
|
||||||
test? (
|
|
||||||
${RDEPEND}
|
|
||||||
dev-python/mock[${PYTHON_USEDEP}]
|
|
||||||
)
|
|
||||||
"
|
|
||||||
|
|
||||||
S="${WORKDIR}/${PN}-${MY_PV}"
|
|
||||||
|
|
||||||
python_compile_all() {
|
|
||||||
use doc && emake -C docs html
|
|
||||||
}
|
|
||||||
|
|
||||||
python_test() {
|
|
||||||
esetup.py test
|
|
||||||
}
|
|
||||||
|
|
||||||
python_install_all() {
|
|
||||||
newinitd "${FILESDIR}/init.d-r1" supervisord
|
|
||||||
newconfd "${FILESDIR}/conf.d" supervisord
|
|
||||||
use doc && local HTML_DOCS=( docs/.build/html/. )
|
|
||||||
distutils-r1_python_install_all
|
|
||||||
}
|
|
@ -1,46 +0,0 @@
|
|||||||
# Copyright 1999-2016 Gentoo Foundation
|
|
||||||
# Distributed under the terms of the GNU General Public License v2
|
|
||||||
|
|
||||||
EAPI="5"
|
|
||||||
|
|
||||||
PYTHON_COMPAT=( python2_7 ) # py2 only
|
|
||||||
# xml.etree.ElementTree module required.
|
|
||||||
PYTHON_REQ_USE="xml"
|
|
||||||
|
|
||||||
inherit distutils-r1
|
|
||||||
|
|
||||||
MY_PV="${PV/_beta/b}"
|
|
||||||
|
|
||||||
DESCRIPTION="A system for controlling process state under UNIX"
|
|
||||||
HOMEPAGE="http://supervisord.org/ https://pypi.python.org/pypi/supervisor"
|
|
||||||
SRC_URI="mirror://pypi/${P:0:1}/${PN}/${PN}-${MY_PV}.tar.gz"
|
|
||||||
|
|
||||||
LICENSE="repoze ZPL BSD HPND GPL-2"
|
|
||||||
SLOT="0"
|
|
||||||
KEYWORDS="~amd64 ~x86"
|
|
||||||
IUSE="doc test"
|
|
||||||
|
|
||||||
# ALL versions of meld3 match to >=meld3-0.6.5
|
|
||||||
RDEPEND="dev-python/meld3[${PYTHON_USEDEP}]
|
|
||||||
dev-python/setuptools[${PYTHON_USEDEP}]"
|
|
||||||
DEPEND="${RDEPEND}
|
|
||||||
test? ( dev-python/mock[${PYTHON_USEDEP}] )
|
|
||||||
doc? ( dev-python/sphinx[${PYTHON_USEDEP}] )"
|
|
||||||
|
|
||||||
S="${WORKDIR}/${PN}-${MY_PV}"
|
|
||||||
|
|
||||||
python_compile_all() {
|
|
||||||
# Somehow the test phase is called and run on invoking a doc build; harmless
|
|
||||||
use doc && emake -C docs html
|
|
||||||
}
|
|
||||||
|
|
||||||
python_test() {
|
|
||||||
esetup.py test
|
|
||||||
}
|
|
||||||
|
|
||||||
python_install_all() {
|
|
||||||
newinitd "${FILESDIR}/init.d-r1" supervisord
|
|
||||||
newconfd "${FILESDIR}/conf.d" supervisord
|
|
||||||
use doc && local HTML_DOCS=( docs/.build/html/. )
|
|
||||||
distutils-r1_python_install_all
|
|
||||||
}
|
|
@ -1,6 +1,9 @@
|
|||||||
DIST rarlinux-5.5.0_beta4_p20170628.tar.gz 544409 SHA256 08c76882c42352ce36dd7cc78ce629a875889dbed41c713af078dbc4fe721073 SHA512 41c1da62995fab00421f788cb65dda3c5e1eb265fe1f4cd6a3bf4f9c28c63c39e4a0aa654f93ae444833c5c17397ee0beb98a6e02a515371ae245ac215d618b6 WHIRLPOOL e7c9c3a47deb1524aad46063fae486adadfd36850c42929494a83c05c86108e0c7da496da13114f72cbe32ca7791545cb43c1bff53b0fcd789357eda901e2511
|
DIST rarlinux-5.5.0_beta4_p20170628.tar.gz 544409 SHA256 08c76882c42352ce36dd7cc78ce629a875889dbed41c713af078dbc4fe721073 SHA512 41c1da62995fab00421f788cb65dda3c5e1eb265fe1f4cd6a3bf4f9c28c63c39e4a0aa654f93ae444833c5c17397ee0beb98a6e02a515371ae245ac215d618b6 WHIRLPOOL e7c9c3a47deb1524aad46063fae486adadfd36850c42929494a83c05c86108e0c7da496da13114f72cbe32ca7791545cb43c1bff53b0fcd789357eda901e2511
|
||||||
DIST rarlinux-5.5.0_beta5_p20170706.tar.gz 546152 SHA256 d94cfc792b3bf7ad90c428d3a2749f9f267a7809a5de33de11a99386631089d5 SHA512 6440c0bf17e11370216114c8fab3994779930b10a813fe3c4195cee9d23bce239cb4575ccfee319842059688c744e91496b7e9de98eae98d98beb4884e8e84ad WHIRLPOOL 668de3befd4fac0f2be6a307c7161a57cff3bc7915d4bb796bf32c24c9278ed1eb4734e645d2668555bdb566f5ec60c11eb1cd7cbcafdd36d94651a6e19611b3
|
DIST rarlinux-5.5.0_beta5_p20170706.tar.gz 546152 SHA256 d94cfc792b3bf7ad90c428d3a2749f9f267a7809a5de33de11a99386631089d5 SHA512 6440c0bf17e11370216114c8fab3994779930b10a813fe3c4195cee9d23bce239cb4575ccfee319842059688c744e91496b7e9de98eae98d98beb4884e8e84ad WHIRLPOOL 668de3befd4fac0f2be6a307c7161a57cff3bc7915d4bb796bf32c24c9278ed1eb4734e645d2668555bdb566f5ec60c11eb1cd7cbcafdd36d94651a6e19611b3
|
||||||
|
DIST rarlinux-5.5.0_beta6_p20170725.tar.gz 547172 SHA256 dae91da11e75aa592bf0332fad9e8df437a079fbd2b9727eb385b89c634ea9ae SHA512 7f74d55027313b2315c911e064af1bc0934d64b63db7d483c9373a2777a53b2116e44625403f99a91b33154accf31c57fdb6acfcb7a7e4960dbb89b605dd0c8a WHIRLPOOL 1efc0dea28ac9975028899208d647efbd7e8c32cd91b0c48478a3c497a2404f68b913a853fa36db8d1dea9fbbc13658e918214912b45751203df5bb3ad0c3060
|
||||||
DIST rarlinux-x64-5.5.0_beta4_p20170628.tar.gz 534501 SHA256 5efa3b24b9f4b5aff2538f13c4d6ecae766a54badeb06d12387cbbcc1ca85608 SHA512 630033f9a5201d53ecb8796651b89caf7351b09e37087e071fc14c4c683fd32404322e80a71f6f1e6e449f264c0209d8ce7ad554c37420dfb764f091188ced2e WHIRLPOOL 17904bffb07da1670d2fc0359c0dfc116330ce938cb6dd150e6d9608e89723875d05322e26f2a803946da2a7eaae0ae8c693750964b908061be405d1da3a68a3
|
DIST rarlinux-x64-5.5.0_beta4_p20170628.tar.gz 534501 SHA256 5efa3b24b9f4b5aff2538f13c4d6ecae766a54badeb06d12387cbbcc1ca85608 SHA512 630033f9a5201d53ecb8796651b89caf7351b09e37087e071fc14c4c683fd32404322e80a71f6f1e6e449f264c0209d8ce7ad554c37420dfb764f091188ced2e WHIRLPOOL 17904bffb07da1670d2fc0359c0dfc116330ce938cb6dd150e6d9608e89723875d05322e26f2a803946da2a7eaae0ae8c693750964b908061be405d1da3a68a3
|
||||||
DIST rarlinux-x64-5.5.0_beta5_p20170706.tar.gz 535846 SHA256 68f2dbae2b0fd714a5c9a73369af26c8a186f910c4c7d094e39c456543eabe3c SHA512 09ce316774b6a0a4a54cd2db5fd87f266d203cc97a893ba88ed9573df3a0e068408e0715267121a9434bea4be9c6187bfe51d114b086d4bb792f26644ae8ec86 WHIRLPOOL 751926132a81fba209898d197146ef57afd7d6e698af02fb755c8f5fc191ac02de2fe6a90e0c298413e6e0610a3c1579276115bab5762010488a650b2e374ea2
|
DIST rarlinux-x64-5.5.0_beta5_p20170706.tar.gz 535846 SHA256 68f2dbae2b0fd714a5c9a73369af26c8a186f910c4c7d094e39c456543eabe3c SHA512 09ce316774b6a0a4a54cd2db5fd87f266d203cc97a893ba88ed9573df3a0e068408e0715267121a9434bea4be9c6187bfe51d114b086d4bb792f26644ae8ec86 WHIRLPOOL 751926132a81fba209898d197146ef57afd7d6e698af02fb755c8f5fc191ac02de2fe6a90e0c298413e6e0610a3c1579276115bab5762010488a650b2e374ea2
|
||||||
|
DIST rarlinux-x64-5.5.0_beta6_p20170725.tar.gz 536054 SHA256 01e8146063319439df6efbda06b9a31e9bb8c9cebd3c1b61bada95d708f065f3 SHA512 9f6adaabe0e1f05778fa3d5265692c3b0af4216c08eea23b637d69dd24fbbb113aaa213105a9be26d7c4e4de43df60a45cbc630f78c520699d82807559b20671 WHIRLPOOL 6064181a986c8c695a8fe7aedd3104750556f67716c6b9d1a6a54bbe33188a2700af57659560307e63ff94e4006d5f77bbc65be23ad0a8ca1e883710f2182fbe
|
||||||
DIST winrar-x64-5.5.0_beta4_p20170628.exe 2212800 SHA256 bf4dcf7c42ecb9028a2106297ebd6739fb75194c262e1f0ea7823ceaceccc8c8 SHA512 5a452d5a4f96dc240b1a04d690ced1ed6395857e1eafce8bcb91a3fe1feb60a54376b36c1d4117e6660556947bda6cf550e9a495842bdba4d6029ddeb17116c1 WHIRLPOOL 5f91b1b9eb8a0563c969b09027ad7197cc0d5586f8cddae0b0ce44a1d45489ba3461792f639a86c7829f7437b0dc9f0e14019cb5029f854ac65ff51f111eb79a
|
DIST winrar-x64-5.5.0_beta4_p20170628.exe 2212800 SHA256 bf4dcf7c42ecb9028a2106297ebd6739fb75194c262e1f0ea7823ceaceccc8c8 SHA512 5a452d5a4f96dc240b1a04d690ced1ed6395857e1eafce8bcb91a3fe1feb60a54376b36c1d4117e6660556947bda6cf550e9a495842bdba4d6029ddeb17116c1 WHIRLPOOL 5f91b1b9eb8a0563c969b09027ad7197cc0d5586f8cddae0b0ce44a1d45489ba3461792f639a86c7829f7437b0dc9f0e14019cb5029f854ac65ff51f111eb79a
|
||||||
DIST winrar-x64-5.5.0_beta5_p20170706.exe 2215544 SHA256 3e566c006b4941318597f9e47c3b5161ee4e944cd12b4ec9a38622f96e1af0a8 SHA512 c64ca0b992245ab402872b44b037ba499e00d452dae695ad6b49bf6cb497b24154171b1b2bd8978c32c740d59c0da89fe0c1e56bb95714afe7ac529264371ab8 WHIRLPOOL 610acf4ebb67100a335bc7a70be2c69cf8a828df84a0ac90392451efd760e2e0f701a795993b43520763c5d1c9e0556426feabdebfb7841b589604b95256fa3b
|
DIST winrar-x64-5.5.0_beta5_p20170706.exe 2215544 SHA256 3e566c006b4941318597f9e47c3b5161ee4e944cd12b4ec9a38622f96e1af0a8 SHA512 c64ca0b992245ab402872b44b037ba499e00d452dae695ad6b49bf6cb497b24154171b1b2bd8978c32c740d59c0da89fe0c1e56bb95714afe7ac529264371ab8 WHIRLPOOL 610acf4ebb67100a335bc7a70be2c69cf8a828df84a0ac90392451efd760e2e0f701a795993b43520763c5d1c9e0556426feabdebfb7841b589604b95256fa3b
|
||||||
|
DIST winrar-x64-5.5.0_beta6_p20170725.exe 2217944 SHA256 49cfd01faf509a874d2d3a4c14bd1c0a27670e918a2eb00b6b75c5a35f37f5a9 SHA512 d0a777491018300e417da4acc0dd3998c7a7009c9f6b51f34d26d5cdb4b8dde09c06e3231ba44942deae4aeec5d8425b67bc93960fb65bcc41dfbdc02f41c88e WHIRLPOOL 81aeb87a24d366dede805baecf18ad37b7aa93fab05bcff51d6966e088e4f02b87b370f045e7eecdba3c79ed8bd91947b393cc79061d5e9a18d630a7f69cf475
|
||||||
|
@ -0,0 +1,109 @@
|
|||||||
|
# Copyright 1999-2017 Gentoo Foundation
|
||||||
|
# Distributed under the terms of the GNU General Public License v2
|
||||||
|
|
||||||
|
EAPI="6"
|
||||||
|
|
||||||
|
DESCRIPTION="RAR compressor/uncompressor"
|
||||||
|
HOMEPAGE="http://www.rarsoft.com/"
|
||||||
|
URI_x86="https://mirror.whissi.de/distfiles/rar/rarlinux-${PV}.tar.gz"
|
||||||
|
URI_amd64="https://mirror.whissi.de/distfiles/rar/rarlinux-x64-${PV}.tar.gz"
|
||||||
|
URI_w64="https://mirror.whissi.de/distfiles/rar/winrar-x64-${PV}.exe"
|
||||||
|
SRC_URI="x86? ( ${URI_x86} )
|
||||||
|
amd64? ( ${URI_amd64} )
|
||||||
|
all_sfx? (
|
||||||
|
${URI_x86}
|
||||||
|
${URI_amd64}
|
||||||
|
${URI_w64}
|
||||||
|
)"
|
||||||
|
|
||||||
|
LICENSE="RAR BSD BSD-2"
|
||||||
|
SLOT="0"
|
||||||
|
KEYWORDS="-* ~amd64 ~x86"
|
||||||
|
IUSE="all_sfx"
|
||||||
|
RESTRICT="mirror bindist"
|
||||||
|
|
||||||
|
DEPEND="all_sfx? ( app-arch/unrar )"
|
||||||
|
RDEPEND="sys-libs/glibc"
|
||||||
|
|
||||||
|
S="${WORKDIR}/${PN}"
|
||||||
|
|
||||||
|
QA_FLAGS_IGNORED="opt/rar/default.sfx
|
||||||
|
opt/rar/default-elf32.sfx
|
||||||
|
opt/rar/default-elf64.sfx
|
||||||
|
opt/rar/default-win32.sfx
|
||||||
|
opt/rar/default-win64.sfx
|
||||||
|
opt/rar/WinCon.SFX
|
||||||
|
opt/rar/WinCon64.SFX
|
||||||
|
opt/rar/Zip.SFX
|
||||||
|
opt/rar/Zip64.SFX
|
||||||
|
opt/rar/unrar
|
||||||
|
opt/rar/rar"
|
||||||
|
QA_PRESTRIPPED=${QA_FLAGS_IGNORED}
|
||||||
|
|
||||||
|
src_unpack() {
|
||||||
|
local _file
|
||||||
|
|
||||||
|
for _file in ${A}; do
|
||||||
|
if [[ "${_file}" == rarli* ]]; then
|
||||||
|
if [[ "${_file}" =~ x64 ]]; then
|
||||||
|
if ! use amd64; then
|
||||||
|
continue
|
||||||
|
fi
|
||||||
|
|
||||||
|
unpack "${_file}"
|
||||||
|
elif [[ ! "${_file}" =~ x64 ]]; then
|
||||||
|
if ! use x86; then
|
||||||
|
continue
|
||||||
|
fi
|
||||||
|
|
||||||
|
unpack "${_file}"
|
||||||
|
else
|
||||||
|
die "Unknown SRC file '${_file}'!"
|
||||||
|
fi
|
||||||
|
fi
|
||||||
|
done
|
||||||
|
|
||||||
|
rm -f "${S}"/license.txt
|
||||||
|
|
||||||
|
if use all_sfx ; then
|
||||||
|
mkdir sfx
|
||||||
|
cd sfx
|
||||||
|
for _file in ${A}; do
|
||||||
|
if [[ "${_file}" == rarli* ]]; then
|
||||||
|
unpack "${_file}"
|
||||||
|
if [[ "${_file}" =~ x64 ]]; then
|
||||||
|
mv rar/default.sfx default-elf64.sfx || die
|
||||||
|
else
|
||||||
|
mv rar/default.sfx default-elf32.sfx || die
|
||||||
|
fi
|
||||||
|
elif [[ "${_file}" == winrar* ]]; then
|
||||||
|
ln -s "${DISTDIR}"/${_file} w64.rar || die
|
||||||
|
unpack ./w64.rar
|
||||||
|
mv Default.SFX default-win32.sfx || die
|
||||||
|
mv Default64.SFX default-win64.sfx || die
|
||||||
|
else
|
||||||
|
die "Unknown SFX file '${_file}'!"
|
||||||
|
fi
|
||||||
|
done
|
||||||
|
fi
|
||||||
|
}
|
||||||
|
|
||||||
|
src_compile() { :; }
|
||||||
|
|
||||||
|
src_install() {
|
||||||
|
exeinto /opt/rar
|
||||||
|
doexe rar unrar || die
|
||||||
|
|
||||||
|
dodir /opt/bin
|
||||||
|
dosym ../rar/rar /opt/bin/rar || die
|
||||||
|
dosym ../rar/unrar /opt/bin/unrar || die
|
||||||
|
|
||||||
|
insinto /opt/rar
|
||||||
|
if use all_sfx ; then
|
||||||
|
doins "${WORKDIR}"/sfx/*.{sfx,SFX} || die
|
||||||
|
else
|
||||||
|
doins default.sfx || die
|
||||||
|
fi
|
||||||
|
doins rarfiles.lst || die
|
||||||
|
dodoc *.txt
|
||||||
|
}
|
@ -1,3 +1,4 @@
|
|||||||
DIST unrar-5.5.5.tar.gz 220377 SHA256 a4553839cb2f025d0d9c5633816a83a723e3938209f17620c8c15da06ed061ef SHA512 b0979641737e3ef18f6708cc19e335c312ac5c6e2a13206d5fed9a5564ac99042c45a842da95163e53c6415131a39a91e901aeb186016da2e3781164679a07ff WHIRLPOOL e22399e866fabeb6f0c1617ca6b8852cf1bd406c0e95e5480692fe33bed9a130dd678f93dde6401015928437b99949865a80b21774788fdb1c7a12e3175560f4
|
DIST unrar-5.5.5.tar.gz 220377 SHA256 a4553839cb2f025d0d9c5633816a83a723e3938209f17620c8c15da06ed061ef SHA512 b0979641737e3ef18f6708cc19e335c312ac5c6e2a13206d5fed9a5564ac99042c45a842da95163e53c6415131a39a91e901aeb186016da2e3781164679a07ff WHIRLPOOL e22399e866fabeb6f0c1617ca6b8852cf1bd406c0e95e5480692fe33bed9a130dd678f93dde6401015928437b99949865a80b21774788fdb1c7a12e3175560f4
|
||||||
DIST unrar-5.5.6.tar.gz 221099 SHA256 68a9d8f40c709b883bb15b21a9811907e56a07411d90aeaa992622ed9cf128c0 SHA512 591575ba573e7f1b658041595b8439c7f1f60d354bc2b0a6aa9d3be6340d4892b2752e8ce94a928cf0270a0e1c491ce3ee59b3c36167174c53cfd657b9c85837 WHIRLPOOL 5c43856c418fffccc1fe1202441b628a1491dc94873643044c9791947ebfeb21e281231c6ccacaa80df512d6f62cb9d0d1f555d53c1b7e2cae280e65ad8558d0
|
DIST unrar-5.5.6.tar.gz 221099 SHA256 68a9d8f40c709b883bb15b21a9811907e56a07411d90aeaa992622ed9cf128c0 SHA512 591575ba573e7f1b658041595b8439c7f1f60d354bc2b0a6aa9d3be6340d4892b2752e8ce94a928cf0270a0e1c491ce3ee59b3c36167174c53cfd657b9c85837 WHIRLPOOL 5c43856c418fffccc1fe1202441b628a1491dc94873643044c9791947ebfeb21e281231c6ccacaa80df512d6f62cb9d0d1f555d53c1b7e2cae280e65ad8558d0
|
||||||
|
DIST unrar-5.5.7.tar.gz 222293 SHA256 8aef0a0d91bf9c9ac48fab8a26049ac7ac49907e75a2dcbd511a4ba375322d8f SHA512 7dfad639df1f64db662a24b79fe77c7085096ad1d63de8f3e6ed01082334ac83e7bdf0572d2137e5fc11e261491da55b579b6fc50933a4cb3569c7fe972be5db WHIRLPOOL 94208650cc3e63fa5b121f3c2fe2d1c985a1d94589e4b57c13e2112b81c1ad959c4e5d149d4193b61cef98805ae1fecd88e80093ac0affd1b7769fc1e0121f99
|
||||||
DIST unrarsrc-5.4.5.tar.gz 226320 SHA256 e470c584332422893fb52e049f2cbd99e24dc6c6da971008b4e2ae4284f8796c SHA512 ba2abf11638b5ee026cb9e0c3576c94376a01ab3c5411b9bd0e8116d64879c81e76df16f98d850f0f0f5387dda046f38be64ddfb4fe57431cc4d97066d6e3c2f WHIRLPOOL c8e035ec183f41d8faf8345b49d2a4d20e21f9c6e27f14d7794389942df4954cd66ab4a5be2fdff6d369b514ae99d5d015f35a36143d686563b2a8efdfc77dce
|
DIST unrarsrc-5.4.5.tar.gz 226320 SHA256 e470c584332422893fb52e049f2cbd99e24dc6c6da971008b4e2ae4284f8796c SHA512 ba2abf11638b5ee026cb9e0c3576c94376a01ab3c5411b9bd0e8116d64879c81e76df16f98d850f0f0f5387dda046f38be64ddfb4fe57431cc4d97066d6e3c2f WHIRLPOOL c8e035ec183f41d8faf8345b49d2a4d20e21f9c6e27f14d7794389942df4954cd66ab4a5be2fdff6d369b514ae99d5d015f35a36143d686563b2a8efdfc77dce
|
||||||
|
@ -0,0 +1,65 @@
|
|||||||
|
# Copyright 1999-2017 Gentoo Foundation
|
||||||
|
# Distributed under the terms of the GNU General Public License v2
|
||||||
|
|
||||||
|
EAPI="5"
|
||||||
|
|
||||||
|
inherit eutils flag-o-matic multilib toolchain-funcs
|
||||||
|
|
||||||
|
MY_PN=${PN}src
|
||||||
|
|
||||||
|
DESCRIPTION="Uncompress rar files"
|
||||||
|
HOMEPAGE="http://www.rarlab.com/rar_add.htm"
|
||||||
|
SRC_URI="http://www.rarlab.com/rar/${MY_PN}-${PV}.tar.gz -> ${P}.tar.gz"
|
||||||
|
|
||||||
|
LICENSE="unRAR"
|
||||||
|
# subslot = soname version
|
||||||
|
SLOT="0/5"
|
||||||
|
KEYWORDS="~alpha ~amd64 ~arm ~arm64 ~hppa ~ia64 ~m68k ~mips ~ppc ~ppc64 ~s390 ~sh ~sparc ~x86 ~amd64-fbsd ~x86-fbsd ~amd64-linux ~arm-linux ~x86-linux ~ppc-macos ~x64-macos ~x86-macos ~sparc-solaris ~x86-solaris"
|
||||||
|
IUSE=""
|
||||||
|
|
||||||
|
RDEPEND="!<=app-arch/unrar-gpl-0.0.1_p20080417"
|
||||||
|
|
||||||
|
S=${WORKDIR}/unrar
|
||||||
|
|
||||||
|
src_prepare() {
|
||||||
|
epatch "${FILESDIR}"/${PN}-5.5.5-build.patch
|
||||||
|
epatch "${FILESDIR}"/${PN}-5.5.5-honor-flags.patch
|
||||||
|
epatch_user
|
||||||
|
|
||||||
|
local sed_args=( -e "/libunrar/s:.so:$(get_libname ${PV%.*.*}):" )
|
||||||
|
if [[ ${CHOST} == *-darwin* ]] ; then
|
||||||
|
sed_args+=( -e "s:-shared:-dynamiclib -install_name ${EPREFIX}/usr/$(get_libdir)/libunrar$(get_libname ${PV%.*.*}):" )
|
||||||
|
else
|
||||||
|
sed_args+=( -e "s:-shared:& -Wl,-soname -Wl,libunrar$(get_libname ${PV%.*.*}):" )
|
||||||
|
fi
|
||||||
|
sed -i "${sed_args[@]}" makefile || die
|
||||||
|
}
|
||||||
|
|
||||||
|
src_configure() {
|
||||||
|
mkdir -p build-{lib,bin}
|
||||||
|
printf 'VPATH = ..\ninclude ../makefile' > build-lib/Makefile || die
|
||||||
|
cp build-{lib,bin}/Makefile || die
|
||||||
|
}
|
||||||
|
|
||||||
|
src_compile() {
|
||||||
|
unrar_make() {
|
||||||
|
emake CXX="$(tc-getCXX)" CXXFLAGS="${CXXFLAGS}" STRIP=true "$@"
|
||||||
|
}
|
||||||
|
|
||||||
|
unrar_make CXXFLAGS+=" -fPIC" -C build-lib lib
|
||||||
|
ln -s libunrar$(get_libname ${PV%.*.*}) build-lib/libunrar$(get_libname) || die
|
||||||
|
ln -s libunrar$(get_libname ${PV%.*.*}) build-lib/libunrar$(get_libname ${PV}) || die
|
||||||
|
|
||||||
|
unrar_make -C build-bin
|
||||||
|
}
|
||||||
|
|
||||||
|
src_install() {
|
||||||
|
dobin build-bin/unrar
|
||||||
|
dodoc readme.txt
|
||||||
|
|
||||||
|
dolib.so build-lib/libunrar*
|
||||||
|
|
||||||
|
insinto /usr/include/libunrar${PV%.*.*}
|
||||||
|
doins *.hpp
|
||||||
|
dosym libunrar${PV%.*.*} /usr/include/libunrar
|
||||||
|
}
|
@ -1 +1,2 @@
|
|||||||
DIST 1.0-dev.oxt 186411 SHA256 dc07976e7ee03f556a0c2a0daaceca8fcccbaa823e6a9e31a8d709cb58666576 SHA512 164ac71523d688c4f32ca14b44c87a15d15eaad11e553c44e2ebc75e4d5ffa98b96663059a8d57b0c18556f5fb5c95d55a4b5c16e89b3b8c4f2116e2cdac0f1c WHIRLPOOL 99caf55085895ac81e9e9392d42ab99a252bd60346766c95f3cc7b15abd000d93a451d31f6a71a2cccd778897ecf5b75bb872bd51c21ad838d984044bca9be97
|
DIST 1.0-dev.oxt 186411 SHA256 dc07976e7ee03f556a0c2a0daaceca8fcccbaa823e6a9e31a8d709cb58666576 SHA512 164ac71523d688c4f32ca14b44c87a15d15eaad11e553c44e2ebc75e4d5ffa98b96663059a8d57b0c18556f5fb5c95d55a4b5c16e89b3b8c4f2116e2cdac0f1c WHIRLPOOL 99caf55085895ac81e9e9392d42ab99a252bd60346766c95f3cc7b15abd000d93a451d31f6a71a2cccd778897ecf5b75bb872bd51c21ad838d984044bca9be97
|
||||||
|
DIST myspell-eo-1.0.oxt 186407 SHA256 70d65bb07db99aaa1b0db50862057a712b454c8f0211c6a5353cdc48140eff91 SHA512 b5cf3a14672fb0e6b810e5b4d811f430b3c3cc38cf09a0083b7e26471597c6df055242349a2a239607621301f71527e8bf225dc03de727c5863e7b7b1c821824 WHIRLPOOL 64ded4ee18c3b9bb2e3796c16c71fa04e32303579e2a1c652b697a1281a1de35912317987da9cbabe791072eac44ee0f89b6dd18289039af6ec9d9002a51338a
|
||||||
|
@ -0,0 +1,34 @@
|
|||||||
|
# Copyright 1999-2017 Gentoo Foundation
|
||||||
|
# Distributed under the terms of the GNU General Public License v2
|
||||||
|
|
||||||
|
EAPI=6
|
||||||
|
|
||||||
|
MYSPELL_DICT=(
|
||||||
|
"eo_l3.aff"
|
||||||
|
"eo_l3.dic"
|
||||||
|
)
|
||||||
|
|
||||||
|
MYSPELL_HYPH=(
|
||||||
|
)
|
||||||
|
|
||||||
|
MYSPELL_THES=(
|
||||||
|
)
|
||||||
|
|
||||||
|
inherit myspell-r2
|
||||||
|
|
||||||
|
DESCRIPTION="Esperanto dictionaries for myspell/hunspell"
|
||||||
|
HOMEPAGE="http://nlp.fi.muni.cz/projekty/esperanto_spell_checker/"
|
||||||
|
SRC_URI="mirror://sourceforge/aoo-extensions/3377/1/${PV}-dev.oxt -> ${P}.oxt"
|
||||||
|
|
||||||
|
LICENSE="GPL-2 LGPL-3 MPL-1.1"
|
||||||
|
SLOT="0"
|
||||||
|
KEYWORDS="~alpha ~amd64 ~arm ~arm64 ~hppa ~ia64 ~mips ~ppc ~ppc64 ~sh ~sparc ~x86 ~amd64-fbsd ~x86-fbsd"
|
||||||
|
IUSE=""
|
||||||
|
|
||||||
|
src_prepare() {
|
||||||
|
default
|
||||||
|
|
||||||
|
# move the dicts for nicer name
|
||||||
|
mv literumilo.aff eo_l3.aff || die
|
||||||
|
mv literumilo.dic eo_l3.dic || die
|
||||||
|
}
|
@ -1,3 +1,4 @@
|
|||||||
DIST libvirt-3.2.0.tar.xz 14057340 SHA256 9481a083b567a07927f239553dd70b5c0d1bff5b9b4ec61be1899981c646209e SHA512 35a9db3d59a3817d15fd6a586a2a73860b3d8a2d2ff37dbea1b4045fe1514c3535fce2eeba0f09df2d0bb9072ed9f1078ca9bad61a37c586eb019ddad3f898c4 WHIRLPOOL 499eb2cbf1367c99c106a747c76087f6ed980cc057cdb10cefe50a8a823a294f67925c98b1baa6ac7e12dcc20c90145b9a0c1e0927772e3b4a046bb4414391a0
|
DIST libvirt-3.2.0.tar.xz 14057340 SHA256 9481a083b567a07927f239553dd70b5c0d1bff5b9b4ec61be1899981c646209e SHA512 35a9db3d59a3817d15fd6a586a2a73860b3d8a2d2ff37dbea1b4045fe1514c3535fce2eeba0f09df2d0bb9072ed9f1078ca9bad61a37c586eb019ddad3f898c4 WHIRLPOOL 499eb2cbf1367c99c106a747c76087f6ed980cc057cdb10cefe50a8a823a294f67925c98b1baa6ac7e12dcc20c90145b9a0c1e0927772e3b4a046bb4414391a0
|
||||||
DIST libvirt-3.3.0.tar.xz 14043384 SHA256 29e00984174e33cf2183b478382c017de26860452ffee17b73871051264ebb1b SHA512 69166ddd7d4b9ef3b1bf2466e781139ef9b4d224a64acc7b8e6fca8786d36482138a1fe7b7407c0fca3b3d012cb418d168671a3e65e428f023c16493b7718c2d WHIRLPOOL 1b2688f6b9a89608677070b5ce1fd2b2af115336126d4214071bc1abba25056d54dbbf16d6bdfab7582b252a833d3e53e51175d552d5c936b08973c0eed76643
|
DIST libvirt-3.3.0.tar.xz 14043384 SHA256 29e00984174e33cf2183b478382c017de26860452ffee17b73871051264ebb1b SHA512 69166ddd7d4b9ef3b1bf2466e781139ef9b4d224a64acc7b8e6fca8786d36482138a1fe7b7407c0fca3b3d012cb418d168671a3e65e428f023c16493b7718c2d WHIRLPOOL 1b2688f6b9a89608677070b5ce1fd2b2af115336126d4214071bc1abba25056d54dbbf16d6bdfab7582b252a833d3e53e51175d552d5c936b08973c0eed76643
|
||||||
DIST libvirt-3.4.0.tar.xz 14630904 SHA256 42186af6225904d2ada0b494fda4fa777fe5e662a9134686816e7919332c248d SHA512 41a3374e8a171827dfc11feb2ae8c1a9d889912257191b94111f53bbe0521d5bc73c824ea856e4cece257918b244120e9f44c800abe23d0296c85c18b5d14461 WHIRLPOOL 3b4b9ad35f590748fbc63595fab86671f66674d2c40fa8e02860265a39be5b48ed9c66c14ac235b36d29d833475aebbbf57f691e53ac2bd324dacb16507793bf
|
DIST libvirt-3.4.0.tar.xz 14630904 SHA256 42186af6225904d2ada0b494fda4fa777fe5e662a9134686816e7919332c248d SHA512 41a3374e8a171827dfc11feb2ae8c1a9d889912257191b94111f53bbe0521d5bc73c824ea856e4cece257918b244120e9f44c800abe23d0296c85c18b5d14461 WHIRLPOOL 3b4b9ad35f590748fbc63595fab86671f66674d2c40fa8e02860265a39be5b48ed9c66c14ac235b36d29d833475aebbbf57f691e53ac2bd324dacb16507793bf
|
||||||
|
DIST libvirt-3.5.0.tar.xz 14695760 SHA256 2963bae30d41411a2a8184de6a69cc3bd4dba14d2824b67906263dc35b27b516 SHA512 319d1573e55df0cbfd0808d658fb4ef5484d8381db6fe348b36a650ea60b62b7146882e616e9494109d44c8e57ed956137fb7b51c3895d96bd19e9aee6a3e82c WHIRLPOOL 90dc243e8fb8e619af319f2a8469dc98109a6200bee94f09508c22a75e90f82edf278796cf53ca38a7649e5ad1f5f4c0a258395624f830c1a42538519200637a
|
||||||
|
@ -0,0 +1,382 @@
|
|||||||
|
# Copyright 1999-2017 Gentoo Foundation
|
||||||
|
# Distributed under the terms of the GNU General Public License v2
|
||||||
|
|
||||||
|
EAPI=6
|
||||||
|
|
||||||
|
inherit autotools eutils user linux-info systemd readme.gentoo-r1
|
||||||
|
|
||||||
|
if [[ ${PV} = *9999* ]]; then
|
||||||
|
inherit git-r3
|
||||||
|
EGIT_REPO_URI="git://libvirt.org/libvirt.git"
|
||||||
|
SRC_URI=""
|
||||||
|
KEYWORDS=""
|
||||||
|
SLOT="0"
|
||||||
|
else
|
||||||
|
# Versions with 4 numbers are stable updates:
|
||||||
|
if [[ ${PV} =~ ^[0-9]+(\.[0-9]+){3} ]]; then
|
||||||
|
SRC_URI="http://libvirt.org/sources/stable_updates/${P}.tar.xz"
|
||||||
|
else
|
||||||
|
SRC_URI="http://libvirt.org/sources/${P}.tar.xz"
|
||||||
|
fi
|
||||||
|
KEYWORDS="~amd64 ~arm64 ~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 firewalld fuse glusterfs iscsi +libvirtd lvm
|
||||||
|
libssh lxc +macvtap nfs nls numa openvz parted pcap phyp policykit
|
||||||
|
+qemu rbd sasl selinux +udev uml +vepa virtualbox virt-network
|
||||||
|
wireshark-plugins xen zeroconf zfs elibc_glibc
|
||||||
|
"
|
||||||
|
|
||||||
|
REQUIRED_USE="
|
||||||
|
firewalld? ( virt-network )
|
||||||
|
libvirtd? ( || ( lxc openvz qemu uml virtualbox xen ) )
|
||||||
|
lxc? ( caps libvirtd )
|
||||||
|
openvz? ( libvirtd )
|
||||||
|
policykit? ( dbus )
|
||||||
|
qemu? ( libvirtd )
|
||||||
|
uml? ( 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="
|
||||||
|
app-misc/scrub
|
||||||
|
dev-libs/libgcrypt:0
|
||||||
|
dev-libs/libnl:3
|
||||||
|
>=dev-libs/libxml2-2.7.6
|
||||||
|
|| ( >=net-analyzer/netcat6-1.0-r2 >=net-analyzer/openbsd-netcat-1.105-r1 )
|
||||||
|
>=net-libs/gnutls-1.0.25:0=
|
||||||
|
net-libs/libssh2
|
||||||
|
>=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 )
|
||||||
|
elibc_glibc? ( sys-libs/glibc[rpc(+)] )
|
||||||
|
firewalld? ( net-firewall/firewalld )
|
||||||
|
fuse? ( >=sys-fs/fuse-2.8.6:= )
|
||||||
|
glusterfs? ( >=sys-cluster/glusterfs-3.4.1 )
|
||||||
|
iscsi? ( sys-block/open-iscsi )
|
||||||
|
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
|
||||||
|
)
|
||||||
|
openvz? ( sys-kernel/openvz-sources:* )
|
||||||
|
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-0.13.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
|
||||||
|
app-emulation/xen-tools:=
|
||||||
|
)
|
||||||
|
udev? (
|
||||||
|
virtual/udev
|
||||||
|
>=x11-libs/libpciaccess-0.10.9
|
||||||
|
)
|
||||||
|
zeroconf? ( >=net-dns/avahi-0.6[dbus] )
|
||||||
|
zfs? ( sys-fs/zfs )"
|
||||||
|
|
||||||
|
DEPEND="${RDEPEND}
|
||||||
|
app-text/xhtml1
|
||||||
|
dev-lang/perl
|
||||||
|
dev-libs/libxslt
|
||||||
|
dev-perl/XML-XPath
|
||||||
|
virtual/pkgconfig"
|
||||||
|
|
||||||
|
PATCHES=(
|
||||||
|
"${FILESDIR}"/${PN}-1.3.0-do_not_use_sysconf.patch
|
||||||
|
"${FILESDIR}"/${PN}-1.2.16-fix_paths_in_libvirt-guests_sh.patch
|
||||||
|
"${FILESDIR}"/${PN}-3.0.0-fix_paths_for_apparmor.patch
|
||||||
|
"${FILESDIR}"/${PN}-1.3.4-glibc-2.23.patch
|
||||||
|
"${FILESDIR}"/${PN}-3.1.0-musl-fix-includes.patch # bug #609488
|
||||||
|
)
|
||||||
|
|
||||||
|
pkg_setup() {
|
||||||
|
if use qemu; then
|
||||||
|
enewgroup qemu 77
|
||||||
|
enewuser qemu 77 -1 -1 "qemu,kvm"
|
||||||
|
fi
|
||||||
|
|
||||||
|
use policykit && enewgroup libvirt
|
||||||
|
|
||||||
|
# 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"
|
||||||
|
# Bandwidth Limiting Support
|
||||||
|
use virt-network && CONFIG_CHECK+="
|
||||||
|
~BRIDGE_EBT_T_NAT
|
||||||
|
~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
|
||||||
|
|
||||||
|
if [[ ${PV} = *9999* ]]; then
|
||||||
|
# git checkouts require bootstrapping to create the configure script.
|
||||||
|
# Additionally the submodules must be cloned to the right locations
|
||||||
|
# bug #377279
|
||||||
|
./bootstrap || die "bootstrap failed"
|
||||||
|
(
|
||||||
|
git submodule status | sed 's/^[ +-]//;s/ .*//'
|
||||||
|
git hash-object bootstrap.conf
|
||||||
|
) >.git-module-status
|
||||||
|
fi
|
||||||
|
|
||||||
|
# Tweak the init script:
|
||||||
|
cp "${FILESDIR}/libvirtd.init-r16" "${S}/libvirtd.init" || die
|
||||||
|
sed -e "s/USE_FLAG_FIREWALLD/$(usex firewalld 'need firewalld' '')/" \
|
||||||
|
-e "s/USE_FLAG_AVAHI/$(usex zeroconf 'use avahi-daemon' '')/" \
|
||||||
|
-e "s/USE_FLAG_ISCSI/$(usex iscsi 'use iscsid' '')/" \
|
||||||
|
-e "s/USE_FLAG_RBD/$(usex rbd 'use ceph' '')/" \
|
||||||
|
-i "${S}/libvirtd.init" || die "sed failed"
|
||||||
|
|
||||||
|
eautoreconf
|
||||||
|
}
|
||||||
|
|
||||||
|
src_configure() {
|
||||||
|
local myeconfargs=(
|
||||||
|
$(use_with apparmor)
|
||||||
|
$(use_with apparmor apparmor-profiles)
|
||||||
|
$(use_with audit)
|
||||||
|
$(use_with caps capng)
|
||||||
|
$(use_with dbus)
|
||||||
|
$(use_with firewalld)
|
||||||
|
$(use_with fuse)
|
||||||
|
$(use_with glusterfs)
|
||||||
|
$(use_with glusterfs storage-gluster)
|
||||||
|
$(use_with iscsi storage-iscsi)
|
||||||
|
$(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 phyp)
|
||||||
|
$(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 uml)
|
||||||
|
$(use_with vepa virtualport)
|
||||||
|
$(use_with virt-network network)
|
||||||
|
$(use_with wireshark-plugins wireshark-dissector)
|
||||||
|
$(use_with xen)
|
||||||
|
$(use_with xen xen-inotify)
|
||||||
|
$(use_with xen libxl)
|
||||||
|
$(use_with zeroconf avahi)
|
||||||
|
$(use_with zfs storage-zfs)
|
||||||
|
|
||||||
|
--without-hal
|
||||||
|
--without-netcf
|
||||||
|
--without-sanlock
|
||||||
|
--without-xenapi
|
||||||
|
|
||||||
|
--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
|
||||||
|
|
||||||
|
--with-html-subdir=${PF}/html
|
||||||
|
--localstatedir=/var
|
||||||
|
)
|
||||||
|
|
||||||
|
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[@]}"
|
||||||
|
|
||||||
|
if [[ ${PV} = *9999* ]]; then
|
||||||
|
# Restore gnulib's config.sub and config.guess
|
||||||
|
# bug #377279
|
||||||
|
(cd .gnulib && git reset --hard > /dev/null)
|
||||||
|
fi
|
||||||
|
}
|
||||||
|
|
||||||
|
src_test() {
|
||||||
|
cd "${BUILD_DIR}"
|
||||||
|
|
||||||
|
# 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 || die "tests failed"
|
||||||
|
}
|
||||||
|
|
||||||
|
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/cache
|
||||||
|
rm -rf "${D}"/var/run
|
||||||
|
rm -rf "${D}"/var/log
|
||||||
|
|
||||||
|
use libvirtd || return 0
|
||||||
|
# From here, only libvirtd-related instructions, be warned!
|
||||||
|
|
||||||
|
systemd_install_serviced \
|
||||||
|
"${FILESDIR}"/libvirtd.service.conf libvirtd.service
|
||||||
|
|
||||||
|
systemd_newtmpfilesd "${FILESDIR}"/libvirtd.tmpfiles.conf libvirtd.conf
|
||||||
|
|
||||||
|
newinitd "${S}/libvirtd.init" libvirtd || die
|
||||||
|
newinitd "${FILESDIR}/libvirt-guests.init-r2" libvirt-guests || die
|
||||||
|
newinitd "${FILESDIR}/virtlockd.init-r1" virtlockd || die
|
||||||
|
newinitd "${FILESDIR}/virtlogd.init-r1" virtlogd || die
|
||||||
|
|
||||||
|
newconfd "${FILESDIR}/libvirtd.confd-r5" libvirtd || die
|
||||||
|
newconfd "${FILESDIR}/libvirt-guests.confd" libvirt-guests || die
|
||||||
|
|
||||||
|
DOC_CONTENTS=$(<"${FILESDIR}/README.gentoo-r2")
|
||||||
|
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
|
||||||
|
}
|
@ -0,0 +1,199 @@
|
|||||||
|
# Copyright 1999-2017 Gentoo Foundation
|
||||||
|
# Distributed under the terms of the GNU General Public License v2
|
||||||
|
|
||||||
|
EAPI="6"
|
||||||
|
|
||||||
|
PYTHON_COMPAT=( python{3_4,3_5} )
|
||||||
|
DISTUTILS_OPTIONAL=1
|
||||||
|
|
||||||
|
inherit autotools bash-completion-r1 distutils-r1 linux-info versionator flag-o-matic systemd
|
||||||
|
|
||||||
|
DESCRIPTION="LinuX Containers userspace utilities"
|
||||||
|
HOMEPAGE="https://linuxcontainers.org/"
|
||||||
|
SRC_URI="https://linuxcontainers.org/downloads/lxc/${P}.tar.gz"
|
||||||
|
|
||||||
|
KEYWORDS="~amd64 ~arm ~arm64"
|
||||||
|
|
||||||
|
LICENSE="LGPL-3"
|
||||||
|
SLOT="0"
|
||||||
|
IUSE="cgmanager doc examples lua python seccomp"
|
||||||
|
|
||||||
|
RDEPEND="net-libs/gnutls
|
||||||
|
sys-libs/libcap
|
||||||
|
cgmanager? ( app-admin/cgmanager )
|
||||||
|
lua? ( >=dev-lang/lua-5.1:= )
|
||||||
|
python? ( ${PYTHON_DEPS} )
|
||||||
|
seccomp? ( sys-libs/libseccomp )"
|
||||||
|
|
||||||
|
DEPEND="${RDEPEND}
|
||||||
|
doc? ( app-text/docbook-sgml-utils )
|
||||||
|
>=sys-kernel/linux-headers-3.2"
|
||||||
|
|
||||||
|
RDEPEND="${RDEPEND}
|
||||||
|
sys-process/criu
|
||||||
|
sys-apps/util-linux
|
||||||
|
app-misc/pax-utils
|
||||||
|
virtual/awk"
|
||||||
|
|
||||||
|
CONFIG_CHECK="~CGROUPS ~CGROUP_DEVICE
|
||||||
|
~CPUSETS ~CGROUP_CPUACCT
|
||||||
|
~CGROUP_SCHED
|
||||||
|
|
||||||
|
~NAMESPACES
|
||||||
|
~IPC_NS ~USER_NS ~PID_NS
|
||||||
|
|
||||||
|
~NETLINK_DIAG ~PACKET_DIAG
|
||||||
|
~INET_UDP_DIAG ~INET_TCP_DIAG
|
||||||
|
~UNIX_DIAG ~CHECKPOINT_RESTORE
|
||||||
|
|
||||||
|
~CGROUP_FREEZER
|
||||||
|
~UTS_NS ~NET_NS
|
||||||
|
~VETH ~MACVLAN
|
||||||
|
|
||||||
|
~POSIX_MQUEUE
|
||||||
|
~!NETPRIO_CGROUP
|
||||||
|
|
||||||
|
~!GRKERNSEC_CHROOT_MOUNT
|
||||||
|
~!GRKERNSEC_CHROOT_DOUBLE
|
||||||
|
~!GRKERNSEC_CHROOT_PIVOT
|
||||||
|
~!GRKERNSEC_CHROOT_CHMOD
|
||||||
|
~!GRKERNSEC_CHROOT_CAPS
|
||||||
|
~!GRKERNSEC_PROC
|
||||||
|
~!GRKERNSEC_SYSFS_RESTRICT
|
||||||
|
"
|
||||||
|
|
||||||
|
ERROR_DEVPTS_MULTIPLE_INSTANCES="CONFIG_DEVPTS_MULTIPLE_INSTANCES: needed for pts inside container"
|
||||||
|
|
||||||
|
ERROR_CGROUP_FREEZER="CONFIG_CGROUP_FREEZER: needed to freeze containers"
|
||||||
|
|
||||||
|
ERROR_UTS_NS="CONFIG_UTS_NS: needed to unshare hostnames and uname info"
|
||||||
|
ERROR_NET_NS="CONFIG_NET_NS: needed for unshared network"
|
||||||
|
|
||||||
|
ERROR_VETH="CONFIG_VETH: needed for internal (host-to-container) networking"
|
||||||
|
ERROR_MACVLAN="CONFIG_MACVLAN: needed for internal (inter-container) networking"
|
||||||
|
|
||||||
|
ERROR_NETLINK_DIAG="CONFIG_NETLINK_DIAG: needed for lxc-checkpoint"
|
||||||
|
ERROR_PACKET_DIAG="CONFIG_PACKET_DIAG: needed for lxc-checkpoint"
|
||||||
|
ERROR_INET_UDP_DIAG="CONFIG_INET_UDP_DIAG: needed for lxc-checkpoint"
|
||||||
|
ERROR_INET_TCP_DIAG="CONFIG_INET_TCP_DIAG: needed for lxc-checkpoint"
|
||||||
|
ERROR_UNIX_DIAG="CONFIG_UNIX_DIAG: needed for lxc-checkpoint"
|
||||||
|
ERROR_CHECKPOINT_RESTORE="CONFIG_CHECKPOINT_RESTORE: needed for lxc-checkpoint"
|
||||||
|
|
||||||
|
ERROR_POSIX_MQUEUE="CONFIG_POSIX_MQUEUE: needed for lxc-execute command"
|
||||||
|
|
||||||
|
ERROR_NETPRIO_CGROUP="CONFIG_NETPRIO_CGROUP: as of kernel 3.3 and lxc 0.8.0_rc1 this causes LXCs to fail booting."
|
||||||
|
|
||||||
|
ERROR_GRKERNSEC_CHROOT_MOUNT="CONFIG_GRKERNSEC_CHROOT_MOUNT: some GRSEC features make LXC unusable see postinst notes"
|
||||||
|
ERROR_GRKERNSEC_CHROOT_DOUBLE="CONFIG_GRKERNSEC_CHROOT_DOUBLE: some GRSEC features make LXC unusable see postinst notes"
|
||||||
|
ERROR_GRKERNSEC_CHROOT_PIVOT="CONFIG_GRKERNSEC_CHROOT_PIVOT: some GRSEC features make LXC unusable see postinst notes"
|
||||||
|
ERROR_GRKERNSEC_CHROOT_CHMOD="CONFIG_GRKERNSEC_CHROOT_CHMOD: some GRSEC features make LXC unusable see postinst notes"
|
||||||
|
ERROR_GRKERNSEC_CHROOT_CAPS="CONFIG_GRKERNSEC_CHROOT_CAPS: some GRSEC features make LXC unusable see postinst notes"
|
||||||
|
ERROR_GRKERNSEC_PROC="CONFIG_GRKERNSEC_PROC: this GRSEC feature is incompatible with unprivileged containers"
|
||||||
|
ERROR_GRKERNSEC_SYSFS_RESTRICT="CONFIG_GRKERNSEC_SYSFS_RESTRICT: this GRSEC feature is incompatible with unprivileged containers"
|
||||||
|
|
||||||
|
DOCS=(AUTHORS CONTRIBUTING MAINTAINERS NEWS README doc/FAQ.txt)
|
||||||
|
|
||||||
|
REQUIRED_USE="python? ( ${PYTHON_REQUIRED_USE} )"
|
||||||
|
|
||||||
|
pkg_setup() {
|
||||||
|
kernel_is -lt 4 7 && CONFIG_CHECK="${CONFIG_CHECK} ~DEVPTS_MULTIPLE_INSTANCES"
|
||||||
|
linux-info_pkg_setup
|
||||||
|
}
|
||||||
|
|
||||||
|
src_prepare() {
|
||||||
|
eapply "${FILESDIR}"/${PN}-2.0.6-bash-completion.patch
|
||||||
|
#558854
|
||||||
|
eapply "${FILESDIR}"/${PN}-2.0.5-omit-sysconfig.patch
|
||||||
|
eapply_user
|
||||||
|
eautoreconf
|
||||||
|
}
|
||||||
|
|
||||||
|
src_configure() {
|
||||||
|
append-flags -fno-strict-aliasing
|
||||||
|
|
||||||
|
if use python; then
|
||||||
|
#541932
|
||||||
|
python_setup "python3*"
|
||||||
|
export PKG_CONFIG_PATH="${T}/${EPYTHON}/pkgconfig:${PKG_CONFIG_PATH}"
|
||||||
|
fi
|
||||||
|
|
||||||
|
# I am not sure about the --with-rootfs-path
|
||||||
|
# /var/lib/lxc is probably more appropriate than
|
||||||
|
# /usr/lib/lxc.
|
||||||
|
# Note by holgersson: Why is apparmor disabled?
|
||||||
|
econf \
|
||||||
|
--localstatedir=/var \
|
||||||
|
--bindir=/usr/bin \
|
||||||
|
--sbindir=/usr/bin \
|
||||||
|
--with-config-path=/var/lib/lxc \
|
||||||
|
--with-rootfs-path=/var/lib/lxc/rootfs \
|
||||||
|
--with-distro=gentoo \
|
||||||
|
--with-runtime-path=/run \
|
||||||
|
--disable-apparmor \
|
||||||
|
--disable-werror \
|
||||||
|
$(use_enable cgmanager) \
|
||||||
|
$(use_enable doc) \
|
||||||
|
$(use_enable examples) \
|
||||||
|
$(use_enable lua) \
|
||||||
|
$(use_enable python) \
|
||||||
|
$(use_enable seccomp)
|
||||||
|
}
|
||||||
|
|
||||||
|
python_compile() {
|
||||||
|
distutils-r1_python_compile build_ext -I ../ -L ../${PN}
|
||||||
|
}
|
||||||
|
|
||||||
|
src_compile() {
|
||||||
|
default
|
||||||
|
|
||||||
|
if use python; then
|
||||||
|
pushd "${S}/src/python-${PN}" > /dev/null
|
||||||
|
distutils-r1_src_compile
|
||||||
|
popd > /dev/null
|
||||||
|
fi
|
||||||
|
}
|
||||||
|
|
||||||
|
src_install() {
|
||||||
|
default
|
||||||
|
|
||||||
|
mv "${ED}"/usr/share/bash-completion/completions/${PN} "${ED}"/$(get_bashcompdir)/${PN}-start || die
|
||||||
|
# start-ephemeral is no longer a command but removing it here
|
||||||
|
# generates QA warnings (still in upstream completion script)
|
||||||
|
bashcomp_alias ${PN}-start \
|
||||||
|
${PN}-{attach,cgroup,copy,console,create,destroy,device,execute,freeze,info,monitor,snapshot,start-ephemeral,stop,unfreeze,wait}
|
||||||
|
|
||||||
|
if use python; then
|
||||||
|
pushd "${S}/src/python-lxc" > /dev/null
|
||||||
|
# Unset DOCS. This has been handled by the default target
|
||||||
|
unset DOCS
|
||||||
|
distutils-r1_src_install
|
||||||
|
popd > /dev/null
|
||||||
|
fi
|
||||||
|
|
||||||
|
keepdir /etc/lxc /var/lib/lxc/rootfs /var/log/lxc
|
||||||
|
|
||||||
|
find "${D}" -name '*.la' -delete
|
||||||
|
|
||||||
|
# Gentoo-specific additions!
|
||||||
|
newinitd "${FILESDIR}/${PN}.initd.5" ${PN}
|
||||||
|
|
||||||
|
# Remember to compare our systemd unit file with the upstream one
|
||||||
|
# config/init/systemd/lxc.service.in
|
||||||
|
systemd_newunit "${FILESDIR}"/${PN}_at.service.4 "lxc@.service"
|
||||||
|
}
|
||||||
|
|
||||||
|
pkg_postinst() {
|
||||||
|
elog ""
|
||||||
|
elog "Starting from version ${PN}-1.1.0-r3, the default lxc path has been"
|
||||||
|
elog "moved from /etc/lxc to /var/lib/lxc. If you still want to use /etc/lxc"
|
||||||
|
elog "please add the following to your /etc/lxc/default.conf"
|
||||||
|
elog "lxc.lxcpath = /etc/lxc"
|
||||||
|
elog ""
|
||||||
|
elog "There is an init script provided with the package now; no documentation"
|
||||||
|
elog "is currently available though, so please check out /etc/init.d/lxc ."
|
||||||
|
elog "You _should_ only need to symlink it to /etc/init.d/lxc.configname"
|
||||||
|
elog "to start the container defined into /etc/lxc/configname.conf ."
|
||||||
|
elog "For further information about LXC development see"
|
||||||
|
elog "http://blog.flameeyes.eu/tag/lxc" # remove once proper doc is available
|
||||||
|
elog ""
|
||||||
|
}
|
@ -1,2 +1,3 @@
|
|||||||
DIST nemu-1.1.0.tar.gz 52456 SHA256 da9df77ab2579890b2513ac78bac1a3bff3789d1fee326b31acd77a94c59f4dd SHA512 d0eb1b0df61f417fe25295c4f2d0c54d8f11153f03afd8e2fb5f59122558f1e5d1021d73b0b6a4e13dc80c4eabb8a20eabccf472ff4d5c82f27eefa83a5c773d WHIRLPOOL 91a775f67fc197b840a9f9d047b6144e0d109ed4acfd130f08fc5bc2d1f9827e907f2664ec5ef773717fcaa1e111d3ec78cd6e5b6ea2e781ee27242ae771572c
|
DIST nemu-1.1.0.tar.gz 52456 SHA256 da9df77ab2579890b2513ac78bac1a3bff3789d1fee326b31acd77a94c59f4dd SHA512 d0eb1b0df61f417fe25295c4f2d0c54d8f11153f03afd8e2fb5f59122558f1e5d1021d73b0b6a4e13dc80c4eabb8a20eabccf472ff4d5c82f27eefa83a5c773d WHIRLPOOL 91a775f67fc197b840a9f9d047b6144e0d109ed4acfd130f08fc5bc2d1f9827e907f2664ec5ef773717fcaa1e111d3ec78cd6e5b6ea2e781ee27242ae771572c
|
||||||
DIST nemu-1.2.0.tar.gz 61953 SHA256 d60e2e9d58d5448718be6966aa08c0e00be7fd9578a4684ff8c56011e0a0b2b3 SHA512 a91c31c4161369d42cb1b9e66c312db760b899c5f444a4d1d22cda39036a14b1a2c83e6fee5470282e13555771ce6704258da0ce6f76ae10343bb5f581eab514 WHIRLPOOL 69bc477b991a980e791878084199fc5d4988769604b6ebd03d4f707d4eb819d3cdd6728cc498714a82f4647c36babb21f0f3191e7bd568e26b5cc5173fd377dd
|
DIST nemu-1.2.0.tar.gz 61953 SHA256 d60e2e9d58d5448718be6966aa08c0e00be7fd9578a4684ff8c56011e0a0b2b3 SHA512 a91c31c4161369d42cb1b9e66c312db760b899c5f444a4d1d22cda39036a14b1a2c83e6fee5470282e13555771ce6704258da0ce6f76ae10343bb5f581eab514 WHIRLPOOL 69bc477b991a980e791878084199fc5d4988769604b6ebd03d4f707d4eb819d3cdd6728cc498714a82f4647c36babb21f0f3191e7bd568e26b5cc5173fd377dd
|
||||||
|
DIST nemu-1.3.0.tar.gz 70769 SHA256 470be541b3251430d8e25dc242a7e8a8b2919661d537bd7c201c587e61cea78a SHA512 0ca74a3d0ef1f8032d74cecef71518c18b839dcab5deb2ec221aa47159bf40345517d1b8ec80bf1ff268b9b7dbcd90301ad3594583ddf75d517a23545db23c26 WHIRLPOOL 306af1ce20e80baf717f29d22064e1aaeb35155ccacd7f0b7aed7183ddd21b5b846bd8f45e3171ffd156bdaef80ccf115cd9e136e6431b0b3ad57996e9dcca5b
|
||||||
|
@ -0,0 +1,42 @@
|
|||||||
|
# Copyright 1999-2017 Gentoo Foundation
|
||||||
|
# Distributed under the terms of the GNU General Public License v2
|
||||||
|
|
||||||
|
EAPI=6
|
||||||
|
|
||||||
|
inherit cmake-utils
|
||||||
|
|
||||||
|
DESCRIPTION="ncurses interface for QEMU"
|
||||||
|
HOMEPAGE="https://unixdev.ru/nemu"
|
||||||
|
SRC_URI="http://unixdev.ru/src/${P}.tar.gz"
|
||||||
|
|
||||||
|
LICENSE="BSD-2"
|
||||||
|
SLOT="0"
|
||||||
|
KEYWORDS="~amd64 ~x86"
|
||||||
|
IUSE="+vnc debug"
|
||||||
|
|
||||||
|
RDEPEND="
|
||||||
|
virtual/udev
|
||||||
|
virtual/libusb:1=
|
||||||
|
dev-db/sqlite:3=
|
||||||
|
sys-libs/ncurses:0=[unicode]
|
||||||
|
app-emulation/qemu[vnc]
|
||||||
|
vnc? ( net-misc/tigervnc )"
|
||||||
|
|
||||||
|
DEPEND="
|
||||||
|
${RDEPEND}
|
||||||
|
sys-devel/gettext"
|
||||||
|
|
||||||
|
src_configure() {
|
||||||
|
local mycmakeargs=(
|
||||||
|
-DNM_WITH_VNC_CLIENT=$(usex vnc)
|
||||||
|
-DNM_DEBUG=$(usex debug)
|
||||||
|
)
|
||||||
|
cmake-utils_src_configure
|
||||||
|
}
|
||||||
|
|
||||||
|
pkg_postinst() {
|
||||||
|
elog "Old database is not supported (nEMU versions < 1.0.0)."
|
||||||
|
elog "You will need to delete current database."
|
||||||
|
elog "If upgraded from 1.0.0, execute script:"
|
||||||
|
elog "/usr/share/nemu/scripts/upgrade_db.sh"
|
||||||
|
}
|
@ -1,32 +0,0 @@
|
|||||||
http://bugs.gentoo.org/597108
|
|
||||||
https://lists.gnu.org/archive/html/qemu-devel/2016-10/msg02577.html
|
|
||||||
|
|
||||||
From: Prasad J Pandit <address@hidden>
|
|
||||||
|
|
||||||
The JAZZ RC4030 chipset emulator has a periodic timer and
|
|
||||||
associated interval reload register. The reload value is used
|
|
||||||
as divider when computing timer's next tick value. If reload
|
|
||||||
value is large, it could lead to divide by zero error. Limit
|
|
||||||
the interval reload value to avoid it.
|
|
||||||
|
|
||||||
Reported-by: Huawei PSIRT <address@hidden>
|
|
||||||
Signed-off-by: Prasad J Pandit <address@hidden>
|
|
||||||
---
|
|
||||||
hw/dma/rc4030.c | 2 +-
|
|
||||||
1 file changed, 1 insertion(+), 1 deletion(-)
|
|
||||||
|
|
||||||
diff --git a/hw/dma/rc4030.c b/hw/dma/rc4030.c
|
|
||||||
index 2f2576f..c1b4997 100644
|
|
||||||
--- a/hw/dma/rc4030.c
|
|
||||||
+++ b/hw/dma/rc4030.c
|
|
||||||
@@ -460,7 +460,7 @@ static void rc4030_write(void *opaque, hwaddr addr, uint64_t data,
|
|
||||||
break;
|
|
||||||
/* Interval timer reload */
|
|
||||||
case 0x0228:
|
|
||||||
- s->itr = val;
|
|
||||||
+ s->itr = val & 0x01FF;
|
|
||||||
qemu_irq_lower(s->timer_irq);
|
|
||||||
set_next_tick(s);
|
|
||||||
break;
|
|
||||||
--
|
|
||||||
2.5.5
|
|
@ -1,40 +0,0 @@
|
|||||||
https://lists.gnu.org/archive/html/qemu-devel/2016-12/msg01903.html
|
|
||||||
https://bugs.gentoo.org/603444
|
|
||||||
|
|
||||||
From: P J P
|
|
||||||
Subject: [Qemu-devel] [PATCH] display: virtio-gpu-3d: check virgl capabilities max_size
|
|
||||||
Date: Wed, 14 Dec 2016 12:31:56 +0530
|
|
||||||
From: Prasad J Pandit <address@hidden>
|
|
||||||
|
|
||||||
Virtio GPU device while processing 'VIRTIO_GPU_CMD_GET_CAPSET'
|
|
||||||
command, retrieves the maximum capabilities size to fill in the
|
|
||||||
response object. It continues to fill in capabilities even if
|
|
||||||
retrieved 'max_size' is zero(0), thus resulting in OOB access.
|
|
||||||
Add check to avoid it.
|
|
||||||
|
|
||||||
Reported-by: Zhenhao Hong <address@hidden>
|
|
||||||
Signed-off-by: Prasad J Pandit <address@hidden>
|
|
||||||
---
|
|
||||||
hw/display/virtio-gpu-3d.c | 6 +++++-
|
|
||||||
1 file changed, 5 insertions(+), 1 deletion(-)
|
|
||||||
|
|
||||||
diff --git a/hw/display/virtio-gpu-3d.c b/hw/display/virtio-gpu-3d.c
|
|
||||||
index 758d33a..6ceeba3 100644
|
|
||||||
--- a/hw/display/virtio-gpu-3d.c
|
|
||||||
+++ b/hw/display/virtio-gpu-3d.c
|
|
||||||
@@ -370,8 +370,12 @@ static void virgl_cmd_get_capset(VirtIOGPU *g,
|
|
||||||
|
|
||||||
virgl_renderer_get_cap_set(gc.capset_id, &max_ver,
|
|
||||||
&max_size);
|
|
||||||
+ if (!max_size) {
|
|
||||||
+ cmd->error = VIRTIO_GPU_RESP_ERR_INVALID_PARAMETER;
|
|
||||||
+ return;
|
|
||||||
+ }
|
|
||||||
+
|
|
||||||
resp = g_malloc0(sizeof(*resp) + max_size);
|
|
||||||
-
|
|
||||||
resp->hdr.type = VIRTIO_GPU_RESP_OK_CAPSET;
|
|
||||||
virgl_renderer_fill_caps(gc.capset_id,
|
|
||||||
gc.capset_version,
|
|
||||||
--
|
|
||||||
2.9.3
|
|
@ -1,46 +0,0 @@
|
|||||||
From eb7a20a3616085d46aa6b4b4224e15587ec67e6e Mon Sep 17 00:00:00 2001
|
|
||||||
From: Li Qiang <liqiang6-s@360.cn>
|
|
||||||
Date: Mon, 28 Nov 2016 17:49:04 -0800
|
|
||||||
Subject: [PATCH] watchdog: 6300esb: add exit function
|
|
||||||
|
|
||||||
When the Intel 6300ESB watchdog is hot unplug. The timer allocated
|
|
||||||
in realize isn't freed thus leaking memory leak. This patch avoid
|
|
||||||
this through adding the exit function.
|
|
||||||
|
|
||||||
Signed-off-by: Li Qiang <liqiang6-s@360.cn>
|
|
||||||
Message-Id: <583cde9c.3223ed0a.7f0c2.886e@mx.google.com>
|
|
||||||
Signed-off-by: Paolo Bonzini <pbonzini@redhat.com>
|
|
||||||
---
|
|
||||||
hw/watchdog/wdt_i6300esb.c | 9 +++++++++
|
|
||||||
1 file changed, 9 insertions(+)
|
|
||||||
|
|
||||||
diff --git a/hw/watchdog/wdt_i6300esb.c b/hw/watchdog/wdt_i6300esb.c
|
|
||||||
index a83d951..49b3cd1 100644
|
|
||||||
--- a/hw/watchdog/wdt_i6300esb.c
|
|
||||||
+++ b/hw/watchdog/wdt_i6300esb.c
|
|
||||||
@@ -428,6 +428,14 @@ static void i6300esb_realize(PCIDevice *dev, Error **errp)
|
|
||||||
/* qemu_register_coalesced_mmio (addr, 0x10); ? */
|
|
||||||
}
|
|
||||||
|
|
||||||
+static void i6300esb_exit(PCIDevice *dev)
|
|
||||||
+{
|
|
||||||
+ I6300State *d = WATCHDOG_I6300ESB_DEVICE(dev);
|
|
||||||
+
|
|
||||||
+ timer_del(d->timer);
|
|
||||||
+ timer_free(d->timer);
|
|
||||||
+}
|
|
||||||
+
|
|
||||||
static WatchdogTimerModel model = {
|
|
||||||
.wdt_name = "i6300esb",
|
|
||||||
.wdt_description = "Intel 6300ESB",
|
|
||||||
@@ -441,6 +449,7 @@ static void i6300esb_class_init(ObjectClass *klass, void *data)
|
|
||||||
k->config_read = i6300esb_config_read;
|
|
||||||
k->config_write = i6300esb_config_write;
|
|
||||||
k->realize = i6300esb_realize;
|
|
||||||
+ k->exit = i6300esb_exit;
|
|
||||||
k->vendor_id = PCI_VENDOR_ID_INTEL;
|
|
||||||
k->device_id = PCI_DEVICE_ID_INTEL_ESB_9;
|
|
||||||
k->class_id = PCI_CLASS_SYSTEM_OTHER;
|
|
||||||
--
|
|
||||||
2.10.2
|
|
||||||
|
|
@ -1,35 +0,0 @@
|
|||||||
https://lists.gnu.org/archive/html/qemu-devel/2016-11/msg00059.html
|
|
||||||
https://bugs.gentoo.org/601826
|
|
||||||
|
|
||||||
From: Li Qiang
|
|
||||||
Subject: [Qemu-devel] [PATCH] virtio-gpu: fix information leak in capset get dispatch
|
|
||||||
Date: Tue, 1 Nov 2016 05:37:57 -0700
|
|
||||||
From: Li Qiang <address@hidden>
|
|
||||||
|
|
||||||
In virgl_cmd_get_capset function, it uses g_malloc to allocate
|
|
||||||
a response struct to the guest. As the 'resp'struct hasn't been full
|
|
||||||
initialized it will lead the 'resp->padding' field to the guest.
|
|
||||||
Use g_malloc0 to avoid this.
|
|
||||||
|
|
||||||
Signed-off-by: Li Qiang <address@hidden>
|
|
||||||
---
|
|
||||||
hw/display/virtio-gpu-3d.c | 2 +-
|
|
||||||
1 file changed, 1 insertion(+), 1 deletion(-)
|
|
||||||
|
|
||||||
diff --git a/hw/display/virtio-gpu-3d.c b/hw/display/virtio-gpu-3d.c
|
|
||||||
index 23f39de..d98b140 100644
|
|
||||||
--- a/hw/display/virtio-gpu-3d.c
|
|
||||||
+++ b/hw/display/virtio-gpu-3d.c
|
|
||||||
@@ -371,7 +371,7 @@ static void virgl_cmd_get_capset(VirtIOGPU *g,
|
|
||||||
|
|
||||||
virgl_renderer_get_cap_set(gc.capset_id, &max_ver,
|
|
||||||
&max_size);
|
|
||||||
- resp = g_malloc(sizeof(*resp) + max_size);
|
|
||||||
+ resp = g_malloc0(sizeof(*resp) + max_size);
|
|
||||||
|
|
||||||
resp->hdr.type = VIRTIO_GPU_RESP_OK_CAPSET;
|
|
||||||
virgl_renderer_fill_caps(gc.capset_id,
|
|
||||||
--
|
|
||||||
1.8.3.1
|
|
||||||
|
|
||||||
|
|
@ -1,38 +0,0 @@
|
|||||||
https://lists.gnu.org/archive/html/qemu-devel/2016-11/msg05043.html
|
|
||||||
https://bugs.gentoo.org/602630
|
|
||||||
|
|
||||||
From: Li Qiang
|
|
||||||
Subject: [Qemu-devel] [PATCH] virtio-gpu: call cleanup mapping function in resource destroy
|
|
||||||
Date: Mon, 28 Nov 2016 21:29:25 -0500
|
|
||||||
If the guest destroy the resource before detach banking, the 'iov'
|
|
||||||
and 'addrs' field in resource is not freed thus leading memory
|
|
||||||
leak issue. This patch avoid this.
|
|
||||||
|
|
||||||
Signed-off-by: Li Qiang <address@hidden>
|
|
||||||
---
|
|
||||||
hw/display/virtio-gpu.c | 3 +++
|
|
||||||
1 file changed, 3 insertions(+)
|
|
||||||
|
|
||||||
diff --git a/hw/display/virtio-gpu.c b/hw/display/virtio-gpu.c
|
|
||||||
index 60bce94..98dadf2 100644
|
|
||||||
--- a/hw/display/virtio-gpu.c
|
|
||||||
+++ b/hw/display/virtio-gpu.c
|
|
||||||
@@ -28,6 +28,8 @@
|
|
||||||
static struct virtio_gpu_simple_resource*
|
|
||||||
virtio_gpu_find_resource(VirtIOGPU *g, uint32_t resource_id);
|
|
||||||
|
|
||||||
+static void virtio_gpu_cleanup_mapping(struct virtio_gpu_simple_resource *res);
|
|
||||||
+
|
|
||||||
#ifdef CONFIG_VIRGL
|
|
||||||
#include <virglrenderer.h>
|
|
||||||
#define VIRGL(_g, _virgl, _simple, ...) \
|
|
||||||
@@ -358,6 +360,7 @@ static void virtio_gpu_resource_destroy(VirtIOGPU *g,
|
|
||||||
struct virtio_gpu_simple_resource *res)
|
|
||||||
{
|
|
||||||
pixman_image_unref(res->image);
|
|
||||||
+ virtio_gpu_cleanup_mapping(res);
|
|
||||||
QTAILQ_REMOVE(&g->reslist, res, next);
|
|
||||||
g_free(res);
|
|
||||||
}
|
|
||||||
--
|
|
||||||
1.8.3.1
|
|
@ -1,48 +0,0 @@
|
|||||||
From 62d4c6bd5263bb8413a06c80144fc678df6dfb64 Mon Sep 17 00:00:00 2001
|
|
||||||
From: Li Qiang <liqiang6-s@360.cn>
|
|
||||||
Date: Wed, 1 Feb 2017 09:35:01 +0100
|
|
||||||
Subject: [PATCH] cirrus: fix oob access issue (CVE-2017-2615)
|
|
||||||
|
|
||||||
When doing bitblt copy in backward mode, we should minus the
|
|
||||||
blt width first just like the adding in the forward mode. This
|
|
||||||
can avoid the oob access of the front of vga's vram.
|
|
||||||
|
|
||||||
Signed-off-by: Li Qiang <liqiang6-s@360.cn>
|
|
||||||
|
|
||||||
{ kraxel: with backward blits (negative pitch) addr is the topmost
|
|
||||||
address, so check it as-is against vram size ]
|
|
||||||
|
|
||||||
Cc: qemu-stable@nongnu.org
|
|
||||||
Cc: P J P <ppandit@redhat.com>
|
|
||||||
Cc: Laszlo Ersek <lersek@redhat.com>
|
|
||||||
Cc: Paolo Bonzini <pbonzini@redhat.com>
|
|
||||||
Cc: Wolfgang Bumiller <w.bumiller@proxmox.com>
|
|
||||||
Fixes: d3532a0db02296e687711b8cdc7791924efccea0 (CVE-2014-8106)
|
|
||||||
Signed-off-by: Gerd Hoffmann <kraxel@redhat.com>
|
|
||||||
Message-id: 1485938101-26602-1-git-send-email-kraxel@redhat.com
|
|
||||||
Reviewed-by: Laszlo Ersek <lersek@redhat.com>
|
|
||||||
---
|
|
||||||
hw/display/cirrus_vga.c | 7 +++----
|
|
||||||
1 file changed, 3 insertions(+), 4 deletions(-)
|
|
||||||
|
|
||||||
diff --git a/hw/display/cirrus_vga.c b/hw/display/cirrus_vga.c
|
|
||||||
index 7db6409..16f27e8 100644
|
|
||||||
--- a/hw/display/cirrus_vga.c
|
|
||||||
+++ b/hw/display/cirrus_vga.c
|
|
||||||
@@ -274,10 +274,9 @@ static bool blit_region_is_unsafe(struct CirrusVGAState *s,
|
|
||||||
{
|
|
||||||
if (pitch < 0) {
|
|
||||||
int64_t min = addr
|
|
||||||
- + ((int64_t)s->cirrus_blt_height-1) * pitch;
|
|
||||||
- int32_t max = addr
|
|
||||||
- + s->cirrus_blt_width;
|
|
||||||
- if (min < 0 || max > s->vga.vram_size) {
|
|
||||||
+ + ((int64_t)s->cirrus_blt_height - 1) * pitch
|
|
||||||
+ - s->cirrus_blt_width;
|
|
||||||
+ if (min < -1 || addr >= s->vga.vram_size) {
|
|
||||||
return true;
|
|
||||||
}
|
|
||||||
} else {
|
|
||||||
--
|
|
||||||
2.10.2
|
|
||||||
|
|
@ -1,56 +0,0 @@
|
|||||||
From: Gerd Hoffmann <kraxel@redhat.com>
|
|
||||||
Subject: [PATCH 3/3] cirrus: add blit_is_unsafe call to cirrus_bitblt_cputovideo
|
|
||||||
|
|
||||||
CIRRUS_BLTMODE_MEMSYSSRC blits do NOT check blit destination
|
|
||||||
and blit width, at all. Oops. Fix it.
|
|
||||||
|
|
||||||
Security impact: high.
|
|
||||||
|
|
||||||
The missing blit destination check allows to write to host memory.
|
|
||||||
Basically same as CVE-2014-8106 for the other blit variants.
|
|
||||||
|
|
||||||
The missing blit width check allows to overflow cirrus_bltbuf,
|
|
||||||
with the attractive target cirrus_srcptr (current cirrus_bltbuf write
|
|
||||||
position) being located right after cirrus_bltbuf in CirrusVGAState.
|
|
||||||
|
|
||||||
Due to cirrus emulation writing cirrus_bltbuf bytewise the attacker
|
|
||||||
hasn't full control over cirrus_srcptr though, only one byte can be
|
|
||||||
changed. Once the first byte has been modified further writes land
|
|
||||||
elsewhere.
|
|
||||||
|
|
||||||
[ This is CVE-2017-2620 / XSA-209 - Ian Jackson ]
|
|
||||||
|
|
||||||
Signed-off-by: Gerd Hoffmann <kraxel@redhat.com>
|
|
||||||
---
|
|
||||||
hw/display/cirrus_vga.c | 8 ++++++++
|
|
||||||
1 file changed, 8 insertions(+)
|
|
||||||
|
|
||||||
diff --git a/hw/display/cirrus_vga.c b/hw/display/cirrus_vga.c
|
|
||||||
index 0e47cf8..a093dc8 100644
|
|
||||||
--- a/hw/display/cirrus_vga.c
|
|
||||||
+++ b/hw/display/cirrus_vga.c
|
|
||||||
@@ -899,6 +899,10 @@ static int cirrus_bitblt_cputovideo(CirrusVGAState * s)
|
|
||||||
{
|
|
||||||
int w;
|
|
||||||
|
|
||||||
+ if (blit_is_unsafe(s)) {
|
|
||||||
+ return 0;
|
|
||||||
+ }
|
|
||||||
+
|
|
||||||
s->cirrus_blt_mode &= ~CIRRUS_BLTMODE_MEMSYSSRC;
|
|
||||||
s->cirrus_srcptr = &s->cirrus_bltbuf[0];
|
|
||||||
s->cirrus_srcptr_end = &s->cirrus_bltbuf[0];
|
|
||||||
@@ -924,6 +928,10 @@ static int cirrus_bitblt_cputovideo(CirrusVGAState * s)
|
|
||||||
}
|
|
||||||
s->cirrus_srccounter = s->cirrus_blt_srcpitch * s->cirrus_blt_height;
|
|
||||||
}
|
|
||||||
+
|
|
||||||
+ /* the blit_is_unsafe call above should catch this */
|
|
||||||
+ assert(s->cirrus_blt_srcpitch <= CIRRUS_BLTBUFSIZE);
|
|
||||||
+
|
|
||||||
s->cirrus_srcptr = s->cirrus_bltbuf;
|
|
||||||
s->cirrus_srcptr_end = s->cirrus_bltbuf + s->cirrus_blt_srcpitch;
|
|
||||||
cirrus_update_memory_access(s);
|
|
||||||
--
|
|
||||||
1.8.3.1
|
|
||||||
|
|
@ -1,22 +0,0 @@
|
|||||||
Comparison symbol is misused. It may lead to memory corruption.
|
|
||||||
|
|
||||||
Signed-off-by: Vladimir Sementsov-Ogievskiy <address@hidden>
|
|
||||||
---
|
|
||||||
nbd/client.c | 2 +-
|
|
||||||
1 file changed, 1 insertion(+), 1 deletion(-)
|
|
||||||
|
|
||||||
diff --git a/nbd/client.c b/nbd/client.c
|
|
||||||
index 6caf6bda6d..351731bc63 100644
|
|
||||||
--- a/nbd/client.c
|
|
||||||
+++ b/nbd/client.c
|
|
||||||
@@ -94,7 +94,7 @@ static ssize_t drop_sync(QIOChannel *ioc, size_t size)
|
|
||||||
char small[1024];
|
|
||||||
char *buffer;
|
|
||||||
|
|
||||||
- buffer = sizeof(small) < size ? small : g_malloc(MIN(65536, size));
|
|
||||||
+ buffer = sizeof(small) > size ? small : g_malloc(MIN(65536, size));
|
|
||||||
while (size > 0) {
|
|
||||||
ssize_t count = read_sync(ioc, buffer, MIN(65536, size));
|
|
||||||
|
|
||||||
--
|
|
||||||
2.11.0
|
|
@ -1,52 +0,0 @@
|
|||||||
From 12351a91da97b414eec8cdb09f1d9f41e535a401 Mon Sep 17 00:00:00 2001
|
|
||||||
From: Li Qiang <liqiang6-s@360.cn>
|
|
||||||
Date: Wed, 14 Dec 2016 18:30:21 -0800
|
|
||||||
Subject: [PATCH] audio: ac97: add exit function
|
|
||||||
MIME-Version: 1.0
|
|
||||||
Content-Type: text/plain; charset=UTF-8
|
|
||||||
Content-Transfer-Encoding: 8bit
|
|
||||||
|
|
||||||
Currently the ac97 device emulation doesn't have a exit function,
|
|
||||||
hot unplug this device will leak some memory. Add a exit function to
|
|
||||||
avoid this.
|
|
||||||
|
|
||||||
Signed-off-by: Li Qiang <liqiang6-s@360.cn>
|
|
||||||
Reviewed-by: Marc-André Lureau <marcandre.lureau@redhat.com>
|
|
||||||
Message-id: 58520052.4825ed0a.27a71.6cae@mx.google.com
|
|
||||||
Signed-off-by: Gerd Hoffmann <kraxel@redhat.com>
|
|
||||||
---
|
|
||||||
hw/audio/ac97.c | 11 +++++++++++
|
|
||||||
1 file changed, 11 insertions(+)
|
|
||||||
|
|
||||||
diff --git a/hw/audio/ac97.c b/hw/audio/ac97.c
|
|
||||||
index cbd959e..c306575 100644
|
|
||||||
--- a/hw/audio/ac97.c
|
|
||||||
+++ b/hw/audio/ac97.c
|
|
||||||
@@ -1387,6 +1387,16 @@ static void ac97_realize(PCIDevice *dev, Error **errp)
|
|
||||||
ac97_on_reset (&s->dev.qdev);
|
|
||||||
}
|
|
||||||
|
|
||||||
+static void ac97_exit(PCIDevice *dev)
|
|
||||||
+{
|
|
||||||
+ AC97LinkState *s = DO_UPCAST(AC97LinkState, dev, dev);
|
|
||||||
+
|
|
||||||
+ AUD_close_in(&s->card, s->voice_pi);
|
|
||||||
+ AUD_close_out(&s->card, s->voice_po);
|
|
||||||
+ AUD_close_in(&s->card, s->voice_mc);
|
|
||||||
+ AUD_remove_card(&s->card);
|
|
||||||
+}
|
|
||||||
+
|
|
||||||
static int ac97_init (PCIBus *bus)
|
|
||||||
{
|
|
||||||
pci_create_simple (bus, -1, "AC97");
|
|
||||||
@@ -1404,6 +1414,7 @@ static void ac97_class_init (ObjectClass *klass, void *data)
|
|
||||||
PCIDeviceClass *k = PCI_DEVICE_CLASS (klass);
|
|
||||||
|
|
||||||
k->realize = ac97_realize;
|
|
||||||
+ k->exit = ac97_exit;
|
|
||||||
k->vendor_id = PCI_VENDOR_ID_INTEL;
|
|
||||||
k->device_id = PCI_DEVICE_ID_INTEL_82801AA_5;
|
|
||||||
k->revision = 0x01;
|
|
||||||
--
|
|
||||||
2.10.2
|
|
||||||
|
|
@ -1,55 +0,0 @@
|
|||||||
From 069eb7b2b8fc47c7cb52e5a4af23ea98d939e3da Mon Sep 17 00:00:00 2001
|
|
||||||
From: Li Qiang <liqiang6-s@360.cn>
|
|
||||||
Date: Wed, 14 Dec 2016 18:32:22 -0800
|
|
||||||
Subject: [PATCH] audio: es1370: add exit function
|
|
||||||
MIME-Version: 1.0
|
|
||||||
Content-Type: text/plain; charset=UTF-8
|
|
||||||
Content-Transfer-Encoding: 8bit
|
|
||||||
|
|
||||||
Currently the es1370 device emulation doesn't have a exit function,
|
|
||||||
hot unplug this device will leak some memory. Add a exit function to
|
|
||||||
avoid this.
|
|
||||||
|
|
||||||
Signed-off-by: Li Qiang <liqiang6-s@360.cn>
|
|
||||||
Reviewed-by: Marc-André Lureau <marcandre.lureau@redhat.com>
|
|
||||||
Message-id: 585200c9.a968ca0a.1ab80.4c98@mx.google.com
|
|
||||||
Signed-off-by: Gerd Hoffmann <kraxel@redhat.com>
|
|
||||||
---
|
|
||||||
hw/audio/es1370.c | 14 ++++++++++++++
|
|
||||||
1 file changed, 14 insertions(+)
|
|
||||||
|
|
||||||
diff --git a/hw/audio/es1370.c b/hw/audio/es1370.c
|
|
||||||
index 8449b5f..883ec69 100644
|
|
||||||
--- a/hw/audio/es1370.c
|
|
||||||
+++ b/hw/audio/es1370.c
|
|
||||||
@@ -1041,6 +1041,19 @@ static void es1370_realize(PCIDevice *dev, Error **errp)
|
|
||||||
es1370_reset (s);
|
|
||||||
}
|
|
||||||
|
|
||||||
+static void es1370_exit(PCIDevice *dev)
|
|
||||||
+{
|
|
||||||
+ ES1370State *s = ES1370(dev);
|
|
||||||
+ int i;
|
|
||||||
+
|
|
||||||
+ for (i = 0; i < 2; ++i) {
|
|
||||||
+ AUD_close_out(&s->card, s->dac_voice[i]);
|
|
||||||
+ }
|
|
||||||
+
|
|
||||||
+ AUD_close_in(&s->card, s->adc_voice);
|
|
||||||
+ AUD_remove_card(&s->card);
|
|
||||||
+}
|
|
||||||
+
|
|
||||||
static int es1370_init (PCIBus *bus)
|
|
||||||
{
|
|
||||||
pci_create_simple (bus, -1, TYPE_ES1370);
|
|
||||||
@@ -1053,6 +1066,7 @@ static void es1370_class_init (ObjectClass *klass, void *data)
|
|
||||||
PCIDeviceClass *k = PCI_DEVICE_CLASS (klass);
|
|
||||||
|
|
||||||
k->realize = es1370_realize;
|
|
||||||
+ k->exit = es1370_exit;
|
|
||||||
k->vendor_id = PCI_VENDOR_ID_ENSONIQ;
|
|
||||||
k->device_id = PCI_DEVICE_ID_ENSONIQ_ES1370;
|
|
||||||
k->class_id = PCI_CLASS_MULTIMEDIA_AUDIO;
|
|
||||||
--
|
|
||||||
2.10.2
|
|
||||||
|
|
@ -1,41 +0,0 @@
|
|||||||
From 33243031dad02d161225ba99d782616da133f689 Mon Sep 17 00:00:00 2001
|
|
||||||
From: Li Qiang <liq3ea@gmail.com>
|
|
||||||
Date: Thu, 29 Dec 2016 03:11:26 -0500
|
|
||||||
Subject: [PATCH] virtio-gpu-3d: fix memory leak in resource attach backing
|
|
||||||
MIME-Version: 1.0
|
|
||||||
Content-Type: text/plain; charset=UTF-8
|
|
||||||
Content-Transfer-Encoding: 8bit
|
|
||||||
|
|
||||||
If the virgl_renderer_resource_attach_iov function fails the
|
|
||||||
'res_iovs' will be leaked. Add check of the return value to
|
|
||||||
free the 'res_iovs' when failing.
|
|
||||||
|
|
||||||
Signed-off-by: Li Qiang <liq3ea@gmail.com>
|
|
||||||
Reviewed-by: Marc-André Lureau <marcandre.lureau@redhat.com>
|
|
||||||
Message-id: 1482999086-59795-1-git-send-email-liq3ea@gmail.com
|
|
||||||
Signed-off-by: Gerd Hoffmann <kraxel@redhat.com>
|
|
||||||
---
|
|
||||||
hw/display/virtio-gpu-3d.c | 7 +++++--
|
|
||||||
1 file changed, 5 insertions(+), 2 deletions(-)
|
|
||||||
|
|
||||||
diff --git a/hw/display/virtio-gpu-3d.c b/hw/display/virtio-gpu-3d.c
|
|
||||||
index e29f099..b13ced3 100644
|
|
||||||
--- a/hw/display/virtio-gpu-3d.c
|
|
||||||
+++ b/hw/display/virtio-gpu-3d.c
|
|
||||||
@@ -291,8 +291,11 @@ static void virgl_resource_attach_backing(VirtIOGPU *g,
|
|
||||||
return;
|
|
||||||
}
|
|
||||||
|
|
||||||
- virgl_renderer_resource_attach_iov(att_rb.resource_id,
|
|
||||||
- res_iovs, att_rb.nr_entries);
|
|
||||||
+ ret = virgl_renderer_resource_attach_iov(att_rb.resource_id,
|
|
||||||
+ res_iovs, att_rb.nr_entries);
|
|
||||||
+
|
|
||||||
+ if (ret != 0)
|
|
||||||
+ virtio_gpu_cleanup_mapping_iov(res_iovs, att_rb.nr_entries);
|
|
||||||
}
|
|
||||||
|
|
||||||
static void virgl_resource_detach_backing(VirtIOGPU *g,
|
|
||||||
--
|
|
||||||
2.10.2
|
|
||||||
|
|
@ -1,35 +0,0 @@
|
|||||||
From 204f01b30975923c64006f8067f0937b91eea68b Mon Sep 17 00:00:00 2001
|
|
||||||
From: Li Qiang <liq3ea@gmail.com>
|
|
||||||
Date: Thu, 29 Dec 2016 04:28:41 -0500
|
|
||||||
Subject: [PATCH] virtio-gpu: fix memory leak in resource attach backing
|
|
||||||
|
|
||||||
In the resource attach backing function, everytime it will
|
|
||||||
allocate 'res->iov' thus can leading a memory leak. This
|
|
||||||
patch avoid this.
|
|
||||||
|
|
||||||
Signed-off-by: Li Qiang <liq3ea@gmail.com>
|
|
||||||
Message-id: 1483003721-65360-1-git-send-email-liq3ea@gmail.com
|
|
||||||
Signed-off-by: Gerd Hoffmann <kraxel@redhat.com>
|
|
||||||
---
|
|
||||||
hw/display/virtio-gpu.c | 5 +++++
|
|
||||||
1 file changed, 5 insertions(+)
|
|
||||||
|
|
||||||
diff --git a/hw/display/virtio-gpu.c b/hw/display/virtio-gpu.c
|
|
||||||
index 6a26258..ca88cf4 100644
|
|
||||||
--- a/hw/display/virtio-gpu.c
|
|
||||||
+++ b/hw/display/virtio-gpu.c
|
|
||||||
@@ -714,6 +714,11 @@ virtio_gpu_resource_attach_backing(VirtIOGPU *g,
|
|
||||||
return;
|
|
||||||
}
|
|
||||||
|
|
||||||
+ if (res->iov) {
|
|
||||||
+ cmd->error = VIRTIO_GPU_RESP_ERR_UNSPEC;
|
|
||||||
+ return;
|
|
||||||
+ }
|
|
||||||
+
|
|
||||||
ret = virtio_gpu_create_mapping_iov(&ab, cmd, &res->addrs, &res->iov);
|
|
||||||
if (ret != 0) {
|
|
||||||
cmd->error = VIRTIO_GPU_RESP_ERR_UNSPEC;
|
|
||||||
--
|
|
||||||
2.10.2
|
|
||||||
|
|
@ -1,40 +0,0 @@
|
|||||||
From 8409dc884a201bf74b30a9d232b6bbdd00cb7e2b Mon Sep 17 00:00:00 2001
|
|
||||||
From: Li Qiang <liqiang6-s@360.cn>
|
|
||||||
Date: Wed, 4 Jan 2017 00:43:16 -0800
|
|
||||||
Subject: [PATCH] serial: fix memory leak in serial exit
|
|
||||||
|
|
||||||
The serial_exit_core function doesn't free some resources.
|
|
||||||
This can lead memory leak when hotplug and unplug. This
|
|
||||||
patch avoid this.
|
|
||||||
|
|
||||||
Signed-off-by: Li Qiang <liqiang6-s@360.cn>
|
|
||||||
Message-Id: <586cb5ab.f31d9d0a.38ac3.acf2@mx.google.com>
|
|
||||||
Signed-off-by: Paolo Bonzini <pbonzini@redhat.com>
|
|
||||||
---
|
|
||||||
hw/char/serial.c | 10 ++++++++++
|
|
||||||
1 file changed, 10 insertions(+)
|
|
||||||
|
|
||||||
diff --git a/hw/char/serial.c b/hw/char/serial.c
|
|
||||||
index ffbacd8..67b18ed 100644
|
|
||||||
--- a/hw/char/serial.c
|
|
||||||
+++ b/hw/char/serial.c
|
|
||||||
@@ -906,6 +906,16 @@ void serial_realize_core(SerialState *s, Error **errp)
|
|
||||||
void serial_exit_core(SerialState *s)
|
|
||||||
{
|
|
||||||
qemu_chr_fe_deinit(&s->chr);
|
|
||||||
+
|
|
||||||
+ timer_del(s->modem_status_poll);
|
|
||||||
+ timer_free(s->modem_status_poll);
|
|
||||||
+
|
|
||||||
+ timer_del(s->fifo_timeout_timer);
|
|
||||||
+ timer_free(s->fifo_timeout_timer);
|
|
||||||
+
|
|
||||||
+ fifo8_destroy(&s->recv_fifo);
|
|
||||||
+ fifo8_destroy(&s->xmit_fifo);
|
|
||||||
+
|
|
||||||
qemu_unregister_reset(serial_reset, s);
|
|
||||||
}
|
|
||||||
|
|
||||||
--
|
|
||||||
2.10.2
|
|
||||||
|
|
@ -1,37 +0,0 @@
|
|||||||
From 42922105beb14c2fc58185ea022b9f72fb5465e9 Mon Sep 17 00:00:00 2001
|
|
||||||
From: Prasad J Pandit <pjp@fedoraproject.org>
|
|
||||||
Date: Tue, 7 Feb 2017 18:29:59 +0000
|
|
||||||
Subject: [PATCH] sd: sdhci: check data length during dma_memory_read
|
|
||||||
|
|
||||||
While doing multi block SDMA transfer in routine
|
|
||||||
'sdhci_sdma_transfer_multi_blocks', the 's->fifo_buffer' starting
|
|
||||||
index 'begin' and data length 's->data_count' could end up to be same.
|
|
||||||
This could lead to an OOB access issue. Correct transfer data length
|
|
||||||
to avoid it.
|
|
||||||
|
|
||||||
Cc: qemu-stable@nongnu.org
|
|
||||||
Reported-by: Jiang Xin <jiangxin1@huawei.com>
|
|
||||||
Signed-off-by: Prasad J Pandit <pjp@fedoraproject.org>
|
|
||||||
Reviewed-by: Peter Maydell <peter.maydell@linaro.org>
|
|
||||||
Message-id: 20170130064736.9236-1-ppandit@redhat.com
|
|
||||||
Signed-off-by: Peter Maydell <peter.maydell@linaro.org>
|
|
||||||
---
|
|
||||||
hw/sd/sdhci.c | 2 +-
|
|
||||||
1 file changed, 1 insertion(+), 1 deletion(-)
|
|
||||||
|
|
||||||
diff --git a/hw/sd/sdhci.c b/hw/sd/sdhci.c
|
|
||||||
index 01fbf22..5bd5ab6 100644
|
|
||||||
--- a/hw/sd/sdhci.c
|
|
||||||
+++ b/hw/sd/sdhci.c
|
|
||||||
@@ -536,7 +536,7 @@ static void sdhci_sdma_transfer_multi_blocks(SDHCIState *s)
|
|
||||||
boundary_count -= block_size - begin;
|
|
||||||
}
|
|
||||||
dma_memory_read(&address_space_memory, s->sdmasysad,
|
|
||||||
- &s->fifo_buffer[begin], s->data_count);
|
|
||||||
+ &s->fifo_buffer[begin], s->data_count - begin);
|
|
||||||
s->sdmasysad += s->data_count - begin;
|
|
||||||
if (s->data_count == block_size) {
|
|
||||||
for (n = 0; n < block_size; n++) {
|
|
||||||
--
|
|
||||||
2.10.2
|
|
||||||
|
|
@ -1,64 +0,0 @@
|
|||||||
From 765a707000e838c30b18d712fe6cb3dd8e0435f3 Mon Sep 17 00:00:00 2001
|
|
||||||
From: Paolo Bonzini <pbonzini@redhat.com>
|
|
||||||
Date: Mon, 2 Jan 2017 11:03:33 +0100
|
|
||||||
Subject: [PATCH] megasas: fix guest-triggered memory leak
|
|
||||||
|
|
||||||
If the guest sets the sglist size to a value >=2GB, megasas_handle_dcmd
|
|
||||||
will return MFI_STAT_MEMORY_NOT_AVAILABLE without freeing the memory.
|
|
||||||
Avoid this by returning only the status from map_dcmd, and loading
|
|
||||||
cmd->iov_size in the caller.
|
|
||||||
|
|
||||||
Reported-by: Li Qiang <liqiang6-s@360.cn>
|
|
||||||
Signed-off-by: Paolo Bonzini <pbonzini@redhat.com>
|
|
||||||
---
|
|
||||||
hw/scsi/megasas.c | 11 ++++++-----
|
|
||||||
1 file changed, 6 insertions(+), 5 deletions(-)
|
|
||||||
|
|
||||||
diff --git a/hw/scsi/megasas.c b/hw/scsi/megasas.c
|
|
||||||
index 67fc1e7..6233865 100644
|
|
||||||
--- a/hw/scsi/megasas.c
|
|
||||||
+++ b/hw/scsi/megasas.c
|
|
||||||
@@ -683,14 +683,14 @@ static int megasas_map_dcmd(MegasasState *s, MegasasCmd *cmd)
|
|
||||||
trace_megasas_dcmd_invalid_sge(cmd->index,
|
|
||||||
cmd->frame->header.sge_count);
|
|
||||||
cmd->iov_size = 0;
|
|
||||||
- return -1;
|
|
||||||
+ return -EINVAL;
|
|
||||||
}
|
|
||||||
iov_pa = megasas_sgl_get_addr(cmd, &cmd->frame->dcmd.sgl);
|
|
||||||
iov_size = megasas_sgl_get_len(cmd, &cmd->frame->dcmd.sgl);
|
|
||||||
pci_dma_sglist_init(&cmd->qsg, PCI_DEVICE(s), 1);
|
|
||||||
qemu_sglist_add(&cmd->qsg, iov_pa, iov_size);
|
|
||||||
cmd->iov_size = iov_size;
|
|
||||||
- return cmd->iov_size;
|
|
||||||
+ return 0;
|
|
||||||
}
|
|
||||||
|
|
||||||
static void megasas_finish_dcmd(MegasasCmd *cmd, uint32_t iov_size)
|
|
||||||
@@ -1559,19 +1559,20 @@ static const struct dcmd_cmd_tbl_t {
|
|
||||||
|
|
||||||
static int megasas_handle_dcmd(MegasasState *s, MegasasCmd *cmd)
|
|
||||||
{
|
|
||||||
- int opcode, len;
|
|
||||||
+ int opcode;
|
|
||||||
int retval = 0;
|
|
||||||
+ size_t len;
|
|
||||||
const struct dcmd_cmd_tbl_t *cmdptr = dcmd_cmd_tbl;
|
|
||||||
|
|
||||||
opcode = le32_to_cpu(cmd->frame->dcmd.opcode);
|
|
||||||
trace_megasas_handle_dcmd(cmd->index, opcode);
|
|
||||||
- len = megasas_map_dcmd(s, cmd);
|
|
||||||
- if (len < 0) {
|
|
||||||
+ if (megasas_map_dcmd(s, cmd) < 0) {
|
|
||||||
return MFI_STAT_MEMORY_NOT_AVAILABLE;
|
|
||||||
}
|
|
||||||
while (cmdptr->opcode != -1 && cmdptr->opcode != opcode) {
|
|
||||||
cmdptr++;
|
|
||||||
}
|
|
||||||
+ len = cmd->iov_size;
|
|
||||||
if (cmdptr->opcode == -1) {
|
|
||||||
trace_megasas_dcmd_unhandled(cmd->index, opcode, len);
|
|
||||||
retval = megasas_dcmd_dummy(s, cmd);
|
|
||||||
--
|
|
||||||
2.10.2
|
|
||||||
|
|
@ -1,38 +0,0 @@
|
|||||||
When the guest sends VIRTIO_GPU_CMD_RESOURCE_UNREF without detaching the
|
|
||||||
backing storage beforehand (VIRTIO_GPU_CMD_RESOURCE_DETACH_BACKING)
|
|
||||||
we'll leak memory.
|
|
||||||
|
|
||||||
This patch fixes it for 3d mode, simliar to the 2d mode fix in commit
|
|
||||||
"b8e2392 virtio-gpu: call cleanup mapping function in resource destroy".
|
|
||||||
|
|
||||||
Reported-by: 李强 <address@hidden>
|
|
||||||
Signed-off-by: Gerd Hoffmann <address@hidden>
|
|
||||||
---
|
|
||||||
hw/display/virtio-gpu-3d.c | 8 ++++++++
|
|
||||||
1 file changed, 8 insertions(+)
|
|
||||||
|
|
||||||
diff --git a/hw/display/virtio-gpu-3d.c b/hw/display/virtio-gpu-3d.c
|
|
||||||
index f96a0c2..ecb09d1 100644
|
|
||||||
--- a/hw/display/virtio-gpu-3d.c
|
|
||||||
+++ b/hw/display/virtio-gpu-3d.c
|
|
||||||
@@ -77,10 +77,18 @@ static void virgl_cmd_resource_unref(VirtIOGPU *g,
|
|
||||||
struct virtio_gpu_ctrl_command *cmd)
|
|
||||||
{
|
|
||||||
struct virtio_gpu_resource_unref unref;
|
|
||||||
+ struct iovec *res_iovs = NULL;
|
|
||||||
+ int num_iovs = 0;
|
|
||||||
|
|
||||||
VIRTIO_GPU_FILL_CMD(unref);
|
|
||||||
trace_virtio_gpu_cmd_res_unref(unref.resource_id);
|
|
||||||
|
|
||||||
+ virgl_renderer_resource_detach_iov(unref.resource_id,
|
|
||||||
+ &res_iovs,
|
|
||||||
+ &num_iovs);
|
|
||||||
+ if (res_iovs != NULL && num_iovs != 0) {
|
|
||||||
+ virtio_gpu_cleanup_mapping_iov(res_iovs, num_iovs);
|
|
||||||
+ }
|
|
||||||
virgl_renderer_resource_unref(unref.resource_id);
|
|
||||||
}
|
|
||||||
|
|
||||||
--
|
|
||||||
1.8.3.1
|
|
@ -1,35 +0,0 @@
|
|||||||
From c7dfbf322595ded4e70b626bf83158a9f3807c6a Mon Sep 17 00:00:00 2001
|
|
||||||
From: Prasad J Pandit <pjp@fedoraproject.org>
|
|
||||||
Date: Fri, 3 Feb 2017 00:52:28 +0530
|
|
||||||
Subject: [PATCH] usb: ccid: check ccid apdu length
|
|
||||||
|
|
||||||
CCID device emulator uses Application Protocol Data Units(APDU)
|
|
||||||
to exchange command and responses to and from the host.
|
|
||||||
The length in these units couldn't be greater than 65536. Add
|
|
||||||
check to ensure the same. It'd also avoid potential integer
|
|
||||||
overflow in emulated_apdu_from_guest.
|
|
||||||
|
|
||||||
Reported-by: Li Qiang <liqiang6-s@360.cn>
|
|
||||||
Signed-off-by: Prasad J Pandit <pjp@fedoraproject.org>
|
|
||||||
Message-id: 20170202192228.10847-1-ppandit@redhat.com
|
|
||||||
Signed-off-by: Gerd Hoffmann <kraxel@redhat.com>
|
|
||||||
---
|
|
||||||
hw/usb/dev-smartcard-reader.c | 2 +-
|
|
||||||
1 file changed, 1 insertion(+), 1 deletion(-)
|
|
||||||
|
|
||||||
diff --git a/hw/usb/dev-smartcard-reader.c b/hw/usb/dev-smartcard-reader.c
|
|
||||||
index 89e11b6..1325ea1 100644
|
|
||||||
--- a/hw/usb/dev-smartcard-reader.c
|
|
||||||
+++ b/hw/usb/dev-smartcard-reader.c
|
|
||||||
@@ -967,7 +967,7 @@ static void ccid_on_apdu_from_guest(USBCCIDState *s, CCID_XferBlock *recv)
|
|
||||||
DPRINTF(s, 1, "%s: seq %d, len %d\n", __func__,
|
|
||||||
recv->hdr.bSeq, len);
|
|
||||||
ccid_add_pending_answer(s, (CCID_Header *)recv);
|
|
||||||
- if (s->card) {
|
|
||||||
+ if (s->card && len <= BULK_OUT_DATA_SIZE) {
|
|
||||||
ccid_card_apdu_from_guest(s->card, recv->abData, len);
|
|
||||||
} else {
|
|
||||||
DPRINTF(s, D_WARN, "warning: discarded apdu\n");
|
|
||||||
--
|
|
||||||
2.10.2
|
|
||||||
|
|
@ -1,46 +0,0 @@
|
|||||||
From a08aaff811fb194950f79711d2afe5a892ae03a4 Mon Sep 17 00:00:00 2001
|
|
||||||
From: Gonglei <arei.gonglei@huawei.com>
|
|
||||||
Date: Tue, 3 Jan 2017 14:50:03 +0800
|
|
||||||
Subject: [PATCH] virtio-crypto: fix possible integer and heap overflow
|
|
||||||
|
|
||||||
Because the 'size_t' type is 4 bytes in 32-bit platform, which
|
|
||||||
is the same with 'int'. It's easy to make 'max_len' to zero when
|
|
||||||
integer overflow and then cause heap overflow if 'max_len' is zero.
|
|
||||||
|
|
||||||
Using uint_64 instead of size_t to avoid the integer overflow.
|
|
||||||
|
|
||||||
Cc: qemu-stable@nongnu.org
|
|
||||||
Reported-by: Li Qiang <liqiang6-s@360.cn>
|
|
||||||
Signed-off-by: Gonglei <arei.gonglei@huawei.com>
|
|
||||||
Tested-by: Li Qiang <liqiang6-s@360.cn>
|
|
||||||
Reviewed-by: Michael S. Tsirkin <mst@redhat.com>
|
|
||||||
Signed-off-by: Michael S. Tsirkin <mst@redhat.com>
|
|
||||||
---
|
|
||||||
hw/virtio/virtio-crypto.c | 4 ++--
|
|
||||||
1 file changed, 2 insertions(+), 2 deletions(-)
|
|
||||||
|
|
||||||
diff --git a/hw/virtio/virtio-crypto.c b/hw/virtio/virtio-crypto.c
|
|
||||||
index 2f2467e..c23e1ad 100644
|
|
||||||
--- a/hw/virtio/virtio-crypto.c
|
|
||||||
+++ b/hw/virtio/virtio-crypto.c
|
|
||||||
@@ -416,7 +416,7 @@ virtio_crypto_sym_op_helper(VirtIODevice *vdev,
|
|
||||||
uint32_t hash_start_src_offset = 0, len_to_hash = 0;
|
|
||||||
uint32_t cipher_start_src_offset = 0, len_to_cipher = 0;
|
|
||||||
|
|
||||||
- size_t max_len, curr_size = 0;
|
|
||||||
+ uint64_t max_len, curr_size = 0;
|
|
||||||
size_t s;
|
|
||||||
|
|
||||||
/* Plain cipher */
|
|
||||||
@@ -441,7 +441,7 @@ virtio_crypto_sym_op_helper(VirtIODevice *vdev,
|
|
||||||
return NULL;
|
|
||||||
}
|
|
||||||
|
|
||||||
- max_len = iv_len + aad_len + src_len + dst_len + hash_result_len;
|
|
||||||
+ max_len = (uint64_t)iv_len + aad_len + src_len + dst_len + hash_result_len;
|
|
||||||
if (unlikely(max_len > vcrypto->conf.max_size)) {
|
|
||||||
virtio_error(vdev, "virtio-crypto too big length");
|
|
||||||
return NULL;
|
|
||||||
--
|
|
||||||
2.10.2
|
|
||||||
|
|
@ -1,87 +0,0 @@
|
|||||||
Limits should be big enough that normal guest should not hit it.
|
|
||||||
Add a tracepoint to log them, just in case. Also, while being
|
|
||||||
at it, log the existing link trb limit too.
|
|
||||||
|
|
||||||
Reported-by: 李强 <address@hidden>
|
|
||||||
Signed-off-by: Gerd Hoffmann <address@hidden>
|
|
||||||
---
|
|
||||||
hw/usb/hcd-xhci.c | 15 ++++++++++++++-
|
|
||||||
hw/usb/trace-events | 1 +
|
|
||||||
2 files changed, 15 insertions(+), 1 deletion(-)
|
|
||||||
|
|
||||||
diff --git a/hw/usb/hcd-xhci.c b/hw/usb/hcd-xhci.c
|
|
||||||
index fbf8a8b..28dd2f2 100644
|
|
||||||
--- a/hw/usb/hcd-xhci.c
|
|
||||||
+++ b/hw/usb/hcd-xhci.c
|
|
||||||
@@ -51,6 +51,8 @@
|
|
||||||
#define EV_QUEUE (((3 * 24) + 16) * MAXSLOTS)
|
|
||||||
|
|
||||||
#define TRB_LINK_LIMIT 4
|
|
||||||
+#define COMMAND_LIMIT 256
|
|
||||||
+#define TRANSFER_LIMIT 256
|
|
||||||
|
|
||||||
#define LEN_CAP 0x40
|
|
||||||
#define LEN_OPER (0x400 + 0x10 * MAXPORTS)
|
|
||||||
@@ -943,6 +945,7 @@ static TRBType xhci_ring_fetch(XHCIState *xhci, XHCIRing *ring, XHCITRB *trb,
|
|
||||||
return type;
|
|
||||||
} else {
|
|
||||||
if (++link_cnt > TRB_LINK_LIMIT) {
|
|
||||||
+ trace_usb_xhci_enforced_limit("trb-link");
|
|
||||||
return 0;
|
|
||||||
}
|
|
||||||
ring->dequeue = xhci_mask64(trb->parameter);
|
|
||||||
@@ -2060,6 +2063,7 @@ static void xhci_kick_epctx(XHCIEPContext *epctx, unsigned int streamid)
|
|
||||||
XHCIRing *ring;
|
|
||||||
USBEndpoint *ep = NULL;
|
|
||||||
uint64_t mfindex;
|
|
||||||
+ unsigned int count = 0;
|
|
||||||
int length;
|
|
||||||
int i;
|
|
||||||
|
|
||||||
@@ -2172,6 +2176,10 @@ static void xhci_kick_epctx(XHCIEPContext *epctx, unsigned int streamid)
|
|
||||||
epctx->retry = xfer;
|
|
||||||
break;
|
|
||||||
}
|
|
||||||
+ if (count++ > TRANSFER_LIMIT) {
|
|
||||||
+ trace_usb_xhci_enforced_limit("transfers");
|
|
||||||
+ break;
|
|
||||||
+ }
|
|
||||||
}
|
|
||||||
epctx->kick_active--;
|
|
||||||
|
|
||||||
@@ -2618,7 +2626,7 @@ static void xhci_process_commands(XHCIState *xhci)
|
|
||||||
TRBType type;
|
|
||||||
XHCIEvent event = {ER_COMMAND_COMPLETE, CC_SUCCESS};
|
|
||||||
dma_addr_t addr;
|
|
||||||
- unsigned int i, slotid = 0;
|
|
||||||
+ unsigned int i, slotid = 0, count = 0;
|
|
||||||
|
|
||||||
DPRINTF("xhci_process_commands()\n");
|
|
||||||
if (!xhci_running(xhci)) {
|
|
||||||
@@ -2735,6 +2743,11 @@ static void xhci_process_commands(XHCIState *xhci)
|
|
||||||
}
|
|
||||||
event.slotid = slotid;
|
|
||||||
xhci_event(xhci, &event, 0);
|
|
||||||
+
|
|
||||||
+ if (count++ > COMMAND_LIMIT) {
|
|
||||||
+ trace_usb_xhci_enforced_limit("commands");
|
|
||||||
+ return;
|
|
||||||
+ }
|
|
||||||
}
|
|
||||||
}
|
|
||||||
|
|
||||||
diff --git a/hw/usb/trace-events b/hw/usb/trace-events
|
|
||||||
index fdd1d29..0c323d4 100644
|
|
||||||
--- a/hw/usb/trace-events
|
|
||||||
+++ b/hw/usb/trace-events
|
|
||||||
@@ -174,6 +174,7 @@ usb_xhci_xfer_retry(void *xfer) "%p"
|
|
||||||
usb_xhci_xfer_success(void *xfer, uint32_t bytes) "%p: len %d"
|
|
||||||
usb_xhci_xfer_error(void *xfer, uint32_t ret) "%p: ret %d"
|
|
||||||
usb_xhci_unimplemented(const char *item, int nr) "%s (0x%x)"
|
|
||||||
+usb_xhci_enforced_limit(const char *item) "%s"
|
|
||||||
|
|
||||||
# hw/usb/desc.c
|
|
||||||
usb_desc_device(int addr, int len, int ret) "dev %d query device, len %d, ret %d"
|
|
||||||
--
|
|
||||||
1.8.3.1
|
|
||||||
|
|
@ -1,50 +0,0 @@
|
|||||||
From: Prasad J Pandit <address@hidden>
|
|
||||||
|
|
||||||
In the SDHCI protocol, the transfer mode register value
|
|
||||||
is used during multi block transfer to check if block count
|
|
||||||
register is enabled and should be updated. Transfer mode
|
|
||||||
register could be set such that, block count register would
|
|
||||||
not be updated, thus leading to an infinite loop. Add check
|
|
||||||
to avoid it.
|
|
||||||
|
|
||||||
Reported-by: Wjjzhang <address@hidden>
|
|
||||||
Reported-by: Jiang Xin <address@hidden>
|
|
||||||
Signed-off-by: Prasad J Pandit <address@hidden>
|
|
||||||
---
|
|
||||||
hw/sd/sdhci.c | 10 +++++-----
|
|
||||||
1 file changed, 5 insertions(+), 5 deletions(-)
|
|
||||||
|
|
||||||
Update: use qemu_log_mask(LOG_UNIMP, ...)
|
|
||||||
-> https://lists.gnu.org/archive/html/qemu-devel/2017-02/msg02354.html
|
|
||||||
|
|
||||||
diff --git a/hw/sd/sdhci.c b/hw/sd/sdhci.c
|
|
||||||
index 5bd5ab6..a9c744b 100644
|
|
||||||
--- a/hw/sd/sdhci.c
|
|
||||||
+++ b/hw/sd/sdhci.c
|
|
||||||
@@ -486,6 +486,11 @@ static void sdhci_sdma_transfer_multi_blocks(SDHCIState *s)
|
|
||||||
uint32_t boundary_chk = 1 << (((s->blksize & 0xf000) >> 12) + 12);
|
|
||||||
uint32_t boundary_count = boundary_chk - (s->sdmasysad % boundary_chk);
|
|
||||||
|
|
||||||
+ if (!(s->trnmod & SDHC_TRNS_BLK_CNT_EN) || !s->blkcnt) {
|
|
||||||
+ qemu_log_mask(LOG_UNIMP, "infinite transfer is not supported\n");
|
|
||||||
+ return;
|
|
||||||
+ }
|
|
||||||
+
|
|
||||||
/* XXX: Some sd/mmc drivers (for example, u-boot-slp) do not account for
|
|
||||||
* possible stop at page boundary if initial address is not page aligned,
|
|
||||||
* allow them to work properly */
|
|
||||||
@@ -797,11 +802,6 @@ static void sdhci_data_transfer(void *opaque)
|
|
||||||
if (s->trnmod & SDHC_TRNS_DMA) {
|
|
||||||
switch (SDHC_DMA_TYPE(s->hostctl)) {
|
|
||||||
case SDHC_CTRL_SDMA:
|
|
||||||
- if ((s->trnmod & SDHC_TRNS_MULTI) &&
|
|
||||||
- (!(s->trnmod & SDHC_TRNS_BLK_CNT_EN) || s->blkcnt == 0)) {
|
|
||||||
- break;
|
|
||||||
- }
|
|
||||||
-
|
|
||||||
if ((s->blkcnt == 1) || !(s->trnmod & SDHC_TRNS_MULTI)) {
|
|
||||||
sdhci_sdma_transfer_single_block(s);
|
|
||||||
} else {
|
|
||||||
--
|
|
||||||
2.9.3
|
|
||||||
|
|
@ -1,112 +0,0 @@
|
|||||||
This patch fixed a problem that was introduced in commit eb700029.
|
|
||||||
|
|
||||||
When net_rx_pkt_attach_iovec() calls eth_strip_vlan()
|
|
||||||
this can result in pkt->ehdr_buf being overflowed, because
|
|
||||||
ehdr_buf is only sizeof(struct eth_header) bytes large
|
|
||||||
but eth_strip_vlan() can write
|
|
||||||
sizeof(struct eth_header) + sizeof(struct vlan_header)
|
|
||||||
bytes into it.
|
|
||||||
|
|
||||||
Devices affected by this problem: vmxnet3.
|
|
||||||
|
|
||||||
Reported-by: Peter Maydell <address@hidden>
|
|
||||||
Signed-off-by: Dmitry Fleytman <address@hidden>
|
|
||||||
---
|
|
||||||
hw/net/net_rx_pkt.c | 34 +++++++++++++++++-----------------
|
|
||||||
1 file changed, 17 insertions(+), 17 deletions(-)
|
|
||||||
|
|
||||||
diff --git a/hw/net/net_rx_pkt.c b/hw/net/net_rx_pkt.c
|
|
||||||
index 1019b50..7c0beac 100644
|
|
||||||
--- a/hw/net/net_rx_pkt.c
|
|
||||||
+++ b/hw/net/net_rx_pkt.c
|
|
||||||
@@ -23,13 +23,13 @@
|
|
||||||
|
|
||||||
struct NetRxPkt {
|
|
||||||
struct virtio_net_hdr virt_hdr;
|
|
||||||
- uint8_t ehdr_buf[sizeof(struct eth_header)];
|
|
||||||
+ uint8_t ehdr_buf[sizeof(struct eth_header) + sizeof(struct vlan_header)];
|
|
||||||
struct iovec *vec;
|
|
||||||
uint16_t vec_len_total;
|
|
||||||
uint16_t vec_len;
|
|
||||||
uint32_t tot_len;
|
|
||||||
uint16_t tci;
|
|
||||||
- bool vlan_stripped;
|
|
||||||
+ size_t ehdr_buf_len;
|
|
||||||
bool has_virt_hdr;
|
|
||||||
eth_pkt_types_e packet_type;
|
|
||||||
|
|
||||||
@@ -88,15 +88,13 @@ net_rx_pkt_pull_data(struct NetRxPkt *pkt,
|
|
||||||
const struct iovec *iov, int iovcnt,
|
|
||||||
size_t ploff)
|
|
||||||
{
|
|
||||||
- if (pkt->vlan_stripped) {
|
|
||||||
+ if (pkt->ehdr_buf_len) {
|
|
||||||
net_rx_pkt_iovec_realloc(pkt, iovcnt + 1);
|
|
||||||
|
|
||||||
pkt->vec[0].iov_base = pkt->ehdr_buf;
|
|
||||||
- pkt->vec[0].iov_len = sizeof(pkt->ehdr_buf);
|
|
||||||
-
|
|
||||||
- pkt->tot_len =
|
|
||||||
- iov_size(iov, iovcnt) - ploff + sizeof(struct eth_header);
|
|
||||||
+ pkt->vec[0].iov_len = pkt->ehdr_buf_len;
|
|
||||||
|
|
||||||
+ pkt->tot_len = iov_size(iov, iovcnt) - ploff + pkt->ehdr_buf_len;
|
|
||||||
pkt->vec_len = iov_copy(pkt->vec + 1, pkt->vec_len_total - 1,
|
|
||||||
iov, iovcnt, ploff, pkt->tot_len);
|
|
||||||
} else {
|
|
||||||
@@ -123,11 +121,12 @@ void net_rx_pkt_attach_iovec(struct NetRxPkt *pkt,
|
|
||||||
uint16_t tci = 0;
|
|
||||||
uint16_t ploff = iovoff;
|
|
||||||
assert(pkt);
|
|
||||||
- pkt->vlan_stripped = false;
|
|
||||||
|
|
||||||
if (strip_vlan) {
|
|
||||||
- pkt->vlan_stripped = eth_strip_vlan(iov, iovcnt, iovoff, pkt->ehdr_buf,
|
|
||||||
- &ploff, &tci);
|
|
||||||
+ pkt->ehdr_buf_len = eth_strip_vlan(iov, iovcnt, iovoff, pkt->ehdr_buf,
|
|
||||||
+ &ploff, &tci);
|
|
||||||
+ } else {
|
|
||||||
+ pkt->ehdr_buf_len = 0;
|
|
||||||
}
|
|
||||||
|
|
||||||
pkt->tci = tci;
|
|
||||||
@@ -143,12 +142,13 @@ void net_rx_pkt_attach_iovec_ex(struct NetRxPkt *pkt,
|
|
||||||
uint16_t tci = 0;
|
|
||||||
uint16_t ploff = iovoff;
|
|
||||||
assert(pkt);
|
|
||||||
- pkt->vlan_stripped = false;
|
|
||||||
|
|
||||||
if (strip_vlan) {
|
|
||||||
- pkt->vlan_stripped = eth_strip_vlan_ex(iov, iovcnt, iovoff, vet,
|
|
||||||
- pkt->ehdr_buf,
|
|
||||||
- &ploff, &tci);
|
|
||||||
+ pkt->ehdr_buf_len = eth_strip_vlan_ex(iov, iovcnt, iovoff, vet,
|
|
||||||
+ pkt->ehdr_buf,
|
|
||||||
+ &ploff, &tci);
|
|
||||||
+ } else {
|
|
||||||
+ pkt->ehdr_buf_len = 0;
|
|
||||||
}
|
|
||||||
|
|
||||||
pkt->tci = tci;
|
|
||||||
@@ -162,8 +162,8 @@ void net_rx_pkt_dump(struct NetRxPkt *pkt)
|
|
||||||
NetRxPkt *pkt = (NetRxPkt *)pkt;
|
|
||||||
assert(pkt);
|
|
||||||
|
|
||||||
- printf("RX PKT: tot_len: %d, vlan_stripped: %d, vlan_tag: %d\n",
|
|
||||||
- pkt->tot_len, pkt->vlan_stripped, pkt->tci);
|
|
||||||
+ printf("RX PKT: tot_len: %d, ehdr_buf_len: %lu, vlan_tag: %d\n",
|
|
||||||
+ pkt->tot_len, pkt->ehdr_buf_len, pkt->tci);
|
|
||||||
#endif
|
|
||||||
}
|
|
||||||
|
|
||||||
@@ -426,7 +426,7 @@ bool net_rx_pkt_is_vlan_stripped(struct NetRxPkt *pkt)
|
|
||||||
{
|
|
||||||
assert(pkt);
|
|
||||||
|
|
||||||
- return pkt->vlan_stripped;
|
|
||||||
+ return pkt->ehdr_buf_len ? true : false;
|
|
||||||
}
|
|
||||||
|
|
||||||
bool net_rx_pkt_has_virt_hdr(struct NetRxPkt *pkt)
|
|
||||||
--
|
|
||||||
2.7.4
|
|
@ -1,52 +0,0 @@
|
|||||||
From 95ed56939eb2eaa4e2f349fe6dcd13ca4edfd8fb Mon Sep 17 00:00:00 2001
|
|
||||||
From: Li Qiang <liqiang6-s@360.cn>
|
|
||||||
Date: Tue, 7 Feb 2017 02:23:33 -0800
|
|
||||||
Subject: [PATCH] usb: ohci: limit the number of link eds
|
|
||||||
|
|
||||||
The guest may builds an infinite loop with link eds. This patch
|
|
||||||
limit the number of linked ed to avoid this.
|
|
||||||
|
|
||||||
Signed-off-by: Li Qiang <liqiang6-s@360.cn>
|
|
||||||
Message-id: 5899a02e.45ca240a.6c373.93c1@mx.google.com
|
|
||||||
Signed-off-by: Gerd Hoffmann <kraxel@redhat.com>
|
|
||||||
---
|
|
||||||
hw/usb/hcd-ohci.c | 9 ++++++++-
|
|
||||||
1 file changed, 8 insertions(+), 1 deletion(-)
|
|
||||||
|
|
||||||
diff --git a/hw/usb/hcd-ohci.c b/hw/usb/hcd-ohci.c
|
|
||||||
index 2cba3e3..21c93e0 100644
|
|
||||||
--- a/hw/usb/hcd-ohci.c
|
|
||||||
+++ b/hw/usb/hcd-ohci.c
|
|
||||||
@@ -42,6 +42,8 @@
|
|
||||||
|
|
||||||
#define OHCI_MAX_PORTS 15
|
|
||||||
|
|
||||||
+#define ED_LINK_LIMIT 4
|
|
||||||
+
|
|
||||||
static int64_t usb_frame_time;
|
|
||||||
static int64_t usb_bit_time;
|
|
||||||
|
|
||||||
@@ -1184,7 +1186,7 @@ static int ohci_service_ed_list(OHCIState *ohci, uint32_t head, int completion)
|
|
||||||
uint32_t next_ed;
|
|
||||||
uint32_t cur;
|
|
||||||
int active;
|
|
||||||
-
|
|
||||||
+ uint32_t link_cnt = 0;
|
|
||||||
active = 0;
|
|
||||||
|
|
||||||
if (head == 0)
|
|
||||||
@@ -1199,6 +1201,11 @@ static int ohci_service_ed_list(OHCIState *ohci, uint32_t head, int completion)
|
|
||||||
|
|
||||||
next_ed = ed.next & OHCI_DPTR_MASK;
|
|
||||||
|
|
||||||
+ if (++link_cnt > ED_LINK_LIMIT) {
|
|
||||||
+ ohci_die(ohci);
|
|
||||||
+ return 0;
|
|
||||||
+ }
|
|
||||||
+
|
|
||||||
if ((ed.head & OHCI_ED_H) || (ed.flags & OHCI_ED_K)) {
|
|
||||||
uint32_t addr;
|
|
||||||
/* Cancel pending packets for ED that have been paused. */
|
|
||||||
--
|
|
||||||
2.10.2
|
|
||||||
|
|
@ -1,49 +0,0 @@
|
|||||||
From d63fb193e71644a073b77ff5ac6f1216f2f6cf6e Mon Sep 17 00:00:00 2001
|
|
||||||
From: Li Qiang <liq3ea@gmail.com>
|
|
||||||
Date: Mon, 27 Mar 2017 21:13:19 +0200
|
|
||||||
Subject: [PATCH] 9pfs: fix file descriptor leak
|
|
||||||
|
|
||||||
The v9fs_create() and v9fs_lcreate() functions are used to create a file
|
|
||||||
on the backend and to associate it to a fid. The fid shouldn't be already
|
|
||||||
in-use, otherwise both functions may silently leak a file descriptor or
|
|
||||||
allocated memory. The current code doesn't check that.
|
|
||||||
|
|
||||||
This patch ensures that the fid isn't already associated to anything
|
|
||||||
before using it.
|
|
||||||
|
|
||||||
Signed-off-by: Li Qiang <liqiang6-s@360.cn>
|
|
||||||
(reworded the changelog, Greg Kurz)
|
|
||||||
Signed-off-by: Greg Kurz <groug@kaod.org>
|
|
||||||
---
|
|
||||||
hw/9pfs/9p.c | 8 ++++++++
|
|
||||||
1 file changed, 8 insertions(+)
|
|
||||||
|
|
||||||
diff --git a/hw/9pfs/9p.c b/hw/9pfs/9p.c
|
|
||||||
index b8c0b99..48babce 100644
|
|
||||||
--- a/hw/9pfs/9p.c
|
|
||||||
+++ b/hw/9pfs/9p.c
|
|
||||||
@@ -1550,6 +1550,10 @@ static void coroutine_fn v9fs_lcreate(void *opaque)
|
|
||||||
err = -ENOENT;
|
|
||||||
goto out_nofid;
|
|
||||||
}
|
|
||||||
+ if (fidp->fid_type != P9_FID_NONE) {
|
|
||||||
+ err = -EINVAL;
|
|
||||||
+ goto out;
|
|
||||||
+ }
|
|
||||||
|
|
||||||
flags = get_dotl_openflags(pdu->s, flags);
|
|
||||||
err = v9fs_co_open2(pdu, fidp, &name, gid,
|
|
||||||
@@ -2153,6 +2157,10 @@ static void coroutine_fn v9fs_create(void *opaque)
|
|
||||||
err = -EINVAL;
|
|
||||||
goto out_nofid;
|
|
||||||
}
|
|
||||||
+ if (fidp->fid_type != P9_FID_NONE) {
|
|
||||||
+ err = -EINVAL;
|
|
||||||
+ goto out;
|
|
||||||
+ }
|
|
||||||
if (perm & P9_STAT_MODE_DIR) {
|
|
||||||
err = v9fs_co_mkdir(pdu, fidp, &name, perm & 0777,
|
|
||||||
fidp->uid, -1, &stbuf);
|
|
||||||
--
|
|
||||||
2.10.2
|
|
||||||
|
|
@ -1,64 +0,0 @@
|
|||||||
From 9c6b899f7a46893ab3b671e341a2234e9c0c060e Mon Sep 17 00:00:00 2001
|
|
||||||
From: Greg Kurz <groug@kaod.org>
|
|
||||||
Date: Mon, 17 Apr 2017 10:53:23 +0200
|
|
||||||
Subject: [PATCH] 9pfs: local: set the path of the export root to "."
|
|
||||||
MIME-Version: 1.0
|
|
||||||
Content-Type: text/plain; charset=UTF-8
|
|
||||||
Content-Transfer-Encoding: 8bit
|
|
||||||
|
|
||||||
The local backend was recently converted to using "at*()" syscalls in order
|
|
||||||
to ensure all accesses happen below the shared directory. This requires that
|
|
||||||
we only pass relative paths, otherwise the dirfd argument to the "at*()"
|
|
||||||
syscalls is ignored and the path is treated as an absolute path in the host.
|
|
||||||
This is actually the case for paths in all fids, with the notable exception
|
|
||||||
of the root fid, whose path is "/". This causes the following backend ops to
|
|
||||||
act on the "/" directory of the host instead of the virtfs shared directory
|
|
||||||
when the export root is involved:
|
|
||||||
- lstat
|
|
||||||
- chmod
|
|
||||||
- chown
|
|
||||||
- utimensat
|
|
||||||
|
|
||||||
ie, chmod /9p_mount_point in the guest will be converted to chmod / in the
|
|
||||||
host for example. This could cause security issues with a privileged QEMU.
|
|
||||||
|
|
||||||
All "*at()" syscalls are being passed an open file descriptor. In the case
|
|
||||||
of the export root, this file descriptor points to the path in the host that
|
|
||||||
was passed to -fsdev.
|
|
||||||
|
|
||||||
The fix is thus as simple as changing the path of the export root fid to be
|
|
||||||
"." instead of "/".
|
|
||||||
|
|
||||||
This is CVE-2017-7471.
|
|
||||||
|
|
||||||
Cc: qemu-stable@nongnu.org
|
|
||||||
Reported-by: Léo Gaspard <leo@gaspard.io>
|
|
||||||
Signed-off-by: Greg Kurz <groug@kaod.org>
|
|
||||||
Reviewed-by: Eric Blake <eblake@redhat.com>
|
|
||||||
Signed-off-by: Peter Maydell <peter.maydell@linaro.org>
|
|
||||||
---
|
|
||||||
hw/9pfs/9p-local.c | 7 ++++++-
|
|
||||||
1 file changed, 6 insertions(+), 1 deletion(-)
|
|
||||||
|
|
||||||
diff --git a/hw/9pfs/9p-local.c b/hw/9pfs/9p-local.c
|
|
||||||
index 45e9a1f..f3ebca4 100644
|
|
||||||
--- a/hw/9pfs/9p-local.c
|
|
||||||
+++ b/hw/9pfs/9p-local.c
|
|
||||||
@@ -1098,8 +1098,13 @@ static int local_name_to_path(FsContext *ctx, V9fsPath *dir_path,
|
|
||||||
{
|
|
||||||
if (dir_path) {
|
|
||||||
v9fs_path_sprintf(target, "%s/%s", dir_path->data, name);
|
|
||||||
- } else {
|
|
||||||
+ } else if (strcmp(name, "/")) {
|
|
||||||
v9fs_path_sprintf(target, "%s", name);
|
|
||||||
+ } else {
|
|
||||||
+ /* We want the path of the export root to be relative, otherwise
|
|
||||||
+ * "*at()" syscalls would treat it as "/" in the host.
|
|
||||||
+ */
|
|
||||||
+ v9fs_path_sprintf(target, "%s", ".");
|
|
||||||
}
|
|
||||||
return 0;
|
|
||||||
}
|
|
||||||
--
|
|
||||||
2.10.2
|
|
||||||
|
|
@ -1,28 +0,0 @@
|
|||||||
From 4ffcdef4277a91af15a3c09f7d16af072c29f3f2 Mon Sep 17 00:00:00 2001
|
|
||||||
From: Li Qiang <liq3ea@gmail.com>
|
|
||||||
Date: Fri, 7 Apr 2017 03:48:52 -0700
|
|
||||||
Subject: [PATCH] 9pfs: xattr: fix memory leak in v9fs_list_xattr
|
|
||||||
|
|
||||||
Free 'orig_value' in error path.
|
|
||||||
|
|
||||||
Signed-off-by: Li Qiang <liqiang6-s@360.cn>
|
|
||||||
Signed-off-by: Greg Kurz <groug@kaod.org>
|
|
||||||
---
|
|
||||||
hw/9pfs/9p-xattr.c | 1 +
|
|
||||||
1 file changed, 1 insertion(+)
|
|
||||||
|
|
||||||
diff --git a/hw/9pfs/9p-xattr.c b/hw/9pfs/9p-xattr.c
|
|
||||||
index eec160b..d05c1a1 100644
|
|
||||||
--- a/hw/9pfs/9p-xattr.c
|
|
||||||
+++ b/hw/9pfs/9p-xattr.c
|
|
||||||
@@ -108,6 +108,7 @@ ssize_t v9fs_list_xattr(FsContext *ctx, const char *path,
|
|
||||||
g_free(name);
|
|
||||||
close_preserve_errno(dirfd);
|
|
||||||
if (xattr_len < 0) {
|
|
||||||
+ g_free(orig_value);
|
|
||||||
return -1;
|
|
||||||
}
|
|
||||||
|
|
||||||
--
|
|
||||||
2.10.2
|
|
||||||
|
|
@ -0,0 +1,47 @@
|
|||||||
|
From 041e32b8d9d076980b4e35317c0339e57ab888f1 Mon Sep 17 00:00:00 2001
|
||||||
|
From: Max Reitz <mreitz@redhat.com>
|
||||||
|
Date: Sun, 11 Jun 2017 14:37:14 +0200
|
||||||
|
Subject: [PATCH] qemu-nbd: Ignore SIGPIPE
|
||||||
|
|
||||||
|
qemu proper has done so for 13 years
|
||||||
|
(8a7ddc38a60648257dc0645ab4a05b33d6040063), qemu-img and qemu-io have
|
||||||
|
done so for four years (526eda14a68d5b3596be715505289b541288ef2a).
|
||||||
|
Ignoring this signal is especially important in qemu-nbd because
|
||||||
|
otherwise a client can easily take down the qemu-nbd server by dropping
|
||||||
|
the connection when the server wants to send something, for example:
|
||||||
|
|
||||||
|
$ qemu-nbd -x foo -f raw -t null-co:// &
|
||||||
|
[1] 12726
|
||||||
|
$ qemu-io -c quit nbd://localhost/bar
|
||||||
|
can't open device nbd://localhost/bar: No export with name 'bar' available
|
||||||
|
[1] + 12726 broken pipe qemu-nbd -x foo -f raw -t null-co://
|
||||||
|
|
||||||
|
In this case, the client sends an NBD_OPT_ABORT and closes the
|
||||||
|
connection (because it is not required to wait for a reply), but the
|
||||||
|
server replies with an NBD_REP_ACK (because it is required to reply).
|
||||||
|
|
||||||
|
Signed-off-by: Max Reitz <mreitz@redhat.com>
|
||||||
|
Message-Id: <20170611123714.31292-1-mreitz@redhat.com>
|
||||||
|
Signed-off-by: Paolo Bonzini <pbonzini@redhat.com>
|
||||||
|
---
|
||||||
|
qemu-nbd.c | 4 ++++
|
||||||
|
1 file changed, 4 insertions(+)
|
||||||
|
|
||||||
|
diff --git a/qemu-nbd.c b/qemu-nbd.c
|
||||||
|
index 9464a0461c..4dd3fd4732 100644
|
||||||
|
--- a/qemu-nbd.c
|
||||||
|
+++ b/qemu-nbd.c
|
||||||
|
@@ -581,6 +581,10 @@ int main(int argc, char **argv)
|
||||||
|
sa_sigterm.sa_handler = termsig_handler;
|
||||||
|
sigaction(SIGTERM, &sa_sigterm, NULL);
|
||||||
|
|
||||||
|
+#ifdef CONFIG_POSIX
|
||||||
|
+ signal(SIGPIPE, SIG_IGN);
|
||||||
|
+#endif
|
||||||
|
+
|
||||||
|
module_call_init(MODULE_INIT_TRACE);
|
||||||
|
qcrypto_init(&error_fatal);
|
||||||
|
|
||||||
|
--
|
||||||
|
2.13.0
|
||||||
|
|
@ -0,0 +1,50 @@
|
|||||||
|
From bd4a683505b27adc1ac809f71e918e58573d851d Mon Sep 17 00:00:00 2001
|
||||||
|
From: Gerd Hoffmann <kraxel@redhat.com>
|
||||||
|
Date: Tue, 9 May 2017 13:01:28 +0200
|
||||||
|
Subject: [PATCH] usb-redir: fix stack overflow in usbredir_log_data
|
||||||
|
MIME-Version: 1.0
|
||||||
|
Content-Type: text/plain; charset=UTF-8
|
||||||
|
Content-Transfer-Encoding: 8bit
|
||||||
|
|
||||||
|
Don't reinvent a broken wheel, just use the hexdump function we have.
|
||||||
|
|
||||||
|
Impact: low, broken code doesn't run unless you have debug logging
|
||||||
|
enabled.
|
||||||
|
|
||||||
|
Reported-by: 李强 <liqiang6-s@360.cn>
|
||||||
|
Signed-off-by: Gerd Hoffmann <kraxel@redhat.com>
|
||||||
|
Message-id: 20170509110128.27261-1-kraxel@redhat.com
|
||||||
|
---
|
||||||
|
hw/usb/redirect.c | 13 +------------
|
||||||
|
1 file changed, 1 insertion(+), 12 deletions(-)
|
||||||
|
|
||||||
|
diff --git a/hw/usb/redirect.c b/hw/usb/redirect.c
|
||||||
|
index b001a27f05..ad5ef783a6 100644
|
||||||
|
--- a/hw/usb/redirect.c
|
||||||
|
+++ b/hw/usb/redirect.c
|
||||||
|
@@ -229,21 +229,10 @@ static void usbredir_log(void *priv, int level, const char *msg)
|
||||||
|
static void usbredir_log_data(USBRedirDevice *dev, const char *desc,
|
||||||
|
const uint8_t *data, int len)
|
||||||
|
{
|
||||||
|
- int i, j, n;
|
||||||
|
-
|
||||||
|
if (dev->debug < usbredirparser_debug_data) {
|
||||||
|
return;
|
||||||
|
}
|
||||||
|
-
|
||||||
|
- for (i = 0; i < len; i += j) {
|
||||||
|
- char buf[128];
|
||||||
|
-
|
||||||
|
- n = sprintf(buf, "%s", desc);
|
||||||
|
- for (j = 0; j < 8 && i + j < len; j++) {
|
||||||
|
- n += sprintf(buf + n, " %02X", data[i + j]);
|
||||||
|
- }
|
||||||
|
- error_report("%s", buf);
|
||||||
|
- }
|
||||||
|
+ qemu_hexdump((char *)data, stderr, desc, len);
|
||||||
|
}
|
||||||
|
|
||||||
|
/*
|
||||||
|
--
|
||||||
|
2.13.0
|
||||||
|
|
@ -0,0 +1,40 @@
|
|||||||
|
[Qemu-devel] [PULL 21/41] exec: use qemu_ram_ptr_length to access guest
|
||||||
|
From: Prasad J Pandit <address@hidden>
|
||||||
|
|
||||||
|
When accessing guest's ram block during DMA operation, use
|
||||||
|
'qemu_ram_ptr_length' to get ram block pointer. It ensures
|
||||||
|
that DMA operation of given length is possible; And avoids
|
||||||
|
any OOB memory access situations.
|
||||||
|
|
||||||
|
Reported-by: Alex <address@hidden>
|
||||||
|
Signed-off-by: Prasad J Pandit <address@hidden>
|
||||||
|
Message-Id: <address@hidden>
|
||||||
|
Signed-off-by: Paolo Bonzini <address@hidden>
|
||||||
|
---
|
||||||
|
exec.c | 4 ++--
|
||||||
|
1 file changed, 2 insertions(+), 2 deletions(-)
|
||||||
|
|
||||||
|
diff --git a/exec.c b/exec.c
|
||||||
|
index a083ff8..ad103ce 100644
|
||||||
|
--- a/exec.c
|
||||||
|
+++ b/exec.c
|
||||||
|
@@ -2929,7 +2929,7 @@ static MemTxResult address_space_write_continue(AddressSpace *as, hwaddr addr,
|
||||||
|
}
|
||||||
|
} else {
|
||||||
|
/* RAM case */
|
||||||
|
- ptr = qemu_map_ram_ptr(mr->ram_block, addr1);
|
||||||
|
+ ptr = qemu_ram_ptr_length(mr->ram_block, addr1, &l);
|
||||||
|
memcpy(ptr, buf, l);
|
||||||
|
invalidate_and_set_dirty(mr, addr1, l);
|
||||||
|
}
|
||||||
|
@@ -3020,7 +3020,7 @@ MemTxResult address_space_read_continue(AddressSpace *as, hwaddr addr,
|
||||||
|
}
|
||||||
|
} else {
|
||||||
|
/* RAM case */
|
||||||
|
- ptr = qemu_map_ram_ptr(mr->ram_block, addr1);
|
||||||
|
+ ptr = qemu_ram_ptr_length(mr->ram_block, addr1, &l);
|
||||||
|
memcpy(buf, ptr, l);
|
||||||
|
}
|
||||||
|
|
||||||
|
--
|
||||||
|
1.8.3.1
|
@ -0,0 +1,29 @@
|
|||||||
|
[Qemu-devel] [PATCH] slirp: check len against dhcp options array end
|
||||||
|
From: Prasad J Pandit <address@hidden>
|
||||||
|
|
||||||
|
While parsing dhcp options string in 'dhcp_decode', if an options'
|
||||||
|
length 'len' appeared towards the end of 'bp_vend' array, ensuing
|
||||||
|
read could lead to an OOB memory access issue. Add check to avoid it.
|
||||||
|
|
||||||
|
Reported-by: Reno Robert <address@hidden>
|
||||||
|
Signed-off-by: Prasad J Pandit <address@hidden>
|
||||||
|
---
|
||||||
|
slirp/bootp.c | 3 +++
|
||||||
|
1 file changed, 3 insertions(+)
|
||||||
|
|
||||||
|
diff --git a/slirp/bootp.c b/slirp/bootp.c
|
||||||
|
index 5a4646c..5dd1a41 100644
|
||||||
|
--- a/slirp/bootp.c
|
||||||
|
+++ b/slirp/bootp.c
|
||||||
|
@@ -123,6 +123,9 @@ static void dhcp_decode(const struct bootp_t *bp, int *pmsg_type,
|
||||||
|
if (p >= p_end)
|
||||||
|
break;
|
||||||
|
len = *p++;
|
||||||
|
+ if (p + len > p_end) {
|
||||||
|
+ break;
|
||||||
|
+ }
|
||||||
|
DPRINTF("dhcp: tag=%d len=%d\n", tag, len);
|
||||||
|
|
||||||
|
switch(tag) {
|
||||||
|
--
|
||||||
|
2.9.4
|
@ -0,0 +1,122 @@
|
|||||||
|
From 87e459a810d7b1ec1638085b5a80ea3d9b43119a Mon Sep 17 00:00:00 2001
|
||||||
|
From: Paolo Bonzini <pbonzini@redhat.com>
|
||||||
|
Date: Thu, 1 Jun 2017 17:26:14 +0200
|
||||||
|
Subject: [PATCH] megasas: always store SCSIRequest* into MegasasCmd
|
||||||
|
|
||||||
|
This ensures that the request is unref'ed properly, and avoids a
|
||||||
|
segmentation fault in the new qtest testcase that is added.
|
||||||
|
This is CVE-2017-9503.
|
||||||
|
|
||||||
|
Reported-by: Zhangyanyu <zyy4013@stu.ouc.edu.cn>
|
||||||
|
Signed-off-by: Paolo Bonzini <pbonzini@redhat.com>
|
||||||
|
---
|
||||||
|
hw/scsi/megasas.c | 31 ++++++++++++++++---------------
|
||||||
|
2 files changed, 51 insertions(+), 15 deletions(-)
|
||||||
|
|
||||||
|
diff --git a/hw/scsi/megasas.c b/hw/scsi/megasas.c
|
||||||
|
index 135662df31..734fdaef90 100644
|
||||||
|
--- a/hw/scsi/megasas.c
|
||||||
|
+++ b/hw/scsi/megasas.c
|
||||||
|
@@ -609,6 +609,9 @@ static void megasas_reset_frames(MegasasState *s)
|
||||||
|
static void megasas_abort_command(MegasasCmd *cmd)
|
||||||
|
{
|
||||||
|
/* Never abort internal commands. */
|
||||||
|
+ if (cmd->dcmd_opcode != -1) {
|
||||||
|
+ return;
|
||||||
|
+ }
|
||||||
|
if (cmd->req != NULL) {
|
||||||
|
scsi_req_cancel(cmd->req);
|
||||||
|
}
|
||||||
|
@@ -1017,7 +1020,6 @@ static int megasas_pd_get_info_submit(SCSIDevice *sdev, int lun,
|
||||||
|
uint64_t pd_size;
|
||||||
|
uint16_t pd_id = ((sdev->id & 0xFF) << 8) | (lun & 0xFF);
|
||||||
|
uint8_t cmdbuf[6];
|
||||||
|
- SCSIRequest *req;
|
||||||
|
size_t len, resid;
|
||||||
|
|
||||||
|
if (!cmd->iov_buf) {
|
||||||
|
@@ -1026,8 +1028,8 @@ static int megasas_pd_get_info_submit(SCSIDevice *sdev, int lun,
|
||||||
|
info->inquiry_data[0] = 0x7f; /* Force PQual 0x3, PType 0x1f */
|
||||||
|
info->vpd_page83[0] = 0x7f;
|
||||||
|
megasas_setup_inquiry(cmdbuf, 0, sizeof(info->inquiry_data));
|
||||||
|
- req = scsi_req_new(sdev, cmd->index, lun, cmdbuf, cmd);
|
||||||
|
- if (!req) {
|
||||||
|
+ cmd->req = scsi_req_new(sdev, cmd->index, lun, cmdbuf, cmd);
|
||||||
|
+ if (!cmd->req) {
|
||||||
|
trace_megasas_dcmd_req_alloc_failed(cmd->index,
|
||||||
|
"PD get info std inquiry");
|
||||||
|
g_free(cmd->iov_buf);
|
||||||
|
@@ -1036,26 +1038,26 @@ static int megasas_pd_get_info_submit(SCSIDevice *sdev, int lun,
|
||||||
|
}
|
||||||
|
trace_megasas_dcmd_internal_submit(cmd->index,
|
||||||
|
"PD get info std inquiry", lun);
|
||||||
|
- len = scsi_req_enqueue(req);
|
||||||
|
+ len = scsi_req_enqueue(cmd->req);
|
||||||
|
if (len > 0) {
|
||||||
|
cmd->iov_size = len;
|
||||||
|
- scsi_req_continue(req);
|
||||||
|
+ scsi_req_continue(cmd->req);
|
||||||
|
}
|
||||||
|
return MFI_STAT_INVALID_STATUS;
|
||||||
|
} else if (info->inquiry_data[0] != 0x7f && info->vpd_page83[0] == 0x7f) {
|
||||||
|
megasas_setup_inquiry(cmdbuf, 0x83, sizeof(info->vpd_page83));
|
||||||
|
- req = scsi_req_new(sdev, cmd->index, lun, cmdbuf, cmd);
|
||||||
|
- if (!req) {
|
||||||
|
+ cmd->req = scsi_req_new(sdev, cmd->index, lun, cmdbuf, cmd);
|
||||||
|
+ if (!cmd->req) {
|
||||||
|
trace_megasas_dcmd_req_alloc_failed(cmd->index,
|
||||||
|
"PD get info vpd inquiry");
|
||||||
|
return MFI_STAT_FLASH_ALLOC_FAIL;
|
||||||
|
}
|
||||||
|
trace_megasas_dcmd_internal_submit(cmd->index,
|
||||||
|
"PD get info vpd inquiry", lun);
|
||||||
|
- len = scsi_req_enqueue(req);
|
||||||
|
+ len = scsi_req_enqueue(cmd->req);
|
||||||
|
if (len > 0) {
|
||||||
|
cmd->iov_size = len;
|
||||||
|
- scsi_req_continue(req);
|
||||||
|
+ scsi_req_continue(cmd->req);
|
||||||
|
}
|
||||||
|
return MFI_STAT_INVALID_STATUS;
|
||||||
|
}
|
||||||
|
@@ -1217,7 +1219,6 @@ static int megasas_ld_get_info_submit(SCSIDevice *sdev, int lun,
|
||||||
|
struct mfi_ld_info *info = cmd->iov_buf;
|
||||||
|
size_t dcmd_size = sizeof(struct mfi_ld_info);
|
||||||
|
uint8_t cdb[6];
|
||||||
|
- SCSIRequest *req;
|
||||||
|
ssize_t len, resid;
|
||||||
|
uint16_t sdev_id = ((sdev->id & 0xFF) << 8) | (lun & 0xFF);
|
||||||
|
uint64_t ld_size;
|
||||||
|
@@ -1226,8 +1227,8 @@ static int megasas_ld_get_info_submit(SCSIDevice *sdev, int lun,
|
||||||
|
cmd->iov_buf = g_malloc0(dcmd_size);
|
||||||
|
info = cmd->iov_buf;
|
||||||
|
megasas_setup_inquiry(cdb, 0x83, sizeof(info->vpd_page83));
|
||||||
|
- req = scsi_req_new(sdev, cmd->index, lun, cdb, cmd);
|
||||||
|
- if (!req) {
|
||||||
|
+ cmd->req = scsi_req_new(sdev, cmd->index, lun, cdb, cmd);
|
||||||
|
+ if (!cmd->req) {
|
||||||
|
trace_megasas_dcmd_req_alloc_failed(cmd->index,
|
||||||
|
"LD get info vpd inquiry");
|
||||||
|
g_free(cmd->iov_buf);
|
||||||
|
@@ -1236,10 +1237,10 @@ static int megasas_ld_get_info_submit(SCSIDevice *sdev, int lun,
|
||||||
|
}
|
||||||
|
trace_megasas_dcmd_internal_submit(cmd->index,
|
||||||
|
"LD get info vpd inquiry", lun);
|
||||||
|
- len = scsi_req_enqueue(req);
|
||||||
|
+ len = scsi_req_enqueue(cmd->req);
|
||||||
|
if (len > 0) {
|
||||||
|
cmd->iov_size = len;
|
||||||
|
- scsi_req_continue(req);
|
||||||
|
+ scsi_req_continue(cmd->req);
|
||||||
|
}
|
||||||
|
return MFI_STAT_INVALID_STATUS;
|
||||||
|
}
|
||||||
|
@@ -1851,7 +1852,7 @@ static void megasas_command_complete(SCSIRequest *req, uint32_t status,
|
||||||
|
return;
|
||||||
|
}
|
||||||
|
|
||||||
|
- if (cmd->req == NULL) {
|
||||||
|
+ if (cmd->dcmd_opcode != -1) {
|
||||||
|
/*
|
||||||
|
* Internal command complete
|
||||||
|
*/
|
@ -0,0 +1,114 @@
|
|||||||
|
From 5104fac8539eaf155fc6de93e164be43e1e62242 Mon Sep 17 00:00:00 2001
|
||||||
|
From: Paolo Bonzini <pbonzini@redhat.com>
|
||||||
|
Date: Thu, 1 Jun 2017 17:18:23 +0200
|
||||||
|
Subject: [PATCH] megasas: do not read DCMD opcode more than once from frame
|
||||||
|
|
||||||
|
Avoid TOC-TOU bugs by storing the DCMD opcode in the MegasasCmd
|
||||||
|
|
||||||
|
Signed-off-by: Paolo Bonzini <pbonzini@redhat.com>
|
||||||
|
---
|
||||||
|
hw/scsi/megasas.c | 25 +++++++++++--------------
|
||||||
|
1 file changed, 11 insertions(+), 14 deletions(-)
|
||||||
|
|
||||||
|
diff --git a/hw/scsi/megasas.c b/hw/scsi/megasas.c
|
||||||
|
index c353118882..a3f75c1650 100644
|
||||||
|
--- a/hw/scsi/megasas.c
|
||||||
|
+++ b/hw/scsi/megasas.c
|
||||||
|
@@ -63,6 +63,7 @@ typedef struct MegasasCmd {
|
||||||
|
|
||||||
|
hwaddr pa;
|
||||||
|
hwaddr pa_size;
|
||||||
|
+ uint32_t dcmd_opcode;
|
||||||
|
union mfi_frame *frame;
|
||||||
|
SCSIRequest *req;
|
||||||
|
QEMUSGList qsg;
|
||||||
|
@@ -513,6 +514,7 @@ static MegasasCmd *megasas_enqueue_frame(MegasasState *s,
|
||||||
|
cmd->context &= (uint64_t)0xFFFFFFFF;
|
||||||
|
}
|
||||||
|
cmd->count = count;
|
||||||
|
+ cmd->dcmd_opcode = -1;
|
||||||
|
s->busy++;
|
||||||
|
|
||||||
|
if (s->consumer_pa) {
|
||||||
|
@@ -1562,22 +1564,21 @@ static const struct dcmd_cmd_tbl_t {
|
||||||
|
|
||||||
|
static int megasas_handle_dcmd(MegasasState *s, MegasasCmd *cmd)
|
||||||
|
{
|
||||||
|
- int opcode;
|
||||||
|
int retval = 0;
|
||||||
|
size_t len;
|
||||||
|
const struct dcmd_cmd_tbl_t *cmdptr = dcmd_cmd_tbl;
|
||||||
|
|
||||||
|
- opcode = le32_to_cpu(cmd->frame->dcmd.opcode);
|
||||||
|
- trace_megasas_handle_dcmd(cmd->index, opcode);
|
||||||
|
+ cmd->dcmd_opcode = le32_to_cpu(cmd->frame->dcmd.opcode);
|
||||||
|
+ trace_megasas_handle_dcmd(cmd->index, cmd->dcmd_opcode);
|
||||||
|
if (megasas_map_dcmd(s, cmd) < 0) {
|
||||||
|
return MFI_STAT_MEMORY_NOT_AVAILABLE;
|
||||||
|
}
|
||||||
|
- while (cmdptr->opcode != -1 && cmdptr->opcode != opcode) {
|
||||||
|
+ while (cmdptr->opcode != -1 && cmdptr->opcode != cmd->dcmd_opcode) {
|
||||||
|
cmdptr++;
|
||||||
|
}
|
||||||
|
len = cmd->iov_size;
|
||||||
|
if (cmdptr->opcode == -1) {
|
||||||
|
- trace_megasas_dcmd_unhandled(cmd->index, opcode, len);
|
||||||
|
+ trace_megasas_dcmd_unhandled(cmd->index, cmd->dcmd_opcode, len);
|
||||||
|
retval = megasas_dcmd_dummy(s, cmd);
|
||||||
|
} else {
|
||||||
|
trace_megasas_dcmd_enter(cmd->index, cmdptr->desc, len);
|
||||||
|
@@ -1592,13 +1593,11 @@ static int megasas_handle_dcmd(MegasasState *s, MegasasCmd *cmd)
|
||||||
|
static int megasas_finish_internal_dcmd(MegasasCmd *cmd,
|
||||||
|
SCSIRequest *req)
|
||||||
|
{
|
||||||
|
- int opcode;
|
||||||
|
int retval = MFI_STAT_OK;
|
||||||
|
int lun = req->lun;
|
||||||
|
|
||||||
|
- opcode = le32_to_cpu(cmd->frame->dcmd.opcode);
|
||||||
|
- trace_megasas_dcmd_internal_finish(cmd->index, opcode, lun);
|
||||||
|
- switch (opcode) {
|
||||||
|
+ trace_megasas_dcmd_internal_finish(cmd->index, cmd->dcmd_opcode, lun);
|
||||||
|
+ switch (cmd->dcmd_opcode) {
|
||||||
|
case MFI_DCMD_PD_GET_INFO:
|
||||||
|
retval = megasas_pd_get_info_submit(req->dev, lun, cmd);
|
||||||
|
break;
|
||||||
|
@@ -1606,7 +1605,7 @@ static int megasas_finish_internal_dcmd(MegasasCmd *cmd,
|
||||||
|
retval = megasas_ld_get_info_submit(req->dev, lun, cmd);
|
||||||
|
break;
|
||||||
|
default:
|
||||||
|
- trace_megasas_dcmd_internal_invalid(cmd->index, opcode);
|
||||||
|
+ trace_megasas_dcmd_internal_invalid(cmd->index, cmd->dcmd_opcode);
|
||||||
|
retval = MFI_STAT_INVALID_DCMD;
|
||||||
|
break;
|
||||||
|
}
|
||||||
|
@@ -1827,7 +1826,6 @@ static void megasas_xfer_complete(SCSIRequest *req, uint32_t len)
|
||||||
|
{
|
||||||
|
MegasasCmd *cmd = req->hba_private;
|
||||||
|
uint8_t *buf;
|
||||||
|
- uint32_t opcode;
|
||||||
|
|
||||||
|
trace_megasas_io_complete(cmd->index, len);
|
||||||
|
|
||||||
|
@@ -1837,8 +1835,7 @@ static void megasas_xfer_complete(SCSIRequest *req, uint32_t len)
|
||||||
|
}
|
||||||
|
|
||||||
|
buf = scsi_req_get_buf(req);
|
||||||
|
- opcode = le32_to_cpu(cmd->frame->dcmd.opcode);
|
||||||
|
- if (opcode == MFI_DCMD_PD_GET_INFO && cmd->iov_buf) {
|
||||||
|
+ if (cmd->dcmd_opcode == MFI_DCMD_PD_GET_INFO && cmd->iov_buf) {
|
||||||
|
struct mfi_pd_info *info = cmd->iov_buf;
|
||||||
|
|
||||||
|
if (info->inquiry_data[0] == 0x7f) {
|
||||||
|
@@ -1849,7 +1846,7 @@ static void megasas_xfer_complete(SCSIRequest *req, uint32_t len)
|
||||||
|
memcpy(info->vpd_page83, buf, len);
|
||||||
|
}
|
||||||
|
scsi_req_continue(req);
|
||||||
|
- } else if (opcode == MFI_DCMD_LD_GET_INFO) {
|
||||||
|
+ } else if (cmd->dcmd_opcode == MFI_DCMD_LD_GET_INFO) {
|
||||||
|
struct mfi_ld_info *info = cmd->iov_buf;
|
||||||
|
|
||||||
|
if (cmd->iov_buf) {
|
||||||
|
--
|
||||||
|
2.13.0
|
||||||
|
|
@ -0,0 +1,80 @@
|
|||||||
|
From df8ad9f128c15aa0a0ebc7b24e9a22c9775b67af Mon Sep 17 00:00:00 2001
|
||||||
|
From: Eric Blake <eblake@redhat.com>
|
||||||
|
Date: Fri, 26 May 2017 22:04:21 -0500
|
||||||
|
Subject: [PATCH] nbd: Fully initialize client in case of failed negotiation
|
||||||
|
|
||||||
|
If a non-NBD client connects to qemu-nbd, we would end up with
|
||||||
|
a SIGSEGV in nbd_client_put() because we were trying to
|
||||||
|
unregister the client's association to the export, even though
|
||||||
|
we skipped inserting the client into that list. Easy trigger
|
||||||
|
in two terminals:
|
||||||
|
|
||||||
|
$ qemu-nbd -p 30001 --format=raw file
|
||||||
|
$ nmap 127.0.0.1 -p 30001
|
||||||
|
|
||||||
|
nmap claims that it thinks it connected to a pago-services1
|
||||||
|
server (which probably means nmap could be updated to learn the
|
||||||
|
NBD protocol and give a more accurate diagnosis of the open
|
||||||
|
port - but that's not our problem), then terminates immediately,
|
||||||
|
so our call to nbd_negotiate() fails. The fix is to reorder
|
||||||
|
nbd_co_client_start() to ensure that all initialization occurs
|
||||||
|
before we ever try talking to a client in nbd_negotiate(), so
|
||||||
|
that the teardown sequence on negotiation failure doesn't fault
|
||||||
|
while dereferencing a half-initialized object.
|
||||||
|
|
||||||
|
While debugging this, I also noticed that nbd_update_server_watch()
|
||||||
|
called by nbd_client_closed() was still adding a channel to accept
|
||||||
|
the next client, even when the state was no longer RUNNING. That
|
||||||
|
is fixed by making nbd_can_accept() pay attention to the current
|
||||||
|
state.
|
||||||
|
|
||||||
|
Fixes: https://bugzilla.redhat.com/show_bug.cgi?id=1451614
|
||||||
|
|
||||||
|
Signed-off-by: Eric Blake <eblake@redhat.com>
|
||||||
|
Message-Id: <20170527030421.28366-1-eblake@redhat.com>
|
||||||
|
Signed-off-by: Paolo Bonzini <pbonzini@redhat.com>
|
||||||
|
---
|
||||||
|
nbd/server.c | 8 +++-----
|
||||||
|
qemu-nbd.c | 2 +-
|
||||||
|
2 files changed, 4 insertions(+), 6 deletions(-)
|
||||||
|
|
||||||
|
diff --git a/nbd/server.c b/nbd/server.c
|
||||||
|
index ee59e5d234..49b55f6ede 100644
|
||||||
|
--- a/nbd/server.c
|
||||||
|
+++ b/nbd/server.c
|
||||||
|
@@ -1358,16 +1358,14 @@ static coroutine_fn void nbd_co_client_start(void *opaque)
|
||||||
|
|
||||||
|
if (exp) {
|
||||||
|
nbd_export_get(exp);
|
||||||
|
+ QTAILQ_INSERT_TAIL(&exp->clients, client, next);
|
||||||
|
}
|
||||||
|
+ qemu_co_mutex_init(&client->send_lock);
|
||||||
|
+
|
||||||
|
if (nbd_negotiate(data)) {
|
||||||
|
client_close(client);
|
||||||
|
goto out;
|
||||||
|
}
|
||||||
|
- qemu_co_mutex_init(&client->send_lock);
|
||||||
|
-
|
||||||
|
- if (exp) {
|
||||||
|
- QTAILQ_INSERT_TAIL(&exp->clients, client, next);
|
||||||
|
- }
|
||||||
|
|
||||||
|
nbd_client_receive_next_request(client);
|
||||||
|
|
||||||
|
diff --git a/qemu-nbd.c b/qemu-nbd.c
|
||||||
|
index f60842fd86..651f85ecc1 100644
|
||||||
|
--- a/qemu-nbd.c
|
||||||
|
+++ b/qemu-nbd.c
|
||||||
|
@@ -325,7 +325,7 @@ out:
|
||||||
|
|
||||||
|
static int nbd_can_accept(void)
|
||||||
|
{
|
||||||
|
- return nb_fds < shared;
|
||||||
|
+ return state == RUNNING && nb_fds < shared;
|
||||||
|
}
|
||||||
|
|
||||||
|
static void nbd_export_closed(NBDExport *exp)
|
||||||
|
--
|
||||||
|
2.13.0
|
||||||
|
|
@ -0,0 +1,197 @@
|
|||||||
|
From 0c9390d978cbf61e8f16c9f580fa96b305c43568 Mon Sep 17 00:00:00 2001
|
||||||
|
From: Eric Blake <eblake@redhat.com>
|
||||||
|
Date: Thu, 8 Jun 2017 17:26:17 -0500
|
||||||
|
Subject: [PATCH] nbd: Fix regression on resiliency to port scan
|
||||||
|
|
||||||
|
Back in qemu 2.5, qemu-nbd was immune to port probes (a transient
|
||||||
|
server would not quit, regardless of how many probe connections
|
||||||
|
came and went, until a connection actually negotiated). But we
|
||||||
|
broke that in commit ee7d7aa when removing the return value to
|
||||||
|
nbd_client_new(), although that patch also introduced a bug causing
|
||||||
|
an assertion failure on a client that fails negotiation. We then
|
||||||
|
made it worse during refactoring in commit 1a6245a (a segfault
|
||||||
|
before we could even assert); the (masked) assertion was cleaned
|
||||||
|
up in d3780c2 (still in 2.6), and just recently we finally fixed
|
||||||
|
the segfault ("nbd: Fully intialize client in case of failed
|
||||||
|
negotiation"). But that still means that ever since we added
|
||||||
|
TLS support to qemu-nbd, we have been vulnerable to an ill-timed
|
||||||
|
port-scan being able to cause a denial of service by taking down
|
||||||
|
qemu-nbd before a real client has a chance to connect.
|
||||||
|
|
||||||
|
Since negotiation is now handled asynchronously via coroutines,
|
||||||
|
we no longer have a synchronous point of return by re-adding a
|
||||||
|
return value to nbd_client_new(). So this patch instead wires
|
||||||
|
things up to pass the negotiation status through the close_fn
|
||||||
|
callback function.
|
||||||
|
|
||||||
|
Simple test across two terminals:
|
||||||
|
$ qemu-nbd -f raw -p 30001 file
|
||||||
|
$ nmap 127.0.0.1 -p 30001 && \
|
||||||
|
qemu-io -c 'r 0 512' -f raw nbd://localhost:30001
|
||||||
|
|
||||||
|
Note that this patch does not change what constitutes successful
|
||||||
|
negotiation (thus, a client must enter transmission phase before
|
||||||
|
that client can be considered as a reason to terminate the server
|
||||||
|
when the connection ends). Perhaps we may want to tweak things
|
||||||
|
in a later patch to also treat a client that uses NBD_OPT_ABORT
|
||||||
|
as being a 'successful' negotiation (the client correctly talked
|
||||||
|
the NBD protocol, and informed us it was not going to use our
|
||||||
|
export after all), but that's a discussion for another day.
|
||||||
|
|
||||||
|
Fixes: https://bugzilla.redhat.com/show_bug.cgi?id=1451614
|
||||||
|
|
||||||
|
Signed-off-by: Eric Blake <eblake@redhat.com>
|
||||||
|
Message-Id: <20170608222617.20376-1-eblake@redhat.com>
|
||||||
|
Signed-off-by: Paolo Bonzini <pbonzini@redhat.com>
|
||||||
|
---
|
||||||
|
blockdev-nbd.c | 6 +++++-
|
||||||
|
include/block/nbd.h | 2 +-
|
||||||
|
nbd/server.c | 24 +++++++++++++++---------
|
||||||
|
qemu-nbd.c | 4 ++--
|
||||||
|
4 files changed, 23 insertions(+), 13 deletions(-)
|
||||||
|
|
||||||
|
diff --git a/blockdev-nbd.c b/blockdev-nbd.c
|
||||||
|
index dd0860f4a6..28f551a7b0 100644
|
||||||
|
--- a/blockdev-nbd.c
|
||||||
|
+++ b/blockdev-nbd.c
|
||||||
|
@@ -27,6 +27,10 @@ typedef struct NBDServerData {
|
||||||
|
|
||||||
|
static NBDServerData *nbd_server;
|
||||||
|
|
||||||
|
+static void nbd_blockdev_client_closed(NBDClient *client, bool ignored)
|
||||||
|
+{
|
||||||
|
+ nbd_client_put(client);
|
||||||
|
+}
|
||||||
|
|
||||||
|
static gboolean nbd_accept(QIOChannel *ioc, GIOCondition condition,
|
||||||
|
gpointer opaque)
|
||||||
|
@@ -46,7 +50,7 @@ static gboolean nbd_accept(QIOChannel *ioc, GIOCondition condition,
|
||||||
|
qio_channel_set_name(QIO_CHANNEL(cioc), "nbd-server");
|
||||||
|
nbd_client_new(NULL, cioc,
|
||||||
|
nbd_server->tlscreds, NULL,
|
||||||
|
- nbd_client_put);
|
||||||
|
+ nbd_blockdev_client_closed);
|
||||||
|
object_unref(OBJECT(cioc));
|
||||||
|
return TRUE;
|
||||||
|
}
|
||||||
|
diff --git a/include/block/nbd.h b/include/block/nbd.h
|
||||||
|
index 416257abca..8fa5ce51f3 100644
|
||||||
|
--- a/include/block/nbd.h
|
||||||
|
+++ b/include/block/nbd.h
|
||||||
|
@@ -162,7 +162,7 @@ void nbd_client_new(NBDExport *exp,
|
||||||
|
QIOChannelSocket *sioc,
|
||||||
|
QCryptoTLSCreds *tlscreds,
|
||||||
|
const char *tlsaclname,
|
||||||
|
- void (*close)(NBDClient *));
|
||||||
|
+ void (*close_fn)(NBDClient *, bool));
|
||||||
|
void nbd_client_get(NBDClient *client);
|
||||||
|
void nbd_client_put(NBDClient *client);
|
||||||
|
|
||||||
|
diff --git a/nbd/server.c b/nbd/server.c
|
||||||
|
index 49b55f6ede..f2b1aa47ce 100644
|
||||||
|
--- a/nbd/server.c
|
||||||
|
+++ b/nbd/server.c
|
||||||
|
@@ -81,7 +81,7 @@ static QTAILQ_HEAD(, NBDExport) exports = QTAILQ_HEAD_INITIALIZER(exports);
|
||||||
|
|
||||||
|
struct NBDClient {
|
||||||
|
int refcount;
|
||||||
|
- void (*close)(NBDClient *client);
|
||||||
|
+ void (*close_fn)(NBDClient *client, bool negotiated);
|
||||||
|
|
||||||
|
bool no_zeroes;
|
||||||
|
NBDExport *exp;
|
||||||
|
@@ -778,7 +778,7 @@ void nbd_client_put(NBDClient *client)
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
-static void client_close(NBDClient *client)
|
||||||
|
+static void client_close(NBDClient *client, bool negotiated)
|
||||||
|
{
|
||||||
|
if (client->closing) {
|
||||||
|
return;
|
||||||
|
@@ -793,8 +793,8 @@ static void client_close(NBDClient *client)
|
||||||
|
NULL);
|
||||||
|
|
||||||
|
/* Also tell the client, so that they release their reference. */
|
||||||
|
- if (client->close) {
|
||||||
|
- client->close(client);
|
||||||
|
+ if (client->close_fn) {
|
||||||
|
+ client->close_fn(client, negotiated);
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
@@ -975,7 +975,7 @@ void nbd_export_close(NBDExport *exp)
|
||||||
|
|
||||||
|
nbd_export_get(exp);
|
||||||
|
QTAILQ_FOREACH_SAFE(client, &exp->clients, next, next) {
|
||||||
|
- client_close(client);
|
||||||
|
+ client_close(client, true);
|
||||||
|
}
|
||||||
|
nbd_export_set_name(exp, NULL);
|
||||||
|
nbd_export_set_description(exp, NULL);
|
||||||
|
@@ -1337,7 +1337,7 @@ done:
|
||||||
|
|
||||||
|
out:
|
||||||
|
nbd_request_put(req);
|
||||||
|
- client_close(client);
|
||||||
|
+ client_close(client, true);
|
||||||
|
nbd_client_put(client);
|
||||||
|
}
|
||||||
|
|
||||||
|
@@ -1363,7 +1363,7 @@ static coroutine_fn void nbd_co_client_start(void *opaque)
|
||||||
|
qemu_co_mutex_init(&client->send_lock);
|
||||||
|
|
||||||
|
if (nbd_negotiate(data)) {
|
||||||
|
- client_close(client);
|
||||||
|
+ client_close(client, false);
|
||||||
|
goto out;
|
||||||
|
}
|
||||||
|
|
||||||
|
@@ -1373,11 +1373,17 @@ out:
|
||||||
|
g_free(data);
|
||||||
|
}
|
||||||
|
|
||||||
|
+/*
|
||||||
|
+ * Create a new client listener on the given export @exp, using the
|
||||||
|
+ * given channel @sioc. Begin servicing it in a coroutine. When the
|
||||||
|
+ * connection closes, call @close_fn with an indication of whether the
|
||||||
|
+ * client completed negotiation.
|
||||||
|
+ */
|
||||||
|
void nbd_client_new(NBDExport *exp,
|
||||||
|
QIOChannelSocket *sioc,
|
||||||
|
QCryptoTLSCreds *tlscreds,
|
||||||
|
const char *tlsaclname,
|
||||||
|
- void (*close_fn)(NBDClient *))
|
||||||
|
+ void (*close_fn)(NBDClient *, bool))
|
||||||
|
{
|
||||||
|
NBDClient *client;
|
||||||
|
NBDClientNewData *data = g_new(NBDClientNewData, 1);
|
||||||
|
@@ -1394,7 +1400,7 @@ void nbd_client_new(NBDExport *exp,
|
||||||
|
object_ref(OBJECT(client->sioc));
|
||||||
|
client->ioc = QIO_CHANNEL(sioc);
|
||||||
|
object_ref(OBJECT(client->ioc));
|
||||||
|
- client->close = close_fn;
|
||||||
|
+ client->close_fn = close_fn;
|
||||||
|
|
||||||
|
data->client = client;
|
||||||
|
data->co = qemu_coroutine_create(nbd_co_client_start, data);
|
||||||
|
diff --git a/qemu-nbd.c b/qemu-nbd.c
|
||||||
|
index 651f85ecc1..9464a0461c 100644
|
||||||
|
--- a/qemu-nbd.c
|
||||||
|
+++ b/qemu-nbd.c
|
||||||
|
@@ -336,10 +336,10 @@ static void nbd_export_closed(NBDExport *exp)
|
||||||
|
|
||||||
|
static void nbd_update_server_watch(void);
|
||||||
|
|
||||||
|
-static void nbd_client_closed(NBDClient *client)
|
||||||
|
+static void nbd_client_closed(NBDClient *client, bool negotiated)
|
||||||
|
{
|
||||||
|
nb_fds--;
|
||||||
|
- if (nb_fds == 0 && !persistent && state == RUNNING) {
|
||||||
|
+ if (negotiated && nb_fds == 0 && !persistent && state == RUNNING) {
|
||||||
|
state = TERMINATE;
|
||||||
|
}
|
||||||
|
nbd_update_server_watch();
|
||||||
|
--
|
||||||
|
2.13.0
|
||||||
|
|
@ -0,0 +1,158 @@
|
|||||||
|
diff -Naur VirtualBox-5.1.24/Config.kmk VirtualBox-5.1.24/Config.kmk
|
||||||
|
--- VirtualBox-5.1.24/Config.kmk 2017-07-26 13:55:27.803972185 -0400
|
||||||
|
+++ VirtualBox-5.1.24/Config.kmk 2017-07-26 13:53:10.700974328 -0400
|
||||||
|
@@ -2601,6 +2601,7 @@
|
||||||
|
$(QUIET)$(APPEND) '$@' 'VBOX_GCC_Wno-overlength-strings?= $(call VBOX_GCC_CHECK_CC,-Wno-overlength-strings,)'
|
||||||
|
$(QUIET)$(APPEND) '$@' 'VBOX_GCC_Wno-overloaded-virtual?= $(call VBOX_GCC_CHECK_CXX,-Wno-overloaded-virtual,)'
|
||||||
|
$(QUIET)$(APPEND) '$@' 'VBOX_GCC_fno-stack-protector ?= $(call VBOX_GCC_CHECK_CC,-fno-stack-protector,)'
|
||||||
|
+ $(QUIET)$(APPEND) '$@' 'VBOX_GCC_nopie ?= $(call VBOX_GCC_CHECK_CC,-nopie,)'
|
||||||
|
$(QUIET)$(APPEND) '$@' 'VBOX_GCC_fno-dwarf2-cfi-asm ?= $(call VBOX_GCC_CHECK_CC,-fno-dwarf2-cfi-asm,)'
|
||||||
|
$(QUIET)$(APPEND) '$@' 'VBOX_GCC_m64 ?= $(call VBOX_GCC_CHECK_CC,-m64,)'
|
||||||
|
$(QUIET)$(APPEND) '$@' 'VBOX_GCC_no-pie ?= $(call VBOX_GCC_CHECK_CC,-no-pie,)'
|
||||||
|
@@ -3843,8 +3844,8 @@
|
||||||
|
|
||||||
|
ifeq ($(VBOX_LDR_FMT32),elf)
|
||||||
|
TEMPLATE_VBoxRc_TOOL = $(VBOX_GCC32_TOOL)
|
||||||
|
- TEMPLATE_VBoxRc_CXXFLAGS = -fno-pie -nostdinc -g $(VBOX_GCC_pipe) $(VBOX_GCC_WERR) $(VBOX_GCC_PEDANTIC_CXX) $(VBOX_GCC32_Wno-variadic-macros) -fno-exceptions $(VBOX_GCC_GC_OPT) $(VBOX_GCC_GC_FP) -mno-sse -mno-mmx -mno-sse2 -mno-3dnow -fno-strict-aliasing $(VBOX_GCC_fno-stack-protector) $(VBOX_GCC_fvisibility-hidden) $(VBOX_GCC_fvisibility-inlines-hidden) -fno-rtti $(VBOX_GCC_IPRT_FMT_CHECK)
|
||||||
|
- TEMPLATE_VBoxRc_CFLAGS = -fno-pie -nostdinc -g $(VBOX_GCC_pipe) $(VBOX_GCC_WERR) $(VBOX_GCC_PEDANTIC_C) $(VBOX_GCC32_Wno-variadic-macros) -fno-exceptions $(VBOX_GCC_GC_OPT) $(VBOX_GCC_GC_FP) -mno-sse -mno-mmx -mno-sse2 -mno-3dnow -fno-strict-aliasing $(VBOX_GCC_fno-stack-protector) $(VBOX_GCC_fvisibility-hidden) $(VBOX_GCC_IPRT_FMT_CHECK)
|
||||||
|
+ TEMPLATE_VBoxRc_CXXFLAGS = -nostdinc -g $(VBOX_GCC_pipe) $(VBOX_GCC_WERR) $(VBOX_GCC_PEDANTIC_CXX) $(VBOX_GCC32_Wno-variadic-macros) -fno-exceptions $(VBOX_GCC_GC_OPT) $(VBOX_GCC_GC_FP) -mno-sse -mno-mmx -mno-sse2 -mno-3dnow -fno-strict-aliasing $(VBOX_GCC_fno-stack-protector) $(VBOX_GCC_nopie) $(VBOX_GCC_fvisibility-hidden) $(VBOX_GCC_fvisibility-inlines-hidden) -fno-rtti $(VBOX_GCC_IPRT_FMT_CHECK)
|
||||||
|
+ TEMPLATE_VBoxRc_CFLAGS = -nostdinc -g $(VBOX_GCC_pipe) $(VBOX_GCC_WERR) $(VBOX_GCC_PEDANTIC_C) $(VBOX_GCC32_Wno-variadic-macros) -fno-exceptions $(VBOX_GCC_GC_OPT) $(VBOX_GCC_GC_FP) -mno-sse -mno-mmx -mno-sse2 -mno-3dnow -fno-strict-aliasing $(VBOX_GCC_fno-stack-protector) $(VBOX_GCC_nopie) $(VBOX_GCC_fvisibility-hidden) $(VBOX_GCC_IPRT_FMT_CHECK)
|
||||||
|
ifeq ($(KBUILD_TARGET),solaris)
|
||||||
|
TEMPLATE_VBoxRc_LDFLAGS = -r
|
||||||
|
else
|
||||||
|
@@ -3864,8 +3865,8 @@
|
||||||
|
ifeq ($(VBOX_LDR_FMT32),macho)
|
||||||
|
TEMPLATE_VBoxRc_TOOL = $(VBOX_GCC_TOOL)
|
||||||
|
TEMPLATE_VBoxRc_DEFS += $(VBOX_DARWIN_DEF_SDK_DEFS)
|
||||||
|
- TEMPLATE_VBoxRc_CXXFLAGS = $(VBOX_DARWIN_DEF_SDK_CXXFLAGS) -m32 -nostdinc -g $(VBOX_GCC_pipe) $(VBOX_GCC_WERR) $(VBOX_GCC_PEDANTIC_CXX) $(VBOX_GCC32_Wno-variadic-macros) -fno-common -msoft-float -static $(VBOX_GCC_fno-stack-protector) -fno-exceptions $(VBOX_GCC_GC_OPT) $(VBOX_GCC_GC_FP) -fno-strict-aliasing -fno-rtti
|
||||||
|
- TEMPLATE_VBoxRc_CFLAGS = $(VBOX_DARWIN_DEF_SDK_CFLAGS) -m32 -nostdinc -g $(VBOX_GCC_pipe) $(VBOX_GCC_WERR) $(VBOX_GCC_PEDANTIC_C) $(VBOX_GCC32_Wno-variadic-macros) -fno-common -msoft-float -static $(VBOX_GCC_fno-stack-protector) -fno-exceptions $(VBOX_GCC_GC_OPT) $(VBOX_GCC_GC_FP) -fno-strict-aliasing
|
||||||
|
+ TEMPLATE_VBoxRc_CXXFLAGS = $(VBOX_DARWIN_DEF_SDK_CXXFLAGS) -m32 -nostdinc -g $(VBOX_GCC_pipe) $(VBOX_GCC_WERR) $(VBOX_GCC_PEDANTIC_CXX) $(VBOX_GCC32_Wno-variadic-macros) -fno-common -msoft-float -static $(VBOX_GCC_fno-stack-protector) $(VBOX_GCC_nopie) -fno-exceptions $(VBOX_GCC_GC_OPT) $(VBOX_GCC_GC_FP) -fno-strict-aliasing -fno-rtti
|
||||||
|
+ TEMPLATE_VBoxRc_CFLAGS = $(VBOX_DARWIN_DEF_SDK_CFLAGS) -m32 -nostdinc -g $(VBOX_GCC_pipe) $(VBOX_GCC_WERR) $(VBOX_GCC_PEDANTIC_C) $(VBOX_GCC32_Wno-variadic-macros) -fno-common -msoft-float -static $(VBOX_GCC_fno-stack-protector) $(VBOX_GCC_nopie) -fno-exceptions $(VBOX_GCC_GC_OPT) $(VBOX_GCC_GC_FP) -fno-strict-aliasing
|
||||||
|
TEMPLATE_VBoxRc_LDFLAGS = $(VBOX_DARWIN_DEF_SDK_LDFLAGS) -m32 -nostdlib
|
||||||
|
#TEMPLATE_VBoxRc_LDFLAGS.release = -Wl,-S ???
|
||||||
|
endif
|
||||||
|
@@ -3903,9 +3904,9 @@
|
||||||
|
endif
|
||||||
|
|
||||||
|
ifeq ($(VBOX_LDR_FMT32),elf)
|
||||||
|
- TEMPLATE_VBoxRcExe_CFLAGS = $(filter-out -nostdinc,$(TEMPLATE_VBoxRc_CFLAGS)) -O0
|
||||||
|
- TEMPLATE_VBoxRcExe_CXXFLAGS = $(filter-out -nostdinc,$(TEMPLATE_VBoxRc_CXXFLAGS)) -O0
|
||||||
|
- TEMPLATE_VBoxRcExe_LDFLAGS = -g
|
||||||
|
+ TEMPLATE_VBoxRcExe_CFLAGS = $(filter-out -nostdinc,$(TEMPLATE_VBoxRc_CFLAGS)) -O0 $(VBOX_GCC_nopie)
|
||||||
|
+ TEMPLATE_VBoxRcExe_CXXFLAGS = $(filter-out -nostdinc,$(TEMPLATE_VBoxRc_CXXFLAGS)) -O0 $(VBOX_GCC_nopie)
|
||||||
|
+ TEMPLATE_VBoxRcExe_LDFLAGS = -g $(VBOX_GCC_nopie)
|
||||||
|
TEMPLATE_VBoxRcExe_LDFLAGS.dbgopt = -g
|
||||||
|
TEMPLATE_VBoxRcExe_LDFLAGS.strict = -g
|
||||||
|
TEMPLATE_VBoxRcExe_LDFLAGS.release = -g
|
||||||
|
@@ -3984,8 +3985,8 @@
|
||||||
|
|
||||||
|
ifeq ($(VBOX_LDR_FMT),elf)
|
||||||
|
TEMPLATE_VBoxR0_TOOL = $(VBOX_GCC_TOOL)
|
||||||
|
-TEMPLATE_VBoxR0_CFLAGS = -fno-pie -nostdinc -g $(VBOX_GCC_pipe) $(VBOX_GCC_WERR) $(VBOX_GCC_PEDANTIC_C) $(VBOX_GCC_Wno-variadic-macros) $(VBOX_GCC_R0_OPT) $(VBOX_GCC_R0_FP) -fno-strict-aliasing -fno-exceptions $(VBOX_GCC_fno-stack-protector) -fno-common $(VBOX_GCC_fvisibility-hidden) -std=gnu99 $(VBOX_GCC_IPRT_FMT_CHECK)
|
||||||
|
-TEMPLATE_VBoxR0_CXXFLAGS = -fno-pie -nostdinc -g $(VBOX_GCC_pipe) $(VBOX_GCC_WERR) $(VBOX_GCC_PEDANTIC_CXX) $(VBOX_GCC_Wno-variadic-macros) $(VBOX_GCC_R0_OPT) $(VBOX_GCC_R0_FP) -fno-strict-aliasing -fno-exceptions $(VBOX_GCC_fno-stack-protector) -fno-common $(VBOX_GCC_fvisibility-inlines-hidden) $(VBOX_GCC_fvisibility-hidden) -fno-rtti $(VBOX_GCC_IPRT_FMT_CHECK)
|
||||||
|
+TEMPLATE_VBoxR0_CFLAGS = -nostdinc -g $(VBOX_GCC_pipe) $(VBOX_GCC_WERR) $(VBOX_GCC_PEDANTIC_C) $(VBOX_GCC_Wno-variadic-macros) $(VBOX_GCC_R0_OPT) $(VBOX_GCC_R0_FP) -fno-strict-aliasing -fno-exceptions $(VBOX_GCC_fno-stack-protector) $(VBOX_GCC_nopie) -fno-common $(VBOX_GCC_fvisibility-hidden) -std=gnu99 $(VBOX_GCC_IPRT_FMT_CHECK)
|
||||||
|
+TEMPLATE_VBoxR0_CXXFLAGS = -nostdinc -g $(VBOX_GCC_pipe) $(VBOX_GCC_WERR) $(VBOX_GCC_PEDANTIC_CXX) $(VBOX_GCC_Wno-variadic-macros) $(VBOX_GCC_R0_OPT) $(VBOX_GCC_R0_FP) -fno-strict-aliasing -fno-exceptions $(VBOX_GCC_fno-stack-protector) $(VBOX_GCC_nopie) -fno-common $(VBOX_GCC_fvisibility-inlines-hidden) $(VBOX_GCC_fvisibility-hidden) -fno-rtti $(VBOX_GCC_IPRT_FMT_CHECK)
|
||||||
|
TEMPLATE_VBoxR0_CFLAGS.amd64 = -m64 -mno-red-zone -mcmodel=kernel -mno-sse -mno-mmx -mno-sse2 -mno-3dnow -fno-asynchronous-unwind-tables -ffreestanding
|
||||||
|
TEMPLATE_VBoxR0_CXXFLAGS.amd64 = -m64 -mno-red-zone -mcmodel=kernel -mno-sse -mno-mmx -mno-sse2 -mno-3dnow -fno-asynchronous-unwind-tables
|
||||||
|
ifeq ($(KBUILD_TARGET),solaris)
|
||||||
|
@@ -4018,12 +4019,12 @@
|
||||||
|
TEMPLATE_VBoxR0_DEFS += $(VBOX_DARWIN_DEF_SDK_DEFS)
|
||||||
|
TEMPLATE_VBoxR0_CXXFLAGS = $(VBOX_DARWIN_DEF_SDK_CXXFLAGS) -nostdinc -g $(VBOX_GCC_pipe) $(VBOX_GCC_WERR) $(VBOX_GCC_PEDANTIC_CXX) $(VBOX_GCC_Wno-variadic-macros) \
|
||||||
|
-fno-common -msoft-float -static -fno-rtti -fno-exceptions $(VBOX_GCC_R0_OPT) $(VBOX_GCC_R0_FP) -fno-strict-aliasing \
|
||||||
|
- -mno-sse -mno-mmx -mno-sse2 -mno-3dnow $(VBOX_GCC_fno-stack-protector)
|
||||||
|
+ -mno-sse -mno-mmx -mno-sse2 -mno-3dnow $(VBOX_GCC_fno-stack-protector) $(VBOX_GCC_nopie)
|
||||||
|
TEMPLATE_VBoxR0_CXXFLAGS.amd64 = -m64 -mno-red-zone -mno-sse3 -mno-sse4 -mno-sse4.1 -mno-sse4.2 -mno-sse4a -fno-unwind-tables
|
||||||
|
TEMPLATE_VBoxR0_CXXFLAGS.x86 = -m32
|
||||||
|
TEMPLATE_VBoxR0_CFLAGS = $(VBOX_DARWIN_DEF_SDK_CFLAGS) -nostdinc -g $(VBOX_GCC_pipe) $(VBOX_GCC_WERR) $(VBOX_GCC_PEDANTIC_C) $(VBOX_GCC_Wno-variadic-macros) \
|
||||||
|
-fno-common -msoft-float -static -fno-exceptions $(VBOX_GCC_R0_OPT) $(VBOX_GCC_R0_FP) -fno-strict-aliasing \
|
||||||
|
- -mno-sse -mno-mmx -mno-sse2 -mno-3dnow $(VBOX_GCC_fno-stack-protector)
|
||||||
|
+ -mno-sse -mno-mmx -mno-sse2 -mno-3dnow $(VBOX_GCC_fno-stack-protector) $(VBOX_GCC_nopie)
|
||||||
|
TEMPLATE_VBoxR0_CFLAGS.amd64 = -m64 -mno-red-zone -mno-sse3 -mno-sse4 -mno-sse4.1 -mno-sse4.2 -mno-sse4a -fno-unwind-tables
|
||||||
|
TEMPLATE_VBoxR0_CFLAGS.x86 = -m32
|
||||||
|
TEMPLATE_VBoxR0_LDFLAGS = $(VBOX_DARWIN_DEF_SDK_LDFLAGS) -nostdlib
|
||||||
|
@@ -4259,7 +4260,7 @@
|
||||||
|
-Wstrict-prototypes -Wmissing-prototypes -Wstrict-prototypes \
|
||||||
|
-Wimplicit-function-declaration -Werror-implicit-function-declaration \
|
||||||
|
-O2 -ffreestanding -fno-strict-aliasing -fno-common -finline-limit=8000 \
|
||||||
|
- $(VBOX_GCC_fno-stack-protector) $(VBOX_GCC_R0_OPT) $(VBOX_GCC_R0_FP) \
|
||||||
|
+ $(VBOX_GCC_fno-stack-protector) $(VBOX_GCC_nopie) $(VBOX_GCC_R0_OPT) $(VBOX_GCC_R0_FP) \
|
||||||
|
-nostdinc -std=c99
|
||||||
|
TEMPLATE_VBOXR0DRV_CFLAGS.x86 = -m32 -mno-align-long-strings -mpreferred-stack-boundary=2 -mno-mmx -mno-3dnow -mno-sse -mno-sse2
|
||||||
|
TEMPLATE_VBOXR0DRV_CFLAGS.amd64 = -m64 --param inline-unit-growth=100 --param large-function-growth=1000 \
|
||||||
|
@@ -4268,7 +4269,7 @@
|
||||||
|
TEMPLATE_VBOXR0DRV_CXXFLAGS = -fno-exceptions -fno-rtti \
|
||||||
|
$(VBOX_GCC_WARN) -Wpointer-arith -Winline \
|
||||||
|
-O2 -fno-strict-aliasing -fno-common -finline-limit=8000 \
|
||||||
|
- $(VBOX_GCC_fno-stack-protector) $(VBOX_GCC_R0_OPT) $(VBOX_GCC_R0_FP) \
|
||||||
|
+ $(VBOX_GCC_fno-stack-protector) $(VBOX_GCC_nopie) $(VBOX_GCC_R0_OPT) $(VBOX_GCC_R0_FP) \
|
||||||
|
-nostdinc
|
||||||
|
TEMPLATE_VBOXR0DRV_CXXFLAGS.x86 = $(TEMPLATE_VBOXR0DRV_CFLAGS.x86)
|
||||||
|
TEMPLATE_VBOXR0DRV_CXXFLAGS.amd64 = $(TEMPLATE_VBOXR0DRV_CFLAGS.amd64)
|
||||||
|
@@ -4341,7 +4342,7 @@
|
||||||
|
-Wstrict-prototypes -Wmissing-prototypes -Wstrict-prototypes \
|
||||||
|
-Wimplicit-function-declaration -Werror-implicit-function-declaration \
|
||||||
|
-O2 -ffreestanding -fno-strict-aliasing -fno-common -finline-limit=8000 \
|
||||||
|
- $(VBOX_GCC_fno-stack-protector) $(VBOX_GCC_R0_OPT) $(VBOX_GCC_R0_FP) \
|
||||||
|
+ $(VBOX_GCC_fno-stack-protector) $(VBOX_GCC_nopie) $(VBOX_GCC_R0_OPT) $(VBOX_GCC_R0_FP) \
|
||||||
|
-nostdinc -std=c99 -msoft-float
|
||||||
|
TEMPLATE_VBOXR0DRV_CFLAGS.x86 = -m32 \
|
||||||
|
-mpreferred-stack-boundary=2 -mno-mmx -mno-sse -mno-avx \
|
||||||
|
@@ -4353,7 +4354,7 @@
|
||||||
|
TEMPLATE_VBOXR0DRV_CXXFLAGS = -fno-exceptions -fno-rtti \
|
||||||
|
$(VBOX_GCC_WARN) -Wpointer-arith -Winline \
|
||||||
|
-O2 -fno-strict-aliasing -fno-common -finline-limit=8000 \
|
||||||
|
- $(VBOX_GCC_fno-stack-protector) $(VBOX_GCC_R0_OPT) $(VBOX_GCC_R0_FP) \
|
||||||
|
+ $(VBOX_GCC_fno-stack-protector) $(VBOX_GCC_nopie) $(VBOX_GCC_R0_OPT) $(VBOX_GCC_R0_FP) \
|
||||||
|
-nostdinc -msoft-float
|
||||||
|
TEMPLATE_VBOXR0DRV_CXXFLAGS.x86 = $(TEMPLATE_VBOXR0DRV_CFLAGS.x86)
|
||||||
|
TEMPLATE_VBOXR0DRV_CXXFLAGS.amd64 = $(TEMPLATE_VBOXR0DRV_CFLAGS.amd64)
|
||||||
|
@@ -4394,7 +4395,7 @@
|
||||||
|
TEMPLATE_VBOXR0DRV_LDFLAGS = -shared -no-undefined -dc -dy -lroot -rpath-link /boot/system/develop/lib/x86 --no-add-needed /boot/system/develop/lib/_KERNEL_ --no-add-needed /boot/system/develop/lib/haiku_version_glue.o
|
||||||
|
TEMPLATE_VBOXR0DRV_CFLAGS = -fno-PIC \
|
||||||
|
$(VBOX_GCC_WARN) -Wstrict-prototypes $(VBOX_GCC_Wno-pointer-sign) -Wno-sign-compare \
|
||||||
|
- $(VBOX_GCC_fno-stack-protector) $(VBOX_GCC_R0_OPT) $(VBOX_GCC_R0_FP) -fno-strict-aliasing -fno-common -Werror-implicit-function-declaration
|
||||||
|
+ $(VBOX_GCC_fno-stack-protector) $(VBOX_GCC_nopie) $(VBOX_GCC_R0_OPT) $(VBOX_GCC_R0_FP) -fno-strict-aliasing -fno-common -Werror-implicit-function-declaration
|
||||||
|
TEMPLATE_VBOXR0DRV_CFLAGS.x86 = -mno-sse -mno-mmx -mno-sse2 -mno-3dnow
|
||||||
|
TEMPLATE_VBOXR0DRV_CFLAGS.x86 = -m32 -mno-sse -mno-mmx -mno-sse2 -mno-3dnow
|
||||||
|
TEMPLATE_VBOXR0DRV_CFLAGS.amd64 = -m64 -mno-sse -mno-mmx -mno-sse2 -mno-3dnow \
|
||||||
|
@@ -5210,8 +5211,8 @@
|
||||||
|
TEMPLATE_VBoxNoCrtGccLib_TOOL = $(VBOX_GCC_TOOL)
|
||||||
|
TEMPLATE_VBoxNoCrtGccLib_ASTOOL = $(VBOX_ASTOOL)
|
||||||
|
TEMPLATE_VBoxNoCrtGccLib_ASFLAGS = $(VBOX_ASFLAGS)
|
||||||
|
- TEMPLATE_VBoxNoCrtGccLib_CFLAGS += $(VBOX_GCC_fno-stack-protector)
|
||||||
|
- TEMPLATE_VBoxNoCrtGccLib_CXXFLAGS += $(VBOX_GCC_fno-stack-protector)
|
||||||
|
+ TEMPLATE_VBoxNoCrtGccLib_CFLAGS += $(VBOX_GCC_fno-stack-protector) $(VBOX_GCC_nopie)
|
||||||
|
+ TEMPLATE_VBoxNoCrtGccLib_CXXFLAGS += $(VBOX_GCC_fno-stack-protector) $(VBOX_GCC_nopie)
|
||||||
|
ifeq ($(KBUILD_TARGET_ARCH),amd64)
|
||||||
|
# in 64-bit mode we'll build a sys-module (VBoxREM2).
|
||||||
|
if1of ($(KBUILD_TARGET), darwin solaris)
|
||||||
|
@@ -6467,8 +6468,8 @@
|
||||||
|
TEMPLATE_VBOXGUESTR3XF86MOD_CFLAGS = $(TEMPLATE_VBOXGUESTR3EXE_CFLAGS) -fno-pie -fno-merge-constants -std=c99 -ffreestanding
|
||||||
|
TEMPLATE_VBOXGUESTR3XF86MOD_CXXFLAGS= $(TEMPLATE_VBOXGUESTR3EXE_CXXFLAGS) -fno-pie -fno-merge-constants -ffreestanding
|
||||||
|
ifndef VBOX_WITH_COMPATIBLE_LINUX_GUEST_PACKAGE
|
||||||
|
- TEMPLATE_VBOXGUESTR3XF86MOD_CFLAGS += $(VBOX_GCC_fno-stack-protector)
|
||||||
|
- TEMPLATE_VBOXGUESTR3XF86MOD_CXXFLAGS += $(VBOX_GCC_fno-stack-protector)
|
||||||
|
+ TEMPLATE_VBOXGUESTR3XF86MOD_CFLAGS += $(VBOX_GCC_fno-stack-protector) $(VBOX_GCC_nopie)
|
||||||
|
+ TEMPLATE_VBOXGUESTR3XF86MOD_CXXFLAGS += $(VBOX_GCC_fno-stack-protector) $(VBOX_GCC_nopie)
|
||||||
|
endif
|
||||||
|
TEMPLATE_VBOXGUESTR3XF86MOD_SYSSUFF = .o
|
||||||
|
TEMPLATE_VBOXGUESTR3XF86MOD_LIBS = \
|
||||||
|
diff -Naur VirtualBox-5.1.24/src/VBox/Devices/PC/ipxe/Makefile.kmk VirtualBox-5.1.24/src/VBox/Devices/PC/ipxe/Makefile.kmk
|
||||||
|
--- VirtualBox-5.1.24/src/VBox/Devices/PC/ipxe/Makefile.kmk 2017-07-26 13:55:27.746972186 -0400
|
||||||
|
+++ VirtualBox-5.1.24/src/VBox/Devices/PC/ipxe/Makefile.kmk 2017-07-26 13:53:10.641974329 -0400
|
||||||
|
@@ -132,6 +132,7 @@
|
||||||
|
-W \
|
||||||
|
-Wformat-nonliteral \
|
||||||
|
$(VBOX_GCC_fno-stack-protector) \
|
||||||
|
+ $(VBOX_GCC_nopie) \
|
||||||
|
$(VBOX_GCC_fno-dwarf2-cfi-asm) \
|
||||||
|
$(VBOX_GCC_Wno-address)
|
||||||
|
TEMPLATE_iPxe_ASFLAGS = \
|
||||||
|
@@ -155,6 +156,7 @@
|
||||||
|
-W \
|
||||||
|
-Wformat-nonliteral \
|
||||||
|
$(VBOX_GCC_fno-stack-protector) \
|
||||||
|
+ $(VBOX_GCC_nopie) \
|
||||||
|
$(VBOX_GCC_fno-dwarf2-cfi-asm) \
|
||||||
|
$(VBOX_GCC_Wno-address) \
|
||||||
|
-DASSEMBLY
|
@ -1 +1,2 @@
|
|||||||
DIST eselect-php-0.9.2.tar.xz 48356 SHA256 8b2acfccb3d2e3d7cad137fc4306711371ebd544cbcdad8e9d46c5dacf8ed889 SHA512 ebf4c9039aaa3ffad79dee181b5cd77f144a4b1b49d80291b290377b7ca5a9618d8b18922f0624e646c4d80266c58199bb936a7b8dd5d2e2bdc296099f583edf WHIRLPOOL 5ca0673a80b5e88522ff1ca82c4b4f842a63439cd47562c72048a4d66dc88d2dcc7070c28c0b8ff50a75bdb1a9056ee5391b37f4dc34cc9eda3652c6791a276c
|
DIST eselect-php-0.9.2.tar.xz 48356 SHA256 8b2acfccb3d2e3d7cad137fc4306711371ebd544cbcdad8e9d46c5dacf8ed889 SHA512 ebf4c9039aaa3ffad79dee181b5cd77f144a4b1b49d80291b290377b7ca5a9618d8b18922f0624e646c4d80266c58199bb936a7b8dd5d2e2bdc296099f583edf WHIRLPOOL 5ca0673a80b5e88522ff1ca82c4b4f842a63439cd47562c72048a4d66dc88d2dcc7070c28c0b8ff50a75bdb1a9056ee5391b37f4dc34cc9eda3652c6791a276c
|
||||||
|
DIST eselect-php-0.9.4.tar.xz 49576 SHA256 44c5966a2c7f0a052f77f780995d658cecf2407b928e31e99ac810c16c7c1a95 SHA512 2ba1dd75d4bb9611c6687ed4449f715728263538f772652aa1ac013103cf9ddf328c854326cf6da4f9b3ff2279bf99d973325520fe8b4e3ba7a76a9c3264e78e WHIRLPOOL cd743fd8a99955e03ec9693e83fb808b6c048e04b8609f1a12be22cdcbfc4d6fd28fa5e66e74f1ef665d6366e9bb53120fcf91a088095fe7386549b6fb3bbff1
|
||||||
|
@ -0,0 +1,66 @@
|
|||||||
|
# Copyright 1999-2017 Gentoo Foundation
|
||||||
|
# Distributed under the terms of the GNU General Public License v2
|
||||||
|
|
||||||
|
EAPI=6
|
||||||
|
|
||||||
|
inherit systemd
|
||||||
|
|
||||||
|
DESCRIPTION="PHP eselect module"
|
||||||
|
HOMEPAGE="https://gitweb.gentoo.org/proj/eselect-php.git/"
|
||||||
|
SRC_URI="https://dev.gentoo.org/~mjo/distfiles/${P}.tar.xz"
|
||||||
|
|
||||||
|
LICENSE="GPL-2"
|
||||||
|
SLOT="0"
|
||||||
|
KEYWORDS="~alpha ~amd64 ~arm ~arm64 ~hppa ~ia64 ~mips ~ppc ~ppc64 ~s390 ~sh ~sparc ~x86 ~amd64-fbsd ~x86-fbsd ~amd64-linux ~x86-linux ~ppc-macos ~x64-macos ~x86-macos"
|
||||||
|
IUSE="fpm apache2"
|
||||||
|
|
||||||
|
# The "DirectoryIndex" line in 70_mod_php.conf requires mod_dir.
|
||||||
|
RDEPEND="app-admin/eselect
|
||||||
|
apache2? ( www-servers/apache[apache2_modules_dir] )
|
||||||
|
fpm? ( sys-apps/gentoo-functions )"
|
||||||
|
|
||||||
|
src_configure(){
|
||||||
|
# We expect localstatedir to be "var"ish, not "var/lib"ish, because
|
||||||
|
# that's what PHP upstream expects. See for example the FPM
|
||||||
|
# configuration where they put logs in @localstatedir@/log.
|
||||||
|
#
|
||||||
|
# The libdir is passed explicitly in case the /usr/lib symlink
|
||||||
|
# is not present (bug 624528).
|
||||||
|
econf --libdir="${EPREFIX}/usr/$(get_libdir)" \
|
||||||
|
--localstatedir="${EPREFIX}/var" \
|
||||||
|
--with-piddir="${EPREFIX}/run" \
|
||||||
|
$(use_enable apache2) \
|
||||||
|
$(use_enable fpm)
|
||||||
|
}
|
||||||
|
|
||||||
|
src_install() {
|
||||||
|
default
|
||||||
|
|
||||||
|
# This can be removed after a while...
|
||||||
|
if use apache2 ; then
|
||||||
|
insinto /etc/apache2/modules.d
|
||||||
|
newins "${FILESDIR}/70_mod_php5.backcompat.conf" 70_mod_php5.conf
|
||||||
|
fi
|
||||||
|
|
||||||
|
if use fpm ; then
|
||||||
|
systemd_dotmpfilesd "${FILESDIR}/php-fpm.conf"
|
||||||
|
exeinto /usr/libexec
|
||||||
|
newexe "${FILESDIR}/php-fpm-launcher-r1" php-fpm-launcher
|
||||||
|
fi
|
||||||
|
}
|
||||||
|
|
||||||
|
pkg_postinst() {
|
||||||
|
if use apache2 ; then
|
||||||
|
elog
|
||||||
|
elog "If you are upgrading, be warned that our mod_php configuration"
|
||||||
|
elog "file has changed! You should now define -DPHP for the apache2"
|
||||||
|
elog "daemon, and inspect the new 70_mod_php.conf which has been"
|
||||||
|
elog "installed. Module loading involves eselect as of this version."
|
||||||
|
elog
|
||||||
|
elog "You must run eselect at least once to choose your apache2 target"
|
||||||
|
elog "before the new configuration will work. Afterwards, and after you"
|
||||||
|
elog "have reviewed your new configuration, you are advised to remove"
|
||||||
|
elog "the obsolete 70_mod_php5.conf file."
|
||||||
|
elog
|
||||||
|
fi
|
||||||
|
}
|
@ -1 +1,2 @@
|
|||||||
DIST rlwrap-0.42.tar.gz 279608 SHA256 5a70d8469db9d0a6630628f2d5d2972ad16c092400b7fbbdf699693ec0f87e44 SHA512 991885e75aabf0d43581d59f7c78f7f64c3f32072de08ff5796cba75c0716548d2186cbe2d739f3e772871e3586d036f069db73b2ee8a30b2f7985088d0f68df WHIRLPOOL a4ff4ac599f87695c15060dcacb2d10b5d8ff21512f38b7374e096ef71ae17f7e977ecb9e3004c231d8d8c5b37e2ddbab724fedb3439f507a5a483373f4af14b
|
DIST rlwrap-0.42.tar.gz 279608 SHA256 5a70d8469db9d0a6630628f2d5d2972ad16c092400b7fbbdf699693ec0f87e44 SHA512 991885e75aabf0d43581d59f7c78f7f64c3f32072de08ff5796cba75c0716548d2186cbe2d739f3e772871e3586d036f069db73b2ee8a30b2f7985088d0f68df WHIRLPOOL a4ff4ac599f87695c15060dcacb2d10b5d8ff21512f38b7374e096ef71ae17f7e977ecb9e3004c231d8d8c5b37e2ddbab724fedb3439f507a5a483373f4af14b
|
||||||
|
DIST rlwrap-0.43.tar.gz 313139 SHA256 8e86d0b7882d9b8a73d229897a90edc207b1ae7fa0899dca8ee01c31a93feb2f SHA512 4a1440b2eef3a1664c6381eb09c19f4030de2c0ef4f1f3509f7d6e130d3c5e9c3ceb00fc6ea6052b22bbe1f6b162f72e0b47564df34ccecc5220f195c22e86a1 WHIRLPOOL 89975c663b6584b09b3d7b0e16ff06c7daa88c22af4414e964e06266be5822c8fc2f3894ba4bbfa5e0464c1303077488e2b77dbf5c94d27107b1ce1f0ae85364
|
||||||
|
@ -0,0 +1,21 @@
|
|||||||
|
# Copyright 1999-2017 Gentoo Foundation
|
||||||
|
# Distributed under the terms of the GNU General Public License v2
|
||||||
|
|
||||||
|
EAPI=6
|
||||||
|
|
||||||
|
DESCRIPTION="GNU readline wrapper"
|
||||||
|
HOMEPAGE="http://utopia.knoware.nl/~hlub/uck/rlwrap/"
|
||||||
|
SRC_URI="http://utopia.knoware.nl/~hlub/uck/rlwrap/${P}.tar.gz"
|
||||||
|
SRC_URI="https://github.com/hanslub42/${PN}/releases/download/v${PV}/${P}.tar.gz"
|
||||||
|
|
||||||
|
LICENSE="GPL-2"
|
||||||
|
SLOT="0"
|
||||||
|
KEYWORDS="~amd64 ~mips ~ppc ~x86 ~ppc-aix ~x64-cygwin ~amd64-linux ~x86-linux ~ppc-macos ~x64-macos ~x86-macos"
|
||||||
|
IUSE="debug"
|
||||||
|
|
||||||
|
RDEPEND="sys-libs/readline:0="
|
||||||
|
DEPEND="${RDEPEND}"
|
||||||
|
|
||||||
|
src_configure() {
|
||||||
|
econf $(use_enable debug)
|
||||||
|
}
|
@ -0,0 +1 @@
|
|||||||
|
DIST ttyload-0.5.3.tar.bz2 15039 SHA256 7d3147b22530e6de865279aaad8b9e0348575379413ed1a2d410257baf92d783 SHA512 1affc171fd569d4127d7a51dda5764272e554a96db6ad4418ff6120f9b0e573679b33d45797adcb667216d167e9f3ee41349a53d4f7808b3b1c5bed76e3f4bbb WHIRLPOOL 469011ee2acc6e785ecbbe957a6ebe6e88e0d97cee9b3872d663a7ed907768167aaf2c8113d853de905db84ec96a03c6798926013a7aed76f9ebd70807b0c500
|
@ -0,0 +1,12 @@
|
|||||||
|
<?xml version="1.0" encoding="UTF-8"?>
|
||||||
|
<!DOCTYPE pkgmetadata SYSTEM "http://www.gentoo.org/dtd/metadata.dtd">
|
||||||
|
<pkgmetadata>
|
||||||
|
<maintainer type="person">
|
||||||
|
<email>monsieurp@gentoo.org</email>
|
||||||
|
<name>Patrice Clement</name>
|
||||||
|
</maintainer>
|
||||||
|
<maintainer type="project">
|
||||||
|
<email>shell-tools@gentoo.org</email>
|
||||||
|
<name>Gentoo Shell Tools Project</name>
|
||||||
|
</maintainer>
|
||||||
|
</pkgmetadata>
|
@ -0,0 +1,36 @@
|
|||||||
|
# Copyright 1999-2017 Gentoo Foundation
|
||||||
|
# Distributed under the terms of the GNU General Public License v2
|
||||||
|
|
||||||
|
EAPI=6
|
||||||
|
|
||||||
|
inherit toolchain-funcs
|
||||||
|
|
||||||
|
DESCRIPTION="color-coded graph of load averages over time"
|
||||||
|
HOMEPAGE="http://www.daveltd.com/src/util/ttyload https://github.com/lindes/ttyload"
|
||||||
|
SRC_URI="http://www.daveltd.com/src/util/${PN}/${P}.tar.bz2"
|
||||||
|
|
||||||
|
KEYWORDS="~amd64 ~x86"
|
||||||
|
LICENSE="ISC"
|
||||||
|
SLOT="0"
|
||||||
|
|
||||||
|
DEPEND="sys-libs/ncurses:0="
|
||||||
|
|
||||||
|
RESTRICT="test"
|
||||||
|
|
||||||
|
DOCS=( BUGS HISTORY LICENSE README.md TODO )
|
||||||
|
|
||||||
|
src_prepare() {
|
||||||
|
default
|
||||||
|
sed -i '10i#include <time.h>' "${PN}.h" || die
|
||||||
|
sed -i -e "s#make#$\(MAKE\)#" Makefile || die
|
||||||
|
}
|
||||||
|
|
||||||
|
src_compile() {
|
||||||
|
emake CC=$(tc-getCC)
|
||||||
|
}
|
||||||
|
|
||||||
|
src_install() {
|
||||||
|
dobin "${PN}"
|
||||||
|
doman "${PN}.1"
|
||||||
|
einstalldocs
|
||||||
|
}
|
@ -1,2 +1,3 @@
|
|||||||
DIST OOoFBTools-2.48.zip 5631726 SHA256 752e5d3dc404ee2199cee3b347699133054ab10b8b1e7ec3bd659055733f501a SHA512 31d6571e4050975bdec92f85578235dea4784cd0e45dc4d1e612e0999744f1700a8bf22983378333aecdb146ffd151b6e7cbe071b90e9816443e939b27d117f8 WHIRLPOOL bc5effbb7f171168feb16e983d8d32d3bbf5885e49b5c8dcf7db733c865a36d5bd229b7caa6c3756fff7aa315bd0c9a4567717eaa311b21539f5ef3c75bb1cfa
|
DIST OOoFBTools-2.48.zip 5631726 SHA256 752e5d3dc404ee2199cee3b347699133054ab10b8b1e7ec3bd659055733f501a SHA512 31d6571e4050975bdec92f85578235dea4784cd0e45dc4d1e612e0999744f1700a8bf22983378333aecdb146ffd151b6e7cbe071b90e9816443e939b27d117f8 WHIRLPOOL bc5effbb7f171168feb16e983d8d32d3bbf5885e49b5c8dcf7db733c865a36d5bd229b7caa6c3756fff7aa315bd0c9a4567717eaa311b21539f5ef3c75bb1cfa
|
||||||
DIST OOoFBTools-2.50.zip 5631882 SHA256 d69d97a668d3f980280304d844b5e7dc24af147cfc5f41f2b128f4790ad65cc0 SHA512 a2aed60ac1690f9a629f3d81e449a7700b949f75e332748b846edb85c5954622e1cbac62e97cb9a5f823f1da2c901cc6cb4fedfd58a1c45136331b55ef6ce482 WHIRLPOOL eecc08b165e22b19d2f50edf7fcce81c43f864911633dc08e24abb814f3b11ce20a4c16b3c6fadc249f3d9a04762fd399a8c1286ad05ce3d56116ae877116ff3
|
DIST OOoFBTools-2.50.zip 5631882 SHA256 d69d97a668d3f980280304d844b5e7dc24af147cfc5f41f2b128f4790ad65cc0 SHA512 a2aed60ac1690f9a629f3d81e449a7700b949f75e332748b846edb85c5954622e1cbac62e97cb9a5f823f1da2c901cc6cb4fedfd58a1c45136331b55ef6ce482 WHIRLPOOL eecc08b165e22b19d2f50edf7fcce81c43f864911633dc08e24abb814f3b11ce20a4c16b3c6fadc249f3d9a04762fd399a8c1286ad05ce3d56116ae877116ff3
|
||||||
|
DIST OOoFBTools-2.51.zip 5632570 SHA256 78d7d9e0f0176de322d20143165a9ece65d776308cc8d376e89dadac01057943 SHA512 c89044c9e6b82a51fcfb370a31cc2ef6ab16cc2895667519324c42c450164ed933e3b492b3ed21a50dd5e563bf796f71bb7333132410fba512eb59e1d5b7255d WHIRLPOOL 748f17c23538c4424e63b4070ca6317a6b813dd240787e98b10b62456d024414b3d6960a2fd6b3c1551225ea8009f87f62faab5f62b5205ddbe3ae717ecdd139
|
||||||
|
@ -0,0 +1,41 @@
|
|||||||
|
# Copyright 1999-2017 Gentoo Foundation
|
||||||
|
# Distributed under the terms of the GNU General Public License v2
|
||||||
|
|
||||||
|
EAPI=6
|
||||||
|
|
||||||
|
MY_PN="OOoFBTools"
|
||||||
|
|
||||||
|
OFFICE_EXTENSIONS=(
|
||||||
|
"${MY_PN}.oxt"
|
||||||
|
)
|
||||||
|
|
||||||
|
inherit office-ext-r1
|
||||||
|
|
||||||
|
DESCRIPTION="OpenOffice extension for the FictionBook2 format with validation"
|
||||||
|
HOMEPAGE="https://sourceforge.net/projects/fbtools/"
|
||||||
|
SRC_URI="mirror://sourceforge/fbtools/files/release/${MY_PN}-${PV}.zip"
|
||||||
|
|
||||||
|
LICENSE="GPL-3"
|
||||||
|
SLOT="0"
|
||||||
|
KEYWORDS="~amd64 ~x86"
|
||||||
|
|
||||||
|
RDEPEND="dev-libs/libxml2
|
||||||
|
app-arch/zip"
|
||||||
|
|
||||||
|
S="${WORKDIR}/${MY_PN}-${PV}"
|
||||||
|
|
||||||
|
OFFICE_EXTENSIONS_LOCATION="${S}"
|
||||||
|
|
||||||
|
src_prepare() {
|
||||||
|
# Remove Windows cruft
|
||||||
|
pushd "${WORKDIR}/${MY_PN}.oxt" &>/dev/null || die
|
||||||
|
rm -r win32 || die
|
||||||
|
popd &>/dev/null || die
|
||||||
|
|
||||||
|
eapply_user
|
||||||
|
}
|
||||||
|
|
||||||
|
src_install() {
|
||||||
|
office-ext-r1_src_install
|
||||||
|
dodoc ChangeLog*
|
||||||
|
}
|
@ -1,5 +1,2 @@
|
|||||||
DIST paperwork-backend-1.0.5.tar.gz 46433 SHA256 a2e481873eec6b676b89aab21d6863264f10e4179cf72a253f52e565a602fcfd SHA512 87debdcef457bc1873d25d7bdb15addf0c78d9f1cc9c324cec51c60bc863a4e891680f85258399f1f0506235e7524bffbf49783a6f23d0f6d0fee68924d697da WHIRLPOOL ebb5d1fc5054fe4306879404805b9ca5e763eadf39fe491775bb767fb7369bc39484449eac0b81ee2e961597a9bf13a4a4eeef426be0afb21211e717ad3382c7
|
|
||||||
DIST paperwork-backend-1.0.6.tar.gz 46773 SHA256 6881de10aa7e47039baebbd4742ceb49e048f46f22398a81f690e62a7cdce3ce SHA512 e372d1b702f026746d53f62a85fdf406234e13047e08202e5a793af5669e53f0a87b84ad6ae5e5a56570707bb38a0dcd0503f5578caa2d616502de2757a0d0b9 WHIRLPOOL 37e185769ca984072715a7abe4ca80759a6be3ea110ab56ac01f5e2397c7a95aa0ee22422eb6ef786ca94e7f1ac3b57688a21780843f12923d7f53f155681cb2
|
|
||||||
DIST paperwork-backend-1.1.1.tar.gz 54095 SHA256 5201868718de37c669c2e9670e61a32b4c2f6833258d0c0ce238026612e4b5c1 SHA512 bcbdfe1a55fb82b7c8eb1b2a6e4eea367203992d4d87c42db3b3f55852f127d6688d1cfdc1016151648a2d83690534ad951d6852c5306c53c9096aa052244168 WHIRLPOOL 3e72b6aee4a8e3bc2ef4064ad300a042c5a81837725e36a5933d861472b6975ea8d792de0545f6c97e367e82e1753646bbf46259a1cf46416c98886bcb24ba33
|
|
||||||
DIST paperwork-backend-1.1.2.tar.gz 54340 SHA256 19b15ed995b06bd9d9a61c82389983feaaaa6d5dffe41b88e87bbe3a5e297dd8 SHA512 626a4e44243769c0982d2a4677e35e4c3431e6b68b05687f13574e1f9cfd026d0b949e95e53ea37c976ea5826883eb2ac672cffc346eb05631f3498bb525391a WHIRLPOOL ba197dfb5d131e522df9a8b8d77c8a94e01a1001dede460d8e7ecce6c413c1e7735d6bcd19a739b01b4abceb72c88ca654aa59b2a1513eb4aa3bf68132e07330
|
DIST paperwork-backend-1.1.2.tar.gz 54340 SHA256 19b15ed995b06bd9d9a61c82389983feaaaa6d5dffe41b88e87bbe3a5e297dd8 SHA512 626a4e44243769c0982d2a4677e35e4c3431e6b68b05687f13574e1f9cfd026d0b949e95e53ea37c976ea5826883eb2ac672cffc346eb05631f3498bb525391a WHIRLPOOL ba197dfb5d131e522df9a8b8d77c8a94e01a1001dede460d8e7ecce6c413c1e7735d6bcd19a739b01b4abceb72c88ca654aa59b2a1513eb4aa3bf68132e07330
|
||||||
DIST paperwork-backend-1.1.tar.gz 54088 SHA256 d2a78de1c6288779b191e616fec8b6fdfd37934c2ccec90563fadc6d2f2013ba SHA512 57e95b3a29989e0d615ba5295e32fa5b513521b354407565be95be96374b991923c89880fe92138225012e21d0a52149878e2c807673c811771d8fc16e5d4988 WHIRLPOOL 701f2ea789b2f7d45d3e369cab9baa7976f885ee0f7236f8b356fca0fc769f9e52a137cfdf62f8ec56cf62a0d80327d361172e38bd2d2830aa1f09a53cbcd63d
|
DIST paperwork-backend-1.2.tar.gz 63167 SHA256 321f1a637b4df6c8d01caa2d172ca10c6285d1515ba75f594eeee71643ef5378 SHA512 278d7080c9806a6ae68cb15ba9df2ac22bd2c120f0e77a9d7eacbbd6e70476d4fb803c572216e580a068527ae8c10c3f2e66199aca3d94949e655c08214beeb1 WHIRLPOOL c064abc9feaac7a8d55a9e712bc3f0c61d60c7518560d44328d4cf3147614914445c9a29598b4d536e29186af793851acfcc6d2b0e3d5a3f7b93ed2987bfe144
|
||||||
|
@ -1,28 +0,0 @@
|
|||||||
# Copyright 1999-2016 Gentoo Foundation
|
|
||||||
# Distributed under the terms of the GNU General Public License v2
|
|
||||||
|
|
||||||
EAPI=6
|
|
||||||
PYTHON_COMPAT=( python{2_7,3_4,3_5} )
|
|
||||||
|
|
||||||
inherit distutils-r1
|
|
||||||
|
|
||||||
DESCRIPTION="Backend part of Paperwork (Python API, no UI)"
|
|
||||||
HOMEPAGE="https://github.com/jflesch/paperwork-backend"
|
|
||||||
SRC_URI="https://github.com/jflesch/${PN}/archive/${PV}.tar.gz -> ${P}.tar.gz"
|
|
||||||
|
|
||||||
LICENSE="GPL-3"
|
|
||||||
SLOT="0"
|
|
||||||
KEYWORDS="~amd64 ~x86"
|
|
||||||
IUSE=""
|
|
||||||
|
|
||||||
RDEPEND="app-text/poppler[introspection]
|
|
||||||
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}"
|
|
@ -1,29 +0,0 @@
|
|||||||
# Copyright 1999-2017 Gentoo Foundation
|
|
||||||
# Distributed under the terms of the GNU General Public License v2
|
|
||||||
|
|
||||||
EAPI=6
|
|
||||||
PYTHON_COMPAT=( python{2_7,3_4,3_5} )
|
|
||||||
|
|
||||||
inherit distutils-r1
|
|
||||||
|
|
||||||
DESCRIPTION="Backend part of Paperwork (Python API, no UI)"
|
|
||||||
HOMEPAGE="https://github.com/jflesch/paperwork-backend"
|
|
||||||
SRC_URI="https://github.com/jflesch/${PN}/archive/${PV}.tar.gz -> ${P}.tar.gz"
|
|
||||||
|
|
||||||
LICENSE="GPL-3"
|
|
||||||
SLOT="0"
|
|
||||||
KEYWORDS="~amd64 ~x86"
|
|
||||||
IUSE=""
|
|
||||||
|
|
||||||
RDEPEND="app-text/poppler[introspection]
|
|
||||||
$(python_gen_cond_dep 'dev-python/configparser[${PYTHON_USEDEP}]' python2_7 )
|
|
||||||
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}"
|
|
@ -1,28 +0,0 @@
|
|||||||
# Copyright 1999-2017 Gentoo Foundation
|
|
||||||
# Distributed under the terms of the GNU General Public License v2
|
|
||||||
|
|
||||||
EAPI=6
|
|
||||||
PYTHON_COMPAT=( python{3_4,3_5} )
|
|
||||||
|
|
||||||
inherit distutils-r1
|
|
||||||
|
|
||||||
DESCRIPTION="Backend part of Paperwork (Python API, no UI)"
|
|
||||||
HOMEPAGE="https://github.com/jflesch/paperwork-backend"
|
|
||||||
SRC_URI="https://github.com/jflesch/${PN}/archive/${PV}.tar.gz -> ${P}.tar.gz"
|
|
||||||
|
|
||||||
LICENSE="GPL-3"
|
|
||||||
SLOT="0"
|
|
||||||
KEYWORDS="~amd64 ~x86"
|
|
||||||
IUSE=""
|
|
||||||
|
|
||||||
RDEPEND="app-text/poppler[introspection]
|
|
||||||
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}"
|
|
@ -1,6 +1,2 @@
|
|||||||
DIST paperwork-0.3.2.tar.gz 179509 SHA256 55a3aa814cf0b62bc2e40d0b4789068ebec9bfd9fff182d75429aca624d243f1 SHA512 b9dd1010f308d28e300d246d103cdd15253ed8e653721a89ab7de1aa6129b9a52f6ca6afe4714e19fca41369441240900af23faefd7284bbd420a9833bf3449e WHIRLPOOL f20ac1e45b754612b452d3bbb5854857c604108fe4a71b8870de7b317087b99597dc3c9275776c0b1cd68118c78c45f38195ef4635abe514a565a7e1b911895d
|
|
||||||
DIST paperwork-1.0.5.tar.gz 328468 SHA256 8a09910f852196983f4beabe97711ae1624d2071755cf6a6fed99d73bedc91ae SHA512 92c7515f10a766064cf1b48a3a482529665c265b09c26c27971e5942020749698168171fa7d242984883d9d4b09c5dd8ae6a29c6626fcb4d96972495164e425e WHIRLPOOL ce18d41ada101cc4b3a7d5d192fe780a78c9d41d044a7c7b1f0eca701ece25653c8b1588bcfd32eb5ae30552e299dd8537850c5363f38d875cde2d29663293a3
|
|
||||||
DIST paperwork-1.0.6.tar.gz 329420 SHA256 b0f5d1cea1f4930e748d635f5aab7eed3282b8aea221b8c0624c71e76c7674c1 SHA512 35248ce3428a60f05865cf02ffda1f60c5462bae5bc0544566d64d827f3466ebfbf410f933ad70563e04c687b28255071a3d8c833d2316cbeb228a0e965398af WHIRLPOOL 269a365c303ecb23276613996f1daf571120406cb39edcb00ef5cbf1168bfb6b8c0fb5571d3a1d155de9ba41bb960ed8829d377dbaed3793ad33358ce6bd5267
|
|
||||||
DIST paperwork-1.1.1.tar.gz 330784 SHA256 ab10462f0e50560a99d796bca582844c1f9eec6e8987c5fbcd3ff8b40c946018 SHA512 72d98d252ad9249d95df1c1ce907acba6b7b797fb72091bdc142a69d8786e947915bdfed8640159775edf8d29e119cf322a17ce728685c57dba4a4f12c85bbcd WHIRLPOOL 454e656ed82c31b254d98728f41a40c7e32c610bb43552ec2c5b9090e4a1db05851b8f663933eaa9476bf137372e09deab9c302158b4d21a3b01e177e258fcde
|
|
||||||
DIST paperwork-1.1.2.tar.gz 331028 SHA256 7beaf56fa91fb602d185256f3bbf3d9a85a332efd87d35dc22dbb9051bd94fa8 SHA512 14c018c9b148e1569948d2de7b1c0c04d353a7af7aa6a7102585665d9af2f5f2055145338a001085be0fc165abec066d73d3adc4a378a307326edf730c3c3606 WHIRLPOOL f951a15a9e2c14dbd08cd0b767c99dfa8ba63890d07ca135c347f141696652085494bc42f01d29015676a45fa4bc0f5785e4ec8a33cd5ab46bea48e21770d050
|
DIST paperwork-1.1.2.tar.gz 331028 SHA256 7beaf56fa91fb602d185256f3bbf3d9a85a332efd87d35dc22dbb9051bd94fa8 SHA512 14c018c9b148e1569948d2de7b1c0c04d353a7af7aa6a7102585665d9af2f5f2055145338a001085be0fc165abec066d73d3adc4a378a307326edf730c3c3606 WHIRLPOOL f951a15a9e2c14dbd08cd0b767c99dfa8ba63890d07ca135c347f141696652085494bc42f01d29015676a45fa4bc0f5785e4ec8a33cd5ab46bea48e21770d050
|
||||||
DIST paperwork-1.1.tar.gz 330284 SHA256 0f41f85f7d7111b41f1326959a81149e4b93c593045b5594b6f2056dd8137589 SHA512 a96924113dc804ae24d08b14334777e8e586b516b197b463c924d74fac8f45b299b4eb437b72d02d7e0423f41f819bfa13804ba01654ef4eeb1d4e424f3cea5b WHIRLPOOL 053a0cfffbd908b303611e5ba9e7f2e3b87462b947c29de34478b62472586cd3c96651e1c65b83ca295d38eebaf246e8785ba1fc0d119fc303faa56d186ab4b4
|
DIST paperwork-1.2.tar.gz 8086428 SHA256 87f4610adfe0f79931d27d9a3c3b5441f77d9db64ed4f72ae2a1bf844df7eca5 SHA512 9c8c43ef31be2eef57ffbcdb00b4e91dd2b1eade75814b789c489abfb6f7bae07e68f7207c8fdef4f3bf95bd68bca8a680b965259106af9f0166bee7a6cf5ea0 WHIRLPOOL fa0e6acf4bd7514899433077a32222ced8fdf8565467dd7cb8cc05ab2c737352d67a8375af98bbed507ab5a73b302cd968dddce2bba8f13a3749edef8562f001
|
||||||
|
@ -1,33 +0,0 @@
|
|||||||
# Copyright 1999-2016 Gentoo Foundation
|
|
||||||
# Distributed under the terms of the GNU General Public License v2
|
|
||||||
|
|
||||||
EAPI=6
|
|
||||||
PYTHON_COMPAT=( python2_7 )
|
|
||||||
|
|
||||||
inherit distutils-r1
|
|
||||||
|
|
||||||
DESCRIPTION="a personal document manager for scanned documents (and PDFs)"
|
|
||||||
HOMEPAGE="https://github.com/jflesch/paperwork"
|
|
||||||
SRC_URI="https://github.com/jflesch/${PN}/archive/${PV}.tar.gz -> ${P}.tar.gz"
|
|
||||||
|
|
||||||
LICENSE="GPL-3"
|
|
||||||
SLOT="0"
|
|
||||||
KEYWORDS="~amd64 ~x86"
|
|
||||||
IUSE=""
|
|
||||||
|
|
||||||
RDEPEND="app-text/poppler[introspection]
|
|
||||||
dev-python/joblib[${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/pyinsane-1.3.8:1[${PYTHON_USEDEP}]
|
|
||||||
>=dev-python/pyocr-0.3.0[${PYTHON_USEDEP}]
|
|
||||||
dev-python/python-levenshtein[${PYTHON_USEDEP}]
|
|
||||||
dev-python/termcolor[${PYTHON_USEDEP}]
|
|
||||||
dev-python/whoosh[${PYTHON_USEDEP}]
|
|
||||||
dev-python/simplebayes[${PYTHON_USEDEP}]
|
|
||||||
dev-util/glade[introspection,python]
|
|
||||||
dev-python/pillow[${PYTHON_USEDEP}]
|
|
||||||
x11-libs/gtk+:3[introspection]"
|
|
||||||
DEPEND="${RDEPEND}"
|
|
@ -1,29 +0,0 @@
|
|||||||
# Copyright 1999-2016 Gentoo Foundation
|
|
||||||
# Distributed under the terms of the GNU General Public License v2
|
|
||||||
|
|
||||||
EAPI=6
|
|
||||||
PYTHON_COMPAT=( python{2_7,3_4,3_5} )
|
|
||||||
|
|
||||||
inherit distutils-r1
|
|
||||||
|
|
||||||
DESCRIPTION="a personal document manager for scanned documents (and PDFs)"
|
|
||||||
HOMEPAGE="https://github.com/jflesch/paperwork"
|
|
||||||
SRC_URI="https://github.com/jflesch/${PN}/archive/${PV}.tar.gz -> ${P}.tar.gz"
|
|
||||||
|
|
||||||
LICENSE="GPL-3"
|
|
||||||
SLOT="0"
|
|
||||||
KEYWORDS="~amd64 ~x86"
|
|
||||||
IUSE=""
|
|
||||||
|
|
||||||
RDEPEND="~app-text/paperwork-backend-${PV}[${PYTHON_USEDEP}]
|
|
||||||
dev-python/libpillowfight[${PYTHON_USEDEP}]
|
|
||||||
dev-python/pillow[${PYTHON_USEDEP}]
|
|
||||||
dev-python/pycairo[${PYTHON_USEDEP}]
|
|
||||||
dev-python/pyenchant[${PYTHON_USEDEP}]
|
|
||||||
dev-python/pygobject:3[${PYTHON_USEDEP}]
|
|
||||||
dev-python/pyinsane:2[${PYTHON_USEDEP}]
|
|
||||||
>=dev-python/pyocr-0.3.0[${PYTHON_USEDEP}]
|
|
||||||
dev-python/simplebayes[${PYTHON_USEDEP}]
|
|
||||||
dev-util/glade[introspection,python]
|
|
||||||
x11-libs/gtk+:3[introspection]"
|
|
||||||
DEPEND="${RDEPEND}"
|
|
@ -1,30 +0,0 @@
|
|||||||
# Copyright 1999-2017 Gentoo Foundation
|
|
||||||
# Distributed under the terms of the GNU General Public License v2
|
|
||||||
|
|
||||||
EAPI=6
|
|
||||||
PYTHON_COMPAT=( python{2_7,3_4,3_5} )
|
|
||||||
|
|
||||||
inherit distutils-r1
|
|
||||||
|
|
||||||
DESCRIPTION="a personal document manager for scanned documents (and PDFs)"
|
|
||||||
HOMEPAGE="https://github.com/jflesch/paperwork"
|
|
||||||
SRC_URI="https://github.com/jflesch/${PN}/archive/${PV}.tar.gz -> ${P}.tar.gz"
|
|
||||||
|
|
||||||
LICENSE="GPL-3"
|
|
||||||
SLOT="0"
|
|
||||||
KEYWORDS="~amd64 ~x86"
|
|
||||||
IUSE=""
|
|
||||||
|
|
||||||
RDEPEND="~app-text/paperwork-backend-${PV}[${PYTHON_USEDEP}]
|
|
||||||
$(python_gen_cond_dep 'dev-python/configparser[${PYTHON_USEDEP}]' python2_7 )
|
|
||||||
dev-python/libpillowfight[${PYTHON_USEDEP}]
|
|
||||||
dev-python/pillow[${PYTHON_USEDEP}]
|
|
||||||
dev-python/pycairo[${PYTHON_USEDEP}]
|
|
||||||
dev-python/pyenchant[${PYTHON_USEDEP}]
|
|
||||||
dev-python/pygobject:3[${PYTHON_USEDEP}]
|
|
||||||
dev-python/pyinsane:2[${PYTHON_USEDEP}]
|
|
||||||
>=dev-python/pyocr-0.3.0[${PYTHON_USEDEP}]
|
|
||||||
dev-python/simplebayes[${PYTHON_USEDEP}]
|
|
||||||
dev-util/glade[introspection,python]
|
|
||||||
x11-libs/gtk+:3[introspection]"
|
|
||||||
DEPEND="${RDEPEND}"
|
|
@ -1,29 +0,0 @@
|
|||||||
# Copyright 1999-2017 Gentoo Foundation
|
|
||||||
# Distributed under the terms of the GNU General Public License v2
|
|
||||||
|
|
||||||
EAPI=6
|
|
||||||
PYTHON_COMPAT=( python{3_4,3_5} )
|
|
||||||
|
|
||||||
inherit distutils-r1
|
|
||||||
|
|
||||||
DESCRIPTION="a personal document manager for scanned documents (and PDFs)"
|
|
||||||
HOMEPAGE="https://github.com/jflesch/paperwork"
|
|
||||||
SRC_URI="https://github.com/jflesch/${PN}/archive/${PV}.tar.gz -> ${P}.tar.gz"
|
|
||||||
|
|
||||||
LICENSE="GPL-3"
|
|
||||||
SLOT="0"
|
|
||||||
KEYWORDS="~amd64 ~x86"
|
|
||||||
IUSE=""
|
|
||||||
|
|
||||||
RDEPEND="~app-text/paperwork-backend-${PV}[${PYTHON_USEDEP}]
|
|
||||||
dev-python/libpillowfight[${PYTHON_USEDEP}]
|
|
||||||
dev-python/pillow[${PYTHON_USEDEP}]
|
|
||||||
dev-python/pycairo[${PYTHON_USEDEP}]
|
|
||||||
dev-python/pyenchant[${PYTHON_USEDEP}]
|
|
||||||
dev-python/pygobject:3[${PYTHON_USEDEP}]
|
|
||||||
dev-python/pyinsane:2[${PYTHON_USEDEP}]
|
|
||||||
>=dev-python/pyocr-0.3.0[${PYTHON_USEDEP}]
|
|
||||||
dev-python/simplebayes[${PYTHON_USEDEP}]
|
|
||||||
dev-util/glade[introspection,python]
|
|
||||||
x11-libs/gtk+:3[introspection]"
|
|
||||||
DEPEND="${RDEPEND}"
|
|
@ -1,219 +0,0 @@
|
|||||||
# Copyright 1999-2017 Gentoo Foundation
|
|
||||||
# Distributed under the terms of the GNU General Public License v2
|
|
||||||
|
|
||||||
EAPI="6"
|
|
||||||
MY_EXTRAS_VER="20160818-1822Z"
|
|
||||||
# The wsrep API version must match between upstream WSREP and sys-cluster/galera major number
|
|
||||||
WSREP_REVISION="25"
|
|
||||||
SUBSLOT="18"
|
|
||||||
MYSQL_PV_MAJOR="5.6"
|
|
||||||
|
|
||||||
inherit toolchain-funcs mysql-multilib-r1
|
|
||||||
|
|
||||||
HOMEPAGE="http://mariadb.org/"
|
|
||||||
DESCRIPTION="An enhanced, drop-in replacement for MySQL"
|
|
||||||
|
|
||||||
IUSE="bindist cracklib galera kerberos innodb-lz4 innodb-lzo innodb-snappy jdbc mroonga odbc oqgraph pam sphinx sst-rsync sst-xtrabackup tokudb systemd xml"
|
|
||||||
RESTRICT="!bindist? ( bindist )"
|
|
||||||
|
|
||||||
REQUIRED_USE="jdbc? ( extraengine server !static ) server? ( tokudb? ( jemalloc !tcmalloc ) ) static? ( !pam )"
|
|
||||||
|
|
||||||
# REMEMBER: also update eclass/mysql*.eclass before committing!
|
|
||||||
KEYWORDS="~alpha ~amd64 ~arm ~arm64 ~hppa ~ia64 ~mips ~ppc ~ppc64 ~s390 ~sh ~sparc ~x86 ~sparc-fbsd ~x86-fbsd ~amd64-linux ~x86-linux ~ppc-macos ~x64-macos ~x86-macos ~x64-solaris ~x86-solaris"
|
|
||||||
|
|
||||||
MY_PATCH_DIR="${WORKDIR}/mysql-extras-${MY_EXTRAS_VER}"
|
|
||||||
|
|
||||||
PATCHES=(
|
|
||||||
"${MY_PATCH_DIR}"/20006_all_cmake_elib-mariadb-10.2.1.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.2.1-without-clientlibs-tools.patch
|
|
||||||
)
|
|
||||||
|
|
||||||
COMMON_DEPEND="
|
|
||||||
mroonga? ( app-text/groonga-normalizer-mysql )
|
|
||||||
kerberos? ( virtual/krb5[${MULTILIB_USEDEP}] )
|
|
||||||
systemd? ( sys-apps/systemd:= )
|
|
||||||
!bindist? (
|
|
||||||
sys-libs/binutils-libs:0=
|
|
||||||
>=sys-libs/readline-4.1:0=
|
|
||||||
)
|
|
||||||
server? (
|
|
||||||
cracklib? ( sys-libs/cracklib:0= )
|
|
||||||
extraengine? (
|
|
||||||
odbc? ( dev-db/unixODBC:0= )
|
|
||||||
xml? ( dev-libs/libxml2:2= )
|
|
||||||
)
|
|
||||||
innodb-lz4? ( app-arch/lz4 )
|
|
||||||
innodb-lzo? ( dev-libs/lzo )
|
|
||||||
innodb-snappy? ( app-arch/snappy )
|
|
||||||
oqgraph? ( >=dev-libs/boost-1.40.0:0= dev-libs/judy:0= )
|
|
||||||
pam? ( virtual/pam:0= )
|
|
||||||
tokudb? ( app-arch/snappy )
|
|
||||||
)
|
|
||||||
>=dev-libs/libpcre-8.35:3=
|
|
||||||
"
|
|
||||||
DEPEND="|| ( >=sys-devel/gcc-3.4.6 >=sys-devel/gcc-apple-4.0 )
|
|
||||||
jdbc? ( virtual/jdk )
|
|
||||||
${COMMON_DEPEND}"
|
|
||||||
RDEPEND="${RDEPEND} ${COMMON_DEPEND}
|
|
||||||
galera? (
|
|
||||||
sys-apps/iproute2
|
|
||||||
=sys-cluster/galera-${WSREP_REVISION}*
|
|
||||||
sst-rsync? ( sys-process/lsof )
|
|
||||||
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 )
|
|
||||||
jdbc? ( virtual/jre )
|
|
||||||
"
|
|
||||||
# xtrabackup-bin causes a circular dependency if DBD-mysql is not already installed
|
|
||||||
PDEPEND="galera? ( sst-xtrabackup? ( >=dev-db/xtrabackup-bin-2.2.4 ) )"
|
|
||||||
|
|
||||||
MULTILIB_WRAPPED_HEADERS+=( /usr/include/mysql/mysql_version.h
|
|
||||||
/usr/include/mysql/private/probes_mysql_nodtrace.h
|
|
||||||
/usr/include/mysql/private/probes_mysql_dtrace.h )
|
|
||||||
|
|
||||||
src_configure(){
|
|
||||||
# bug 508724 mariadb cannot use ld.gold
|
|
||||||
tc-ld-disable-gold
|
|
||||||
|
|
||||||
local MYSQL_CMAKE_NATIVE_DEFINES=(
|
|
||||||
-DWITH_JEMALLOC=$(usex jemalloc system)
|
|
||||||
-DWITH_PCRE=system
|
|
||||||
)
|
|
||||||
local MYSQL_CMAKE_EXTRA_DEFINES=(
|
|
||||||
-DPLUGIN_AUTH_GSSAPI_CLIENT=$(usex kerberos YES NO)
|
|
||||||
)
|
|
||||||
if use server ; then
|
|
||||||
# Federated{,X} must be treated special otherwise they will not be built as plugins
|
|
||||||
if ! use extraengine ; then
|
|
||||||
MYSQL_CMAKE_NATIVE_DEFINES+=(
|
|
||||||
-DPLUGIN_FEDERATED=NO
|
|
||||||
-DPLUGIN_FEDERATEDX=NO )
|
|
||||||
fi
|
|
||||||
|
|
||||||
MYSQL_CMAKE_NATIVE_DEFINES+=(
|
|
||||||
-DPLUGIN_OQGRAPH=$(usex oqgraph YES 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)
|
|
||||||
-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 YES NO)
|
|
||||||
-DPLUGIN_AUTH_GSSAPI=$(usex kerberos YES NO)
|
|
||||||
)
|
|
||||||
fi
|
|
||||||
mysql-multilib-r1_src_configure
|
|
||||||
}
|
|
||||||
|
|
||||||
# Official test instructions:
|
|
||||||
# USE='embedded extraengine perl server openssl static-libs' \
|
|
||||||
# FEATURES='test userpriv -usersandbox' \
|
|
||||||
# ebuild mariadb-X.X.XX.ebuild \
|
|
||||||
# digest clean package
|
|
||||||
multilib_src_test() {
|
|
||||||
|
|
||||||
if ! multilib_is_native_abi ; then
|
|
||||||
einfo "Server tests not available on non-native abi".
|
|
||||||
return 0;
|
|
||||||
fi
|
|
||||||
|
|
||||||
local TESTDIR="${BUILD_DIR}/mysql-test"
|
|
||||||
local retstatus_unit
|
|
||||||
local retstatus_tests
|
|
||||||
|
|
||||||
if use server ; then
|
|
||||||
|
|
||||||
# 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 && eerror "Some tests may fail with FEATURES=usersandbox"
|
|
||||||
|
|
||||||
einfo ">>> Test phase [test]: ${CATEGORY}/${PF}"
|
|
||||||
addpredict /this-dir-does-not-exist/t9.MYI
|
|
||||||
|
|
||||||
# Run CTest (test-units)
|
|
||||||
cmake-utils_src_test
|
|
||||||
retstatus_unit=$?
|
|
||||||
[[ $retstatus_unit -eq 0 ]] || eerror "test-unit failed"
|
|
||||||
|
|
||||||
# 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}
|
|
||||||
|
|
||||||
# These are failing in MariaDB 10.0 for now and are believed to be
|
|
||||||
# false positives:
|
|
||||||
#
|
|
||||||
# main.information_schema, binlog.binlog_statement_insert_delayed,
|
|
||||||
# main.mysqld--help, funcs_1.is_triggers, funcs_1.is_tables_mysql,
|
|
||||||
# funcs_1.is_columns_mysql main.bootstrap
|
|
||||||
# fails due to USE=-latin1 / utf8 default
|
|
||||||
#
|
|
||||||
# main.mysql_client_test, main.mysql_client_test_nonblock
|
|
||||||
# main.mysql_client_test_comp:
|
|
||||||
# segfaults at random under Portage only, suspect resource limits.
|
|
||||||
#
|
|
||||||
# plugins.cracklib_password_check
|
|
||||||
# Can randomly fail due to cracklib return message
|
|
||||||
|
|
||||||
for t in main.mysql_client_test main.mysql_client_test_nonblock \
|
|
||||||
main.mysql_client_test_comp main.bootstrap \
|
|
||||||
binlog.binlog_statement_insert_delayed main.information_schema \
|
|
||||||
main.mysqld--help plugins.cracklib_password_check \
|
|
||||||
funcs_1.is_triggers funcs_1.is_tables_mysql funcs_1.is_columns_mysql ; do
|
|
||||||
mysql-multilib-r1_disable_test "$t" "False positives in Gentoo"
|
|
||||||
done
|
|
||||||
|
|
||||||
# Run mysql tests
|
|
||||||
pushd "${TESTDIR}" || die
|
|
||||||
|
|
||||||
# run mysql-test tests
|
|
||||||
perl mysql-test-run.pl --force --vardir="${T}/var-tests" --reorder
|
|
||||||
|
|
||||||
retstatus_tests=$?
|
|
||||||
[[ $retstatus_tests -eq 0 ]] || eerror "tests failed"
|
|
||||||
has usersandbox $FEATURES && eerror "Some tests may fail with FEATURES=usersandbox"
|
|
||||||
|
|
||||||
popd || die
|
|
||||||
|
|
||||||
# Cleanup is important for these testcases.
|
|
||||||
pkill -9 -f "${S}/ndb" 2>/dev/null
|
|
||||||
pkill -9 -f "${S}/sql" 2>/dev/null
|
|
||||||
|
|
||||||
failures=""
|
|
||||||
[[ $retstatus_unit -eq 0 ]] || failures="${failures} test-unit"
|
|
||||||
[[ $retstatus_tests -eq 0 ]] || failures="${failures} tests"
|
|
||||||
has usersandbox $FEATURES && eerror "Some tests may fail with FEATURES=usersandbox"
|
|
||||||
|
|
||||||
[[ -z "$failures" ]] || die "Test failures: $failures"
|
|
||||||
einfo "Tests successfully completed"
|
|
||||||
|
|
||||||
else
|
|
||||||
einfo "Skipping server tests due to minimal build."
|
|
||||||
fi
|
|
||||||
}
|
|
@ -0,0 +1,302 @@
|
|||||||
|
From 9df9837299ab952d4d30db2427beef667e608f79 Mon Sep 17 00:00:00 2001
|
||||||
|
From: Steven Green <steven@greenius.co.uk>
|
||||||
|
Date: Mon, 17 Jul 2017 13:05:44 +0100
|
||||||
|
Subject: [PATCH] SERVER-30166 Replace string with explicit std::string.
|
||||||
|
Enables compulation when using --use-system-pcre which presusably used to do
|
||||||
|
'using std::string' in an earlier version of pcre
|
||||||
|
|
||||||
|
https://github.com/mongodb/mongo/pull/1166
|
||||||
|
|
||||||
|
---
|
||||||
|
src/mongo/db/dbwebserver.cpp | 1 +
|
||||||
|
src/mongo/db/matcher/expression_leaf.cpp | 4 ++--
|
||||||
|
src/mongo/db/repl/master_slave.cpp | 40 ++++++++++++++++----------------
|
||||||
|
src/mongo/shell/bench.cpp | 14 +++++------
|
||||||
|
src/mongo/util/net/miniwebserver.cpp | 1 +
|
||||||
|
5 files changed, 31 insertions(+), 29 deletions(-)
|
||||||
|
|
||||||
|
diff --git a/src/mongo/db/dbwebserver.cpp b/src/mongo/db/dbwebserver.cpp
|
||||||
|
index b202e0500b9..02556135240 100644
|
||||||
|
--- a/src/mongo/db/dbwebserver.cpp
|
||||||
|
+++ b/src/mongo/db/dbwebserver.cpp
|
||||||
|
@@ -67,6 +67,7 @@ namespace mongo {
|
||||||
|
using std::map;
|
||||||
|
using std::stringstream;
|
||||||
|
using std::vector;
|
||||||
|
+using std::string;
|
||||||
|
|
||||||
|
using namespace html;
|
||||||
|
|
||||||
|
diff --git a/src/mongo/db/matcher/expression_leaf.cpp b/src/mongo/db/matcher/expression_leaf.cpp
|
||||||
|
index d562bff141e..b96a36d543f 100644
|
||||||
|
--- a/src/mongo/db/matcher/expression_leaf.cpp
|
||||||
|
+++ b/src/mongo/db/matcher/expression_leaf.cpp
|
||||||
|
@@ -202,7 +202,7 @@ void ComparisonMatchExpression::debugString(StringBuilder& debug, int level) con
|
||||||
|
}
|
||||||
|
|
||||||
|
void ComparisonMatchExpression::serialize(BSONObjBuilder* out) const {
|
||||||
|
- string opString = "";
|
||||||
|
+ std::string opString = "";
|
||||||
|
switch (matchType()) {
|
||||||
|
case LT:
|
||||||
|
opString = "$lt";
|
||||||
|
@@ -884,7 +884,7 @@ void BitTestMatchExpression::debugString(StringBuilder& debug, int level) const
|
||||||
|
}
|
||||||
|
|
||||||
|
void BitTestMatchExpression::serialize(BSONObjBuilder* out) const {
|
||||||
|
- string opString = "";
|
||||||
|
+ std::string opString = "";
|
||||||
|
|
||||||
|
switch (matchType()) {
|
||||||
|
case BITS_ALL_SET:
|
||||||
|
diff --git a/src/mongo/db/repl/master_slave.cpp b/src/mongo/db/repl/master_slave.cpp
|
||||||
|
index 05faad12599..042350465c6 100644
|
||||||
|
--- a/src/mongo/db/repl/master_slave.cpp
|
||||||
|
+++ b/src/mongo/db/repl/master_slave.cpp
|
||||||
|
@@ -168,7 +168,7 @@ BSONObj ReplSource::jsobj() {
|
||||||
|
|
||||||
|
BSONObjBuilder dbsNextPassBuilder;
|
||||||
|
int n = 0;
|
||||||
|
- for (set<string>::iterator i = addDbNextPass.begin(); i != addDbNextPass.end(); i++) {
|
||||||
|
+ for (set<std::string>::iterator i = addDbNextPass.begin(); i != addDbNextPass.end(); i++) {
|
||||||
|
n++;
|
||||||
|
dbsNextPassBuilder.appendBool(*i, 1);
|
||||||
|
}
|
||||||
|
@@ -177,7 +177,7 @@ BSONObj ReplSource::jsobj() {
|
||||||
|
|
||||||
|
BSONObjBuilder incompleteCloneDbsBuilder;
|
||||||
|
n = 0;
|
||||||
|
- for (set<string>::iterator i = incompleteCloneDbs.begin(); i != incompleteCloneDbs.end(); i++) {
|
||||||
|
+ for (set<std::string>::iterator i = incompleteCloneDbs.begin(); i != incompleteCloneDbs.end(); i++) {
|
||||||
|
n++;
|
||||||
|
incompleteCloneDbsBuilder.appendBool(*i, 1);
|
||||||
|
}
|
||||||
|
@@ -188,7 +188,7 @@ BSONObj ReplSource::jsobj() {
|
||||||
|
}
|
||||||
|
|
||||||
|
void ReplSource::ensureMe(OperationContext* txn) {
|
||||||
|
- string myname = getHostName();
|
||||||
|
+ std::string myname = getHostName();
|
||||||
|
|
||||||
|
// local.me is an identifier for a server for getLastError w:2+
|
||||||
|
bool exists = Helpers::getSingleton(txn, "local.me", _me);
|
||||||
|
@@ -378,10 +378,10 @@ class HandshakeCmd : public Command {
|
||||||
|
}
|
||||||
|
|
||||||
|
virtual bool run(OperationContext* txn,
|
||||||
|
- const string& ns,
|
||||||
|
+ const std::string& ns,
|
||||||
|
BSONObj& cmdObj,
|
||||||
|
int options,
|
||||||
|
- string& errmsg,
|
||||||
|
+ std::string& errmsg,
|
||||||
|
BSONObjBuilder& result) {
|
||||||
|
HandshakeArgs handshake;
|
||||||
|
Status status = handshake.initialize(cmdObj);
|
||||||
|
@@ -398,7 +398,7 @@ class HandshakeCmd : public Command {
|
||||||
|
} handshakeCmd;
|
||||||
|
|
||||||
|
bool replHandshake(DBClientConnection* conn, const OID& myRID) {
|
||||||
|
- string myname = getHostName();
|
||||||
|
+ std::string myname = getHostName();
|
||||||
|
|
||||||
|
BSONObjBuilder cmd;
|
||||||
|
cmd.append("handshake", myRID);
|
||||||
|
@@ -450,7 +450,7 @@ void ReplSource::forceResync(OperationContext* txn, const char* requester) {
|
||||||
|
BSONElement e = i.next();
|
||||||
|
if (e.eoo())
|
||||||
|
break;
|
||||||
|
- string name = e.embeddedObject().getField("name").valuestr();
|
||||||
|
+ std::string name = e.embeddedObject().getField("name").valuestr();
|
||||||
|
if (!e.embeddedObject().getBoolField("empty")) {
|
||||||
|
if (name != "local") {
|
||||||
|
if (only.empty() || only == name) {
|
||||||
|
@@ -481,7 +481,7 @@ Status ReplSource::_updateIfDoneWithInitialSync() {
|
||||||
|
return Status::OK();
|
||||||
|
}
|
||||||
|
|
||||||
|
-void ReplSource::resyncDrop(OperationContext* txn, const string& dbName) {
|
||||||
|
+void ReplSource::resyncDrop(OperationContext* txn, const std::string& dbName) {
|
||||||
|
log() << "resync: dropping database " << dbName;
|
||||||
|
invariant(txn->lockState()->isW());
|
||||||
|
|
||||||
|
@@ -531,13 +531,13 @@ void ReplSource::resync(OperationContext* txn, const std::string& dbName) {
|
||||||
|
|
||||||
|
static DatabaseIgnorer ___databaseIgnorer;
|
||||||
|
|
||||||
|
-void DatabaseIgnorer::doIgnoreUntilAfter(const string& db, const Timestamp& futureOplogTime) {
|
||||||
|
+void DatabaseIgnorer::doIgnoreUntilAfter(const std::string& db, const Timestamp& futureOplogTime) {
|
||||||
|
if (futureOplogTime > _ignores[db]) {
|
||||||
|
_ignores[db] = futureOplogTime;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
-bool DatabaseIgnorer::ignoreAt(const string& db, const Timestamp& currentOplogTime) {
|
||||||
|
+bool DatabaseIgnorer::ignoreAt(const std::string& db, const Timestamp& currentOplogTime) {
|
||||||
|
if (_ignores[db].isNull()) {
|
||||||
|
return false;
|
||||||
|
}
|
||||||
|
@@ -627,7 +627,7 @@ bool ReplSource::handleDuplicateDbName(OperationContext* txn,
|
||||||
|
|
||||||
|
// The database is present on the master and no conflicting databases
|
||||||
|
// are present on the master. Drop any local conflicts.
|
||||||
|
- for (set<string>::const_iterator i = duplicates.begin(); i != duplicates.end(); ++i) {
|
||||||
|
+ for (set<std::string>::const_iterator i = duplicates.begin(); i != duplicates.end(); ++i) {
|
||||||
|
___databaseIgnorer.doIgnoreUntilAfter(*i, lastTime);
|
||||||
|
incompleteCloneDbs.erase(*i);
|
||||||
|
addDbNextPass.erase(*i);
|
||||||
|
@@ -826,10 +826,10 @@ void ReplSource::_sync_pullOpLog_applyOperation(OperationContext* txn,
|
||||||
|
}
|
||||||
|
|
||||||
|
void ReplSource::syncToTailOfRemoteLog() {
|
||||||
|
- string _ns = ns();
|
||||||
|
+ std::string _ns = ns();
|
||||||
|
BSONObjBuilder b;
|
||||||
|
if (!only.empty()) {
|
||||||
|
- b.appendRegex("ns", string("^") + pcrecpp::RE::QuoteMeta(only));
|
||||||
|
+ b.appendRegex("ns", std::string("^") + pcrecpp::RE::QuoteMeta(only));
|
||||||
|
}
|
||||||
|
BSONObj last = oplogReader.findOne(_ns.c_str(), Query(b.done()).sort(BSON("$natural" << -1)));
|
||||||
|
if (!last.isEmpty()) {
|
||||||
|
@@ -877,7 +877,7 @@ class ReplApplyBatchSize
|
||||||
|
*/
|
||||||
|
int ReplSource::_sync_pullOpLog(OperationContext* txn, int& nApplied) {
|
||||||
|
int okResultCode = restartSyncAfterSleep;
|
||||||
|
- string ns = string("local.oplog.$") + sourceName();
|
||||||
|
+ std::string ns = std::string("local.oplog.$") + sourceName();
|
||||||
|
LOG(2) << "sync_pullOpLog " << ns << " syncedTo:" << syncedTo.toStringLong() << '\n';
|
||||||
|
|
||||||
|
bool tailing = true;
|
||||||
|
@@ -897,7 +897,7 @@ int ReplSource::_sync_pullOpLog(OperationContext* txn, int& nApplied) {
|
||||||
|
BSONElement e = i.next();
|
||||||
|
if (e.eoo())
|
||||||
|
break;
|
||||||
|
- string name = e.embeddedObject().getField("name").valuestr();
|
||||||
|
+ std::string name = e.embeddedObject().getField("name").valuestr();
|
||||||
|
if (!e.embeddedObject().getBoolField("empty")) {
|
||||||
|
if (name != "local") {
|
||||||
|
if (only.empty() || only == name) {
|
||||||
|
@@ -921,7 +921,7 @@ int ReplSource::_sync_pullOpLog(OperationContext* txn, int& nApplied) {
|
||||||
|
if (!only.empty()) {
|
||||||
|
// note we may here skip a LOT of data table scanning, a lot of work for the master.
|
||||||
|
// maybe append "\\." here?
|
||||||
|
- query.appendRegex("ns", string("^") + pcrecpp::RE::QuoteMeta(only));
|
||||||
|
+ query.appendRegex("ns", std::string("^") + pcrecpp::RE::QuoteMeta(only));
|
||||||
|
}
|
||||||
|
BSONObj queryObj = query.done();
|
||||||
|
// e.g. queryObj = { ts: { $gte: syncedTo } }
|
||||||
|
@@ -940,7 +940,7 @@ int ReplSource::_sync_pullOpLog(OperationContext* txn, int& nApplied) {
|
||||||
|
|
||||||
|
// show any deferred database creates from a previous pass
|
||||||
|
{
|
||||||
|
- set<string>::iterator i = addDbNextPass.begin();
|
||||||
|
+ set<std::string>::iterator i = addDbNextPass.begin();
|
||||||
|
if (i != addDbNextPass.end()) {
|
||||||
|
BSONObjBuilder b;
|
||||||
|
b.append("ns", *i + '.');
|
||||||
|
@@ -984,7 +984,7 @@ int ReplSource::_sync_pullOpLog(OperationContext* txn, int& nApplied) {
|
||||||
|
BSONObj op = oplogReader.nextSafe();
|
||||||
|
BSONElement ts = op.getField("ts");
|
||||||
|
if (ts.type() != Date && ts.type() != bsonTimestamp) {
|
||||||
|
- string err = op.getStringField("$err");
|
||||||
|
+ std::string err = op.getStringField("$err");
|
||||||
|
if (!err.empty()) {
|
||||||
|
// 13051 is "tailable cursor requested on non capped collection"
|
||||||
|
if (op.getIntField("code") == 13051) {
|
||||||
|
@@ -1152,7 +1152,7 @@ int ReplSource::sync(OperationContext* txn, int& nApplied) {
|
||||||
|
|
||||||
|
// FIXME Handle cases where this db isn't on default port, or default port is spec'd in
|
||||||
|
// hostName.
|
||||||
|
- if ((string("localhost") == hostName || string("127.0.0.1") == hostName) &&
|
||||||
|
+ if ((std::string("localhost") == hostName || std::string("127.0.0.1") == hostName) &&
|
||||||
|
serverGlobalParams.port == ServerGlobalParams::DefaultDBPort) {
|
||||||
|
log() << "can't sync from self (localhost). sources configuration may be wrong." << endl;
|
||||||
|
sleepsecs(5);
|
||||||
|
@@ -1297,7 +1297,7 @@ static void replMain(OperationContext* txn) {
|
||||||
|
if (s) {
|
||||||
|
stringstream ss;
|
||||||
|
ss << "sleep " << s << " sec before next pass";
|
||||||
|
- string msg = ss.str();
|
||||||
|
+ std::string msg = ss.str();
|
||||||
|
if (!serverGlobalParams.quiet)
|
||||||
|
log() << msg << endl;
|
||||||
|
ReplInfo r(msg.c_str());
|
||||||
|
diff --git a/src/mongo/shell/bench.cpp b/src/mongo/shell/bench.cpp
|
||||||
|
index 040002f5c6e..338477ebe56 100644
|
||||||
|
--- a/src/mongo/shell/bench.cpp
|
||||||
|
+++ b/src/mongo/shell/bench.cpp
|
||||||
|
@@ -674,7 +674,7 @@ void BenchRunWorker::generateLoadOnConnection(DBClientBase* conn) {
|
||||||
|
invariant(bsonTemplateEvaluator.setId(_id) == BsonTemplateEvaluator::StatusSuccess);
|
||||||
|
|
||||||
|
if (_config->username != "") {
|
||||||
|
- string errmsg;
|
||||||
|
+ std::string errmsg;
|
||||||
|
if (!conn->auth("admin", _config->username, _config->password, errmsg)) {
|
||||||
|
uasserted(15931, "Authenticating to connection for _benchThread failed: " + errmsg);
|
||||||
|
}
|
||||||
|
@@ -918,7 +918,7 @@ void BenchRunWorker::generateLoadOnConnection(DBClientBase* conn) {
|
||||||
|
|
||||||
|
if (!result["err"].eoo() && result["err"].type() == String &&
|
||||||
|
(_config->throwGLE || op.throwGLE))
|
||||||
|
- throw DBException((string) "From benchRun GLE" +
|
||||||
|
+ throw DBException((std::string) "From benchRun GLE" +
|
||||||
|
causedBy(result["err"].String()),
|
||||||
|
result["code"].eoo() ? 0 : result["code"].Int());
|
||||||
|
}
|
||||||
|
@@ -984,7 +984,7 @@ void BenchRunWorker::generateLoadOnConnection(DBClientBase* conn) {
|
||||||
|
|
||||||
|
if (!result["err"].eoo() && result["err"].type() == String &&
|
||||||
|
(_config->throwGLE || op.throwGLE))
|
||||||
|
- throw DBException((string) "From benchRun GLE" +
|
||||||
|
+ throw DBException((std::string) "From benchRun GLE" +
|
||||||
|
causedBy(result["err"].String()),
|
||||||
|
result["code"].eoo() ? 0 : result["code"].Int());
|
||||||
|
}
|
||||||
|
@@ -1031,7 +1031,7 @@ void BenchRunWorker::generateLoadOnConnection(DBClientBase* conn) {
|
||||||
|
|
||||||
|
if (!result["err"].eoo() && result["err"].type() == String &&
|
||||||
|
(_config->throwGLE || op.throwGLE))
|
||||||
|
- throw DBException((string) "From benchRun GLE " +
|
||||||
|
+ throw DBException((std::string) "From benchRun GLE " +
|
||||||
|
causedBy(result["err"].String()),
|
||||||
|
result["code"].eoo() ? 0 : result["code"].Int());
|
||||||
|
}
|
||||||
|
@@ -1133,7 +1133,7 @@ void BenchRunWorker::run() {
|
||||||
|
try {
|
||||||
|
std::unique_ptr<DBClientBase> conn(_config->createConnection());
|
||||||
|
if (!_config->username.empty()) {
|
||||||
|
- string errmsg;
|
||||||
|
+ std::string errmsg;
|
||||||
|
if (!conn->auth("admin", _config->username, _config->password, errmsg)) {
|
||||||
|
uasserted(15932, "Authenticating to connection for benchThread failed: " + errmsg);
|
||||||
|
}
|
||||||
|
@@ -1165,7 +1165,7 @@ void BenchRunner::start() {
|
||||||
|
std::unique_ptr<DBClientBase> conn(_config->createConnection());
|
||||||
|
// Must authenticate to admin db in order to run serverStatus command
|
||||||
|
if (_config->username != "") {
|
||||||
|
- string errmsg;
|
||||||
|
+ std::string errmsg;
|
||||||
|
if (!conn->auth("admin", _config->username, _config->password, errmsg)) {
|
||||||
|
uasserted(
|
||||||
|
16704,
|
||||||
|
@@ -1201,7 +1201,7 @@ void BenchRunner::stop() {
|
||||||
|
{
|
||||||
|
std::unique_ptr<DBClientBase> conn(_config->createConnection());
|
||||||
|
if (_config->username != "") {
|
||||||
|
- string errmsg;
|
||||||
|
+ std::string errmsg;
|
||||||
|
// this can only fail if admin access was revoked since start of run
|
||||||
|
if (!conn->auth("admin", _config->username, _config->password, errmsg)) {
|
||||||
|
uasserted(
|
||||||
|
diff --git a/src/mongo/util/net/miniwebserver.cpp b/src/mongo/util/net/miniwebserver.cpp
|
||||||
|
index 5f4165d42f4..7a7d0714934 100644
|
||||||
|
--- a/src/mongo/util/net/miniwebserver.cpp
|
||||||
|
+++ b/src/mongo/util/net/miniwebserver.cpp
|
||||||
|
@@ -47,6 +47,7 @@ namespace mongo {
|
||||||
|
using std::shared_ptr;
|
||||||
|
using std::stringstream;
|
||||||
|
using std::vector;
|
||||||
|
+using std::string;
|
||||||
|
|
||||||
|
MiniWebServer::MiniWebServer(const string& name, const string& ip, int port, ServiceContext* ctx)
|
||||||
|
: Listener(name, ip, port, ctx, false, false) {}
|
Some files were not shown because too many files have changed in this diff Show More
Loading…
Reference in new issue