dev-php/symfony-dependency-injection: Add 2.1.0 version
authorGuillaume Seren <guillaumeseren@gmail.com>
Thu, 24 Nov 2016 07:57:09 +0000 (08:57 +0100)
committerMichael Orlitzky <mjo@gentoo.org>
Sun, 18 Dec 2016 23:17:04 +0000 (18:17 -0500)
This is needed for composer-1.2.2, bug 439206.

Signed-off-by: Michael Orlitzky <mjo@gentoo.org>
dev-php/symfony-dependency-injection/Manifest [new file with mode: 0644]
dev-php/symfony-dependency-injection/files/autoload.php [new file with mode: 0644]
dev-php/symfony-dependency-injection/metadata.xml [new file with mode: 0644]
dev-php/symfony-dependency-injection/symfony-dependency-injection-2.1.0.ebuild [new file with mode: 0644]

diff --git a/dev-php/symfony-dependency-injection/Manifest b/dev-php/symfony-dependency-injection/Manifest
new file mode 100644 (file)
index 0000000..b3dd8dc
--- /dev/null
@@ -0,0 +1 @@
+DIST symfony-dependency-injection-2.1.0.tar.gz 73560 SHA256 30a693b561743655daa1b58314af0102d2ae8294c73da90e4759b847659f0d4e SHA512 2e21da1eb1dfff9ba9f8cf4c0d62ff2c021e40f611bba0ba98ff0c29dff35774eb252cf04c53437b1a40065209579c48116833fa4f72a674348fd4df8a01ffa7 WHIRLPOOL 260f6ff1a432133d34bd2c6239239ffcc677e7050910447fb02d1ac4126e75fb6104b32ece5b7613142a5199a20c2b8a5fc13c6d789ea2735e261872a8b07cf4
diff --git a/dev-php/symfony-dependency-injection/files/autoload.php b/dev-php/symfony-dependency-injection/files/autoload.php
new file mode 100644 (file)
index 0000000..4df35ec
--- /dev/null
@@ -0,0 +1,15 @@
+<?php
+/* Autoloader for dev-php/symfony-dependency-injection and its dependencies */
+
+$vendorDir = '/usr/share/php';
+if (!class_exists('Fedora\\Autoloader\\Autoload', false)) {
+    require_once '/usr/share/php/Fedora/Autoloader/autoload.php';
+}
+
+\Fedora\Autoloader\Autoload::addPsr4('Symfony\\Component\\DependencyInjection\\', __DIR__);
+
+// Dependencies
+\Fedora\Autoloader\Dependencies::required(array(
+       $vendorDir . '/Symfony/Component/Yaml/autoload.php',
+       $vendorDir . '/Symfony/Component/Config/autoload.php',
+));
diff --git a/dev-php/symfony-dependency-injection/metadata.xml b/dev-php/symfony-dependency-injection/metadata.xml
new file mode 100644 (file)
index 0000000..ed56f05
--- /dev/null
@@ -0,0 +1,16 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<!DOCTYPE pkgmetadata SYSTEM "http://www.gentoo.org/dtd/metadata.dtd">
+<pkgmetadata>
+  <maintainer type="person">
+    <email>guillaumeseren@gmail.com</email>
+    <name>Guillaume Seren</name>
+  </maintainer>
+  <maintainer type="project">
+    <email>proxy-maint@gentoo.org</email>
+    <name>Proxy Maintainers</name>
+  </maintainer>
+  <longdescription>
+       The DependencyInjection component allows you to standardize
+       and centralize the way objects are constructed in your application.
+  </longdescription>
+</pkgmetadata>
diff --git a/dev-php/symfony-dependency-injection/symfony-dependency-injection-2.1.0.ebuild b/dev-php/symfony-dependency-injection/symfony-dependency-injection-2.1.0.ebuild
new file mode 100644 (file)
index 0000000..15b4b0b
--- /dev/null
@@ -0,0 +1,44 @@
+# Copyright 1999-2016 Gentoo Foundation
+# Distributed under the terms of the GNU General Public License v2
+# $Id$
+
+EAPI=6
+
+DESCRIPTION="Symfony DependencyInjection Component"
+HOMEPAGE="https://github.com/symfony/dependency-injection"
+SRC_URI="https://github.com/symfony/dependency-injection/archive/v${PV}.tar.gz -> ${P}.tar.gz"
+
+LICENSE="MIT"
+SLOT="0"
+KEYWORDS="~amd64 ~x86"
+IUSE="test"
+RESTRICT="test"
+
+RDEPEND="
+       dev-lang/php:*
+       dev-php/fedora-autoloader
+       ~dev-php/symfony-config-2.1.0
+       ~dev-php/symfony-yaml-2.1.0"
+DEPEND="
+       test? (
+               ${RDEPEND}
+               dev-php/phpunit )"
+
+S="${WORKDIR}/dependency-injection-${PV}"
+
+src_prepare() {
+       default
+       if use test; then
+               cp "${FILESDIR}"/autoload.php "${S}"/autoload-test.php || die
+       fi
+}
+
+src_install() {
+       insinto "/usr/share/php/Symfony/Component/DependencyInjection"
+       doins -r . "${FILESDIR}"/autoload.php
+       dodoc README.md
+}
+
+src_test() {
+       phpunit --bootstrap "${S}"/autoload-test.php || die "test suite failed"
+}