summaryrefslogtreecommitdiffstats
path: root/php-doctrine-inflector2.spec
diff options
context:
space:
mode:
Diffstat (limited to 'php-doctrine-inflector2.spec')
-rw-r--r--php-doctrine-inflector2.spec38
1 files changed, 23 insertions, 15 deletions
diff --git a/php-doctrine-inflector2.spec b/php-doctrine-inflector2.spec
index 5cdbc65..2cadeeb 100644
--- a/php-doctrine-inflector2.spec
+++ b/php-doctrine-inflector2.spec
@@ -1,8 +1,8 @@
-# remirepo spec file for php-doctrine-inflector, from:
+# remirepo spec file for php-doctrine-inflector2, from:
#
# Fedora spec file for php-doctrine-inflector
#
-# Copyright (c) 2013-2020 Shawn Iwinski <shawn.iwinski@gmail.com>
+# Copyright (c) 2013-2020 Shawn Iwinski, Remi Collet
#
# License: MIT
# http://opensource.org/licenses/MIT
@@ -12,8 +12,9 @@
%global github_owner doctrine
%global github_name inflector
-%global github_version 1.4.1
-%global github_commit 4111f6853aea6f28b2b1dcfdde83d12dd3d5e6e3
+%global github_version 2.0.1
+%global major 2
+%global github_commit 18b995743e7ec8b15fd6efc594f0fa3de4bfe6d7
%global composer_vendor doctrine
%global composer_project inflector
@@ -26,7 +27,7 @@
%{!?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: Common string manipulations with regard to casing and singular/plural rules
@@ -45,16 +46,20 @@ BuildArch: noarch
## composer.json
BuildRequires: phpunit8
BuildRequires: php(language) >= %{php_min_ver}
-## phpcompatinfo (computed from version 1.3.0)
+## phpcompatinfo (computed from version 2.0.1)
+BuildRequires: php-mbstring
BuildRequires: php-pcre
+BuildRequires: php-spl
# Autoloader
BuildRequires: php-fedora-autoloader-devel
%endif
# composer.json
Requires: php(language) >= %{php_min_ver}
-# phpcompatinfo (computed from version 1.3.0)
+# phpcompatinfo (computed from version 2.0.1)
+Requires: php-mbstring
Requires: php-pcre
+Requires: php-spl
# Autoloader
Requires: php-composer(fedora/autoloader)
@@ -65,7 +70,7 @@ Provides: php-composer(%{composer_vendor}/%{composer_project}) = %{version}
Doctrine Inflector is a small library that can perform string manipulations
with regard to upper-/lowercase and singular/plural forms of words.
-Autoloader: %{phpdir}/Doctrine/Common/Inflector/autoload.php
+Autoloader: %{phpdir}/Doctrine/Inflector%{major}/autoload.php
%prep
@@ -74,12 +79,12 @@ Autoloader: %{phpdir}/Doctrine/Common/Inflector/autoload.php
%build
: Create autoloader
-phpab --template fedora --output lib/Doctrine/Common/Inflector/autoload.php lib
+phpab --template fedora --output lib/Doctrine/Inflector/autoload.php lib
%install
-mkdir -p %{buildroot}%{phpdir}
-cp -rp lib/* %{buildroot}%{phpdir}/
+mkdir -p %{buildroot}%{phpdir}/Doctrine
+cp -rp lib/Doctrine/Inflector %{buildroot}%{phpdir}/Doctrine/Inflector%{major}
%check
@@ -87,7 +92,7 @@ cp -rp lib/* %{buildroot}%{phpdir}/
: Create tests bootstrap
cat <<'BOOTSTRAP' | tee bootstrap.php
<?php
-require_once '%{buildroot}%{phpdir}/Doctrine/Common/Inflector/autoload.php';
+require_once '%{buildroot}%{phpdir}/Doctrine/Inflector%{major}/autoload.php';
\Fedora\Autoloader\Autoload::addPsr0('Doctrine\\Tests', __DIR__.'/tests');
BOOTSTRAP
@@ -111,12 +116,15 @@ exit $RETURN_CODE
%doc *.md
%doc composer.json
%dir %{phpdir}/Doctrine
-%dir %{phpdir}/Doctrine/Common
- %{phpdir}/Doctrine/Common/Inflector
- %{phpdir}/Doctrine/Inflector
+ %{phpdir}/Doctrine/Inflector%{major}
%changelog
+* Mon May 11 2020 Remi Collet <remi@remirepo.net> - 2.0.1-1
+- update to 2.0.1
+- rename to php-doctrine-inflector2
+- move to /usr/share/php/Doctrine/Inflector2
+
* Mon May 11 2020 Remi Collet <remi@remirepo.net> - 1.4.1-1
- update to 1.4.1
- raise dependency on PHP 7.2