commit 3bca683dd4b098438f6ce1cd3ef3ac202068b986 Author: Jan Palus <at...@pld-linux.org> Date: Thu Jan 23 00:46:07 2025 +0100
correct types in pdo modules to fix build on x32 php.spec | 2 ++ types.patch | 77 +++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++ 2 files changed, 79 insertions(+) --- diff --git a/php.spec b/php.spec index 68d88ab..62bd185 100644 --- a/php.spec +++ b/php.spec @@ -209,6 +209,7 @@ Patch72: openssl.patch Patch73: missing-includes.patch Patch74: icu74.patch Patch75: libxml2-2.12.patch +Patch76: types.patch URL: https://www.php.net/ %{?with_pdo_firebird:%{!?with_interbase_inst:BuildRequires: Firebird-devel >= 1.0.2.908-2}} %{?with_pspell:BuildRequires: aspell-devel >= 2:0.50.0} @@ -1931,6 +1932,7 @@ cp -p php.ini-production php.ini %patch -P73 -p1 %patch -P74 -p1 %patch -P75 -p1 +%patch -P76 -p1 sed -E -i -e '1s,#!\s*/usr/bin/env\s+(.*),#!%{__bindir}\1,' \ ext/ext_skel.php \ diff --git a/types.patch b/types.patch new file mode 100644 index 0000000..d836464 --- /dev/null +++ b/types.patch @@ -0,0 +1,77 @@ +--- php-8.0.28/ext/pdo_dblib/dblib_stmt.c.orig 2023-02-14 12:05:44.000000000 +0100 ++++ php-8.0.28/ext/pdo_dblib/dblib_stmt.c 2025-01-23 00:05:26.067889731 +0100 +@@ -347,7 +347,7 @@ + } + + static int pdo_dblib_stmt_get_col(pdo_stmt_t *stmt, int colno, char **ptr, +- zend_ulong *len, int *caller_frees) ++ size_t *len, int *caller_frees) + { + + pdo_dblib_stmt *S = (pdo_dblib_stmt*)stmt->driver_data; +--- php-8.0.28/ext/pdo_firebird/firebird_statement.c.orig 2023-02-14 12:05:44.000000000 +0100 ++++ php-8.0.28/ext/pdo_firebird/firebird_statement.c 2025-01-23 00:16:13.415116725 +0100 +@@ -259,7 +259,7 @@ + + /* fetch a blob into a fetch buffer */ + static int firebird_fetch_blob(pdo_stmt_t *stmt, int colno, char **ptr, /* {{{ */ +- zend_ulong *len, ISC_QUAD *blob_id) ++ size_t *len, ISC_QUAD *blob_id) + { + pdo_firebird_stmt *S = (pdo_firebird_stmt*)stmt->driver_data; + pdo_firebird_db_handle *H = S->H; +@@ -341,7 +341,7 @@ + /* }}} */ + + static int firebird_stmt_get_col(pdo_stmt_t *stmt, int colno, char **ptr, /* {{{ */ +- zend_ulong *len, int *caller_frees) ++ size_t *len, int *caller_frees) + { + pdo_firebird_stmt *S = (pdo_firebird_stmt*)stmt->driver_data; + XSQLVAR const *var = &S->out_sqlda.sqlvar[colno]; +@@ -561,7 +561,7 @@ + + switch (event_type) { + char *value; +- zend_ulong value_len; ++ size_t value_len; + int caller_frees; + zval *parameter; + +--- php-8.0.28/ext/pdo_odbc/odbc_stmt.c.orig 2023-02-14 12:05:44.000000000 +0100 ++++ php-8.0.28/ext/pdo_odbc/odbc_stmt.c 2025-01-23 00:30:24.886905826 +0100 +@@ -89,7 +89,7 @@ + } + + static int pdo_odbc_ucs22utf8(pdo_stmt_t *stmt, int is_unicode, const char *buf, +- zend_ulong buflen, zend_ulong *outlen) ++ zend_ulong buflen, size_t *outlen) + { + #ifdef PHP_WIN32 + if (is_unicode && buflen) { +@@ -487,9 +487,9 @@ + P = param->driver_data; + + if (P->outbuf) { +- zend_ulong ulen; ++ size_t ulen; + char *srcbuf; +- zend_ulong srclen = 0; ++ size_t srclen = 0; + + if (Z_ISREF(param->parameter)) { + parameter = Z_REFVAL(param->parameter); +@@ -646,11 +646,11 @@ + return 1; + } + +-static int odbc_stmt_get_col(pdo_stmt_t *stmt, int colno, char **ptr, zend_ulong *len, int *caller_frees) ++static int odbc_stmt_get_col(pdo_stmt_t *stmt, int colno, char **ptr, size_t *len, int *caller_frees) + { + pdo_odbc_stmt *S = (pdo_odbc_stmt*)stmt->driver_data; + pdo_odbc_column *C = &S->cols[colno]; +- zend_ulong ulen; ++ size_t ulen; + + /* if it is a column containing "long" data, perform late binding now */ + if (C->is_long) { ================================================================ ---- gitweb: http://git.pld-linux.org/gitweb.cgi/packages/php.git/commitdiff/1ba980d51cc0dd58e441507e425585d6311f9cd7 _______________________________________________ pld-cvs-commit mailing list pld-cvs-commit@lists.pld-linux.org http://lists.pld-linux.org/mailman/listinfo/pld-cvs-commit