summaryrefslogtreecommitdiffstats
path: root/php-smbclient.spec
diff options
context:
space:
mode:
Diffstat (limited to 'php-smbclient.spec')
-rw-r--r--php-smbclient.spec52
1 files changed, 20 insertions, 32 deletions
diff --git a/php-smbclient.spec b/php-smbclient.spec
index 43e7cd5..cf8324c 100644
--- a/php-smbclient.spec
+++ b/php-smbclient.spec
@@ -1,6 +1,6 @@
# remirepo spec file for php-smbclient
#
-# SPDX-FileCopyrightText: Copyright 2015-2025 Remi Collet
+# SPDX-FileCopyrightText: Copyright 2015-2026 Remi Collet
# SPDX-License-Identifier: CECILL-2.1
# http://www.cecill.info/licences/Licence_CeCILL_V2-en.txt
#
@@ -13,30 +13,28 @@
%global pkg_name %{name}
%endif
-%global gh_commit 18570160a5cb427ed4d55a3a4dc4431d2bea6949
-%global gh_short %(c=%{gh_commit}; echo ${c:0:7})
-%global gh_owner eduardok
-%global gh_project libsmbclient-php
-#global prever RC1
-
%global pecl_name smbclient
%global with_zts 0%{!?_without_zts:%{?__ztsphp:1}}
%global ini_name %{pecl_name}.ini
# Test suite requires a Samba server and configuration file
%bcond_with tests
-%global sources %{pecl_name}-%{version}%{?prever}
+%global sources %{gh_proj}-%{version}%{?prever}
%global _configure ../%{sources}/configure
+# Github forge
+%global gh_vend eduardok
+%global gh_proj libsmbclient-php
+%global forgeurl https://github.com/%{gh_vend}/%{gh_proj}
+%global tag %{version}
Name: %{?scl_prefix}php-smbclient
-Version: 1.1.2
-Release: 3%{?dist}%{!?scl:%{!?nophptag:%(%{__php} -r 'echo ".".PHP_MAJOR_VERSION.".".PHP_MINOR_VERSION;')}}
-
Summary: PHP wrapper for libsmbclient
-
License: BSD-2-Clause
-URL: https://github.com/eduardok/libsmbclient-php
-Source0: https://pecl.php.net/get/%{sources}.tgz
+Version: 1.1.2
+Release: 4%{?dist}
+%forgemeta
+URL: %{forgeurl}
+Source0: %{forgesource}
%if %{with tests}
Source2: %{pecl_name}-phpunit.xml
%endif
@@ -46,7 +44,6 @@ Patch0: %{pecl_name}-upstream.patch
BuildRequires: %{?dtsprefix}gcc
BuildRequires: %{?scl_prefix}php-devel
-BuildRequires: %{?scl_prefix}php-pear
BuildRequires: libsmbclient-devel > 3.6
%if %{with tests}
BuildRequires: php-composer(phpunit/phpunit)
@@ -64,6 +61,7 @@ Provides: %{?scl_prefix}php-pecl-%{pecl_name} = %{version}-%{rele
Provides: %{?scl_prefix}php-pecl-%{pecl_name}%{?_isa} = %{version}-%{release}
Provides: %{?scl_prefix}php-pecl(%{pecl_name}) = %{version}
Provides: %{?scl_prefix}php-pecl(%{pecl_name})%{?_isa} = %{version}
+# No PIE for now
%description
@@ -77,12 +75,7 @@ Package built for PHP %(%{__php} -r 'echo PHP_MAJOR_VERSION.".".PHP_MINOR_VERSIO
%prep
%setup -q -c
-# Don't install/register tests
-sed -e 's/role="test"/role="src"/' \
- -e '/LICENSE/s/role="doc"/role="src"/' \
- -i package.xml
-
-cd %{sources}
+pushd %{sources}
if [ $(%{__php} -r 'echo PHP_VERSION_ID;') -lt 70000 ]; then
%patch -P0 -p1 -R -b .up
fi
@@ -93,7 +86,7 @@ if test "$ver" != "%{version}%{?prever}"; then
: Error: Upstream VERSION version is ${ver}, expecting %{version}%{?prever}.
exit 1
fi
-cd ..
+popd
cat << 'EOF' | tee %{ini_name}
; Enable %{summary} extension module
@@ -134,19 +127,11 @@ cd ../ZTS
# install configuration
install -Dpm 644 %{ini_name} %{buildroot}%{php_inidir}/%{ini_name}
-# Install XML package description
-install -D -m 644 package.xml %{buildroot}%{pecl_xmldir}/%{name}.xml
-
%if %{with_zts}
%make_install -C ZTS
install -Dpm 644 %{ini_name} %{buildroot}%{php_ztsinidir}/%{ini_name}
%endif
-# Documentation
-for i in $(grep 'role="doc"' package.xml | sed -e 's/^.*name="//;s/".*$//')
-do install -Dpm 644 %{sources}/$i %{buildroot}%{pecl_docdir}/%{pecl_name}/$i
-done
-
%check
: Minimal load test for NTS extension
@@ -174,8 +159,7 @@ cp %{SOURCE2} phpunit.xml
%files
%license %{sources}/LICENSE
-%doc %{pecl_docdir}/%{pecl_name}
-%{pecl_xmldir}/%{name}.xml
+%doc %{sources}/*.md
%config(noreplace) %{php_inidir}/%{ini_name}
%{php_extdir}/%{pecl_name}.so
@@ -187,6 +171,10 @@ cp %{SOURCE2} phpunit.xml
%changelog
+* Thu Mar 26 2026 Remi Collet <remi@remirepo.net> - 1.1.2-4
+- drop pear/pecl dependency
+- sources from github
+
* Thu Sep 25 2025 Remi Collet <remi@remirepo.net> - 1.1.2-3
- rebuild for PHP 8.5.0RC1