diff options
-rw-r--r-- | 531.patch | 66 | ||||
-rw-r--r-- | PHPINFO | 2 | ||||
-rw-r--r-- | REFLECTION | 2 | ||||
-rw-r--r-- | php-pecl-xlswriter.spec | 25 |
4 files changed, 88 insertions, 7 deletions
diff --git a/531.patch b/531.patch new file mode 100644 index 0000000..9ef28fb --- /dev/null +++ b/531.patch @@ -0,0 +1,66 @@ +From c8f5a888cb304e8f369ff139964cd923ef3c722b Mon Sep 17 00:00:00 2001 +From: Remi Collet <remi@remirepo.net> +Date: Mon, 30 Sep 2024 08:14:43 +0200 +Subject: [PATCH] fetcsv default values are deprecated with 8.4 + +--- + tests/xlsx_to_csv_callback.phpt | 6 +++--- + tests/xlsx_to_csv_callback_custom_delimiter.phpt | 4 ++-- + tests/xlsx_to_csv_custom_delimiter.phpt | 2 +- + 3 files changed, 6 insertions(+), 6 deletions(-) + +diff --git a/tests/xlsx_to_csv_callback.phpt b/tests/xlsx_to_csv_callback.phpt +index 81d1bdb..eea603e 100644 +--- a/tests/xlsx_to_csv_callback.phpt ++++ b/tests/xlsx_to_csv_callback.phpt +@@ -30,8 +30,8 @@ var_dump($csvResult); + + $fp = fopen('./tests/file.csv', 'r'); + +-var_dump(fgetcsv($fp)); +-var_dump(fgetcsv($fp)); ++var_dump(fgetcsv($fp, 1000, ',', '"', '\\')); ++var_dump(fgetcsv($fp, 1000, ',', '"', '\\')); + ?> + --CLEAN-- + <?php +@@ -55,4 +55,4 @@ array(4) { + string(2) "10" + [3]=> + string(10) "10.9999995" +-} +\ No newline at end of file ++} +diff --git a/tests/xlsx_to_csv_callback_custom_delimiter.phpt b/tests/xlsx_to_csv_callback_custom_delimiter.phpt +index 2a46550..d02cf22 100644 +--- a/tests/xlsx_to_csv_callback_custom_delimiter.phpt ++++ b/tests/xlsx_to_csv_callback_custom_delimiter.phpt +@@ -30,7 +30,7 @@ if (($csvHandler = fopen('./tests/file.csv', 'r')) === FALSE) { + die('csv file open failure'); + } + +-while (($data = fgetcsv($csvHandler, 1000, ';')) !== FALSE) { ++while (($data = fgetcsv($csvHandler, 1000, ';', '"', '\\')) !== FALSE) { + var_dump($data); + } + ?> +@@ -56,4 +56,4 @@ array(4) { + string(2) "10" + [3]=> + string(10) "10.9999995" +-} +\ No newline at end of file ++} +diff --git a/tests/xlsx_to_csv_custom_delimiter.phpt b/tests/xlsx_to_csv_custom_delimiter.phpt +index 5fb749c..0e86053 100644 +--- a/tests/xlsx_to_csv_custom_delimiter.phpt ++++ b/tests/xlsx_to_csv_custom_delimiter.phpt +@@ -28,7 +28,7 @@ if (($csvHandler = fopen('./tests/file.csv', 'r')) === FALSE) { + die('csv file open failure'); + } + +-while (($data = fgetcsv($csvHandler, 1000, ';')) !== FALSE) { ++while (($data = fgetcsv($csvHandler, 1000, ';', '"', '\\')) !== FALSE) { + var_dump($data); + } + ?> @@ -2,6 +2,6 @@ xlswriter xlswriter support => enabled -Version => 1.5.6 +Version => 1.5.7 bundled libxlsxwriter version => 1.1.3 bundled libxlsxio version => 0.2.27 @@ -1,4 +1,4 @@ -Extension [ <persistent> extension #100 xlswriter version 1.5.6 ] { +Extension [ <persistent> extension #101 xlswriter version 1.5.7 ] { - Functions { Function [ <internal:xlswriter> function xlswriter_get_version ] { diff --git a/php-pecl-xlswriter.spec b/php-pecl-xlswriter.spec index 2e469b5..5bcafd5 100644 --- a/php-pecl-xlswriter.spec +++ b/php-pecl-xlswriter.spec @@ -26,12 +26,13 @@ Summary: An efficient and fast xlsx file extension Name: %{?scl_prefix}php-pecl-%{pecl_name} -Version: 1.5.6 -Release: 1%{?dist}%{!?scl:%{!?nophptag:%(%{__php} -r 'echo ".".PHP_MAJOR_VERSION.".".PHP_MINOR_VERSION;')}} +Version: 1.5.7 +Release: 3%{?dist}%{!?scl:%{!?nophptag:%(%{__php} -r 'echo ".".PHP_MAJOR_VERSION.".".PHP_MINOR_VERSION;')}} License: BSD-2-Clause URL: https://pecl.php.net/package/%{pecl_name} Source0: https://pecl.php.net/get/%{pecl_name}-%{version}.tgz +Patch0: 531.patch BuildRequires: %{?dtsprefix}gcc BuildRequires: make BuildRequires: %{?scl_prefix}php-devel >= 7.0 @@ -99,6 +100,8 @@ sed -e 's/role="test"/role="src"/' \ -i package.xml pushd %{sources} +%patch -P0 -p1 + %if %{with syslib} # we use the system libraries rm -r library @@ -139,11 +142,13 @@ peclbuild() { --enable-reader \ --with-php-config=$1 -make %{?_smp_mflags} +%make_build } cd %{sources} %{__phpize} +[ -f Makefile.global ] && GLOBAL=Makefile.global || GLOBAL=build/Makefile.global +sed -e 's/INSTALL_ROOT/DESTDIR/' -i $GLOBAL cd ../NTS peclbuild %{__phpconfig} @@ -157,7 +162,7 @@ peclbuild %{__ztsphpconfig} %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} @@ -166,7 +171,7 @@ 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 @@ -227,6 +232,16 @@ cd .. %changelog +* Mon Sep 30 2024 Remi Collet <remi@remirepo.net> - 1.5.7-3 +- fix test suite using patch from + https://github.com/viest/php-ext-xlswriter/pull/531 + +* Tue Sep 24 2024 Remi Collet <remi@remirepo.net> - 1.5.7-2 +- rebuild for 8.4.0RC1 + +* Wed Sep 4 2024 Remi Collet <remi@remirepo.net> - 1.5.7-1 +- update to 1.5.7 + * Wed Aug 28 2024 Remi Collet <remi@remirepo.net> - 1.5.6-1 - update to 1.5.6 |