summaryrefslogtreecommitdiffstats
path: root/php-pecl-ip2location.spec
diff options
context:
space:
mode:
Diffstat (limited to 'php-pecl-ip2location.spec')
-rw-r--r--php-pecl-ip2location.spec46
1 files changed, 12 insertions, 34 deletions
diff --git a/php-pecl-ip2location.spec b/php-pecl-ip2location.spec
index 4a93acd..e436964 100644
--- a/php-pecl-ip2location.spec
+++ b/php-pecl-ip2location.spec
@@ -19,39 +19,25 @@
%global ini_name 40-%{pecl_name}.ini
%endif
-%global upstream_version 8.0.1
+%global upstream_version 8.1.0
#global upstream_prever RC1
Summary: Get geo location information of an IP address
Name: %{?sub_prefix}php-pecl-%{pecl_name}
License: PHP
Version: %{upstream_version}%{?upstream_prever:~%{upstream_prever}}
-Release: 11%{?dist}%{!?nophptag:%(%{__php} -r 'echo ".".PHP_MAJOR_VERSION.".".PHP_MINOR_VERSION;')}
+Release: 1%{?dist}%{!?nophptag:%(%{__php} -r 'echo ".".PHP_MAJOR_VERSION.".".PHP_MINOR_VERSION;')}
URL: https://pecl.php.net/package/%{pecl_name}
Source0: https://pecl.php.net/get/%{pecl_name}-%{upstream_version}%{?upstream_prever}.tgz
-# https://github.com/chrislim2888/IP2Location-PECL-Extension/pull/5 - test suite
-Patch0: https://patch-diff.githubusercontent.com/raw/chrislim2888/IP2Location-PECL-Extension/pull/5.patch
-# https://github.com/chrislim2888/IP2Location-PECL-Extension/pull/8 - library 8.1
-Patch1: https://patch-diff.githubusercontent.com/raw/chrislim2888/IP2Location-PECL-Extension/pull/8.patch
-# https://github.com/chrislim2888/IP2Location-PECL-Extension/pull/9 - PHP 8
-Patch2: https://patch-diff.githubusercontent.com/raw/chrislim2888/IP2Location-PECL-Extension/pull/9.patch
-# https://github.com/chrislim2888/IP2Location-PECL-Extension/pull/10 - display version
-Patch3: https://patch-diff.githubusercontent.com/raw/chrislim2888/IP2Location-PECL-Extension/pull/10.patch
-# https://github.com/chrislim2888/IP2Location-PECL-Extension/pull/11 - config.m4
-Patch4: https://patch-diff.githubusercontent.com/raw/chrislim2888/IP2Location-PECL-Extension/pull/11.patch
-# https://github.com/chrislim2888/IP2Location-PECL-Extension/pull/12 - library 8.1.4
-Patch5: https://patch-diff.githubusercontent.com/raw/chrislim2888/IP2Location-PECL-Extension/pull/12.patch
-# https://github.com/chrislim2888/IP2Location-PECL-Extension/pull/13 - config
-Patch6: https://patch-diff.githubusercontent.com/raw/chrislim2888/IP2Location-PECL-Extension/pull/13.patch
-# https://github.com/chrislim2888/IP2Location-PECL-Extension/pull/15 - ip2location_bin_version
-Patch7: https://patch-diff.githubusercontent.com/raw/chrislim2888/IP2Location-PECL-Extension/pull/15.patch
+# Fix test with old library < 8.3
+Patch0: %{pecl_name}-tests.patch
BuildRequires: %{?dtsprefix}gcc
BuildRequires: %{?scl_prefix}php-pear
BuildRequires: %{?scl_prefix}php-devel
# ensure proper version is used
-BuildRequires: IP2Location-devel >= 8.2.0
+BuildRequires: IP2Location-devel >= 8.2
Requires: %{?scl_prefix}php(zend-abi) = %{php_zend_api}
Requires: %{?scl_prefix}php(api) = %{php_core_api}
@@ -104,24 +90,12 @@ mv %{pecl_name}-%{upstream_version}%{?upstream_prever} NTS
# Don't install tests
sed -e 's/role="test"/role="src"/' \
%{?_licensedir:-e '/LICENSE/s/role="doc"/role="src"/' } \
- -e '/README.TXT/s/role="doc"/role="src"/' \
+ -e '/README.TXT/s/role="doc"/role="test"/' \
-i package.xml
cd NTS
-sed -e "s/\r//" -i LICENSE CREDITS README *.c *.h
-chmod -x *.c *.h LICENSE CREDITS README
-
-: Patches
-mv test tests
-sed -e "s/\r//" -i *.c config.m4
-%patch0 -p1 -b .pr5
-%patch1 -p1 -b .pr8
-%patch2 -p1 -b .pr9
-%patch3 -p1 -b .pr10
-%patch4 -p1 -b .pr11
-%patch5 -p1 -b .pr12
-%patch6 -p1 -b .pr13
-%patch7 -p1 -b .pr15
+sed -e "s/\r//" -i LICENSE CREDITS *.md *.c *.h
+%patch0 -p0
# Check version
extver=$(sed -n '/#define PHP_IP2LOCATION_VERSION/{s/.* "//;s/".*$//;p}' php_ip2location.h)
@@ -243,6 +217,10 @@ fi
%changelog
+* Thu Nov 19 2020 Remi Collet <remi@remirepo.net> - 8.1.0-1
+- update to 8.1.0
+- drop all patches merged upstream
+
* Wed Nov 18 2020 Remi Collet <remi@remirepo.net> - 8.0.1-11
- add patch to improve configure output from
https://github.com/chrislim2888/IP2Location-PECL-Extension/pull/13