From 5fd70c57090e9c9e55659aabee9f41e1fbf3e6f3 Mon Sep 17 00:00:00 2001 From: Remi Collet Date: Fri, 4 Aug 2017 12:45:09 +0200 Subject: v2.0.8 (beta) --- .gitignore | 7 ++ REFLECTION | 302 +++++++++++++++++++++++++++++++++++++++++--------- php-pecl-swoole2.spec | 49 ++++++-- 3 files changed, 295 insertions(+), 63 deletions(-) create mode 100644 .gitignore diff --git a/.gitignore b/.gitignore new file mode 100644 index 0000000..1ab5c4f --- /dev/null +++ b/.gitignore @@ -0,0 +1,7 @@ +package-*.xml +*.tgz +*.tar.gz +*.tar.xz +*.tar.xz.asc +*.src.rpm +*/*rpm diff --git a/REFLECTION b/REFLECTION index c2c8132..18b2cf6 100644 --- a/REFLECTION +++ b/REFLECTION @@ -1,4 +1,4 @@ -Extension [ extension #132 swoole version 2.0.7 ] { +Extension [ extension #137 swoole version 2.0.8 ] { - INI { Entry [ swoole.aio_thread_num ] @@ -63,7 +63,7 @@ Extension [ extension #132 swoole version 2.0.7 ] { Constant [ integer SWOOLE_DTLSv1_CLIENT_METHOD ] { 17 } Constant [ integer SWOOLE_EVENT_READ ] { 512 } Constant [ integer SWOOLE_EVENT_WRITE ] { 1024 } - Constant [ string SWOOLE_VERSION ] { 2.0.7 } + Constant [ string SWOOLE_VERSION ] { 2.0.8 } Constant [ integer SWOOLE_REDIS_MODE_MULTI ] { 0 } Constant [ integer SWOOLE_REDIS_MODE_PIPELINE ] { 1 } Constant [ integer SWOOLE_REDIS_TYPE_NOT_FOUND ] { 0 } @@ -226,6 +226,12 @@ Extension [ extension #132 swoole version 2.0.7 ] { Parameter #1 [ $content ] } } + Function [ function swoole_async_dns_lookup_coro ] { + + - Parameters [1] { + Parameter #0 [ $domain_name ] + } + } Function [ function swoole_client_select ] { - Parameters [4] { @@ -266,11 +272,9 @@ Extension [ extension #132 swoole version 2.0.7 ] { - Parameters [0] { } } - Function [ function swoole_load_module ] { - } } - - Classes [35] { + - Classes [34] { Class [ class Swoole\Server ] { - Constants [0] { @@ -285,7 +289,7 @@ Extension [ extension #132 swoole version 2.0.7 ] { - Properties [0] { } - - Methods [38] { + - Methods [39] { Method [ public method __construct ] { - Parameters [4] { @@ -296,6 +300,12 @@ Extension [ extension #132 swoole version 2.0.7 ] { } } + Method [ public method __destruct ] { + + - Parameters [0] { + } + } + Method [ public method listen ] { - Parameters [3] { @@ -379,10 +389,11 @@ Extension [ extension #132 swoole version 2.0.7 ] { Method [ public method sendfile ] { - - Parameters [3] { + - Parameters [4] { Parameter #0 [ $conn_fd ] Parameter #1 [ $filename ] Parameter #2 [ $offset ] + Parameter #3 [ $length ] } } @@ -708,7 +719,7 @@ Extension [ extension #132 swoole version 2.0.7 ] { - Static properties [0] { } - - Static methods [6] { + - Static methods [7] { Method [ static public method read ] { - Parameters [4] { @@ -755,6 +766,13 @@ Extension [ extension #132 swoole version 2.0.7 ] { } } + Method [ static public method dnsLookupCoro ] { + + - Parameters [1] { + Parameter #0 [ $domain_name ] + } + } + Method [ static public method set ] { - Parameters [1] { @@ -1038,9 +1056,10 @@ Extension [ extension #132 swoole version 2.0.7 ] { Method [ public method sendfile ] { - - Parameters [2] { + - Parameters [3] { Parameter #0 [ $filename ] Parameter #1 [ $offset ] + Parameter #2 [ $length ] } } @@ -1157,50 +1176,114 @@ Extension [ extension #132 swoole version 2.0.7 ] { Property [ public $sock ] } - - Methods [15] { + - Methods [16] { Method [ public method __construct ] { + + - Parameters [1] { + Parameter #0 [ $type ] + } } Method [ public method __destruct ] { + + - Parameters [0] { + } } Method [ public method set ] { + + - Parameters [1] { + Parameter #0 [ array $settings ] + } } Method [ public method connect ] { + + - Parameters [3] { + Parameter #0 [ $host ] + Parameter #1 [ $port ] + Parameter #2 [ $timeout ] + } } Method [ public method recv ] { + + - Parameters [0] { + } } Method [ public method send ] { + + - Parameters [2] { + Parameter #0 [ $data ] + Parameter #1 [ $flag ] + } } Method [ public method sendfile ] { + + - Parameters [3] { + Parameter #0 [ $filename ] + Parameter #1 [ $offset ] + Parameter #2 [ $length ] + } } Method [ public method sendto ] { + + - Parameters [3] { + Parameter #0 [ $ip ] + Parameter #1 [ $port ] + Parameter #2 [ $data ] + } } Method [ public method enableSSL ] { + + - Parameters [0] { + } } Method [ public method getPeerCert ] { + + - Parameters [0] { + } } Method [ public method verifyPeerCert ] { + + - Parameters [0] { + } } Method [ public method isConnected ] { + + - Parameters [0] { + } } Method [ public method getsockname ] { + + - Parameters [0] { + } } Method [ public method getpeername ] { + + - Parameters [0] { + } } Method [ public method close ] { + + - Parameters [0] { + } + } + + Method [ public method getSocket ] { + + - Parameters [0] { + } } } } @@ -1221,7 +1304,7 @@ Extension [ extension #132 swoole version 2.0.7 ] { Property [ public $errMsg ] } - - Methods [148] { + - Methods [151] { Method [ public method __construct ] { } @@ -1665,6 +1748,15 @@ Extension [ extension #132 swoole version 2.0.7 ] { Method [ public method exec ] { } + + Method [ public method eval ] { + } + + Method [ public method evalSha ] { + } + + Method [ public method script ] { + } } } @@ -1949,12 +2041,13 @@ Extension [ extension #132 swoole version 2.0.7 ] { Method [ public method addFile ] { - - Parameters [5] { + - Parameters [6] { Parameter #0 [ $path ] Parameter #1 [ $name ] Parameter #2 [ $type ] Parameter #3 [ $filename ] Parameter #4 [ $offset ] + Parameter #5 [ $length ] } } @@ -2110,7 +2203,7 @@ Extension [ extension #132 swoole version 2.0.7 ] { Method [ public method useQueue ] { - Parameters [2] { - Parameter #0 [ $key ] + Parameter #0 [ $key ] Parameter #1 [ $mode ] } } @@ -2247,8 +2340,9 @@ Extension [ extension #132 swoole version 2.0.7 ] { Method [ public method get ] { - - Parameters [1] { + - Parameters [2] { Parameter #0 [ $key ] + Parameter #1 [ $field ] } } @@ -2267,8 +2361,9 @@ Extension [ extension #132 swoole version 2.0.7 ] { Method [ public method exist ] { - - Parameters [1] { + - Parameters [2] { Parameter #0 [ $key ] + Parameter #1 [ $field ] } } @@ -2324,7 +2419,12 @@ Extension [ extension #132 swoole version 2.0.7 ] { Class [ class Swoole\Lock ] { - - Constants [0] { + - Constants [5] { + Constant [ integer FILELOCK ] { 2 } + Constant [ integer MUTEX ] { 3 } + Constant [ integer SEM ] { 4 } + Constant [ integer RWLOCK ] { 1 } + Constant [ integer SPINLOCK ] { 5 } } - Static properties [0] { @@ -2336,7 +2436,7 @@ Extension [ extension #132 swoole version 2.0.7 ] { - Properties [0] { } - - Methods [7] { + - Methods [8] { Method [ public method __construct ] { - Parameters [2] { @@ -2357,6 +2457,13 @@ Extension [ extension #132 swoole version 2.0.7 ] { } } + Method [ public method lockwait ] { + + - Parameters [1] { + Parameter #0 [ $timeout ] + } + } + Method [ public method trylock ] { - Parameters [0] { @@ -2397,7 +2504,7 @@ Extension [ extension #132 swoole version 2.0.7 ] { - Properties [0] { } - - Methods [6] { + - Methods [8] { Method [ public method __construct ] { - Parameters [1] { @@ -2432,6 +2539,20 @@ Extension [ extension #132 swoole version 2.0.7 ] { } } + Method [ public method wait ] { + + - Parameters [1] { + Parameter #0 [ $timeout ] + } + } + + Method [ public method wakeup ] { + + - Parameters [1] { + Parameter #0 [ $count ] + } + } + Method [ public method cmpset ] { - Parameters [2] { @@ -2457,7 +2578,7 @@ Extension [ extension #132 swoole version 2.0.7 ] { Property [ private $global ] } - - Methods [38] { + - Methods [39] { Method [ public method on ] { - Parameters [2] { @@ -2482,6 +2603,12 @@ Extension [ extension #132 swoole version 2.0.7 ] { } } + Method [ public method __destruct ] { + + - Parameters [0] { + } + } + Method [ public method listen ] { - Parameters [3] { @@ -2551,10 +2678,11 @@ Extension [ extension #132 swoole version 2.0.7 ] { Method [ public method sendfile ] { - - Parameters [3] { + - Parameters [4] { Parameter #0 [ $conn_fd ] Parameter #1 [ $filename ] Parameter #2 [ $offset ] + Parameter #3 [ $length ] } } @@ -2767,7 +2895,7 @@ Extension [ extension #132 swoole version 2.0.7 ] { - Properties [0] { } - - Methods [10] { + - Methods [11] { Method [ public method initHeader ] { - Parameters [0] { @@ -2823,6 +2951,15 @@ Extension [ extension #132 swoole version 2.0.7 ] { } } + Method [ public method trailer ] { + + - Parameters [3] { + Parameter #0 [ $key ] + Parameter #1 [ $value ] + Parameter #2 [ $ucwords ] + } + } + Method [ public method write ] { - Parameters [1] { @@ -2839,9 +2976,10 @@ Extension [ extension #132 swoole version 2.0.7 ] { Method [ public method sendfile ] { - - Parameters [2] { + - Parameters [3] { Parameter #0 [ $filename ] Parameter #1 [ $offset ] + Parameter #2 [ $length ] } } @@ -2999,7 +3137,7 @@ Extension [ extension #132 swoole version 2.0.7 ] { - Properties [0] { } - - Methods [39] { + - Methods [40] { Method [ public method on ] { - Parameters [2] { @@ -3041,6 +3179,12 @@ Extension [ extension #132 swoole version 2.0.7 ] { } } + Method [ public method __destruct ] { + + - Parameters [0] { + } + } + Method [ public method listen ] { - Parameters [3] { @@ -3103,10 +3247,11 @@ Extension [ extension #132 swoole version 2.0.7 ] { Method [ public method sendfile ] { - - Parameters [3] { + - Parameters [4] { Parameter #0 [ $conn_fd ] Parameter #1 [ $filename ] Parameter #2 [ $offset ] + Parameter #3 [ $length ] } } @@ -3325,7 +3470,13 @@ Extension [ extension #132 swoole version 2.0.7 ] { Class [ class Swoole\MySQL ] { - - Constants [0] { + - Constants [6] { + Constant [ integer STATE_QUERY ] { 0 } + Constant [ integer STATE_READ_START ] { 1 } + Constant [ integer STATE_READ_FIELD ] { 2 } + Constant [ integer STATE_READ_ROW ] { 3 } + Constant [ integer STATE_READ_END ] { 4 } + Constant [ integer STATE_CLOSED ] { 5 } } - Static properties [0] { @@ -3334,10 +3485,14 @@ Extension [ extension #132 swoole version 2.0.7 ] { - Static methods [0] { } - - Properties [0] { + - Properties [4] { + Property [ public $errno ] + Property [ public $connect_errno ] + Property [ public $insert_id ] + Property [ public $affected_rows ] } - - Methods [8] { + - Methods [11] { Method [ public method __construct ] { - Parameters [0] { @@ -3358,6 +3513,27 @@ Extension [ extension #132 swoole version 2.0.7 ] { } } + Method [ public method begin ] { + + - Parameters [1] { + Parameter #0 [ $callback ] + } + } + + Method [ public method commit ] { + + - Parameters [1] { + Parameter #0 [ $callback ] + } + } + + Method [ public method rollback ] { + + - Parameters [1] { + Parameter #0 [ $callback ] + } + } + Method [ public method escape ] { - Parameters [2] { @@ -3374,13 +3550,13 @@ Extension [ extension #132 swoole version 2.0.7 ] { } } - Method [ public method getBuffer ] { + Method [ public method close ] { - Parameters [0] { } } - Method [ public method close ] { + Method [ public method getState ] { - Parameters [0] { } @@ -3453,24 +3629,6 @@ Extension [ extension #132 swoole version 2.0.7 ] { } } - Class [ class Swoole\Module ] { - - - Constants [0] { - } - - - Static properties [0] { - } - - - Static methods [0] { - } - - - Properties [0] { - } - - - Methods [0] { - } - } - Class [ class Swoole\Mmap ] { - Constants [0] { @@ -3568,7 +3726,7 @@ Extension [ extension #132 swoole version 2.0.7 ] { Property [ public $reuseCount ] } - - Methods [30] { + - Methods [33] { Method [ public method __construct ] { } @@ -3599,6 +3757,15 @@ Extension [ extension #132 swoole version 2.0.7 ] { Method [ public method onClose ] { } + Method [ public method openStream ] { + } + + Method [ public method push ] { + } + + Method [ public method closeStream ] { + } + Method [ public method set ] { - Parameters [1] { @@ -3641,9 +3808,10 @@ Extension [ extension #132 swoole version 2.0.7 ] { Method [ public method sendfile ] { - - Parameters [2] { + - Parameters [3] { Parameter #0 [ $filename ] Parameter #1 [ $offset ] + Parameter #2 [ $length ] } } @@ -3793,7 +3961,12 @@ Extension [ extension #132 swoole version 2.0.7 ] { Class [ class Swoole\Redis ] { - - Constants [0] { + - Constants [5] { + Constant [ integer STATE_CONNECT ] { 0 } + Constant [ integer STATE_READY ] { 1 } + Constant [ integer STATE_WAIT_RESULT ] { 2 } + Constant [ integer STATE_SUBSCRIBE ] { 3 } + Constant [ integer STATE_CLOSED ] { 4 } } - Static properties [0] { @@ -3805,11 +3978,18 @@ Extension [ extension #132 swoole version 2.0.7 ] { - Properties [0] { } - - Methods [6] { + - Methods [7] { Method [ public method __construct ] { + + - Parameters [1] { + Parameter #0 [ array or NULL $setting ] + } } Method [ public method __destruct ] { + + - Parameters [0] { + } } Method [ public method on ] { @@ -3830,6 +4010,15 @@ Extension [ extension #132 swoole version 2.0.7 ] { } Method [ public method close ] { + + - Parameters [0] { + } + } + + Method [ public method getState ] { + + - Parameters [0] { + } } Method [ public method __call ] { @@ -3870,7 +4059,7 @@ Extension [ extension #132 swoole version 2.0.7 ] { - Properties [0] { } - - Methods [39] { + - Methods [40] { Method [ public method start ] { - Parameters [0] { @@ -3897,6 +4086,12 @@ Extension [ extension #132 swoole version 2.0.7 ] { } } + Method [ public method __destruct ] { + + - Parameters [0] { + } + } + Method [ public method listen ] { - Parameters [3] { @@ -3974,10 +4169,11 @@ Extension [ extension #132 swoole version 2.0.7 ] { Method [ public method sendfile ] { - - Parameters [3] { + - Parameters [4] { Parameter #0 [ $conn_fd ] Parameter #1 [ $filename ] Parameter #2 [ $offset ] + Parameter #3 [ $length ] } } diff --git a/php-pecl-swoole2.spec b/php-pecl-swoole2.spec index 43c157d..472e1b7 100644 --- a/php-pecl-swoole2.spec +++ b/php-pecl-swoole2.spec @@ -30,8 +30,8 @@ Summary: PHP's asynchronous concurrent distributed networking framework Name: %{?sub_prefix}php-pecl-%{pecl_name}2 -Version: 2.0.7 -Release: 3%{?dist}%{!?scl:%{!?nophptag:%(%{__php} -r 'echo ".".PHP_MAJOR_VERSION.".".PHP_MINOR_VERSION;')}} +Version: 2.0.8 +Release: 1%{?dist}%{!?scl:%{!?nophptag:%(%{__php} -r 'echo ".".PHP_MAJOR_VERSION.".".PHP_MINOR_VERSION;')}} License: BSD Group: Development/Languages URL: http://pecl.php.net/package/%{pecl_name} @@ -68,8 +68,6 @@ Provides: %{?scl_prefix}php-pecl-%{pecl_name}2%{?_isa} = %{version}-%{rele # Single version can be installed Conflicts: %{?sub_prefix}php-pecl-%{pecl_name} < 2 Conflicts: %{?scl_prefix}php-pecl-%{pecl_name} < 2 -# Package have been renamed -Obsoletes: %{?sub_prefix}php-pecl-%{pecl_name} > 2 %if "%{?vendor}" == "Remi Collet" && 0%{!?scl:1} && 0%{?rhel} # Other third party repo stuff @@ -128,13 +126,26 @@ Documentation: https://rawgit.com/tchiotludo/swoole-ide-helper/english/docs/ Package built for PHP %(%{__php} -r 'echo PHP_MAJOR_VERSION.".".PHP_MINOR_VERSION;')%{?scl: as Software Collection (%{scl} by %{?scl_vendor}%{!?scl_vendor:rh})}. +%package devel +Summary: %{name} developer files (header) +Group: Development/Libraries +Requires: %{name}%{?_isa} = %{version}-%{release} +Requires: %{?scl_prefix}php-devel%{?_isa} +%if "%{?scl_prefix}" != "%{?sub_prefix}" +Provides: %{?scl_prefix}php-pecl-%{pecl_name}-devel = %{version}-%{release} +Provides: %{?scl_prefix}php-pecl-%{pecl_name}-devel%{?_isa} = %{version}-%{release} +%endif + +%description devel +These are the files needed to compile programs using %{name}. + + %prep %setup -q -c mv %{pecl_name}-%{version} NTS # Don't install/register tests, install examples as doc -sed -e 's/role="test"/role="src"/' \ - -e '/examples/s/role="src"/role="doc"/' \ +sed -e '/examples/s/role="src"/role="doc"/' \ %{?_licensedir:-e '/LICENSE/s/role="doc"/role="src"/' } \ -i package.xml @@ -175,7 +186,6 @@ peclbuild() { %configure \ --with-swoole \ --enable-sockets \ - --enable-ringbuffer \ %if %{with_hiredis} --enable-async-redis \ %endif @@ -222,7 +232,10 @@ make -C ZTS \ install -D -m 644 %{ini_name} %{buildroot}%{php_ztsinidir}/%{ini_name} %endif -# Documentation +# Test and Documentation +for i in $(grep 'role="test"' package.xml | sed -e 's/^.*name="//;s/".*$//') +do install -Dpm 644 NTS/$i %{buildroot}%{pecl_testdir}/%{pecl_name}/$i +done for i in $(grep 'role="doc"' package.xml | sed -e 's/^.*name="//;s/".*$//') do install -Dpm 644 NTS/$i %{buildroot}%{pecl_docdir}/%{pecl_name}/$i done @@ -270,7 +283,9 @@ cd ../ZTS %files %{?_licensedir:%license NTS/LICENSE} -%doc %{pecl_docdir}/%{pecl_name} +%{!?_licensedir:%{pecl_docdir}/%{pecl_name}/LICENSE} +%doc %{pecl_docdir}/%{pecl_name}/*md +%doc %{pecl_docdir}/%{pecl_name}/CREDITS %{pecl_xmldir}/%{name}.xml %config(noreplace) %{php_inidir}/%{ini_name} @@ -282,7 +297,21 @@ cd ../ZTS %endif +%files devel +%doc %{pecl_testdir}/%{pecl_name} +%doc %{pecl_docdir}/%{pecl_name}/examples +%{php_incldir}/ext/%{pecl_name} + +%if %{with_zts} +%{php_ztsincldir}/ext/%{pecl_name} +%endif + + %changelog +* Fri Aug 4 2017 Remi Collet - 2.0.8-1 +- Update to 2.0.8 (beta) +- add devel sub-package + * Tue Jul 18 2017 Remi Collet - 2.0.7-3 - rebuild for PHP 7.2.0beta1 new API @@ -290,7 +319,7 @@ cd ../ZTS - fix release * Fri Mar 17 2017 Remi Collet - 2.0.7-1 -- Update to 2.0.7 +- Update to 2.0.7 (beta) - rename to php-pecl-swoole2 * Mon Mar 6 2017 Remi Collet - 2.0.6-3 -- cgit