summaryrefslogtreecommitdiffstats
path: root/php-zendframework-zend-diactoros.spec
diff options
context:
space:
mode:
authorRemi Collet <remi@remirepo.net>2017-12-05 15:33:47 +0100
committerRemi Collet <remi@remirepo.net>2017-12-05 15:33:47 +0100
commit9004b656360760c0738283d7ff822d3f6173f785 (patch)
tree5b3d14818e09cbedb756b4c5938ec931cca6faaf /php-zendframework-zend-diactoros.spec
parent17cd3ba369e7349f176d658398f8a801934f8904 (diff)
switch to classmap autoloader for consistency
provide php-autoloader(zendframework/zend-diactoros)
Diffstat (limited to 'php-zendframework-zend-diactoros.spec')
-rw-r--r--php-zendframework-zend-diactoros.spec23
1 files changed, 10 insertions, 13 deletions
diff --git a/php-zendframework-zend-diactoros.spec b/php-zendframework-zend-diactoros.spec
index 28dcf1f..8b4d2a6 100644
--- a/php-zendframework-zend-diactoros.spec
+++ b/php-zendframework-zend-diactoros.spec
@@ -31,7 +31,7 @@
Name: php-%{composer_vendor}-%{composer_project}
Version: %{github_version}
-Release: 1%{?github_release}%{?dist}
+Release: 2%{?github_release}%{?dist}
Summary: PSR HTTP Message implementations
Group: Development/Libraries
@@ -68,9 +68,9 @@ BuildRequires: php-json
BuildRequires: php-pcre
BuildRequires: php-reflection
BuildRequires: php-spl
-## Autoloader
-BuildRequires: php-composer(fedora/autoloader)
%endif
+## Autoloader
+BuildRequires: php-fedora-autoloader-devel
# composer.json
Requires: php(language) >= %{php_min_ver}
@@ -85,6 +85,7 @@ Requires: php-composer(fedora/autoloader)
# Composer
Provides: php-composer(%{composer_vendor}/%{composer_project}) = %{version}
+Provides: php-autoloader(%{composer_vendor}/%{composer_project}) = %{version}
Provides: php-composer(psr/http-message-implementation) = 1.0
%description
@@ -108,16 +109,8 @@ mv LICENSE.md LICENSE
%build
: Create autoloader
-cat <<'AUTOLOAD' | tee src/autoload.php
-<?php
-/**
- * Autoloader for %{name} and its' dependencies
- * (created by %{name}-%{version}-%{release}).
- */
-require_once '%{phpdir}/Fedora/Autoloader/autoload.php';
-
-\Fedora\Autoloader\Autoload::addPsr4('Zend\\Diactoros\\', __DIR__);
-
+phpab --template fedora --output src/autoload.php src
+cat <<'AUTOLOAD' | tee -a src/autoload.php
\Fedora\Autoloader\Dependencies::required(array(
'%{phpdir}/Psr/Http/Message/autoload.php',
));
@@ -173,6 +166,10 @@ exit $RETURN_CODE
%changelog
+* Tue Dec 5 2017 Remi Collet <remi@remirepo.net> - 1.6.1-2
+- switch to classmap autoloader for consistency
+- provide php-autoloader(zendframework/zend-diactoros)
+
* Thu Nov 2 2017 Remi Collet <remi@remirepo.net> - 1.6.1-1
- Update to 1.6.1
- use phpunit6 on F26+