From f0e38a977bb4019de84db91acbaaba506c520d4b Mon Sep 17 00:00:00 2001 From: Remi Collet Date: Fri, 29 Dec 2017 17:49:06 +0100 Subject: v0.2.0 --- REFLECTION | 20 +++++++++++++++++--- php-pecl-geospatial.spec | 18 +++++++++++++----- 2 files changed, 30 insertions(+), 8 deletions(-) diff --git a/REFLECTION b/REFLECTION index aa647dd..56a15ea 100644 --- a/REFLECTION +++ b/REFLECTION @@ -1,8 +1,8 @@ -Extension [ extension #96 geospatial version 0.1.0 ] { +Extension [ extension #91 geospatial version 0.2.0 ] { - Constants [4] { - Constant [ double GEO_DEG_TO_RAD ] { 0.017453292519943 } - Constant [ double GEO_EARTH_RADIUS ] { 6378137 } + Constant [ float GEO_DEG_TO_RAD ] { 0,017453292519943 } + Constant [ float GEO_EARTH_RADIUS ] { 6378137 } Constant [ integer GEO_AIRY_1830 ] { 2 } Constant [ integer GEO_WGS84 ] { 1 } } @@ -114,6 +114,20 @@ Extension [ extension #96 geospatial version 0.1.0 ] { Parameter #1 [ $epsilon ] } } + Function [ function geohash_encode ] { + + - Parameters [3] { + Parameter #0 [ $latitude ] + Parameter #1 [ $longitude ] + Parameter #2 [ $precision ] + } + } + Function [ function geohash_decode ] { + + - Parameters [1] { + Parameter #0 [ $geohash ] + } + } } } diff --git a/php-pecl-geospatial.spec b/php-pecl-geospatial.spec index 05f18ce..aa396e2 100644 --- a/php-pecl-geospatial.spec +++ b/php-pecl-geospatial.spec @@ -11,7 +11,7 @@ %scl_package php-pecl-geospatial %endif -%global gh_commit 27547d489d5b4fc41cce0a0d3118979d6c10c0cf +%global gh_commit 3e36c70e74956ffca5a3145e3e4b3e66762fb520 %global gh_short %(c=%{gh_commit}; echo ${c:0:7}) %global gh_owner php-geospatial %global gh_project geospatial @@ -28,11 +28,11 @@ Summary: PHP Extension to handle common geospatial functions Name: %{?sub_prefix}php-pecl-%{pecl_name} -Version: 0.1.0 +Version: 0.2.0 %if 0%{?gh_date:1} Release: 0.8.%{gh_date}git%{gh_short}%{?dist}%{!?scl:%{!?nophptag:%(%{__php} -r 'echo ".".PHP_MAJOR_VERSION.".".PHP_MINOR_VERSION;')}} %else -Release: 6%{?dist}%{!?scl:%{!?nophptag:%(%{__php} -r 'echo ".".PHP_MAJOR_VERSION.".".PHP_MINOR_VERSION;')}} +Release: 1%{?dist}%{!?scl:%{!?nophptag:%(%{__php} -r 'echo ".".PHP_MAJOR_VERSION.".".PHP_MINOR_VERSION;')}} %endif License: PHP @@ -43,6 +43,7 @@ Source0: https://github.com/%{gh_owner}/%{gh_project}/archive/%{gh_commit BuildRoot: %{_tmppath}/%{name}-%{version}-%{release}-root-%(%{__id_u} -n) BuildRequires: %{?scl_prefix}php-devel > 5.4 BuildRequires: %{?scl_prefix}php-pear +BuildRequires: %{?scl_prefix}php-json Requires: %{?scl_prefix}php(zend-abi) = %{php_zend_api} Requires: %{?scl_prefix}php(api) = %{php_core_api} @@ -177,6 +178,10 @@ done %check cd NTS +OPT="-n" +if [ -f %{php_extdir}/json.so ]; then + OPT="$OPT -d extension=json.so" +fi : Minimal load test for NTS extension %{_bindir}/php --no-php-ini \ @@ -186,7 +191,7 @@ cd NTS %if %{with_tests} : Upstream test suite for NTS extension TEST_PHP_EXECUTABLE=%{__php} \ -TEST_PHP_ARGS="-n -d extension=%{buildroot}%{php_extdir}/%{pecl_name}.so" \ +TEST_PHP_ARGS="$OPT -d extension=%{buildroot}%{php_extdir}/%{pecl_name}.so" \ NO_INTERACTION=1 \ REPORT_EXIT_STATUS=1 \ %{__php} -n run-tests.php --show-diff @@ -205,7 +210,7 @@ cd ../ZTS %if %{with_tests} : Upstream test suite for ZTS extension TEST_PHP_EXECUTABLE=%{__ztsphp} \ -TEST_PHP_ARGS="-n -d extension=%{buildroot}%{php_ztsextdir}/%{pecl_name}.so" \ +TEST_PHP_ARGS="$OPT -d extension=%{buildroot}%{php_ztsextdir}/%{pecl_name}.so" \ NO_INTERACTION=1 \ REPORT_EXIT_STATUS=1 \ %{__ztsphp} -n run-tests.php --show-diff @@ -255,6 +260,9 @@ rm -rf %{buildroot} %changelog +* Fri Dec 29 2017 Remi Collet - 0.2.0-1 +- Update to 0.2.0 (beta) + * Tue Jul 18 2017 Remi Collet - 0.1.0-6 - rebuild for PHP 7.2.0beta1 new API -- cgit