From f738e64f2ae1b3f93d847c098099ed72674d29b4 Mon Sep 17 00:00:00 2001 From: Remi Collet Date: Wed, 9 Sep 2020 12:08:35 +0200 Subject: test build for upcoming 2.5.1 --- PHPINFO | 4 +- REFLECTION | 134 ++++++++++++++++++++++++++++++++++------------------ php-pecl-solr2.spec | 62 ++++++++++-------------- 3 files changed, 116 insertions(+), 84 deletions(-) diff --git a/PHPINFO b/PHPINFO index b16c5c2..0dd3114 100644 --- a/PHPINFO +++ b/PHPINFO @@ -3,5 +3,5 @@ solr Solr Support => enabled Version => 2.5.0 -Last Build Date => Jul 4 2019 -Last Build Time => 16:53:58 +Last Build Date => Sep 9 2020 +Last Build Time => 00:00:00 diff --git a/REFLECTION b/REFLECTION index fdcd7f7..9088d8e 100644 --- a/REFLECTION +++ b/REFLECTION @@ -1,4 +1,4 @@ -Extension [ extension #197 solr version 2.5.0 ] { +Extension [ extension #117 solr version 2.5.0 ] { - Dependencies { Dependency [ libxml (Required) ] @@ -6,9 +6,9 @@ Extension [ extension #197 solr version 2.5.0 ] { } - Constants [4] { - Constant [ integer SOLR_MAJOR_VERSION ] { 2 } - Constant [ integer SOLR_MINOR_VERSION ] { 5 } - Constant [ integer SOLR_PATCH_VERSION ] { 0 } + Constant [ int SOLR_MAJOR_VERSION ] { 2 } + Constant [ int SOLR_MINOR_VERSION ] { 5 } + Constant [ int SOLR_PATCH_VERSION ] { 0 } Constant [ string SOLR_EXTENSION_VERSION ] { 2.5.0 } } @@ -88,12 +88,12 @@ Extension [ extension #197 solr version 2.5.0 ] { Class [ final class SolrDocument implements ArrayAccess, Iterator, Traversable, Serializable ] { - Constants [6] { - Constant [ public integer SORT_DEFAULT ] { 1 } - Constant [ public integer SORT_ASC ] { 1 } - Constant [ public integer SORT_DESC ] { 2 } - Constant [ public integer SORT_FIELD_NAME ] { 1 } - Constant [ public integer SORT_FIELD_VALUE_COUNT ] { 2 } - Constant [ public integer SORT_FIELD_BOOST_VALUE ] { 4 } + Constant [ public int SORT_DEFAULT ] { 1 } + Constant [ public int SORT_ASC ] { 1 } + Constant [ public int SORT_DESC ] { 2 } + Constant [ public int SORT_FIELD_NAME ] { 1 } + Constant [ public int SORT_FIELD_VALUE_COUNT ] { 2 } + Constant [ public int SORT_FIELD_BOOST_VALUE ] { 4 } } - Static properties [0] { @@ -120,6 +120,9 @@ Extension [ extension #197 solr version 2.5.0 ] { } Method [ public method __clone ] { + + - Parameters [0] { + } } Method [ public method __set ] { @@ -211,6 +214,9 @@ Extension [ extension #197 solr version 2.5.0 ] { } Method [ public method serialize ] { + + - Parameters [0] { + } } Method [ public method unserialize ] { @@ -356,20 +362,20 @@ Extension [ extension #197 solr version 2.5.0 ] { Class [ final class SolrInputDocument ] { - Constants [14] { - Constant [ public integer SORT_DEFAULT ] { 1 } - Constant [ public integer SORT_ASC ] { 1 } - Constant [ public integer SORT_DESC ] { 2 } - Constant [ public integer SORT_FIELD_NAME ] { 1 } - Constant [ public integer SORT_FIELD_VALUE_COUNT ] { 2 } - Constant [ public integer SORT_FIELD_BOOST_VALUE ] { 4 } - Constant [ public integer UPDATE_MODIFIER_ADD ] { 1 } - Constant [ public integer UPDATE_MODIFIER_SET ] { 2 } - Constant [ public integer UPDATE_MODIFIER_INC ] { 3 } - Constant [ public integer UPDATE_MODIFIER_REMOVE ] { 4 } - Constant [ public integer UPDATE_MODIFIER_REMOVEREGEX ] { 5 } - Constant [ public integer VERSION_ASSERT_NONE ] { 0 } - Constant [ public integer VERSION_ASSERT_EXISTS ] { 1 } - Constant [ public integer VERSION_ASSERT_NOT_EXISTS ] { -1 } + Constant [ public int SORT_DEFAULT ] { 1 } + Constant [ public int SORT_ASC ] { 1 } + Constant [ public int SORT_DESC ] { 2 } + Constant [ public int SORT_FIELD_NAME ] { 1 } + Constant [ public int SORT_FIELD_VALUE_COUNT ] { 2 } + Constant [ public int SORT_FIELD_BOOST_VALUE ] { 4 } + Constant [ public int UPDATE_MODIFIER_ADD ] { 1 } + Constant [ public int UPDATE_MODIFIER_SET ] { 2 } + Constant [ public int UPDATE_MODIFIER_INC ] { 3 } + Constant [ public int UPDATE_MODIFIER_REMOVE ] { 4 } + Constant [ public int UPDATE_MODIFIER_REMOVEREGEX ] { 5 } + Constant [ public int VERSION_ASSERT_NONE ] { 0 } + Constant [ public int VERSION_ASSERT_EXISTS ] { 1 } + Constant [ public int VERSION_ASSERT_NOT_EXISTS ] { -1 } } - Static properties [0] { @@ -396,6 +402,9 @@ Extension [ extension #197 solr version 2.5.0 ] { } Method [ public method __clone ] { + + - Parameters [0] { + } } Method [ public method __sleep ] { @@ -405,6 +414,9 @@ Extension [ extension #197 solr version 2.5.0 ] { } Method [ public method __wakeup ] { + + - Parameters [0] { + } } Method [ public method setBoost ] { @@ -570,12 +582,12 @@ Extension [ extension #197 solr version 2.5.0 ] { Class [ class SolrClient ] { - Constants [12] { - Constant [ public integer SEARCH_SERVLET_TYPE ] { 1 } - Constant [ public integer UPDATE_SERVLET_TYPE ] { 2 } - Constant [ public integer THREADS_SERVLET_TYPE ] { 4 } - Constant [ public integer PING_SERVLET_TYPE ] { 8 } - Constant [ public integer TERMS_SERVLET_TYPE ] { 16 } - Constant [ public integer SYSTEM_SERVLET_TYPE ] { 32 } + Constant [ public int SEARCH_SERVLET_TYPE ] { 1 } + Constant [ public int UPDATE_SERVLET_TYPE ] { 2 } + Constant [ public int THREADS_SERVLET_TYPE ] { 4 } + Constant [ public int PING_SERVLET_TYPE ] { 8 } + Constant [ public int TERMS_SERVLET_TYPE ] { 16 } + Constant [ public int SYSTEM_SERVLET_TYPE ] { 32 } Constant [ public string DEFAULT_SEARCH_SERVLET ] { select } Constant [ public string DEFAULT_UPDATE_SERVLET ] { update } Constant [ public string DEFAULT_THREADS_SERVLET ] { admin/threads } @@ -615,9 +627,15 @@ Extension [ extension #197 solr version 2.5.0 ] { } Method [ public method __wakeup ] { + + - Parameters [0] { + } } Method [ public method __clone ] { + + - Parameters [0] { + } } Method [ public method getOptions ] { @@ -837,9 +855,15 @@ Extension [ extension #197 solr version 2.5.0 ] { } Method [ public method __clone ] { + + - Parameters [0] { + } } Method [ public method serialize ] { + + - Parameters [0] { + } } Method [ public method unserialize ] { @@ -951,9 +975,15 @@ Extension [ extension #197 solr version 2.5.0 ] { } Method [ public method __clone ] { + + - Parameters [0] { + } } Method [ public method serialize ] { + + - Parameters [0] { + } } Method [ public method unserialize ] { @@ -991,12 +1021,12 @@ Extension [ extension #197 solr version 2.5.0 ] { Class [ class SolrQuery extends SolrModifiableParams implements Serializable ] { - Constants [6] { - Constant [ public integer ORDER_ASC ] { 0 } - Constant [ public integer ORDER_DESC ] { 1 } - Constant [ public integer FACET_SORT_INDEX ] { 0 } - Constant [ public integer FACET_SORT_COUNT ] { 1 } - Constant [ public integer TERMS_SORT_INDEX ] { 0 } - Constant [ public integer TERMS_SORT_COUNT ] { 1 } + Constant [ public int ORDER_ASC ] { 0 } + Constant [ public int ORDER_DESC ] { 1 } + Constant [ public int FACET_SORT_INDEX ] { 0 } + Constant [ public int FACET_SORT_COUNT ] { 1 } + Constant [ public int TERMS_SORT_INDEX ] { 0 } + Constant [ public int TERMS_SORT_COUNT ] { 1 } } - Static properties [0] { @@ -2372,9 +2402,15 @@ Extension [ extension #197 solr version 2.5.0 ] { } Method [ public method __clone ] { + + - Parameters [0] { + } } Method [ public method serialize ] { + + - Parameters [0] { + } } Method [ public method unserialize ] { @@ -3983,9 +4019,15 @@ Extension [ extension #197 solr version 2.5.0 ] { } Method [ public method __clone ] { + + - Parameters [0] { + } } Method [ public method serialize ] { + + - Parameters [0] { + } } Method [ public method unserialize ] { @@ -4237,8 +4279,8 @@ Extension [ extension #197 solr version 2.5.0 ] { Class [ abstract class SolrResponse ] { - Constants [2] { - Constant [ public integer PARSE_SOLR_OBJ ] { 0 } - Constant [ public integer PARSE_SOLR_DOC ] { 1 } + Constant [ public int PARSE_SOLR_OBJ ] { 0 } + Constant [ public int PARSE_SOLR_DOC ] { 1 } } - Static properties [0] { @@ -4340,8 +4382,8 @@ Extension [ extension #197 solr version 2.5.0 ] { Class [ final class SolrQueryResponse extends SolrResponse ] { - Constants [2] { - Constant [ public integer PARSE_SOLR_OBJ ] { 0 } - Constant [ public integer PARSE_SOLR_DOC ] { 1 } + Constant [ public int PARSE_SOLR_OBJ ] { 0 } + Constant [ public int PARSE_SOLR_DOC ] { 1 } } - Static properties [0] { @@ -4455,8 +4497,8 @@ Extension [ extension #197 solr version 2.5.0 ] { Class [ final class SolrUpdateResponse extends SolrResponse ] { - Constants [2] { - Constant [ public integer PARSE_SOLR_OBJ ] { 0 } - Constant [ public integer PARSE_SOLR_DOC ] { 1 } + Constant [ public int PARSE_SOLR_OBJ ] { 0 } + Constant [ public int PARSE_SOLR_DOC ] { 1 } } - Static properties [0] { @@ -4570,8 +4612,8 @@ Extension [ extension #197 solr version 2.5.0 ] { Class [ final class SolrPingResponse extends SolrResponse ] { - Constants [2] { - Constant [ public integer PARSE_SOLR_OBJ ] { 0 } - Constant [ public integer PARSE_SOLR_DOC ] { 1 } + Constant [ public int PARSE_SOLR_OBJ ] { 0 } + Constant [ public int PARSE_SOLR_DOC ] { 1 } } - Static properties [0] { @@ -4685,8 +4727,8 @@ Extension [ extension #197 solr version 2.5.0 ] { Class [ final class SolrGenericResponse extends SolrResponse ] { - Constants [2] { - Constant [ public integer PARSE_SOLR_OBJ ] { 0 } - Constant [ public integer PARSE_SOLR_DOC ] { 1 } + Constant [ public int PARSE_SOLR_OBJ ] { 0 } + Constant [ public int PARSE_SOLR_DOC ] { 1 } } - Static properties [0] { diff --git a/php-pecl-solr2.spec b/php-pecl-solr2.spec index 72a4654..e068a3f 100644 --- a/php-pecl-solr2.spec +++ b/php-pecl-solr2.spec @@ -3,7 +3,7 @@ # # Fedora spec file for php-pecl-solr2 # -# Copyright (c) 2011-2019 Remi Collet +# Copyright (c) 2011-2020 Remi Collet # Copyright (c) 2010 Johan Cwiklinski # License: CC-BY-SA # http://creativecommons.org/licenses/by-sa/4.0/ @@ -24,18 +24,18 @@ # retrieve: docker pull omars/solr53 # create: docker run -d -p 8983:8983 --name solr5 -t omars/solr53 # cleanup: docker stop solr5 && docker rm solr5 -%global with_tests 0%{?_with_tests:1} +%bcond_with tests Summary: Object oriented API to Apache Solr Summary(fr): API orientée objet pour Apache Solr Name: %{?sub_prefix}php-pecl-solr2 -Version: 2.5.0 -Release: 3%{?dist}%{!?scl:%{!?nophptag:%(%{__php} -r 'echo ".".PHP_MAJOR_VERSION.".".PHP_MINOR_VERSION;')}} +Version: 2.5.1 +Release: 0%{?dist}%{!?scl:%{!?nophptag:%(%{__php} -r 'echo ".".PHP_MAJOR_VERSION.".".PHP_MINOR_VERSION;')}} License: PHP Group: Development/Languages -URL: http://pecl.php.net/package/solr +URL: https://pecl.php.net/package/solr -Source0: http://pecl.php.net/get/%{pecl_name}-%{version}%{?prever}.tgz +Source0: https://pecl.php.net/get/%{pecl_name}-%{version}%{?prever}.tgz BuildRequires: %{?scl_prefix}php-devel > 7 BuildRequires: %{?scl_prefix}php-pear @@ -65,30 +65,14 @@ Obsoletes: %{?sub_prefix}php-pecl-%{pecl_name} < 2 Provides: %{?sub_prefix}php-pecl-%{pecl_name} = %{version}-%{release} Provides: %{?sub_prefix}php-pecl-%{pecl_name}%{?_isa} = %{version}-%{release} -%if "%{?vendor}" == "Remi Collet" && 0%{!?scl:1} && 0%{?rhel} -%if "%{php_version}" > "7.1" -Obsoletes: php71u-pecl-%{pecl_name} <= %{version} -Obsoletes: php71w-pecl-%{pecl_name} <= %{version} -Obsoletes: php71u-pecl-%{pecl_name}2 <= %{version} -Obsoletes: php71w-pecl-%{pecl_name}2 <= %{version} -%endif -%if "%{php_version}" > "7.2" -Obsoletes: php72u-pecl-%{pecl_name} <= %{version} -Obsoletes: php72w-pecl-%{pecl_name} <= %{version} -Obsoletes: php72u-pecl-%{pecl_name}2 <= %{version} -Obsoletes: php72w-pecl-%{pecl_name}2 <= %{version} -%endif +%if "%{?packager}" == "Remi Collet" && 0%{!?scl:1} && 0%{?rhel} %if "%{php_version}" > "7.3" Obsoletes: php73-pecl-%{pecl_name} <= %{version} -Obsoletes: php73w-pecl-%{pecl_name} <= %{version} Obsoletes: php73-pecl-%{pecl_name}2 <= %{version} -Obsoletes: php73w-pecl-%{pecl_name}2 <= %{version} %endif %if "%{php_version}" > "7.4" Obsoletes: php74-pecl-%{pecl_name} <= %{version} -Obsoletes: php74w-pecl-%{pecl_name} <= %{version} Obsoletes: php74-pecl-%{pecl_name}2 <= %{version} -Obsoletes: php74w-pecl-%{pecl_name}2 <= %{version} %endif %endif @@ -134,11 +118,16 @@ mv %{pecl_name}-%{version}%{?prever} NTS cd NTS # Check version -DIR=src/php$(%{__php} -r 'echo PHP_MAJOR_VERSION;') +if [ $(%{__php} -r 'echo PHP_MAJOR_VERSION;') < 7 ]; then + DIR=src/php5 +else + DIR=src/php7 +fi + extver=$(sed -n '/#define PHP_SOLR_VERSION /{s/.* "//;s/".*$//;p}' $DIR/php_solr_version.h) if test "x${extver}" != "x%{version}%{?prever}"; then : Error: Upstream version is ${extver}, expecting %{version}%{?prever}. - exit 1 + #exit 1 fi cd .. @@ -214,7 +203,7 @@ fi %check -%if %{with_tests} +%if %{with tests} sed -e '/SOLR_SERVER_CONFIGURED/s/false/true/' \ -e '/SOLR_SERVER_HOSTNAME/s/solr.test/localhost/' \ -i ?TS/tests/test.config.inc @@ -223,17 +212,18 @@ sed -e '/SOLR_SERVER_CONFIGURED/s/true/false/' \ -i ?TS/tests/test.config.inc %endif +OPT="-n" +[ -f %{php_extdir}/curl.so ] && OPT="$OPT -d extension=curl.so" +[ -f %{php_extdir}/json.so ] && OPT="$OPT -d extension=json.so" + : Minimal load test for NTS installed extension -%{__php} \ - -n \ - -d extension=curl.so \ - -d extension=json.so \ +%{__php} $OPT \ -d extension=%{buildroot}%{php_extdir}/%{pecl_name}.so \ -m | grep %{pecl_name} : Upstream test suite for NTS extension cd NTS -TEST_PHP_ARGS="-n -d extension=curl.so -d extension=json.so -d extension=%{buildroot}%{php_extdir}/%{pecl_name}.so" \ +TEST_PHP_ARGS="$OPT -d extension=%{buildroot}%{php_extdir}/%{pecl_name}.so" \ REPORT_EXIT_STATUS=1 \ NO_INTERACTION=1 \ TEST_PHP_EXECUTABLE=%{__php} \ @@ -241,16 +231,13 @@ TEST_PHP_EXECUTABLE=%{__php} \ %if %{with_zts} : Minimal load test for ZTS installed extension -%{__ztsphp} \ - -n \ - -d extension=curl.so \ - -d extension=json.so \ +%{__ztsphp} $OPT \ -d extension=%{buildroot}%{php_ztsextdir}/%{pecl_name}.so \ -m | grep %{pecl_name} : Upstream test suite for ZTS extension cd ../ZTS -TEST_PHP_ARGS="-n -d extension=curl.so -d extension=json.so -d extension=%{buildroot}%{php_ztsextdir}/%{pecl_name}.so" \ +TEST_PHP_ARGS="$OPT -d extension=%{buildroot}%{php_ztsextdir}/%{pecl_name}.so" \ REPORT_EXIT_STATUS=1 \ NO_INTERACTION=1 \ TEST_PHP_EXECUTABLE=%{__ztsphp} \ @@ -273,6 +260,9 @@ TEST_PHP_EXECUTABLE=%{__ztsphp} \ %changelog +* Wed Sep 9 2020 Remi Collet - 2.5.1-0 +- test build for upcoming 2.5.1 + * Tue Sep 03 2019 Remi Collet - 2.5.0-3 - rebuild for 7.4.0RC1 -- cgit