From 05b67243859dd63d0d5115047ee05f47686d745e Mon Sep 17 00:00:00 2001 From: Remi Collet Date: Thu, 17 Sep 2015 09:52:19 +0200 Subject: php-smbclient: cleanup for Fedora review --- php-smbclient-dev.spec | 3 ++- php-smbclient.spec | 63 +++++++++++++++----------------------------------- 2 files changed, 21 insertions(+), 45 deletions(-) diff --git a/php-smbclient-dev.spec b/php-smbclient-dev.spec index b8b467a..652a61d 100644 --- a/php-smbclient-dev.spec +++ b/php-smbclient-dev.spec @@ -96,7 +96,8 @@ Obsoletes: php70w-%{ext_name} <= %{version} %description %{ext_name} is a PHP extension that uses Samba's libsmbclient -library to provide Samba related functions to PHP programs. +library to provide Samba related functions and 'smb' streams +to PHP programs. Package built for PHP %(%{__php} -r 'echo PHP_MAJOR_VERSION.".".PHP_MINOR_VERSION;')%{?scl: as Software Collection (%{scl} by %{scl_vendor})}. diff --git a/php-smbclient.spec b/php-smbclient.spec index b8b467a..ca51ff7 100644 --- a/php-smbclient.spec +++ b/php-smbclient.spec @@ -1,3 +1,6 @@ +# Fedora spec file for php-smbclient +# with SCL compatibility removed, from +# # remirepo spec file for php-smbclient # # Copyright (c) 2015 Remi Collet @@ -6,13 +9,6 @@ # # Please, preserve the changelog entries # -%if 0%{?scl:1} -%if "%{scl}" == "rh-php56" -%global sub_prefix more-php56- -%else -%global sub_prefix %{scl_prefix} -%endif -%endif %global gh_commit 8b9587df1a0859074eae6133c5210451d6527e38 %global gh_short %(c=%{gh_commit}; echo ${c:0:7}) @@ -21,8 +17,6 @@ %global gh_date 20150909 %global prever -rc1 -%{?scl: %scl_package php-smbclient} -%{!?scl: %global pkg_name %{name}} %{!?php_inidir: %global php_inidir %{_sysconfdir}/php.d} %{!?__pecl: %global __pecl %{_bindir}/pecl} %{!?__php: %global __php %{_bindir}/php} @@ -37,55 +31,34 @@ # Test suite requires a Samba server and configuration file %global with_tests 0%{?_with_tests:1} -Name: %{?sub_prefix}php-smbclient +Name: php-smbclient Version: 0.8.0 -Release: 0.2.rc1%{?dist}%{!?scl:%{!?nophptag:%(%{__php} -r 'echo ".".PHP_MAJOR_VERSION.".".PHP_MINOR_VERSION;')}} +Release: 0.3.rc1%{?dist} Summary: PHP wrapper for libsmbclient Group: Development/Languages License: BSD URL: https://github.com/eduardok/libsmbclient-php -Source0: %{pkg_name}-%{version}-%{gh_short}.tgz +Source0: %{name}-%{version}-%{gh_short}.tgz # git snapshot as upstream doesn't provide test suite Source1: makesrc.sh %if %{with_tests} Source2: %{gh_project}-phpunit.xml %endif -BuildRequires: %{?scl_prefix}php-devel +BuildRequires: php-devel BuildRequires: libsmbclient-devel > 3.6 %if %{with_tests} BuildRequires: php-composer(phpunit/phpunit) BuildRequires: samba %endif -Requires: %{?scl_prefix}php(zend-abi) = %{php_zend_api} -Requires: %{?scl_prefix}php(api) = %{php_core_api} -%{?_sclreq:Requires: %{?scl_prefix}runtime%{?_sclreq}%{?_isa}} -# Rename -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} - -%if "%{?vendor}" == "Remi Collet" && 0%{!?scl:1} -# Other third party repo stuff -Obsoletes: php53-%{ext_name} <= %{version} -Obsoletes: php53u-%{ext_name} <= %{version} -Obsoletes: php54-%{ext_name} <= %{version} -Obsoletes: php54w-%{ext_name} <= %{version} -%if "%{php_version}" > "5.5" -Obsoletes: php55u-%{ext_name} <= %{version} -Obsoletes: php55w-%{ext_name} <= %{version} -%endif -%if "%{php_version}" > "5.6" -Obsoletes: php56u-%{ext_name} <= %{version} -Obsoletes: php56w-%{ext_name} <= %{version} -%endif -%if "%{php_version}" > "7.0" -Obsoletes: php70u-%{ext_name} <= %{version} -Obsoletes: php70w-%{ext_name} <= %{version} -%endif -%endif +Requires: php(zend-abi) = %{php_zend_api} +Requires: php(api) = %{php_core_api} +# Rename (and "php -m" reports both smbclient and libsmbclient) +Obsoletes: php-libsmbclient < 0.8.0-0.2 +Provides: php-libsmbclient = %{version}-%{release} +Provides: php-libsmbclient%{?_isa} = %{version}-%{release} %if 0%{?fedora} < 20 && 0%{?rhel} < 7 # Filter private shared @@ -96,9 +69,8 @@ Obsoletes: php70w-%{ext_name} <= %{version} %description %{ext_name} is a PHP extension that uses Samba's libsmbclient -library to provide Samba related functions to PHP programs. - -Package built for PHP %(%{__php} -r 'echo PHP_MAJOR_VERSION.".".PHP_MINOR_VERSION;')%{?scl: as Software Collection (%{scl} by %{scl_vendor})}. +library to provide Samba related functions and 'smb' streams +to PHP programs. %prep @@ -191,10 +163,13 @@ cp %{SOURCE2} phpunit.xml %changelog +* Thu Sep 17 2015 Remi Collet - 0.8.0-0.3.rc1 +- cleanup SCL compatibility for Fedora + * Wed Sep 16 2015 Remi Collet - 0.8.0-0.2.rc1 - update to 0.8.0-rc1 - rename from php-libsmbclient to php-smbclient -- https://github.com/eduardok/libsmbclient-php/pull/26 rename + https://github.com/eduardok/libsmbclient-php/pull/26 * Thu Sep 3 2015 Remi Collet - 0.8.0-0.1.20150909gita65127d - update to 0.8.0-dev -- cgit