diff options
author | Remi Collet <remi@remirepo.net> | 2019-10-17 16:31:23 +0200 |
---|---|---|
committer | Remi Collet <remi@remirepo.net> | 2019-10-17 16:31:23 +0200 |
commit | a86c02af6872e44eb2f7fb6fd8abd8b7a7e4344f (patch) | |
tree | 8044a5644c8d3b3754b64790594d3288b7dd76aa | |
parent | 123e0e7c4ecd0c019e47e266c65371ca1adba44a (diff) |
- use range dependencies
- add patch for PHP 7.4 from
https://github.com/horde/Ldap/pull/1
-rw-r--r-- | 1.patch | 22 | ||||
-rw-r--r-- | php-horde-Horde-Ldap.spec | 31 |
2 files changed, 47 insertions, 6 deletions
@@ -0,0 +1,22 @@ +From 55de8c2b738eb052e5b240b8abc613ccd113203c Mon Sep 17 00:00:00 2001 +From: Remi Collet <remi@remirepo.net> +Date: Thu, 17 Oct 2019 16:22:31 +0200 +Subject: [PATCH] fix curly braces is deprecated + +--- + lib/Horde/Ldap/Filter.php | 2 +- + 1 file changed, 1 insertion(+), 1 deletion(-) + +diff --git a/lib/Horde/Ldap/Filter.php b/lib/Horde/Ldap/Filter.php +index 4d4b4db..8124813 100644 +--- a/lib/Horde/Ldap/Filter.php ++++ b/lib/Horde/Ldap/Filter.php +@@ -350,7 +350,7 @@ protected static function _parseCombination($filter) + // is outside any subcomponent. + $level = 0; + for ($curpos = 0, $len = strlen($filter); $curpos < $len; $curpos++) { +- $cur_char = $filter{$curpos}; ++ $cur_char = $filter[$curpos]; + + // Rise/lower bracket level. + if ($cur_char == '(' && $prev_char != '\\') { diff --git a/php-horde-Horde-Ldap.spec b/php-horde-Horde-Ldap.spec index 2a96eeb..a1f5049 100644 --- a/php-horde-Horde-Ldap.spec +++ b/php-horde-Horde-Ldap.spec @@ -1,6 +1,6 @@ # remirepo/fedora spec file for php-horde-Horde-Ldap # -# Copyright (c) 2012-2018 Remi Collet +# Copyright (c) 2012-2019 Remi Collet # License: CC-BY-SA # http://creativecommons.org/licenses/by-sa/4.0/ # @@ -12,20 +12,28 @@ Name: php-horde-Horde-Ldap Version: 2.4.1 -Release: 1%{?dist} +Release: 6%{?dist} Summary: Horde LDAP libraries -Group: Development/Libraries License: LGPLv3 URL: http://pear.horde.org Source0: http://%{pear_channel}/get/%{pear_name}-%{version}.tgz +Patch0: https://patch-diff.githubusercontent.com/raw/horde/Ldap/pull/1.patch + BuildArch: noarch BuildRequires: php(language) >= 5.3.0 BuildRequires: php-pear(PEAR) >= 1.7.0 BuildRequires: php-channel(%{pear_channel}) # To run unit tests +%if 0%{?fedora} >= 27 || 0%{?rhel} >= 8 +BuildRequires: php-ldap +BuildRequires: (php-pear(%{pear_channel}/Horde_Test) >= 2.1.0 with php-pear(%{pear_channel}/Horde_Test) < 3) +BuildRequires: (php-pear(%{pear_channel}/Horde_Exception) >= 2.0.0 with php-pear(%{pear_channel}/Horde_Exception) < 3) +BuildRequires: (php-pear(%{pear_channel}/Horde_Util) >= 2.0.0 with php-pear(%{pear_channel}/Horde_Util) < 3) +%else BuildRequires: php-pear(%{pear_channel}/Horde_Test) >= 2.1.0 +%endif Requires(post): %{__pear} Requires(postun): %{__pear} @@ -35,10 +43,15 @@ Requires: php-pcre Requires: php-spl Requires: php-pear(PEAR) >= 1.7.0 Requires: php-channel(%{pear_channel}) +%if 0%{?fedora} >= 27 || 0%{?rhel} >= 8 +Requires: (php-pear(%{pear_channel}/Horde_Exception) >= 2.0.0 with php-pear(%{pear_channel}/Horde_Exception) < 3) +Requires: (php-pear(%{pear_channel}/Horde_Util) >= 2.0.0 with php-pear(%{pear_channel}/Horde_Util) < 3) +%else Requires: php-pear(%{pear_channel}/Horde_Exception) >= 2.0.0 Requires: php-pear(%{pear_channel}/Horde_Exception) < 3.0.0 Requires: php-pear(%{pear_channel}/Horde_Util) >= 2.0.0 Requires: php-pear(%{pear_channel}/Horde_Util) < 3.0.0 +%endif Provides: php-pear(%{pear_channel}/%{pear_name}) = %{version} Provides: php-composer(horde/horde-ldap) = %{version} @@ -50,9 +63,10 @@ objects. %prep %setup -q -c - cd %{pear_name}-%{version} -cp ../package.xml %{name}.xml +%patch0 -p1 -b .pr1 +sed -e '/Filter.php/s/md5sum=.*name=/name=/' \ + ../package.xml >%{name}.xml %build @@ -76,7 +90,7 @@ install -pm 644 %{name}.xml %{buildroot}%{pear_xmldir} cd %{pear_name}-%{version}/test/$(echo %{pear_name} | sed -e s:_:/:g) ret=0 -for cmd in php php70 php71 php72; do +for cmd in php php71 php72 php73 php74; do if which $cmd; then $cmd %{_bindir}/phpunit --bootstrap bootstrap.php --verbose . || ret=1 fi @@ -104,6 +118,11 @@ fi %changelog +* Thu Oct 17 2019 Remi Collet <remi@remirepo.net> - 2.4.1-6 +- use range dependencies +- add patch for PHP 7.4 from + https://github.com/horde/Ldap/pull/1 + * Fri Jan 26 2018 Remi Collet <remi@remirepo.net> - 2.4.1-1 - Update to 2.4.1 |