diff options
-rw-r--r-- | PHPINFO | 2 | ||||
-rw-r--r-- | REFLECTION | 35 | ||||
-rw-r--r-- | php-pecl-xattr.spec | 160 |
3 files changed, 83 insertions, 114 deletions
@@ -2,4 +2,4 @@ xattr xattr support => enabled -PECL module version => 1.3.1 +PECL module version => 1.4.0 @@ -1,4 +1,4 @@ -Extension [ <persistent> extension #99 xattr version 1.3.1 ] { +Extension [ <persistent> extension #99 xattr version 1.4.0 ] { - Constants [9] { Constant [ int XATTR_CREATE ] { 1 } @@ -16,41 +16,46 @@ Extension [ <persistent> extension #99 xattr version 1.3.1 ] { Function [ <internal:xattr> function xattr_set ] { - Parameters [4] { - Parameter #0 [ <required> $path ] - Parameter #1 [ <required> $name ] - Parameter #2 [ <required> $value ] - Parameter #3 [ <optional> $flags ] + Parameter #0 [ <required> string $path ] + Parameter #1 [ <required> string $name ] + Parameter #2 [ <required> string $value ] + Parameter #3 [ <optional> int $flag ] } + - Return [ bool ] } Function [ <internal:xattr> function xattr_get ] { - Parameters [3] { - Parameter #0 [ <required> $path ] - Parameter #1 [ <required> $name ] - Parameter #2 [ <optional> $flags ] + Parameter #0 [ <required> string $path ] + Parameter #1 [ <required> string $name ] + Parameter #2 [ <optional> int $flags ] } + - Return [ string ] } Function [ <internal:xattr> function xattr_remove ] { - Parameters [3] { - Parameter #0 [ <required> $path ] - Parameter #1 [ <required> $name ] - Parameter #2 [ <optional> $flags ] + Parameter #0 [ <required> string $path ] + Parameter #1 [ <required> string $name ] + Parameter #2 [ <optional> int $flags ] } + - Return [ bool ] } Function [ <internal:xattr> function xattr_list ] { - Parameters [2] { - Parameter #0 [ <required> $path ] - Parameter #1 [ <optional> $flags ] + Parameter #0 [ <required> string $path ] + Parameter #1 [ <optional> int $flags ] } + - Return [ array ] } Function [ <internal:xattr> function xattr_supported ] { - Parameters [2] { - Parameter #0 [ <required> $path ] - Parameter #1 [ <optional> $flags ] + Parameter #0 [ <required> string $path ] + Parameter #1 [ <optional> int $flags ] } + - Return [ bool ] } } } diff --git a/php-pecl-xattr.spec b/php-pecl-xattr.spec index 168a522..8998924 100644 --- a/php-pecl-xattr.spec +++ b/php-pecl-xattr.spec @@ -1,39 +1,34 @@ # remirepo spec file for php-pecl-xattr # -# Copyright (c) 2013-2020 Remi Collet -# License: CC-BY-SA +# Copyright (c) 2013-2024 Remi Collet +# License: CC-BY-SA-4.0 # http://creativecommons.org/licenses/by-sa/4.0/ # # Please, preserve the changelog entries # -%if 0%{?scl:1} -%global sub_prefix %{scl_prefix} -%scl_package php-pecl-xattr -%endif +%{?scl:%scl_package php-pecl-xattr} -%global pecl_name xattr -%global with_zts 0%{!?_without_zts:%{?__ztsphp:1}} -%if "%{php_version}" < "5.6" -%global ini_name %{pecl_name}.ini -%else -%global ini_name 40-%{pecl_name}.ini -%endif +%global pecl_name xattr +%global with_zts 0%{!?_without_zts:%{?__ztsphp:1}} +%global ini_name 40-%{pecl_name}.ini +%global sources %{pecl_name}-%{version} +%global _configure ../%{sources}/configure Summary: Extended attributes -Name: %{?sub_prefix}php-pecl-%{pecl_name} -Version: 1.3.1 -Release: 1%{?dist}%{!?scl:%{!?nophptag:%(%{__php} -r 'echo ".".PHP_MAJOR_VERSION.".".PHP_MINOR_VERSION;')}} -License: PHP +Name: %{?scl_prefix}php-pecl-%{pecl_name} +Version: 1.4.0 +Release: 7%{?dist}%{!?scl:%{!?nophptag:%(%{__php} -r 'echo ".".PHP_MAJOR_VERSION.".".PHP_MINOR_VERSION;')}} +License: PHP-3.01 URL: https://pecl.php.net/package/%{pecl_name} -Source0: https://pecl.php.net/get/%{pecl_name}-%{version}%{?prever}.tgz +Source0: https://pecl.php.net/get/%{sources}.tgz BuildRequires: %{?dtsprefix}gcc -BuildRequires: %{?scl_prefix}php-devel -BuildRequires: %{?scl_prefix}php-pear +BuildRequires: make +BuildRequires: %{?scl_prefix}php-devel >= 7.2 +BuildRequires: %{?scl_prefix}php-pear >= 1.10 Requires: %{?scl_prefix}php(zend-abi) = %{php_zend_api} Requires: %{?scl_prefix}php(api) = %{php_core_api} -%{?_sclreq:Requires: %{?scl_prefix}runtime%{?_sclreq}%{?_isa}} Provides: %{?scl_prefix}php-%{pecl_name} = %{version} Provides: %{?scl_prefix}php-%{pecl_name}%{?_isa} = %{version} @@ -42,28 +37,6 @@ Provides: %{?scl_prefix}php-pecl(%{pecl_name})%{?_isa} = %{version} Provides: %{?scl_prefix}php-pecl-%{pecl_name} = %{version}-%{release} Provides: %{?scl_prefix}php-pecl-%{pecl_name}%{?_isa} = %{version}-%{release} -%if "%{?vendor}" == "Remi Collet" && 0%{!?scl:1} && 0%{?rhel} -# Other third party repo stuff -%if "%{php_version}" > "7.2" -Obsoletes: php72u-pecl-%{pecl_name} <= %{version} -Obsoletes: php72w-pecl-%{pecl_name} <= %{version} -%endif -%if "%{php_version}" > "7.3" -Obsoletes: php73-pecl-%{pecl_name} <= %{version} -Obsoletes: php73w-pecl-%{pecl_name} <= %{version} -%endif -%if "%{php_version}" > "7.4" -Obsoletes: php74-pecl-%{pecl_name} <= %{version} -Obsoletes: php74w-pecl-%{pecl_name} <= %{version} -%endif -%endif - -%if 0%{?fedora} < 20 && 0%{?rhel} < 7 -# Filter private shared object -%{?filter_provides_in: %filter_provides_in %{_libdir}/.*\.so$} -%{?filter_setup} -%endif - %description This package allows to manipulate extended attributes on filesystems @@ -77,13 +50,10 @@ Package built for PHP %(%{__php} -r 'echo PHP_MAJOR_VERSION.".".PHP_MINOR_VERSIO # Don't install/register tests sed -e 's/role="test"/role="src"/' \ - %{?_licensedir:-e '/LICENSE/s/role="doc"/role="src"/' } \ + -e '/LICENSE/s/role="doc"/role="src"/' \ -i package.xml -mv %{pecl_name}-%{version}%{?prever} NTS - -cd NTS - +cd %{sources} # Sanity check, really often broken extver=$(sed -n '/#define PHP_XATTR_VERSION/{s/.* "//;s/".*$//;p}' php_xattr.h) if test "x${extver}" != "x%{version}%{?prever}"; then @@ -92,10 +62,7 @@ if test "x${extver}" != "x%{version}%{?prever}"; then fi cd .. -%if %{with_zts} -# Duplicate source tree for NTS / ZTS build -cp -pr NTS ZTS -%endif +mkdir NTS ZTS # Create configuration file cat > %{ini_name} << 'EOF' @@ -107,29 +74,32 @@ EOF %build %{?dtsenable} -cd NTS -%{_bindir}/phpize +cd %{sources} +%{__phpize} +[ -f Makefile.global ] && GLOBAL=Makefile.global || GLOBAL=build/Makefile.global +sed -e 's/INSTALL_ROOT/DESTDIR/' -i $GLOBAL + +cd ../NTS %configure \ --with-libdir=%{_lib} \ - --with-php-config=%{_bindir}/php-config + --with-php-config=%{__phpconfig} -make %{?_smp_mflags} +%make_build %if %{with_zts} cd ../ZTS -%{_bindir}/zts-phpize %configure \ --with-libdir=%{_lib} \ - --with-php-config=%{_bindir}/zts-php-config + --with-php-config=%{__ztsphpconfig} -make %{?_smp_mflags} +%make_build %endif %install %{?dtsenable} -make -C NTS install INSTALL_ROOT=%{buildroot} +%make_install -C NTS # install config file install -D -m 644 %{ini_name} %{buildroot}%{php_inidir}/%{ini_name} @@ -138,69 +108,41 @@ install -D -m 644 %{ini_name} %{buildroot}%{php_inidir}/%{ini_name} install -D -m 644 package.xml %{buildroot}%{pecl_xmldir}/%{name}.xml %if %{with_zts} -make -C ZTS install INSTALL_ROOT=%{buildroot} +%make_install -C ZTS install -D -m 644 %{ini_name} %{buildroot}%{php_ztsinidir}/%{ini_name} %endif # Documentation -cd NTS +cd %{sources} for i in $(grep 'role="doc"' ../package.xml | sed -e 's/^.*name="//;s/".*$//') do install -Dpm 644 $i %{buildroot}%{pecl_docdir}/%{pecl_name}/$i done -%if 0%{?fedora} < 24 && 0%{?rhel} < 8 -# when pear installed alone, after us -%triggerin -- %{?scl_prefix}php-pear -if [ -x %{__pecl} ] ; then - %{pecl_install} %{pecl_xmldir}/%{name}.xml >/dev/null || : -fi - -# posttrans as pear can be installed after us -%posttrans -if [ -x %{__pecl} ] ; then - %{pecl_install} %{pecl_xmldir}/%{name}.xml >/dev/null || : -fi - -%postun -if [ $1 -eq 0 -a -x %{__pecl} ] ; then - %{pecl_uninstall} %{pecl_name} >/dev/null || : -fi -%endif - - %check -cd NTS +cd %{sources} + : Minimal load test for NTS extension -%{_bindir}/php --no-php-ini \ +%{__php} --no-php-ini \ --define extension=%{buildroot}%{php_extdir}/%{pecl_name}.so \ - --modules | grep %{pecl_name} + --modules | grep '^%{pecl_name}$' : Upstream test suite for NTS extension TEST_PHP_EXECUTABLE=%{__php} \ -TEST_PHP_ARGS="-n -d extension=$PWD/modules/%{pecl_name}.so" \ -NO_INTERACTION=1 \ -REPORT_EXIT_STATUS=1 \ -%{__php} -n run-tests.php --show-diff +TEST_PHP_ARGS="-n -d extension=%{buildroot}%{php_extdir}/%{pecl_name}.so" \ +%{__php} -n run-tests.php -q --show-diff %if %{with_zts} cd ../ZTS : Minimal load test for ZTS extension %{__ztsphp} --no-php-ini \ --define extension=%{buildroot}%{php_ztsextdir}/%{pecl_name}.so \ - --modules | grep %{pecl_name} - -: Upstream test suite for ZTS extension -TEST_PHP_EXECUTABLE=%{_bindir}/zts-php \ -TEST_PHP_ARGS="-n -d extension=$PWD/modules/%{pecl_name}.so" \ -NO_INTERACTION=1 \ -REPORT_EXIT_STATUS=1 \ -%{_bindir}/zts-php -n run-tests.php --show-diff + --modules | grep '^%{pecl_name}$' %endif %files -%{?_licensedir:%license NTS/LICENSE} +%license %{sources}/LICENSE %doc %{pecl_docdir}/%{pecl_name} %{pecl_xmldir}/%{name}.xml @@ -214,6 +156,28 @@ REPORT_EXIT_STATUS=1 \ %changelog +* Wed Aug 30 2023 Remi Collet <remi@remirepo.net> - 1.4.0-7 +- rebuild for PHP 8.3.0RC1 + +* Thu Sep 1 2022 Remi Collet <remi@remirepo.net> - 1.4.0-6 +- rebuild for PHP 8.2.0RC1 + +* Wed Sep 01 2021 Remi Collet <remi@remirepo.net> - 1.4.0-5 +- rebuild for 8.1.0RC1 + +* Wed Sep 30 2020 Remi Collet <remi@remirepo.net> - 1.4.0-4 +- rebuild for PHP 8.0.0RC1 + +* Wed Sep 2 2020 Remi Collet <remi@remirepo.net> - 1.4.0-3 +- rebuild for PHP 8.0.0beta3 + +* Wed Aug 5 2020 Remi Collet <remi@remirepo.net> - 1.4.0-2 +- rebuild for 8.0.0beta1 + +* Fri Apr 24 2020 Remi Collet <remi@remirepo.net> - 1.4.0-1 +- update to 1.4.0 +- raise dependency on PHP 7.2 + * Wed Apr 22 2020 Remi Collet <remi@remirepo.net> - 1.3.1-1 - update to 1.3.1 |