# remirepo/Fedora spec file for php-laminas-view # # Copyright (c) 2015-2021 Remi Collet # License: CC-BY-SA # http://creativecommons.org/licenses/by-sa/4.0/ # # Please, preserve the changelog entries # %global bootstrap 0 %global gh_commit 23fc886670e05d3fae34d3ba2c5089e2d29beb03 %global gh_short %(c=%{gh_commit}; echo ${c:0:7}) %global gh_owner laminas %global gh_project laminas-view %global zf_name zend-view %global php_home %{_datadir}/php %global namespace Laminas %global library View %global with_tests 0%{!?_without_tests:1} Name: php-%{gh_project} Version: 2.12.1 Release: 1%{?dist} Summary: %{namespace} Framework %{library} component License: BSD URL: https://github.com/%{gh_owner}/%{gh_project} Source0: %{gh_commit}/%{name}-%{version}-%{gh_short}.tgz Source1: makesrc.sh BuildArch: noarch # Tests %if %{with_tests} BuildRequires: php(language) >= 7.3 BuildRequires: php-reflection BuildRequires: php-date BuildRequires: php-dom BuildRequires: php-filter BuildRequires: php-pcre BuildRequires: php-spl # remirepo:1 %if 0%{?fedora} >= 27 || 0%{?rhel} >= 8 BuildRequires: (php-autoloader(%{gh_owner}/laminas-eventmanager) >= 2.6.2 with php-autoloader(%{gh_owner}/laminas-eventmanager) < 4) BuildRequires: (php-autoloader(%{gh_owner}/laminas-json) >= 2.6.1 with php-autoloader(%{gh_owner}/laminas-json) < 4) BuildRequires: (php-autoloader(%{gh_owner}/laminas-loader) >= 2.5 with php-autoloader(%{gh_owner}/laminas-loader) < 3) BuildRequires: (php-autoloader(%{gh_owner}/laminas-stdlib) >= 3.2.1 with php-autoloader(%{gh_owner}/laminas-stdlib) < 4) BuildRequires: (php-autoloader(%{gh_owner}/laminas-zendframework-bridge) >= 1.0 with php-autoloader(%{gh_owner}/laminas-zendframework-bridge) < 2) # From composer, "require-dev": { # "laminas/laminas-authentication": "^2.5", # "laminas/laminas-cache": "^2.6.1", # "laminas/laminas-coding-standard": "~1.0.0", # "laminas/laminas-config": "^2.6", # "laminas/laminas-console": "^2.6", # "laminas/laminas-escaper": "^2.5", # "laminas/laminas-feed": "^2.7", # "laminas/laminas-filter": "^2.6.1", # "laminas/laminas-http": "^2.5.4", # "laminas/laminas-i18n": "^2.6", # "laminas/laminas-log": "^2.7", # "laminas/laminas-modulemanager": "^2.7.1", # "laminas/laminas-mvc": "^2.7.14 || ^3.0", # "laminas/laminas-mvc-i18n": "^1.1", # "laminas/laminas-mvc-plugin-flashmessenger": "^1.2", # "laminas/laminas-navigation": "^2.8.1", # "laminas/laminas-paginator": "^2.5", # "laminas/laminas-permissions-acl": "^2.6", # "laminas/laminas-router": "^3.0.1", # "laminas/laminas-serializer": "^2.6.1", # "laminas/laminas-servicemanager": "^3.3", # "laminas/laminas-session": "^2.8.1", # "laminas/laminas-uri": "^2.5", # "phpspec/prophecy": "^1.12", # "phpspec/prophecy-phpunit": "^2.0", # "phpunit/phpunit": "^9.3" BuildRequires: (php-autoloader(%{gh_owner}/laminas-authentication) >= 2.5 with php-autoloader(%{gh_owner}/laminas-authentication) < 3) BuildRequires: (php-autoloader(%{gh_owner}/laminas-cache) >= 2.6.1 with php-autoloader(%{gh_owner}/laminas-cache) < 3) BuildRequires: (php-autoloader(%{gh_owner}/laminas-config) >= 2.6 with php-autoloader(%{gh_owner}/laminas-config) < 3) BuildRequires: (php-autoloader(%{gh_owner}/laminas-console) >= 2.6 with php-autoloader(%{gh_owner}/laminas-console) < 3) BuildRequires: (php-autoloader(%{gh_owner}/laminas-escaper) >= 2.5 with php-autoloader(%{gh_owner}/laminas-escaper) < 3) BuildRequires: (php-autoloader(%{gh_owner}/laminas-feed) >= 2.7 with php-autoloader(%{gh_owner}/laminas-feed) < 3) BuildRequires: (php-autoloader(%{gh_owner}/laminas-filter) >= 2.6.1 with php-autoloader(%{gh_owner}/laminas-filter) < 3) BuildRequires: (php-autoloader(%{gh_owner}/laminas-http) >= 2.5.4 with php-autoloader(%{gh_owner}/laminas-http) < 3) BuildRequires: (php-autoloader(%{gh_owner}/laminas-i18n) >= 2.6 with php-autoloader(%{gh_owner}/laminas-i18n) < 3) BuildRequires: (php-autoloader(%{gh_owner}/laminas-log) >= 2.7 with php-autoloader(%{gh_owner}/laminas-log) < 3) BuildRequires: (php-autoloader(%{gh_owner}/laminas-modulemanager) >= 2.7.1 with php-autoloader(%{gh_owner}/laminas-modulemanager) < 3) %if ! %{bootstrap} BuildRequires: (php-autoloader(%{gh_owner}/laminas-mvc) >= 3.0 with php-autoloader(%{gh_owner}/laminas-mvc) < 4) BuildRequires: (php-autoloader(%{gh_owner}/laminas-mvc-i18n) >= 1.1 with php-autoloader(%{gh_owner}/laminas-mvc-i18n) < 2) BuildRequires: (php-autoloader(%{gh_owner}/laminas-mvc-plugin-flashmessenger) >= 1.2 with php-autoloader(%{gh_owner}/laminas-mvc-plugin-flashmessenger) < 2) BuildRequires: (php-autoloader(%{gh_owner}/laminas-navigation) >= 2.5 with php-autoloader(%{gh_owner}/laminas-navigation) < 3) BuildRequires: (php-autoloader(%{gh_owner}/laminas-paginator) >= 2.5 with php-autoloader(%{gh_owner}/laminas-paginator) < 3) BuildRequires: (php-autoloader(%{gh_owner}/laminas-permissions-acl) >= 2.6 with php-autoloader(%{gh_owner}/laminas-permissions-acl) < 3) %endif BuildRequires: (php-autoloader(%{gh_owner}/laminas-router) >= 3.0.1 with php-autoloader(%{gh_owner}/laminas-router) < 4) BuildRequires: (php-autoloader(%{gh_owner}/laminas-serializer) >= 2.6.1 with php-autoloader(%{gh_owner}/laminas-serializer) < 3) BuildRequires: (php-autoloader(%{gh_owner}/laminas-servicemanager) >= 3.3 with php-autoloader(%{gh_owner}/laminas-servicemanager) < 4) BuildRequires: (php-autoloader(%{gh_owner}/laminas-session) >= 2.8.1 with php-autoloader(%{gh_owner}/laminas-session) < 3) BuildRequires: (php-autoloader(%{gh_owner}/laminas-uri) >= 2.5 with php-autoloader(%{gh_owner}/laminas-uri) < 3) BuildRequires: (php-composer(phpspec/prophecy) >= 1.12.0 with php-composer(phpspec/prophecy) < 2) BuildRequires: (php-composer(phpspec/prophecy-phpunit) >= 2.0 with php-composer(phpspec/prophecy-phpunit) < 3) # remirepo:32 %else BuildRequires: php-laminas-eventmanager BuildRequires: php-laminas-json BuildRequires: php-laminas-loader BuildRequires: php-laminas-stdlib BuildRequires: php-laminas-zendframework-bridge BuildRequires: php-laminas-authentication BuildRequires: php-laminas-cache BuildRequires: php-laminas-console BuildRequires: php-laminas-escaper BuildRequires: php-laminas-feed BuildRequires: php-laminas-filter BuildRequires: php-laminas-http BuildRequires: php-laminas-i18n BuildRequires: php-laminas-log BuildRequires: php-laminas-modulemanager %if ! %{bootstrap} BuildRequires: php-laminas-mvc BuildRequires: php-laminas-mvc-i18n BuildRequires: php-laminas-mvc-plugin-flashmessenger BuildRequires: php-laminas-navigation BuildRequires: php-laminas-paginator BuildRequires: php-laminas-permissions-acl %endif BuildRequires: php-laminas-router BuildRequires: php-laminas-serializer BuildRequires: php-laminas-servicemanager BuildRequires: php-laminas-session BuildRequires: php-laminas-uri BuildRequires: php-phpspec-prophecy BuildRequires: php-phpspec-prophecy-phpunit %endif BuildRequires: phpunit9 >= 9.3 %endif # Autoloader BuildRequires: php-fedora-autoloader-devel # From composer, "require": { # "php": "^7.3 || ~8.0.0", # "laminas/laminas-eventmanager": "^3.0", # "laminas/laminas-json": "^2.6.1 || ^3.0", # "laminas/laminas-loader": "^2.5", # "laminas/laminas-stdlib": "^3.2.1", # "laminas/laminas-zendframework-bridge": "^1.0" Requires: php(language) >= 7.3 # remirepo:1 %if 0%{?fedora} >= 27 || 0%{?rhel} >= 8 Requires: (php-autoloader(%{gh_owner}/laminas-eventmanager) >= 3.0 with php-autoloader(%{gh_owner}/laminas-eventmanager) < 4) Requires: (php-autoloader(%{gh_owner}/laminas-json) >= 2.6.1 with php-autoloader(%{gh_owner}/laminas-json) < 4) Requires: (php-autoloader(%{gh_owner}/laminas-loader) >= 2.5 with php-autoloader(%{gh_owner}/laminas-loader) < 3) Requires: (php-autoloader(%{gh_owner}/laminas-stdlib) >= 3.2.1 with php-autoloader(%{gh_owner}/laminas-stdlib) < 4) Requires: (php-autoloader(%{gh_owner}/laminas-zendframework-bridge) >= 1.0 with php-autoloader(%{gh_owner}/laminas-zendframework-bridge) < 2) # From composer, "suggest": { # "laminas/laminas-authentication": "Laminas\\Authentication component", # "laminas/laminas-escaper": "Laminas\\Escaper component", # "laminas/laminas-feed": "Laminas\\Feed component", # "laminas/laminas-filter": "Laminas\\Filter component", # "laminas/laminas-http": "Laminas\\Http component", # "laminas/laminas-i18n": "Laminas\\I18n component", # "laminas/laminas-mvc": "Laminas\\Mvc component", # "laminas/laminas-mvc-plugin-flashmessenger": "laminas-mvc-plugin-flashmessenger component, if you want to use the FlashMessenger view helper with laminas-mvc versions 3 and up", # "laminas/laminas-navigation": "Laminas\\Navigation component", # "laminas/laminas-paginator": "Laminas\\Paginator component", # "laminas/laminas-permissions-acl": "Laminas\\Permissions\\Acl component", # "laminas/laminas-servicemanager": "Laminas\\ServiceManager component", # "laminas/laminas-uri": "Laminas\\Uri component" Suggests: php-composer(%{gh_owner}/laminas-authentication) Suggests: php-composer(%{gh_owner}/laminas-escaper) Suggests: php-composer(%{gh_owner}/laminas-feed) Suggests: php-composer(%{gh_owner}/laminas-filter) Suggests: php-composer(%{gh_owner}/laminas-http) Suggests: php-composer(%{gh_owner}/laminas-i18n) Suggests: php-composer(%{gh_owner}/laminas-mvc) Suggests: php-composer(%{gh_owner}/laminas-mvc-plugin-flashmessenger) Suggests: php-composer(%{gh_owner}/laminas-navigation) Suggests: php-composer(%{gh_owner}/laminas-paginator) Suggests: php-composer(%{gh_owner}/laminas-permissions-acl) Suggests: php-composer(%{gh_owner}/laminas-servicemanager) Suggests: php-composer(%{gh_owner}/laminas-uri) # remirepo:7 %else Requires: php-laminas-eventmanager Requires: php-laminas-json Requires: php-laminas-loader Requires: php-laminas-stdlib Requires: php-laminas-zendframework-bridge %endif # Autoloader Requires: php-composer(fedora/autoloader) # From phpcompatinfo report for version 2.11.4 Requires: php-cli Requires: php-reflection Requires: php-date Requires: php-dom Requires: php-filter Requires: php-pcre Requires: php-spl # remirepo:2 Obsoletes: php-ZendFramework2-%{library} < 2.5 Provides: php-ZendFramework2-%{library} = %{version} # Compatibily ensure by the bridge Obsoletes: php-zendframework-%{zf_name} < 2.11.5 Provides: php-zendframework-%{zf_name} = %{version} Provides: php-composer(%{gh_owner}/%{gh_project}) = %{version} Provides: php-composer(zendframework/%{zf_name}) = %{version} Provides: php-autoloader(%{gh_owner}/%{gh_project}) = %{version} Provides: php-autoloader(zendframework/%{zf_name}) = %{version} %description %{namespace}\View provides the “View” layer of Zend Framework 2’s MVC system. It is a multi-tiered system allowing a variety of mechanisms for extension, substitution, and more. Documentation: https://docs.laminas.dev/%{gh_project}/ %prep %setup -q -n %{gh_project}-%{gh_commit} mv LICENSE.md LICENSE %build : Create autoloader phpab --template fedora --output src/autoload.php src cat << 'EOF' | tee -a src/autoload.php \Fedora\Autoloader\Dependencies::required([ '%{php_home}/%{namespace}/EventManager/autoload.php', '%{php_home}/%{namespace}/Loader/autoload.php', '%{php_home}/%{namespace}/Stdlib/autoload.php', ]); \Fedora\Autoloader\Dependencies::optional([ '%{php_home}/%{namespace}/Authentication/autoload.php', '%{php_home}/%{namespace}/Escaper/autoload.php', '%{php_home}/%{namespace}/Feed/autoload.php', '%{php_home}/%{namespace}/Filter/autoload.php', '%{php_home}/%{namespace}/Http/autoload.php', '%{php_home}/%{namespace}/I18n/autoload.php', '%{php_home}/%{namespace}/Json/autoload.php', '%{php_home}/%{namespace}/Mvc/autoload.php', '%{php_home}/%{namespace}/Navigation/autoload.php', '%{php_home}/%{namespace}/Paginator/autoload.php', '%{php_home}/%{namespace}/Permissions/Acl/autoload.php', '%{php_home}/%{namespace}/ServiceManager/autoload.php', '%{php_home}/%{namespace}/Uri/autoload.php', ]); EOF cat << 'EOF' | tee zf.php - 2.12.1-1 - update to 2.12.1 * Thu Jan 7 2021 Remi Collet - 2.12.0-1 - update to 2.12.0 - raise dependency on PHP 7.3 - raise dependency on laminas-stdlib 3.2.1 - switch to phpunit9 * Wed Dec 16 2020 Remi Collet - 2.11.5-1 - update to 2.11.5 - switch to phpunit7 * Wed Jan 15 2020 Remi Collet - 2.11.4-1 - switch to Laminas * Thu Dec 5 2019 Remi Collet - 2.11.4-1 - update to 2.11.4 * Sun Oct 13 2019 Remi Collet - 2.11.3-1 - update to 2.11.3 - drop patches merged upstream * Fri Oct 11 2019 Remi Collet - 2.11.2-3 - add patches for PHP 7.4 from https://github.com/zendframework/zend-view/pull/192 https://github.com/zendframework/zend-view/pull/195 * Wed Feb 20 2019 Remi Collet - 2.11.2-1 - update to 2.11.2 * Tue Dec 11 2018 Remi Collet - 2.11.1-1 - update to 2.11.1 - add mandatory dependency on zendframework/zend-json - add optional dependency on zendframework/zend-mvc-plugin-flashmessenger - raise dependency on zendframework/zend-mvc 2.7.14 - use range dependencies * Thu Dec 6 2018 Remi Collet - 2.10.0-4 - cleanup for EL-8 * Thu Jan 18 2018 Remi Collet - 2.10.0-1 - Update to 2.10.0 - only use phpunit6 * Tue Dec 12 2017 Remi Collet - 2.9.0-3 - switch from zend-loader to fedora/autoloader * Tue Mar 21 2017 Remi Collet - 2.9.0-1 - Update to 2.9.0 - raise dependency on PHP 5.6 - use phpunit6 on F26+ * Tue Mar 21 2017 Remi Collet - 2.8.2-1 - Update to 2.8.2 * Tue Feb 21 2017 Remi Collet - 2.8.1-2 - add missing BR, fix FTBFS #1424088 * Fri Jul 1 2016 Remi Collet - 2.8.1-1 - version 2.8.1 * Wed Jun 22 2016 Remi Collet - 2.8.0-1 - version 2.8.0 - add zf_templatemap_generator (dropped from zf2) * Thu May 12 2016 Remi Collet - 2.7.0-1 - version 2.7.0 * Tue Apr 19 2016 Remi Collet - 2.6.7-1 - version 2.6.7 * Mon Mar 21 2016 Remi Collet - 2.6.5-1 - version 2.6.5 * Mon Mar 21 2016 Remi Collet - 2.6.4-2 - add patch for zend-navigation issue, see: https://github.com/zendframework/zend-navigation/issues/23 * Thu Mar 3 2016 Remi Collet - 2.6.4-1 - version 2.6.4 * Tue Feb 23 2016 Remi Collet - 2.6.3-1 - version 2.6.3 * Fri Feb 19 2016 Remi Collet - 2.6.2-1 - version 2.6.2 * Thu Feb 18 2016 Remi Collet - 2.6.1-1 - version 2.6.1 * Thu Feb 18 2016 Remi Collet - 2.6.0-1 - version 2.6.0 - raise dependency on zend-eventmanager >= 2.6.2 - raise dependency on zend-stdlib >= 2.7 * Wed Jan 20 2016 Remi Collet - 2.5.3-1 - version 2.5.3 * Thu Aug 6 2015 Remi Collet - 2.5.2-1 - version 2.5.2 * Tue Aug 4 2015 Remi Collet - 2.5.1-1 - initial package