diff options
Diffstat (limited to 'php-doctrine-orm-bin.patch')
-rw-r--r-- | php-doctrine-orm-bin.patch | 60 |
1 files changed, 28 insertions, 32 deletions
diff --git a/php-doctrine-orm-bin.patch b/php-doctrine-orm-bin.patch index 37e0e16..94fae70 100644 --- a/php-doctrine-orm-bin.patch +++ b/php-doctrine-orm-bin.patch @@ -1,15 +1,14 @@ -diff --git a/bin/doctrine.php b/bin/doctrine.php -index 842c5493f..e1ccb7506 100755 ---- a/bin/doctrine.php -+++ b/bin/doctrine.php +diff -up ./bin/doctrine.php.rpm1 ./bin/doctrine.php +--- ./bin/doctrine.php.rpm1 2022-09-23 11:23:08.000000000 +0200 ++++ ./bin/doctrine.php 2022-09-23 11:30:54.541647836 +0200 @@ -1,3 +1,4 @@ +#!/usr/bin/env php <?php - /* - * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS -@@ -20,17 +21,7 @@ + use Symfony\Component\Console\Helper\HelperSet; - use Doctrine\ORM\Tools\Console\ConsoleRunner; +@@ -13,17 +14,7 @@ fwrite( + + echo PHP_EOL . PHP_EOL; -$autoloadFiles = [ - __DIR__ . '/../vendor/autoload.php', @@ -26,32 +25,29 @@ index 842c5493f..e1ccb7506 100755 $directories = [getcwd(), getcwd() . DIRECTORY_SEPARATOR . 'config']; -diff -up a/tests/Doctrine/Tests/ORM/Tools/SetupTest.php.rpm b/tests/Doctrine/Tests/ORM/Tools/SetupTest.php ---- a/tests/Doctrine/Tests/ORM/Tools/SetupTest.php.rpm 2019-09-30 08:35:50.547638239 +0200 -+++ b/tests/Doctrine/Tests/ORM/Tools/SetupTest.php 2019-09-30 08:37:02.769360851 +0200 -@@ -43,7 +43,7 @@ class SetupTest extends OrmTestCase - - public function testDirectoryAutoload() - { -- Setup::registerAutoloadDirectory(__DIR__ . "/../../../../../vendor/doctrine/common/lib"); -+ Setup::registerAutoloadDirectory("/usr/share/php"); - - $this->assertEquals($this->originalAutoloaderCount + 2, count(spl_autoload_functions())); - } - -diff -up ./lib/Doctrine/ORM/Tools/Setup.php.rpm ./lib/Doctrine/ORM/Tools/Setup.php ---- ./lib/Doctrine/ORM/Tools/Setup.php.rpm 2020-05-27 11:28:24.144920624 +0200 -+++ ./lib/Doctrine/ORM/Tools/Setup.php 2020-05-27 11:29:14.330733814 +0200 -@@ -45,7 +45,11 @@ class Setup +diff -up ./lib/Doctrine/ORM/Tools/Setup.php.rpm1 ./lib/Doctrine/ORM/Tools/Setup.php +--- ./lib/Doctrine/ORM/Tools/Setup.php.rpm1 2022-09-23 11:30:54.542647834 +0200 ++++ ./lib/Doctrine/ORM/Tools/Setup.php 2022-09-23 11:32:10.791505590 +0200 +@@ -54,7 +54,9 @@ class Setup public static function registerAutoloadDirectory($directory) { - if (!class_exists('Doctrine\Common\ClassLoader', false)) { -- require_once $directory . "/Doctrine/Common/ClassLoader.php"; + if (! class_exists('Doctrine\Common\ClassLoader', false)) { +- if (file_exists($directory . '/Doctrine/Common/ClassLoader.php')) { + if (file_exists($directory . "/Doctrine/Common3/ClassLoader.php")) { + require_once $directory . "/Doctrine/Common3/ClassLoader.php"; -+ } else { -+ require_once $directory . "/Doctrine/Common/ClassLoader.php"; -+ } - } ++ } elseif (file_exists($directory . '/Doctrine/Common/ClassLoader.php')) { + require_once $directory . '/Doctrine/Common/ClassLoader.php'; + } elseif (file_exists(dirname($directory) . '/src/ClassLoader.php')) { + require_once dirname($directory) . '/src/ClassLoader.php'; +diff -up ./tests/Doctrine/Tests/ORM/Tools/SetupTest.php.rpm1 ./tests/Doctrine/Tests/ORM/Tools/SetupTest.php +--- ./tests/Doctrine/Tests/ORM/Tools/SetupTest.php.rpm1 2022-09-23 11:23:08.000000000 +0200 ++++ ./tests/Doctrine/Tests/ORM/Tools/SetupTest.php 2022-09-23 11:30:54.542647834 +0200 +@@ -54,7 +54,7 @@ class SetupTest extends TestCase - $loader = new ClassLoader("Doctrine", $directory); + public function testDirectoryAutoload(): void + { +- Setup::registerAutoloadDirectory(__DIR__ . '/../../../../../vendor/doctrine/common/lib'); ++ Setup::registerAutoloadDirectory("/usr/share/php"); + + self::assertCount($this->originalAutoloaderCount + 2, spl_autoload_functions()); + } |