diff options
Diffstat (limited to 'php-doctrine-collections2.spec')
-rw-r--r-- | php-doctrine-collections2.spec | 44 |
1 files changed, 26 insertions, 18 deletions
diff --git a/php-doctrine-collections2.spec b/php-doctrine-collections2.spec index 71a8507..5bd60d4 100644 --- a/php-doctrine-collections2.spec +++ b/php-doctrine-collections2.spec @@ -1,6 +1,4 @@ -# remirepo spec file for php-doctrine-collections, from: -# -# Fedora spec file for php-doctrine-collections +# remirepo/Fedora spec file for php-doctrine-collections # # Copyright (c) 2013-2022 Shawn Iwinski, Remi Collet # @@ -12,15 +10,17 @@ %global github_owner doctrine %global github_name collections -%global github_version 1.8.0 -%global github_commit 2b44dd4cbca8b5744327de78bafef5945c7e7b5e +%global github_version 2.0.0 +%global github_commit fbc051ebfdb0d11560c86491867cb9268a4d1a8e %global composer_vendor doctrine %global composer_project collections -# "php": "^7.1.3 || ^8.0" -%global php_min_ver 7.1.3 -# "doctrine/deprecations": "^0.5.3 || ^1" +%global major 2 + +# "php": "^8.1" +%global php_min_ver 8.1 +# "doctrine/deprecations": "^1" %global doctrine_depr_min_ver 1 %global doctrine_depr_max_ver 2 @@ -29,10 +29,10 @@ %{!?phpdir: %global phpdir %{_datadir}/php} -Name: php-%{composer_vendor}-%{composer_project} +Name: php-%{composer_vendor}-%{composer_project}%{major} Version: %{github_version} Release: 1%{?github_release}%{?dist} -Summary: Collections abstraction library +Summary: Collections abstraction library, version %{major} License: MIT URL: https://github.com/%{github_owner}/%{github_name} @@ -49,6 +49,7 @@ BuildArch: noarch %global phpunit %{_bindir}/phpunit9 BuildRequires: %{phpunit} BuildRequires: php(language) >= %{php_min_ver} +BuildRequires: php-json # remirepo:1 %if 0%{?fedora} >= 27 || 0%{?rhel} >= 8 BuildRequires: (php-composer(doctrine/deprecations) >= %{doctrine_depr_min_ver} with php-composer(doctrine/deprecations) < %{doctrine_depr_max_ver}) @@ -56,7 +57,7 @@ BuildRequires: (php-composer(doctrine/deprecations) >= %{doctrine_depr_min_ver} %else BuildRequires: php-doctrine-deprecations %endif -## phpcompatinfo (computed from version 1.6.0) +## phpcompatinfo (computed from version 2.0.0) BuildRequires: php-pcre BuildRequires: php-spl %endif @@ -72,7 +73,7 @@ Requires: (php-composer(doctrine/deprecations) >= %{doctrine_depr_min_ver} w %else Requires: php-doctrine-deprecations %endif -# phpcompatinfo (computed from version 1.6.0) +# phpcompatinfo (computed from version 2.0.0) Requires: php-pcre Requires: php-spl # Autoloader @@ -95,12 +96,13 @@ Autoloader: %{phpdir}/Doctrine/Common/Collections/autoload.php %build +mv lib/Doctrine/Common/Collections lib/Doctrine/Common/Collections%{major} : Create autoloader phpab --template fedora \ - --output lib/Doctrine/Common/Collections/autoload.php \ - lib/Doctrine/Common/Collections + --output lib/Doctrine/Common/Collections%{major}/autoload.php \ + lib/Doctrine/Common/Collections%{major} -cat <<'AUTOLOAD' | tee -a lib/Doctrine/Common/Collections/autoload.php +cat <<'AUTOLOAD' | tee -a lib/Doctrine/Common/Collections%{major}/autoload.php \Fedora\Autoloader\Dependencies::required([ '%{phpdir}/Doctrine/Deprecations/autoload.php', ]); @@ -117,13 +119,13 @@ cp -rp lib/* %{buildroot}%{phpdir}/ : Create tests bootstrap cat <<'BOOTSTRAP' | tee bootstrap.php <?php -require_once '%{buildroot}%{phpdir}/Doctrine/Common/Collections/autoload.php'; +require_once '%{buildroot}%{phpdir}/Doctrine/Common/Collections%{major}/autoload.php'; \Fedora\Autoloader\Autoload::addPsr4('Doctrine\\Tests\\', __DIR__.'/tests/Doctrine/Tests'); BOOTSTRAP : Upstream tests SCL_RETURN_CODE=0 -for CMD in "php %{phpunit}" php74 php80 php81 php82; do +for CMD in "php %{phpunit}" php81 php82; do if which $CMD; then set $CMD $1 ${2:-%{_bindir}/phpunit9} --verbose --bootstrap bootstrap.php \ @@ -144,10 +146,16 @@ exit $SCL_RETURN_CODE %doc composer.json %dir %{phpdir}/Doctrine %dir %{phpdir}/Doctrine/Common - %{phpdir}/Doctrine/Common/Collections + %{phpdir}/Doctrine/Common/Collections%{major} %changelog +* Fri Sep 30 2022 Remi Collet <remi@remirepo.net> - 2.0.0-1 +- update to 2.0.0 +- rename to php-doctrine-collections2 +- install in /usr/share/php/Doctrine/Common/Collections2 +- raise dependency on PHP 8.1 + * Fri Sep 30 2022 Remi Collet <remi@remirepo.net> - 1.8.0-1 - update to 1.8.0 |