Commit Graph

1052 Commits

Author SHA1 Message Date
Peter Kokot
1ceadaed52
Autotools: Normalize and quote all PHP_NEW_EXTENSION arguments (#15144)
This adds Autoconf quote characters to all PHP_NEW_EXTENSION arguments
and syncs the CS across the php-src Autotools build system.
2024-07-29 00:14:59 +02:00
Peter Kokot
97afc86437
Autotools: Quote M4 arguments (#15045)
- AC_MSG_CHECKING
- AC_MSG_RESULT
- AC_MSG_WARN
- AC_MSG_ERROR
- AC_MSG_NOTICE
2024-07-21 01:52:17 +02:00
Peter Kokot
68ae477796
Autotools: Quote M4 arguments (#15033)
- PHP_ADD_INCLUDE
- PHP_EVAL_INCLINE
- PHP_EVAL_LIBLINE
2024-07-20 07:21:44 +02:00
Saki Takamachi
acd6ac3324
Fixed parent class of stub (#14990) 2024-07-17 21:38:59 +09:00
Peter Kokot
bee84c0468
Autotools: Quote PHP_SUBST arguments in extensions (#14748) 2024-07-02 06:56:18 +02:00
Arnaud Le Blanc
11accb5cdf
Preferably include from build dir (#13516)
* Include from build dir first

This fixes out of tree builds by ensuring that configure artifacts are included
from the build dir.

Before, out of tree builds would preferably include files from the src dir, as
the include path was defined as follows (ignoring includes from ext/ and sapi/) :

    -I$(top_builddir)/main
    -I$(top_srcdir)
    -I$(top_builddir)/TSRM
    -I$(top_builddir)/Zend
    -I$(top_srcdir)/main
    -I$(top_srcdir)/Zend
    -I$(top_srcdir)/TSRM
    -I$(top_builddir)/

As a result, an out of tree build would include configure artifacts such as
`main/php_config.h` from the src dir.

After this change, the include path is defined as follows:

    -I$(top_builddir)/main
    -I$(top_builddir)
    -I$(top_srcdir)/main
    -I$(top_srcdir)
    -I$(top_builddir)/TSRM
    -I$(top_builddir)/Zend
    -I$(top_srcdir)/Zend
    -I$(top_srcdir)/TSRM

* Fix extension include path for out of tree builds

* Include config.h with the brackets form

`#include "config.h"` searches in the directory containing the including-file
before any other include path. This can include the wrong config.h when building
out of tree and a config.h exists in the source tree.

Using `#include <config.h>` uses exclusively the include path, and gives
priority to the build dir.
2024-06-26 00:26:43 +02:00
Peter Kokot
f3feef8b93
Define default RE2C_FLAGS (#14615)
The --no-generation-date flag is a common re2c flag used in all re2c
invocations. This adds the 2nd optional argument to PHP_PROG_RE2C M4
macro in BC manner to set the default re2c command-line options and sets
the default RE2C_FLAGS similarly on Windows.
2024-06-24 22:09:04 +02:00
Peter Kokot
8d876e435b
Enable static tsrmls cache in pdo_mysql with mysqlnd (#14634)
The tsrmls cache has been integrated in
aac7b1db7c but not enabled when pdo_mysql
is built for mysqlnd extension.
2024-06-23 21:12:35 +02:00
Peter Kokot
0ed134100f
Update mysqli and pdo_mysql extension dependencies (#14633)
- The mysqlnd is required dependency in mysqli extension
- When building pdo_mysql with mysqlnd (--with-pdo-mysql or
  --with-pdo-mysql=mysqlnd) mysqlnd is required
- This also adds missing configure time pdo dependency to pdo_mysql
2024-06-23 19:59:31 +02:00
Matteo Beccati
5a3c4a2c9c
Fix test when using libmysqlclient
TL;DR
When suing libmysqlclient, ints are fetched as strings, so the strict comparison was failing
2024-06-20 13:25:52 +02:00
Matteo Beccati
037243ccd7
pdo_mysql: "--" should be followed by a whitespace character
This required changing how YYFILL works, with no apparent regressions
2024-06-17 23:31:25 +02:00
Matteo Beccati
715b9aaa09
Implemented PDO Driver specific SQL parsers
RFC: http://wiki.php.net/rfc/pdo_driver_specific_parsers
2024-06-17 23:31:24 +02:00
Peter Kokot
df481ef941
Simplify PDO include paths (#14444)
PDO include paths can be simplified and synced as done in other
extensions: either the project root directory or the phpincludedir (for
the system installation). The 'ext' include is automatically appended
when doing phpize build. In php-src it is only present on Windows build.
The PHP_CHECK_PDO_INCLUDES is left intact working as before and checks
if PDO headers are found.
2024-06-03 12:56:21 +02:00
Máté Kocsis
6ec4220148
Amend PDO driver-specific class names (#14069)
As suggested in https://externals.io/message/123166
2024-05-30 20:15:42 +02:00
Gina Peter Banyard
07a48517ac
Merge branch 'PHP-8.3'
* PHP-8.3:
  ext/readline: Fix [-Wcalloc-transposed-args] compiler warning
  ext/pdo_mysql: Fix [-Wcalloc-transposed-args] compiler warning
  ext/gd: Fix [-Wcalloc-transposed-args] compiler warning
  ext/ffi: Fix [-Wenum-int-mismatch] compiler warning
  ext/bcmath: Fix [-Wenum-int-mismatch] compiler warning
2024-05-21 12:23:45 +01:00
Gina Peter Banyard
b2c0db1f89
Merge branch 'PHP-8.2' into PHP-8.3
* PHP-8.2:
  ext/readline: Fix [-Wcalloc-transposed-args] compiler warning
  ext/pdo_mysql: Fix [-Wcalloc-transposed-args] compiler warning
  ext/gd: Fix [-Wcalloc-transposed-args] compiler warning
  ext/ffi: Fix [-Wenum-int-mismatch] compiler warning
  ext/bcmath: Fix [-Wenum-int-mismatch] compiler warning
2024-05-21 12:21:46 +01:00
Gina Peter Banyard
d4accd8b12
ext/pdo_mysql: Fix [-Wcalloc-transposed-args] compiler warning 2024-05-21 12:17:25 +01:00
Peter Kokot
e1181a64d4
Remove HAVE_MYSQL (#13719)
The ext/pdo_mysql symbol has been once used together with the removed
ext/mysql extension and isn't defined on Windows neither used in the
code anymore.
2024-03-15 20:33:59 +01:00
Saki Takamachi
3dc9503a96
Revert "Fixed GH-13167 Fixed the behavior of bindValue and bindParam. (#13384)"
This reverts commit 68f10504de.
2024-03-09 10:34:32 +09:00
Saki Takamachi
00bee30132
Revert "Tidy up UT and add NEWS entry"
This reverts commit 1d45357409.
2024-03-09 10:34:17 +09:00
Niels Dossche
37989666ef Avoid copying escaped string, truncate instead 2024-03-07 20:27:18 +01:00
Saki Takamachi
a31edaa99b
Merge branch 'PHP-8.3'
* PHP-8.3:
    Removed `REPORT_EXIT_STATUS=no` in libmysql tests
2024-02-29 08:49:53 +09:00
Saki Takamachi
116166cd30
Merge branch 'PHP-8.2' into PHP-8.3
* PHP-8.2:
  Removed `REPORT_EXIT_STATUS=no` in libmysql tests
2024-02-29 08:49:04 +09:00
Saki Takamachi
99688dbe7a
Removed REPORT_EXIT_STATUS=no in libmysql tests 2024-02-29 08:41:36 +09:00
Peter Kokot
7b7f97b518 Remove duplicate Autoconf check for sed
The sed program is always available since it is already discovered in
configure.ac and phpize.m4.
2024-02-26 11:47:59 +01:00
Niels Dossche
25dbe5374a Add test with quoting multibyte GBK vs utf8mb4 in PDO 2024-02-23 23:52:24 +01:00
Kamil Tekiela
50598a7097
Tidy up pdo_mysql_attr_max_buffer_size.phpt 2024-02-18 13:09:19 +01:00
Saki Takamachi
d433035319
Fixed tests for libmysql (#13424) 2024-02-18 13:08:31 +01:00
Kamil Tekiela
1d45357409
Tidy up UT and add NEWS entry 2024-02-18 12:47:30 +01:00
Saki Takamachi
68f10504de
Fixed GH-13167 Fixed the behavior of bindValue and bindParam. (#13384)
Fixed to generate an error when a non-scalar value is passed in
`PDO_PARAM_EVT_EXEC_PRE` of `pdo_mysql_stmt_param_hook` unless
it is a `Stringable` object.
2024-02-18 12:10:21 +01:00
Máté Kocsis
10957e498c
Do not generate frameless info items when func info generation is disabled
While here, I fixed newlines around arginfo and function entry generation. Previously, newlines were repeated.
2024-02-18 11:39:00 +01:00
Kamil Tekiela
a96cc80be2
Fix PDO unit test description 2024-01-22 17:29:17 +01:00
Máté Kocsis
9c7b3914e7
DeclarePdoMysql:: ATTR_SSL_VERIFY_SERVER_CERT only for Mysqlnd 2024-01-14 16:29:13 +01:00
Máté Kocsis
d6a0b3af68
Implement PDO driver-specific subclasses
RFC: https://wiki.php.net/rfc/pdo_driver_specific_subclasses
Closes GH-12804

Co-Authored-By: Danack <Danack@basereality.com>
2024-01-11 23:22:41 +01:00
Niels Dossche
c3f6579f93 Merge branch 'PHP-8.2' into PHP-8.3
* PHP-8.2:
  Fix GH-12969: Fixed PDO::getAttribute() to get PDO::ATTR_STRINGIFY_FETCHES
2023-12-22 15:07:10 +01:00
SakiTakamachi
b333164423 Fix GH-12969: Fixed PDO::getAttribute() to get PDO::ATTR_STRINGIFY_FETCHES
Partial backport of GH-12793.

Closes GH-12970.
2023-12-22 15:06:01 +01:00
Saki Takamachi
866aa12bcd
ext/pdo: Fixed PDO::setAttribute() and PDO::getAttribute() (#12793) 2023-12-04 16:05:30 +00:00
Saki Takamachi
4bb75d569e
ext/pdo_mysql: Optimize tests (#12751) 2023-11-27 13:01:24 +00:00
Peter Kokot
de85e4a6d3
Remove unused PDO_MYSQL_MODULE_TYPE variable (#12711) 2023-11-18 04:18:15 +00:00
Alexandre Daubois
6f95273941
ext/pdo_mysql: Improve tests cleanup (#11879)
This allows the tests to be run in parallel.
2023-11-16 18:49:43 +00:00
Ilija Tovilo
39459467f6
Attempt to fix pdo_mysql conflict on CircleCI (#12563) 2023-10-30 16:19:27 +01:00
George Peter Banyard
c1fec9bbc3
PDO: Clean-up tests so it's easier to see if they use default test table (#12552) 2023-10-29 23:13:30 +00:00
Ilija Tovilo
f39b5c4c25
Close PHP tags in tests
Closes GH-12422
2023-10-18 17:34:10 +02:00
Ilija Tovilo
34e6e40447
Merge branch 'PHP-8.3'
* PHP-8.3:
  Move ARM build to CircleCI
2023-10-12 13:16:09 +02:00
Ilija Tovilo
b35e0c3069
Merge branch 'PHP-8.2' into PHP-8.3
* PHP-8.2:
  Move ARM build to CircleCI
2023-10-12 13:14:52 +02:00
Ilija Tovilo
9c3d3be8bd
Merge branch 'PHP-8.1' into PHP-8.2
* PHP-8.1:
  Move ARM build to CircleCI
2023-10-12 13:13:34 +02:00
Ilija Tovilo
4332546bbf
Move ARM build to CircleCI
Closes GH-12415
2023-10-12 13:11:38 +02:00
Peter Kokot
a8e1b1018d Remove unused --with-zlib-dir configure option
Commits that removed this option:
- 34dd032e4e
- a2c21e10b2
- e595f5cd8a

Closes GH-12209
2023-09-14 22:21:54 +02:00
Kamil Tekiela
82934746b7
Merge branch 'PHP-8.2'
* PHP-8.2:
  Fix MySQL Statement has a empty query result when the response field has changed, also Segmentation fault
2023-08-04 22:54:30 +01:00
Kamil Tekiela
4db701c049
Merge branch 'PHP-8.1' into PHP-8.2
* PHP-8.1:
  Fix MySQL Statement has a empty query result when the response field has changed, also Segmentation fault
2023-08-04 22:31:18 +01:00