From 5f982d7fd761b61b46cc967d412b1ab27b57a3e0 Mon Sep 17 00:00:00 2001 From: Remi Collet Date: Fri, 10 Feb 2017 18:21:22 +0100 Subject: php-smbclient: 0.9.0 (stable) --- REFLECTION | 5 +++-- makesrc.sh | 27 --------------------------- php-smbclient.spec | 18 +++++++++++------- smbclient-zts.patch | 49 ------------------------------------------------- 4 files changed, 14 insertions(+), 85 deletions(-) delete mode 100755 makesrc.sh delete mode 100644 smbclient-zts.patch diff --git a/REFLECTION b/REFLECTION index c022792..fcc6bbc 100644 --- a/REFLECTION +++ b/REFLECTION @@ -1,4 +1,4 @@ -Extension [ extension #115 smbclient version 0.9.0-dev ] { +Extension [ extension #123 smbclient version 0.9.0 ] { - Constants [30] { Constant [ integer SMBCLIENT_XATTR_CREATE ] { 1 } @@ -139,9 +139,10 @@ Extension [ extension #115 smbclient version 0.9.0-dev ] { } Function [ function smbclient_read ] { - - Parameters [2] { + - Parameters [3] { Parameter #0 [ $state ] Parameter #1 [ $file ] + Parameter #2 [ $count ] } } Function [ function smbclient_close ] { diff --git a/makesrc.sh b/makesrc.sh deleted file mode 100755 index 24fbf81..0000000 --- a/makesrc.sh +++ /dev/null @@ -1,27 +0,0 @@ -#!/bin/bash - -NAME=$(basename $PWD) -OWNER=$(sed -n '/^%global gh_owner/{s/.* //;p}' $NAME.spec) -PROJECT=$(sed -n '/^%global gh_project/{s/.* //;p}' $NAME.spec) -VERSION=$(sed -n '/^Version:/{s/.* //;p}' $NAME.spec) -COMMIT=$(sed -n '/^%global gh_commit/{s/.* //;p}' $NAME.spec) -SHORT=${COMMIT:0:7} - -echo -e "\nCreate git snapshot\nName=$NAME, Owner=$OWNER, Project=$PROJECT, Version=$VERSION\n" - -echo "Cloning..." -rm -rf $PROJECT-$COMMIT -git clone https://github.com/$OWNER/$PROJECT.git $PROJECT-$COMMIT - -echo "Getting commit..." -pushd $PROJECT-$COMMIT -git checkout $COMMIT -popd - -echo "Archiving..." -tar czf $NAME-$VERSION-$SHORT.tgz --exclude .git $PROJECT-$COMMIT - -echo "Cleaning..." -rm -rf $PROJECT-$COMMIT - -echo "Done." diff --git a/php-smbclient.spec b/php-smbclient.spec index 0498b10..019b831 100644 --- a/php-smbclient.spec +++ b/php-smbclient.spec @@ -17,7 +17,7 @@ %global gh_short %(c=%{gh_commit}; echo ${c:0:7}) %global gh_owner eduardok %global gh_project libsmbclient-php -%global gh_date 20161104 +#global gh_date 20161104 #global prever RC1 %global pecl_name smbclient @@ -35,7 +35,7 @@ Version: 0.9.0 %if 0%{?gh_date} Release: 0.2.%{gh_date}git%{gh_short}%{?dist}%{!?scl:%{!?nophptag:%(%{__php} -r 'echo ".".PHP_MAJOR_VERSION.".".PHP_MINOR_VERSION;')}} %else -Release: 2%{?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 Summary: PHP wrapper for libsmbclient @@ -52,8 +52,6 @@ Source0: http://pecl.php.net/get/%{pecl_name}-%{version}%{?prever}.tgz Source2: %{gh_project}-phpunit.xml %endif -Patch0: %{pecl_name}-zts.patch - BuildRequires: %{?scl_prefix}php-devel BuildRequires: %{?scl_prefix}php-pear BuildRequires: libsmbclient-devel > 3.6 @@ -69,9 +67,10 @@ Requires: %{?scl_prefix}php(api) = %{php_core_api} Obsoletes: %{?sub_prefix}php-libsmbclient < 0.8.0-0.2 Provides: %{?sub_prefix}php-libsmbclient = %{version}-%{release} Provides: %{?sub_prefix}php-libsmbclient%{?_isa} = %{version}-%{release} -# For more-php56 +%if "%{?scl_prefix}" != "%{?sub_prefix}" Provides: %{?scl_prefix}php-%{pecl_name} = %{version}-%{release} Provides: %{?scl_prefix}php-%{pecl_name}%{?_isa} = %{version}-%{release} +%endif # PECL Provides: %{?scl_prefix}php-pecl-%{pecl_name} = %{version}-%{release} Provides: %{?scl_prefix}php-pecl-%{pecl_name}%{?_isa} = %{version}-%{release} @@ -136,8 +135,6 @@ sed -e 's/role="test"/role="src"/' \ -i package.xml cd NTS -%patch0 -p1 -b .zts - # Check extension version ver=$(sed -n '/define PHP_SMBCLIENT_VERSION/{s/.* "//;s/".*$//;p}' php_smbclient.h) if test "$ver" != "%{version}%{?prever}%{?gh_date:-dev}"; then @@ -159,6 +156,8 @@ cp -pr NTS ZTS %build +%{?dtsenable} + cd NTS %{_bindir}/phpize %configure --with-php-config=%{_bindir}/php-config @@ -173,6 +172,8 @@ make %{?_smp_mflags} %install +%{?dtsenable} + make -C NTS install INSTALL_ROOT=%{buildroot} # install configuration @@ -251,6 +252,9 @@ fi %changelog +* Fri Feb 10 2017 Remi Collet - 0.9.0-1 +- update to 0.9.0 (stable) + * Thu Dec 1 2016 Remi Collet - 0.9.0-0.2.20161104git1857016 - rebuild with PHP 7.1.0 GA diff --git a/smbclient-zts.patch b/smbclient-zts.patch deleted file mode 100644 index 56e8f0c..0000000 --- a/smbclient-zts.patch +++ /dev/null @@ -1,49 +0,0 @@ -From 2f30d7689efcb1e3c1c2f8e495884409a009fae1 Mon Sep 17 00:00:00 2001 -From: Remi Collet -Date: Tue, 8 Nov 2016 13:17:20 +0100 -Subject: [PATCH] fix ZTS build - ---- - php_smbclient.h | 2 +- - smb_streams.c | 2 +- - smbclient.c | 2 +- - 3 files changed, 3 insertions(+), 3 deletions(-) - -diff --git a/php_smbclient.h b/php_smbclient.h -index ee6c936..34f7aa5 100644 ---- a/php_smbclient.h -+++ b/php_smbclient.h -@@ -133,6 +133,6 @@ php_smbclient_state * php_smbclient_state_new (php_stream_context *context, int - void php_smbclient_state_free (php_smbclient_state *state TSRMLS_DC); - int php_smbclient_state_init (php_smbclient_state *state TSRMLS_DC); - int flagstring_to_smbflags (const char *flags, int flags_len, int *retval TSRMLS_DC); --void php_smb_pool_cleanup(void); -+void php_smb_pool_cleanup(TSRMLS_D); - - #endif /* PHP_SMBCLIENT_H */ -diff --git a/smb_streams.c b/smb_streams.c -index 454708b..b6f73c6 100644 ---- a/smb_streams.c -+++ b/smb_streams.c -@@ -149,7 +149,7 @@ static void php_smb_pool_drop(php_smbclient_state *state TSRMLS_DC) - } - } - --void php_smb_pool_cleanup(void) { -+void php_smb_pool_cleanup(TSRMLS_D) { - struct _php_smb_pool *pool; - - pool = SMBCLIENT_G(pool_first); -diff --git a/smbclient.c b/smbclient.c -index e247987..791f078 100644 ---- a/smbclient.c -+++ b/smbclient.c -@@ -491,7 +491,7 @@ PHP_MSHUTDOWN_FUNCTION(smbclient) - - PHP_RSHUTDOWN_FUNCTION(smbclient) - { -- php_smb_pool_cleanup(); -+ php_smb_pool_cleanup(TSRMLS_C); - return SUCCESS; - } - -- cgit