summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorRemi Collet <remi@remirepo.net>2021-01-02 07:07:30 +0100
committerRemi Collet <remi@remirepo.net>2021-01-02 07:07:30 +0100
commit8edae9b46a6a059ebcf923da26597d5030038df0 (patch)
tree327216142b15374c9807a0a3005c97031359fecf
parent6a677a6e796b2731ba25bc5f15138938c1cfee35 (diff)
update to 1.3.7
drop patch merged upstream
-rw-r--r--PHPINFO2
-rw-r--r--REFLECTION92
-rw-r--r--php-pecl-xlswriter.spec30
-rw-r--r--xlswriter-php8.patch113
4 files changed, 90 insertions, 147 deletions
diff --git a/PHPINFO b/PHPINFO
index cf61216..d3268b8 100644
--- a/PHPINFO
+++ b/PHPINFO
@@ -2,6 +2,6 @@
xlswriter
xlswriter support => enabled
-Version => 1.3.6
+Version => 1.3.7
bundled libxlsxwriter version => 0.9.4
bundled libxlsxio version => 0.2.27
diff --git a/REFLECTION b/REFLECTION
index a68290f..f4b9a13 100644
--- a/REFLECTION
+++ b/REFLECTION
@@ -1,4 +1,17 @@
-Extension [ <persistent> extension #104 xlswriter version 1.3.6 ] {
+Extension [ <persistent> extension #106 xlswriter version 1.3.7 ] {
+
+ - Functions {
+ Function [ <internal:xlswriter> function xlswriter_get_version ] {
+
+ - Parameters [0] {
+ }
+ }
+ Function [ <internal:xlswriter> function xlswriter_get_author ] {
+
+ - Parameters [0] {
+ }
+ }
+ }
- Classes [4] {
Class [ <internal:xlswriter> class Vtiful\Kernel\Exception extends Exception implements Throwable ] {
@@ -60,9 +73,10 @@ Extension [ <persistent> extension #104 xlswriter version 1.3.6 ] {
Class [ <internal:xlswriter> class Vtiful\Kernel\Excel ] {
- - Constants [12] {
+ - Constants [13] {
Constant [ public int SKIP_NONE ] { 0 }
Constant [ public int SKIP_EMPTY_ROW ] { 1 }
+ Constant [ public int SKIP_HIDDEN_ROW ] { 8 }
Constant [ public int SKIP_EMPTY_CELLS ] { 2 }
Constant [ public int SKIP_EMPTY_VALUE ] { 256 }
Constant [ public int GRIDLINES_HIDE_ALL ] { 0 }
@@ -107,7 +121,7 @@ Extension [ <persistent> extension #104 xlswriter version 1.3.6 ] {
Property [ <default> private $read_row_type ]
}
- - Methods [36] {
+ - Methods [42] {
Method [ <internal:xlswriter, ctor> public method __construct ] {
- Parameters [1] {
@@ -192,8 +206,8 @@ Extension [ <persistent> extension #104 xlswriter version 1.3.6 ] {
Parameter #0 [ <required> $row ]
Parameter #1 [ <required> $column ]
Parameter #2 [ <required> $data ]
- Parameter #3 [ <required> $format ]
- Parameter #4 [ <required> $format_handle ]
+ Parameter #3 [ <optional> $format ]
+ Parameter #4 [ <optional> $format_handle ]
}
}
@@ -203,8 +217,8 @@ Extension [ <persistent> extension #104 xlswriter version 1.3.6 ] {
Parameter #0 [ <required> $row ]
Parameter #1 [ <required> $column ]
Parameter #2 [ <required> $timestamp ]
- Parameter #3 [ <required> $format ]
- Parameter #4 [ <required> $format_handle ]
+ Parameter #3 [ <optional> $format ]
+ Parameter #4 [ <optional> $format_handle ]
}
}
@@ -219,11 +233,13 @@ Extension [ <persistent> extension #104 xlswriter version 1.3.6 ] {
Method [ <internal:xlswriter> public method insertUrl ] {
- - Parameters [4] {
+ - Parameters [6] {
Parameter #0 [ <required> $row ]
Parameter #1 [ <required> $column ]
Parameter #2 [ <required> $url ]
- Parameter #3 [ <required> $format ]
+ Parameter #3 [ <optional> $text ]
+ Parameter #4 [ <optional> $tool_tip ]
+ Parameter #5 [ <optional> $format ]
}
}
@@ -305,6 +321,13 @@ Extension [ <persistent> extension #104 xlswriter version 1.3.6 ] {
}
}
+ Method [ <internal:xlswriter> public method protection ] {
+
+ - Parameters [1] {
+ Parameter #0 [ <optional> $password ]
+ }
+ }
+
Method [ <internal:xlswriter> public method zoom ] {
- Parameters [1] {
@@ -319,6 +342,30 @@ Extension [ <persistent> extension #104 xlswriter version 1.3.6 ] {
}
}
+ Method [ <internal:xlswriter> public method setPrintedPortrait ] {
+
+ - Parameters [0] {
+ }
+ }
+
+ Method [ <internal:xlswriter> public method setPrintedLandscape ] {
+
+ - Parameters [0] {
+ }
+ }
+
+ Method [ <internal:xlswriter> public method setCurrentSheetHide ] {
+
+ - Parameters [0] {
+ }
+ }
+
+ Method [ <internal:xlswriter> public method setCurrentSheetIsFirst ] {
+
+ - Parameters [0] {
+ }
+ }
+
Method [ <internal:xlswriter> public method openFile ] {
- Parameters [1] {
@@ -328,8 +375,9 @@ Extension [ <persistent> extension #104 xlswriter version 1.3.6 ] {
Method [ <internal:xlswriter> public method openSheet ] {
- - Parameters [1] {
- Parameter #0 [ <required> $zs_sheet_name ]
+ - Parameters [2] {
+ Parameter #0 [ <optional> $zs_sheet_name ]
+ Parameter #1 [ <optional> $zl_flag ]
}
}
@@ -367,6 +415,13 @@ Extension [ <persistent> extension #104 xlswriter version 1.3.6 ] {
}
}
+ Method [ <internal:xlswriter> public method setGlobalType ] {
+
+ - Parameters [1] {
+ Parameter #0 [ <required> $zv_type_t ]
+ }
+ }
+
Method [ <internal:xlswriter> public method setSkipRows ] {
- Parameters [1] {
@@ -391,7 +446,7 @@ Extension [ <persistent> extension #104 xlswriter version 1.3.6 ] {
- Parameters [2] {
Parameter #0 [ <required> $fci ]
- Parameter #1 [ <required> $sheet_name ]
+ Parameter #1 [ <optional> $sheet_name ]
}
}
}
@@ -399,7 +454,7 @@ Extension [ <persistent> extension #104 xlswriter version 1.3.6 ] {
Class [ <internal:xlswriter> class Vtiful\Kernel\Format ] {
- - Constants [64] {
+ - Constants [65] {
Constant [ public int UNDERLINE_SINGLE ] { 1 }
Constant [ public int UNDERLINE_DOUBLE ] { 2 }
Constant [ public int UNDERLINE_SINGLE_ACCOUNTING ] { 3 }
@@ -451,6 +506,7 @@ Extension [ <persistent> extension #104 xlswriter version 1.3.6 ] {
Constant [ public int PATTERN_LIGHT_TRELLIS ] { 16 }
Constant [ public int PATTERN_GRAY_125 ] { 17 }
Constant [ public int PATTERN_GRAY_0625 ] { 18 }
+ Constant [ public int BORDER_NONE ] { 0 }
Constant [ public int BORDER_THIN ] { 1 }
Constant [ public int BORDER_MEDIUM ] { 2 }
Constant [ public int BORDER_DASHED ] { 3 }
@@ -475,7 +531,7 @@ Extension [ <persistent> extension #104 xlswriter version 1.3.6 ] {
- Properties [0] {
}
- - Methods [14] {
+ - Methods [15] {
Method [ <internal:xlswriter, ctor> public method __construct ] {
- Parameters [1] {
@@ -511,7 +567,7 @@ Extension [ <persistent> extension #104 xlswriter version 1.3.6 ] {
Method [ <internal:xlswriter> public method align ] {
- Parameters [1] {
- Parameter #0 [ <required> $style ]
+ Parameter #0 [ <required> ...$style ]
}
}
@@ -556,6 +612,12 @@ Extension [ <persistent> extension #104 xlswriter version 1.3.6 ] {
}
}
+ Method [ <internal:xlswriter> public method unlocked ] {
+
+ - Parameters [0] {
+ }
+ }
+
Method [ <internal:xlswriter> public method toResource ] {
- Parameters [0] {
diff --git a/php-pecl-xlswriter.spec b/php-pecl-xlswriter.spec
index 2bcc6f9..c459a0a 100644
--- a/php-pecl-xlswriter.spec
+++ b/php-pecl-xlswriter.spec
@@ -10,14 +10,14 @@
# we don't want -z defs linker flag
%undefine _strict_symbol_defs_build
-%bcond_with syslib
+%bcond_with syslib
+%bcond_without tests
%if 0%{?scl:1}
%scl_package php-pecl-xlswriter
%global sub_prefix %{scl_prefix}
%endif
-%global with_tests 0%{!?_without_tests:1}
%global with_zts 0%{!?_without_zts:%{?__ztsphp:1}}
%global pecl_name xlswriter
# After json
@@ -31,17 +31,15 @@
Summary: An efficient and fast xlsx file export extension
Name: %{?sub_prefix}php-pecl-%{pecl_name}
-Version: 1.3.6
-Release: 9%{?dist}%{!?scl:%{!?nophptag:%(%{__php} -r 'echo ".".PHP_MAJOR_VERSION.".".PHP_MINOR_VERSION;')}}
+Version: 1.3.7
+Release: 1%{?dist}%{!?scl:%{!?nophptag:%(%{__php} -r 'echo ".".PHP_MAJOR_VERSION.".".PHP_MINOR_VERSION;')}}
License: BSD
URL: https://pecl.php.net/package/%{pecl_name}
Source0: https://pecl.php.net/get/%{pecl_name}-%{version}.tgz
-# from https://github.com/viest/php-ext-xlswriter/pull/298
-Patch0: xlswriter-php8.patch
-
BuildRequires: %{?dtsprefix}gcc
-BuildRequires: %{?scl_prefix}php-devel >= 7
+BuildRequires: make
+BuildRequires: %{?scl_prefix}php-devel >= 7.0
BuildRequires: %{?scl_prefix}php-pear
%if %{with syslib}
BuildRequires: libxlsxwriter-devel >= %{libxlsxwriter_version}
@@ -84,12 +82,6 @@ Obsoletes: php80-pecl-%{pecl_name} <= %{version}
%endif
%endif
-%if 0%{?fedora} < 20 && 0%{?rhel} < 7
-# Filter shared private
-%{?filter_provides_in: %filter_provides_in %{_libdir}/.*\.so$}
-%{?filter_setup}
-%endif
-
%description
An efficient and fast xlsx file export extension for PHP.
@@ -114,8 +106,6 @@ sed -e 's/role="test"/role="src"/' \
-i package.xml
cd NTS
-%patch0 -p1 -b .pr
-
%if %{with syslib}
# we use the system libraries
rm -r library
@@ -227,7 +217,7 @@ cd NTS
--define extension=%{buildroot}%{php_extdir}/%{pecl_name}.so \
--modules | grep '^%{pecl_name}$'
-%if %{with_tests}
+%if %{with tests}
: Upstream test suite for NTS extension
TEST_PHP_EXECUTABLE=%{__php} \
TEST_PHP_ARGS="-n -d extension=%{buildroot}%{php_extdir}/%{pecl_name}.so" \
@@ -244,7 +234,7 @@ cd ../ZTS
--define extension=%{buildroot}%{php_ztsextdir}/%{pecl_name}.so \
--modules | grep '^%{pecl_name}$'
-%if %{with_tests}
+%if %{with tests}
: Upstream test suite for ZTS extension
TEST_PHP_EXECUTABLE=%{_bindir}/zts-php \
TEST_PHP_ARGS="-n -d extension=%{buildroot}%{php_ztsextdir}/%{pecl_name}.so" \
@@ -271,6 +261,10 @@ cd ..
%changelog
+* Sat Jan 2 2021 Remi Collet <remi@remirepo.net> - 1.3.7-1
+- update to 1.3.7
+- drop patch merged upstream
+
* Wed Sep 30 2020 Remi Collet <remi@remirepo.net> - 1.3.6-9
- rebuild using bundled libraries
diff --git a/xlswriter-php8.patch b/xlswriter-php8.patch
deleted file mode 100644
index b50fd3c..0000000
--- a/xlswriter-php8.patch
+++ /dev/null
@@ -1,113 +0,0 @@
-diff -up ./include/xlswriter.h.old ./include/xlswriter.h
---- ./include/xlswriter.h.old 2020-09-02 10:37:59.430350020 +0200
-+++ ./include/xlswriter.h 2020-09-02 10:38:03.129338838 +0200
-@@ -183,6 +183,13 @@ static inline chart_object *php_vtiful_c
- #define lxw_snprintf __builtin_snprintf
- #endif
-
-+#if PHP_VERSION_ID < 80000
-+#define PROP_OBJ(zv) (zv)
-+#else
-+#define PROP_OBJ(zv) Z_OBJ_P(zv)
-+#endif
-+
-+
- lxw_format * zval_get_format(zval *handle);
- xls_resource_write_t * zval_get_resource(zval *handle);
- xls_resource_chart_t * zval_get_chart(zval *resource);
-diff -up ./kernel/common.c.old ./kernel/common.c
---- ./kernel/common.c.old 2020-09-02 10:37:41.143405296 +0200
-+++ ./kernel/common.c 2020-09-02 10:37:47.040387471 +0200
-@@ -57,7 +57,7 @@ void call_object_method(zval *object, co
- zval z_f_name;
-
- ZVAL_STRINGL(&z_f_name, function_name, strlen(function_name));
-- call_user_function_ex(NULL, object, &z_f_name, ret_val, param_count, params, 0, NULL);
-+ call_user_function(NULL, object, &z_f_name, ret_val, param_count, params);
-
- if (Z_ISUNDEF_P(ret_val)) {
- ZVAL_NULL(ret_val);
-diff -up ./kernel/excel.c.old ./kernel/excel.c
---- ./kernel/excel.c.old 2020-09-02 10:38:16.686297857 +0200
-+++ ./kernel/excel.c 2020-09-02 10:38:21.573283085 +0200
-@@ -297,7 +297,7 @@ PHP_METHOD(vtiful_xls, fileName)
-
- ZVAL_COPY(return_value, getThis());
-
-- GET_CONFIG_PATH(dir_path, vtiful_xls_ce, return_value);
-+ GET_CONFIG_PATH(dir_path, vtiful_xls_ce, PROP_OBJ(return_value));
-
- if(directory_exists(ZSTR_VAL(Z_STR_P(dir_path))) == XLSWRITER_FALSE) {
- zend_throw_exception(vtiful_exception_ce, "Configure 'path' directory does not exist", 121);
-@@ -423,7 +423,7 @@ PHP_METHOD(vtiful_xls, constMemory)
-
- ZVAL_COPY(return_value, getThis());
-
-- GET_CONFIG_PATH(dir_path, vtiful_xls_ce, return_value);
-+ GET_CONFIG_PATH(dir_path, vtiful_xls_ce, PROP_OBJ(return_value));
-
- xls_object *obj = Z_XLS_P(getThis());
-
-@@ -515,7 +515,7 @@ PHP_METHOD(vtiful_xls, output)
- {
- zval rv, *file_path = NULL;
-
-- file_path = zend_read_property(vtiful_xls_ce, getThis(), ZEND_STRL(V_XLS_FIL), 0, &rv TSRMLS_DC);
-+ file_path = zend_read_property(vtiful_xls_ce, PROP_OBJ(getThis()), ZEND_STRL(V_XLS_FIL), 0, &rv TSRMLS_DC);
-
- xls_object *obj = Z_XLS_P(getThis());
-
-@@ -1066,7 +1066,7 @@ PHP_METHOD(vtiful_xls, openFile)
-
- ZVAL_COPY(return_value, getThis());
-
-- GET_CONFIG_PATH(zv_config_path, vtiful_xls_ce, return_value);
-+ GET_CONFIG_PATH(zv_config_path, vtiful_xls_ce, PROP_OBJ(return_value));
-
- xls_object* obj = Z_XLS_P(getThis());
-
-@@ -1177,7 +1177,7 @@ PHP_METHOD(vtiful_xls, putCSV)
- RETURN_FALSE;
- }
-
-- zv_type = zend_read_property(vtiful_xls_ce, getThis(), ZEND_STRL(V_XLS_TYPE), 0, NULL);
-+ zv_type = zend_read_property(vtiful_xls_ce, PROP_OBJ(getThis()), ZEND_STRL(V_XLS_TYPE), 0, NULL);
-
- if (xlsx_to_csv(
- fp, delimiter_str, delimiter_str_len, enclosure_str, enclosure_str_len, escape_str, escape_str_len,
-@@ -1215,7 +1215,7 @@ PHP_METHOD(vtiful_xls, putCSVCallback)
- RETURN_FALSE;
- }
-
-- zv_type = zend_read_property(vtiful_xls_ce, getThis(), ZEND_STRL(V_XLS_TYPE), 0, NULL);
-+ zv_type = zend_read_property(vtiful_xls_ce, PROP_OBJ(getThis()), ZEND_STRL(V_XLS_TYPE), 0, NULL);
-
- if (xlsx_to_csv(
- fp, delimiter_str, delimiter_str_len, enclosure_str, enclosure_str_len, escape_str, escape_str_len,
-@@ -1238,7 +1238,7 @@ PHP_METHOD(vtiful_xls, getSheetData)
- RETURN_FALSE;
- }
-
-- zval *zv_type = zend_read_property(vtiful_xls_ce, getThis(), ZEND_STRL(V_XLS_TYPE), 0, NULL);
-+ zval *zv_type = zend_read_property(vtiful_xls_ce, PROP_OBJ(getThis()), ZEND_STRL(V_XLS_TYPE), 0, NULL);
-
- if (zv_type != NULL && Z_TYPE_P(zv_type) == IS_ARRAY) {
- load_sheet_all_data(obj->read_ptr.sheet_t, zv_type, return_value);
-@@ -1268,7 +1268,7 @@ PHP_METHOD(vtiful_xls, nextRow)
- }
-
- if (zv_type_t == NULL) {
-- zv_type_t = zend_read_property(vtiful_xls_ce, getThis(), ZEND_STRL(V_XLS_TYPE), 0, NULL);
-+ zv_type_t = zend_read_property(vtiful_xls_ce, PROP_OBJ(getThis()), ZEND_STRL(V_XLS_TYPE), 0, NULL);
- }
-
- load_sheet_current_row_data(obj->read_ptr.sheet_t, return_value, zv_type_t, READ_ROW);
-@@ -1297,7 +1297,7 @@ PHP_METHOD(vtiful_xls, nextCellCallback)
-
- xls_read_callback_data callback_data;
-
-- callback_data.zv_type_t = zend_read_property(vtiful_xls_ce, getThis(), ZEND_STRL(V_XLS_TYPE), 0, NULL);
-+ callback_data.zv_type_t = zend_read_property(vtiful_xls_ce, PROP_OBJ(getThis()), ZEND_STRL(V_XLS_TYPE), 0, NULL);
-
- callback_data.fci = &fci;
- callback_data.fci_cache = &fci_cache;