summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorThomas Deutschmann <whissi@gentoo.org>2020-11-30 01:21:15 +0100
committerThomas Deutschmann <whissi@gentoo.org>2020-11-30 01:39:16 +0100
commitb4fa73e93d4a0b479553332fcb2874feba727593 (patch)
tree8bb9aa9c6e2e69a4962bfc9428b4e8b29f50f11a /dev-php/PHP_CodeCoverage
parentdev-php/theseer-tokenizer: bump to v1.2.0 (diff)
downloadgentoo-b4fa73e93d4a0b479553332fcb2874feba727593.tar.gz
gentoo-b4fa73e93d4a0b479553332fcb2874feba727593.tar.bz2
gentoo-b4fa73e93d4a0b479553332fcb2874feba727593.zip
dev-php/PHP_CodeCoverage: bump to v7.0.12
Package-Manager: Portage-3.0.10, Repoman-3.0.2 Signed-off-by: Thomas Deutschmann <whissi@gentoo.org>
Diffstat (limited to 'dev-php/PHP_CodeCoverage')
-rw-r--r--dev-php/PHP_CodeCoverage/Manifest1
-rw-r--r--dev-php/PHP_CodeCoverage/PHP_CodeCoverage-7.0.12.ebuild106
2 files changed, 107 insertions, 0 deletions
diff --git a/dev-php/PHP_CodeCoverage/Manifest b/dev-php/PHP_CodeCoverage/Manifest
index 10e664b7c52d..01d5396e75e9 100644
--- a/dev-php/PHP_CodeCoverage/Manifest
+++ b/dev-php/PHP_CodeCoverage/Manifest
@@ -1,2 +1,3 @@
DIST PHP_CodeCoverage-4.0.7.tar.gz 349906 BLAKE2B 2ba665efa2d20a5eb66c66375a095425057e883697dd1d3ba7214e56de29c96451516adb2843589e64732c994aac7289afa0e34a74d56ef9bc36f36e635eb944 SHA512 8418efa2585d05b3004ab50e7ba77513429d649f71fdb2479412424a0f40a698a962e1d87852db08fec8f92e569a9a5767dad66d5d64e072637dde33182e71e9
DIST PHP_CodeCoverage-7.0.10.tar.gz 237217 BLAKE2B bd2dc397c15a85ca020abf3d9a1dfb5f438020b577cded7942110dd8affa2d703ed40bf01ae68f38c6ae9383ba59bc9f7706af99596bce0b40cef6d2a7e92fb2 SHA512 37cda2d3687f62b5546372507954eeedd4da1c03fa9cab147b578d035046763799ca1535310ba458403094714060fe8f1327bed6951440392fee3df551be73b1
+DIST PHP_CodeCoverage-7.0.12.tar.gz 237382 BLAKE2B 3051e7e473506a66d7b4720083274f3b3a64b9f480bb1a95682608220d19be60810a899d974ea3189270c0751f8af058f2503ed83c61d92180cbb41708b07536 SHA512 b105672dc50952c3c606010389fd6fb8ebfcbb78d99d72f9a21a1eef045314b0803fdb689bba1314671d0eeab0e5ed00bf416b09ca45d291688f4c59748c2ed1
diff --git a/dev-php/PHP_CodeCoverage/PHP_CodeCoverage-7.0.12.ebuild b/dev-php/PHP_CodeCoverage/PHP_CodeCoverage-7.0.12.ebuild
new file mode 100644
index 000000000000..e820503362c9
--- /dev/null
+++ b/dev-php/PHP_CodeCoverage/PHP_CodeCoverage-7.0.12.ebuild
@@ -0,0 +1,106 @@
+# Copyright 1999-2020 Gentoo Authors
+# Distributed under the terms of the GNU General Public License v2
+
+EAPI=7
+
+MY_PN="php-code-coverage"
+
+USE_PHP="php7-2 php7-3 php7-4"
+
+DESCRIPTION="Collection, processing, and rendering for PHP code coverage"
+HOMEPAGE="https://phpunit.de"
+SRC_URI="https://github.com/sebastianbergmann/${MY_PN}/archive/${PV}.tar.gz -> ${P}.tar.gz"
+
+LICENSE="BSD"
+SLOT="0"
+KEYWORDS="~alpha ~amd64 ~arm ~hppa ~ia64 ~ppc ~ppc64 ~s390 ~sparc ~x86"
+IUSE="test"
+RESTRICT="!test? ( test )"
+
+CDEPEND="dev-php/fedora-autoloader
+ >=dev-php/File_Iterator-2.0.2
+ >=dev-php/Text_Template-1.2.1
+ >=dev-php/PHP_TokenStream-3.1.1
+ >=dev-php/sebastian-environment-4.2.2
+ >=dev-php/sebastian-version-2.0.1
+ >=dev-php/sebastian-code-unit-reverse-lookup-1.0.1
+ >=dev-php/theseer-tokenizer-1.1.3
+ >=dev-lang/php-7.2:*[xml(-),xmlwriter(-)]"
+
+BDEPEND="dev-php/theseer-Autoload
+ test? (
+ ${CDEPEND}
+ dev-php/phpunit
+ )"
+
+RDEPEND="${CDEPEND}"
+
+S="${WORKDIR}/${MY_PN}-${PV}"
+
+src_prepare() {
+ default
+
+ phpab \
+ --output src/autoload.php \
+ --template fedora2 \
+ --basedir src \
+ src || die
+
+ cat >> src/autoload.php <<EOF || die "failed to extend autoload.php"
+
+// Dependencies
+\Fedora\Autoloader\Dependencies::required([
+ '/usr/share/php/File/Iterator/autoload.php',
+ '/usr/share/php/PHP/Token/autoload.php',
+ '/usr/share/php/SebastianBergmann/Version/autoload.php',
+ '/usr/share/php/SebastianBergmann/Environment/autoload.php',
+ '/usr/share/php/SebastianBergmann/CodeUnitReverseLookup/autoload.php',
+ '/usr/share/php/Text/Template/autoload.php',
+ '/usr/share/php/TheSeer/Tokenizer/autoload.php',
+]);
+EOF
+}
+
+src_install() {
+ insinto /usr/share/php/PHP/CodeCoverage
+ doins -r src/*
+}
+
+src_test() {
+ mkdir vendor || die
+
+ phpab \
+ --output vendor/autoload.php \
+ --template fedora2 \
+ --exclude 'tests/_files/Crash.php' \
+ --exclude 'tests/_files/source*.php' \
+ src \
+ tests \
+ || die
+
+ cat >> vendor/autoload.php <<EOF || die "failed to extend autoload.php"
+
+// Dependencies
+\Fedora\Autoloader\Dependencies::required([
+ '/usr/share/php/File/Iterator/autoload.php',
+ '/usr/share/php/PHP/Token/autoload.php',
+ '/usr/share/php/SebastianBergmann/Version/autoload.php',
+ '/usr/share/php/SebastianBergmann/Environment/autoload.php',
+ '/usr/share/php/SebastianBergmann/CodeUnitReverseLookup/autoload.php',
+ '/usr/share/php/Text/Template/autoload.php',
+ '/usr/share/php/TheSeer/Tokenizer/autoload.php',
+]);
+EOF
+
+ local target
+ for target in ${USE_PHP//-/.} ; do
+ if [[ -x /usr/bin/${target} ]] ; then
+ ${target} /usr/bin/phpunit -c phpunit.xml --no-coverage --verbose || die "tests using ${target} failed"
+ fi
+ done
+}
+
+pkg_postinst() {
+ ewarn "This library now loads via /usr/share/php/PHP/CodeCoverage/autoload.php"
+ ewarn "Please update any scripts to require the autoloader"
+}