From 85b3d023ee4d2dced35392e3b13b9624989a3e0b Mon Sep 17 00:00:00 2001 From: Remi Collet Date: Wed, 13 Dec 2017 11:15:42 +0100 Subject: switch from zend-loader to fedora/autoloader --- php-zendframework-zend-mvc-plugin-identity.spec | 66 ++++++++++++------------- 1 file changed, 33 insertions(+), 33 deletions(-) diff --git a/php-zendframework-zend-mvc-plugin-identity.spec b/php-zendframework-zend-mvc-plugin-identity.spec index 4f2020a..2f87a38 100644 --- a/php-zendframework-zend-mvc-plugin-identity.spec +++ b/php-zendframework-zend-mvc-plugin-identity.spec @@ -21,7 +21,7 @@ Name: php-%{gh_owner}-%{gh_project} Version: 1.0.0 -Release: 1%{?dist} +Release: 4%{?dist} Summary: Zend Framework Mvc-Plugin-%{library} component Group: Development/Libraries @@ -35,21 +35,17 @@ BuildArch: noarch %if %{with_tests} BuildRequires: php(language) >= 5.6 BuildRequires: php-composer(container-interop/container-interop) >= 1.1 -BuildRequires: php-composer(%{gh_owner}/zend-mvc) >= 3.0 -BuildRequires: php-composer(%{gh_owner}/zend-authentication) >= 2.5.3 -BuildRequires: php-composer(%{gh_owner}/zend-servicemanager) >= 2.7.5 +BuildRequires: php-autoloader(%{gh_owner}/zend-mvc) >= 3.0 +BuildRequires: php-autoloader(%{gh_owner}/zend-authentication) >= 2.5.3 +BuildRequires: php-autoloader(%{gh_owner}/zend-servicemanager) >= 2.7.5 BuildRequires: php-spl # From composer, "require-dev": { # "phpunit/PHPUnit": "^4.5", # "squizlabs/php_codesniffer": "^2.3.1" BuildRequires: php-composer(phpunit/phpunit) >= 4.5 -BuildRequires: php-composer(%{gh_owner}/zend-filter) >= 2.6.1 -BuildRequires: php-composer(%{gh_owner}/zend-form) >= 2.7 -# Autoloader -BuildRequires: php-composer(%{gh_owner}/zend-loader) >= 2.5 -# For dependencies autoloader -BuildRequires: php-zendframework-zend-loader >= 2.5.1-3 %endif +# Autoloader +BuildRequires: php-fedora-autoloader-devel # From composer, "require": { # "php": "^5.6 || ^7.0", @@ -60,21 +56,19 @@ BuildRequires: php-zendframework-zend-loader >= 2.5.1-3 Requires: php(language) >= 5.6 Requires: php-composer(container-interop/container-interop) >= 1.1 Requires: php-composer(container-interop/container-interop) < 2 -Requires: php-composer(%{gh_owner}/zend-mvc) >= 3.0 -Requires: php-composer(%{gh_owner}/zend-mvc) < 4 -Requires: php-composer(%{gh_owner}/zend-authentication) >= 2.5.3 -Requires: php-composer(%{gh_owner}/zend-authentication) < 3 -Requires: php-composer(%{gh_owner}/zend-servicemanager) >= 2.7.5 -Requires: php-composer(%{gh_owner}/zend-servicemanager) < 4 +Requires: php-autoloader(%{gh_owner}/zend-mvc) >= 3.0 +Requires: php-autoloader(%{gh_owner}/zend-mvc) < 4 +Requires: php-autoloader(%{gh_owner}/zend-authentication) >= 2.5.3 +Requires: php-autoloader(%{gh_owner}/zend-authentication) < 3 +Requires: php-autoloader(%{gh_owner}/zend-servicemanager) >= 2.7.5 +Requires: php-autoloader(%{gh_owner}/zend-servicemanager) < 4 +# Autoloader +Requires: php-composer(fedora/autoloader) # From phpcompatinfo report for version 1.0.0 Requires: php-spl -%if ! %{bootstrap} -# Autoloader -Requires: php-composer(%{gh_owner}/zend-loader) >= 2.5 -Requires: php-zendframework-zend-loader >= 2.5.1-3 -%endif Provides: php-composer(%{gh_owner}/%{gh_project}) = %{version} +Provides: php-autoloader(%{gh_owner}/%{gh_project}) = %{version} %description @@ -90,15 +84,24 @@ the current identity as provided by zend-authentication. mv LICENSE.md LICENSE -: Create dependency autoloader + +%build +: Create dependency autoloader - deprecated cat << 'EOF' | tee autoload.php array( - 'namespaces' => array( - 'ZendTest\\Mvc\\Plugin\\%{library}' => dirname(__DIR__).'/test/', - 'Zend\\Mvc\\Plugin\\%{library}' => '%{buildroot}%{php_home}/Zend/Mvc/Plugin/%{library}' -)))); -require_once '%{php_home}/Zend/autoload.php'; +require_once '%{buildroot}%{php_home}/Zend/Mvc/Plugin/%{library}/autoload.php'; +\Fedora\Autoloader\Autoload::addPsr4('ZendTest\\Mvc\\Plugin\\%{library}\\', dirname(__DIR__) . '/test'); EOF ret=0 @@ -145,6 +142,9 @@ exit $ret %changelog +* Wed Dec 13 2017 Remi Collet - 1.0.0-4 +- switch from zend-loader to fedora/autoloader + * Wed Jun 29 2016 Remi Collet - 1.0.0-1 - initial package -- cgit