DESCRIPTION="Dependency Manager for PHP"
HOMEPAGE="https://github.com/composer/composer"
-SRC_URI="https://github.com/${PN}/${PN}/archive/${PV}.tar.gz -> ${P}.tar.gz"
+SRC_URI="${HOMEPAGE}/archive/${PV}.tar.gz -> ${P}.tar.gz"
LICENSE="MIT"
SLOT="0"
>=dev-php/symfony-finder-2.7.20
>=dev-php/symfony-process-2.8.12"
-PATCHES=(
- "${FILESDIR}/${PN}-update-paths.patch"
-)
-
src_install() {
- insinto "/usr/share/php/Composer/Composer"
+ insinto "/usr/share/${PN}"
# Composer expects the LICENSE file to be there, and the
# easiest thing to do is to give it what it wants.
- doins -r src/Composer/. res LICENSE "${FILESDIR}"/autoload.php
- dobin bin/composer
- dodoc README.md
+ doins -r src res LICENSE
+
+ insinto "/usr/share/${PN}/vendor"
+ doins "${FILESDIR}"/autoload.php
+
+ exeinto "/usr/share/${PN}/bin"
+ doexe "bin/${PN}"
+ dosym "/usr/share/${PN}/bin/${PN}" "/usr/bin/${PN}"
+
+ dodoc CHANGELOG.md README.md doc/*.md
+ dodoc -r doc/articles doc/faqs
}
+++ /dev/null
---- ./src/Composer/Autoload/AutoloadGenerator.php 2016-11-03 17:43:15.000000000 +0100
-+++ ./src/Composer/Autoload/AutoloadGenerator.php 2016-11-18 16:54:55.664985847 +0100
-@@ -291,7 +291,7 @@
- file_put_contents($targetDir.'/autoload_real.php', $this->getAutoloadRealFile(true, (bool) $includePathFileContents, $targetDirLoader, (bool) $includeFilesFileContents, $vendorPathCode, $appBaseDirCode, $suffix, $useGlobalIncludePath, $prependAutoloader, $staticPhpVersion));
-
- $this->safeCopy(__DIR__.'/ClassLoader.php', $targetDir.'/ClassLoader.php');
-- $this->safeCopy(__DIR__.'/../../../LICENSE', $targetDir.'/LICENSE');
-+ $this->safeCopy('/usr/share/php/Composer/Composer/LICENSE', $targetDir.'/LICENSE');
-
- if ($this->runScripts) {
- $this->eventDispatcher->dispatchScript(ScriptEvents::POST_AUTOLOAD_DUMP, $this->devMode, array(), array(
-
---- ./tests/Composer/Test/Json/ComposerSchemaTest.php 2016-11-03 17:43:15.000000000 +0100
-+++ ./tests/Composer/Test/Json/ComposerSchemaTest.php 2016-11-20 18:27:43.169665101 +0100
-@@ -87,7 +87,7 @@
-
- private function check($json)
- {
-- $schema = json_decode(file_get_contents(__DIR__ . '/../../../../res/composer-schema.json'));
-+ $schema = json_decode(file_get_contents('/usr/share/php/Composer/Composer/res/composer-schema.json'));
- $validator = new Validator();
- $validator->check(json_decode($json), $schema);
-
---- ./src/Composer/Json/JsonFile.php 2016-11-04 02:51:03.844719014 +0100
-+++ ./src/Composer/Json/JsonFile.php 2016-11-18 16:44:06.065969630 +0100
-@@ -156,7 +156,7 @@
- self::validateSyntax($content, $this->path);
- }
-
-- $schemaFile = __DIR__ . '/../../../res/composer-schema.json';
-+ $schemaFile = '/usr/share/php/Composer/Composer/res/composer-schema.json';
- $schemaData = json_decode(file_get_contents($schemaFile));
-
- if ($schema === self::LAX_SCHEMA) {
-
---- ./bin/composer 2016-11-18 15:56:40.615898592 +0100
-+++ ./bin/composer 2016-11-18 16:06:05.348912690 +0100
-@@ -5,7 +5,7 @@
- echo 'Warning: Composer should be invoked via the CLI version of PHP, not the '.PHP_SAPI.' SAPI'.PHP_EOL;
- }
-
--require __DIR__.'/../src/bootstrap.php';
-+require '/usr/share/php/Composer/Composer/autoload.php';
-
- use Composer\Console\Application;
-