mirror of
https://github.com/gentoo-mirror/gentoo.git
synced 2026-07-30 22:48:07 -07:00
The twig extension is no longer necessary as PHP 5.6 is end-of-life Also, use the dev-php/fedora-autoloader to replace Twig's autoloader so that it simulates composer loading with Psr4 and does not throw errors in the logs In addition, the ctype USE on dev-lang/php is now required Package-Manager: Portage-2.3.66, Repoman-2.3.12 Signed-off-by: Brian Evans <grknight@gentoo.org>
19 lines
503 B
PHP
19 lines
503 B
PHP
<?php
|
|
/* Autoloader for dev-php/twig */
|
|
|
|
if (!class_exists('Twig_Autoloader', false)) {
|
|
// polyfill for old code
|
|
class Twig_Autoloader {
|
|
public static function register(){}
|
|
public static function autoload(){}
|
|
}
|
|
}
|
|
|
|
if (!class_exists('Fedora\\Autoloader\\Autoload', false)) {
|
|
require_once '/usr/share/php/Fedora/Autoloader/autoload.php';
|
|
}
|
|
|
|
\Fedora\Autoloader\Autoload::addPsr0('Twig_', __DIR__.'/lib');
|
|
\Fedora\Autoloader\Autoload::addPsr4('Twig\\', __DIR__.'/src');
|
|
|