From 8ddc4aa188cd1ba114d0159fc497f3731157c4c7 Mon Sep 17 00:00:00 2001 From: Remi Collet Date: Thu, 22 Feb 2024 12:32:38 +0100 Subject: update to 0.3.0RC1 drop support for PHP 5 and 7 --- PHPINFO | 2 +- REFLECTION | 45 ++++++++++++++++++++++++++------------------- php-pecl-dio.spec | 43 +++++++++++++++++++------------------------ 3 files changed, 46 insertions(+), 44 deletions(-) diff --git a/PHPINFO b/PHPINFO index 98eaad1..1773ad3 100644 --- a/PHPINFO +++ b/PHPINFO @@ -2,4 +2,4 @@ dio dio support => enabled -version => 0.2.2 +version => 0.3.0RC1 diff --git a/REFLECTION b/REFLECTION index 106d247..55930c6 100644 --- a/REFLECTION +++ b/REFLECTION @@ -1,4 +1,4 @@ -Extension [ extension #64 dio version 0.2.2 ] { +Extension [ extension #64 dio version 0.3.0RC1 ] { - Constants [36] { Constant [ int O_RDONLY ] { 0 } @@ -43,9 +43,9 @@ Extension [ extension #64 dio version 0.2.2 ] { Function [ function dio_open ] { - Parameters [3] { - Parameter #0 [ $filename ] - Parameter #1 [ $flags ] - Parameter #2 [ $mode = ] + Parameter #0 [ string $filename ] + Parameter #1 [ int $flags ] + Parameter #2 [ int $mode = 0 ] } } Function [ function dio_fdopen ] { @@ -64,73 +64,80 @@ Extension [ extension #64 dio version 0.2.2 ] { - Parameters [2] { Parameter #0 [ $fd ] - Parameter #1 [ $offset ] + Parameter #1 [ int $offset ] } + - Return [ bool ] } Function [ function dio_stat ] { - Parameters [1] { Parameter #0 [ $fd ] } + - Return [ array|false ] } Function [ function dio_seek ] { - Parameters [3] { Parameter #0 [ $fd ] - Parameter #1 [ $pos ] - Parameter #2 [ $whence ] + Parameter #1 [ int $pos ] + Parameter #2 [ int $whence = SEEK_SET ] } + - Return [ int ] } Function [ function dio_fcntl ] { - Parameters [3] { Parameter #0 [ $fd ] - Parameter #1 [ $cmd ] - Parameter #2 [ $arg = ] + Parameter #1 [ int $cmd ] + Parameter #2 [ $arg = NULL ] } } Function [ function dio_read ] { - Parameters [2] { Parameter #0 [ $fd ] - Parameter #1 [ $n = ] + Parameter #1 [ int $n = 1024 ] } + - Return [ ?string ] } Function [ function dio_write ] { - Parameters [3] { Parameter #0 [ $fd ] - Parameter #1 [ $data ] - Parameter #2 [ $len = ] + Parameter #1 [ string $data ] + Parameter #2 [ int $len = 0 ] } + - Return [ int ] } Function [ function dio_close ] { - Parameters [1] { Parameter #0 [ $fd ] } + - Return [ void ] } Function [ function dio_tcsetattr ] { - Parameters [2] { Parameter #0 [ $fd ] - Parameter #1 [ $args ] + Parameter #1 [ array $args ] } + - Return [ bool ] } Function [ function dio_raw ] { - Parameters [3] { - Parameter #0 [ $filename ] - Parameter #1 [ $mode ] - Parameter #2 [ $options = ] + Parameter #0 [ string $filename ] + Parameter #1 [ string $mode ] + Parameter #2 [ ?array $options = NULL ] } } Function [ function dio_serial ] { - Parameters [3] { - Parameter #0 [ $filename ] - Parameter #1 [ $mode ] - Parameter #2 [ $options = ] + Parameter #0 [ string $filename ] + Parameter #1 [ string $mode ] + Parameter #2 [ ?array $options = NULL ] } } } diff --git a/php-pecl-dio.spec b/php-pecl-dio.spec index b6e1dcb..428d01b 100644 --- a/php-pecl-dio.spec +++ b/php-pecl-dio.spec @@ -1,33 +1,24 @@ # remirepo spec file for php-pecl-dio # -# Copyright (c) 2013-2023 Remi Collet +# 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 # -%{?scl: %scl_package php-pecl-dio} - -# For PHP < 5.6 and EPEL-9 -%{!?__phpize: %global __phpize %{_bindir}/phpize} -%{!?__ztsphpize: %global __ztsphpize %{_bindir}/zts-phpize} -%{!?__phpconfig: %global __phpconfig %{_bindir}/php-config} -%{!?__ztsphpconfig:%global __ztsphpconfig %{_bindir}/zts-php-config} - -#global prever dev -%global pecl_name dio -%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 sources %{pecl_name}-%{version}%{?prever} -%global _configure ../%{sources}/configure +%{?scl:%scl_package php-pecl-dio} + +%global upstream_version 0.3.0 +%global upstream_prever RC1 +%global pecl_name dio +%global with_zts 0%{!?_without_zts:%{?__ztsphp:1}} +%global ini_name 40-%{pecl_name}.ini +%global sources %{pecl_name}-%{upstream_version}%{?upstream_prever} +%global _configure ../%{sources}/configure Summary: Direct I/O functions Name: %{?scl_prefix}php-pecl-%{pecl_name} -Version: 0.2.2 +Version: %{upstream_version}%{?upstream_prever:~%{upstream_prever}} Release: 1%{?dist}%{!?nophptag:%(%{__php} -r 'echo ".".PHP_MAJOR_VERSION.".".PHP_MINOR_VERSION;')} License: PHP-3.01 URL: https://pecl.php.net/package/%{pecl_name} @@ -35,7 +26,7 @@ Source0: https://pecl.php.net/get/%{sources}.tgz BuildRequires: make BuildRequires: %{?dtsprefix}gcc -BuildRequires: %{?scl_prefix}php-devel +BuildRequires: %{?scl_prefix}php-devel >= 8.0 BuildRequires: %{?scl_prefix}php-pear Requires: %{?scl_prefix}php(zend-abi) = %{php_zend_api} @@ -70,9 +61,9 @@ sed -e 's/role="test"/role="src"/' \ cd %{sources} # Sanity check, really often broken -extver=$(sed -n '/#define PHP_DIO_VERSION/{s/.* "//;s/".*$//;p}' php7/php_dio.h) -if test "x${extver}" != "x%{version}%{?prever:-%{prever}}"; then - : Error: Upstream extension version is ${extver}, expecting %{version}%{?prever:-%{prever}}. +extver=$(sed -n '/#define PHP_DIO_VERSION/{s/.* "//;s/".*$//;p}' src/php_dio.h) +if test "x${extver}" != "x%{upstream_version}%{?upstream_prever}"; then + : Error: Upstream extension version is ${extver}, expecting %{upstream_version}%{?upstream_prever}. exit 1 fi cd .. @@ -199,6 +190,10 @@ REPORT_EXIT_STATUS=1 \ %changelog +* Thu Jan 25 2024 Remi Collet - 0.3.0~RC1-1 +- update to 0.3.0RC1 +- drop support for PHP 5 and 7 + * Tue Jan 23 2024 Remi Collet - 0.2.2-1 - update to 0.2.2 -- cgit