96 Commits
Author SHA1 Message Date
Gina Peter Banyard 3e458e5fdc Merge branch 'PHP-8.5' into PHP-8.6
* PHP-8.5:
  Update NEWS
  ext/standard/tests: work around Windows quoting with tempfiles.
  .github/scripts/windows: pass an extension_dir to the test runner.
  {ext/standard,sapi/cli}/tests: pass TEST_PHP_EXTRA_ARGS to php
  ext/standard/tests: pass TEST_PHP_EXTRA_ARGS to some proc_open() tests
  sapi/cli/tests/023.phpt: support TEST_PHP_EXTRA_ARGS
  std: Fix memory leak of the last response headers after a nested HTTP request (#24201)
  Fiber: hold the object a callable resolved to in the creating frame (#24134)
2026-10-14 18:43:37 +01:00
Gina Peter Banyard b1a3a4e082 Merge branch 'PHP-8.4' into PHP-8.5
* PHP-8.4:
  Update NEWS
  ext/standard/tests: work around Windows quoting with tempfiles.
  .github/scripts/windows: pass an extension_dir to the test runner.
  {ext/standard,sapi/cli}/tests: pass TEST_PHP_EXTRA_ARGS to php
  ext/standard/tests: pass TEST_PHP_EXTRA_ARGS to some proc_open() tests
  sapi/cli/tests/023.phpt: support TEST_PHP_EXTRA_ARGS
  std: Fix memory leak of the last response headers after a nested HTTP request (#24201)
  Fiber: hold the object a callable resolved to in the creating frame (#24134)
2026-10-14 18:39:38 +01:00
Michael Orlitzky e56aedb3f7 .github/scripts/windows: pass an extension_dir to the test runner.
In some cases, on Windows, we pass -dextension=mysqli to the test
runner, but omit the extension_dir. This works fine so long as that
extension_dir can be obtained from php.ini. However, we have at least
one test that loads some other (or no) php.ini file; when that
happens, the mysqli extension cannot be found. To solve that problem,
we now also specify an extension_dir whenever we specify an extension
to load.
2026-10-14 18:34:08 +01:00
Matteo Beccati 5714009960 CI updates after forking 8.6 2026-09-22 14:57:33 +02:00
Matteo Beccati 742d4f6454 Merge branch 'PHP-8.5' into PHP-8.6
* PHP-8.5:
  CI updates after forking 8.6
2026-09-22 14:49:28 +02:00
Matteo Beccati 9a3e7f3ab2 Merge branch 'PHP-8.4' into PHP-8.5
* PHP-8.4:
  CI updates after forking 8.6
2026-09-22 14:49:12 +02:00
Matteo Beccati 95c29bbb27 CI updates after forking 8.6 2026-09-22 14:48:18 +02:00
Shivam Mathur 132c0ecc03 Merge branch 'PHP-8.5'
* PHP-8.5:
  Fix hMailServer URL in Windows CI (#23055)
2026-08-05 12:32:04 +05:30
Shivam Mathur 1fb0545d4c Merge branch 'PHP-8.4' into PHP-8.5
* PHP-8.4:
  Fix hMailServer URL in Windows CI (#23055)
2026-08-05 12:31:54 +05:30
Shivam Mathur 43f7a9752d Merge branch 'PHP-8.3' into PHP-8.4
* PHP-8.3:
  Fix hMailServer URL in Windows CI (#23055)
2026-08-05 12:31:24 +05:30
Shivam Mathur e0d6b21c59 Merge branch 'PHP-8.2' into PHP-8.3
* PHP-8.2:
  Fix hMailServer URL in Windows CI (#23055)
2026-08-05 12:28:16 +05:30
Shivam Mathur d3af7240d9 Fix hMailServer URL in Windows CI (#23055) 2026-08-05 12:27:48 +05:30
Shivam Mathur 900afbb315 Merge branch 'PHP-8.5'
* PHP-8.5:
  Switch to VS18 for the master branch (#22094)
2026-05-20 20:03:55 +05:30
Shivam Mathur 3ec06701d6 Merge branch 'PHP-8.4' into PHP-8.5
* PHP-8.4:
  Switch to VS18 for the master branch (#22094)
2026-05-20 20:03:43 +05:30
Shivam Mathur 8708c9d02e Merge branch 'PHP-8.3' into PHP-8.4
* PHP-8.3:
  Switch to VS18 for the master branch (#22094)
2026-05-20 20:02:44 +05:30
Shivam Mathur f3938c3285 Merge branch 'PHP-8.2' into PHP-8.3
* PHP-8.2:
  Switch to VS18 for the master branch (#22094)
2026-05-20 20:01:27 +05:30
Shivam Mathur a03961b187 Switch to VS18 for the master branch (#22094) 2026-05-20 20:01:06 +05:30
Marc 7cd8a0a0a4 [Windows] Improve clang-cl support (#21618)
* fix compiling (intl) C++ extensions --with-toolset=clang

* guard the double extern "C" { ... } for clang-only

* don't error on warnings with clang

* enable compiler intrinsics for clang too

* make --enable-compiler-intrinsics=no same as disabled

* add clang windows x64 ZTS test

* remove check if it's clang

* debloat logs from common warning

* @shivammathur feedback

* remove CI changes

* rebase on https://github.com/php/php-src/pull/21630

* fix default to asan => false

* bring back explicit error

* fix typo
2026-04-20 16:20:59 +02:00
Gina Peter Banyard 7c6affd617 Merge branch 'PHP-8.4' into PHP-8.5
* PHP-8.4:
  Update NEWS for recent pgsql bugfix
  ext/pgsql: Fix segfaults when attempting to fetch row into a non-instantiable class name (#20180)
2025-11-04 00:09:44 +00:00
Gina Peter Banyard afca514c3b Merge branch 'PHP-8.3' into PHP-8.4
* PHP-8.3:
  Update NEWS for recent pgsql bugfix
  ext/pgsql: Fix segfaults when attempting to fetch row into a non-instantiable class name (#20180)
2025-11-04 00:08:42 +00:00
Gina Peter BanyardandNiels Dossche 94dc6ae871 ext/pgsql: Fix segfaults when attempting to fetch row into a non-instantiable class name (#20180)
Also fix Windows CI with Postgres and CLEAN sections

---------

Co-authored-by: Niels Dossche <7771979+nielsdos@users.noreply.github.com>
2025-11-04 00:04:30 +00:00
Ilija Tovilo 08ccbc46aa Merge branch 'PHP-8.4' into PHP-8.5
* PHP-8.4:
  Change master branch check to 8.6
2025-09-28 11:56:26 +02:00
Ilija Tovilo a6b32bd8fc Merge branch 'PHP-8.3' into PHP-8.4
* PHP-8.3:
  Change master branch check to 8.6
2025-09-28 11:56:18 +02:00
Ilija Tovilo 8756ee034d Merge branch 'PHP-8.2' into PHP-8.3
* PHP-8.2:
  Change master branch check to 8.6
2025-09-28 11:56:11 +02:00
Ilija Tovilo 5dd764b1b3 Merge branch 'PHP-8.1' into PHP-8.2
* PHP-8.1:
  Change master branch check to 8.6
2025-09-28 11:56:01 +02:00
Shivam Mathur 107075605d Change master branch check to 8.6 2025-09-28 09:54:13 +05:30
Shivam Mathur 6147be32fc Merge branch 'PHP-8.3' into PHP-8.4 2025-08-06 00:05:28 +00:00
Shivam Mathur f08ac4f1c9 Merge branch 'PHP-8.2' into PHP-8.3 2025-08-06 00:04:58 +00:00
Shivam Mathur 871de14ceb Merge branch 'PHP-8.1' into PHP-8.2 2025-08-06 00:03:49 +00:00
Shivam Mathur 8199cad99f Fix master branch check in find-target-branch.bat (#19385) 2025-08-06 05:32:36 +05:30
Arnaud Le BlancandTim Düsterhus 7b3e68ff69 Fix error handling inconsistency with opcache
When opcache is enabled, error handling is altered in the following ways:

 * Errors emitted during compilation bypass the user-defined error handler
 * Exceptions emitted during class linking are turned into fatal errors

Changes here make the behavior consistent regardless of opcache being enabled or
not:

 * Errors emitted during compilation and class linking are always delayed and
   handled after compilation or class linking. During handling, user-defined
   error handlers are not bypassed. Fatal errors emitted during compilation or
   class linking cause any delayed errors to be handled immediately (without
   calling user-defined error handlers, as it would be unsafe).
 * Exceptions thrown by user-defined error handlers when handling class linking
   error are not promoted to fatal errors anymore and do not prevent linking.

Fixes GH-17422.
Closes GH-18541.
Closes GH-17627.

Co-authored-by: Tim Düsterhus <tim@bastelstu.be>
2025-07-27 11:01:49 +02:00
Arnaud Le BlancandTim Düsterhus 7b4c14dc10 Make OPcache non-optional
This removes the --enable-opcache/--disable-opcache configure switch. OPcache
is now always builtin. The default value of opcache.enable and
opcache.enable_cli is unchanged.

RFC: https://wiki.php.net/rfc/make_opcache_required

Closes GH-18961.

Co-authored-by: Tim Düsterhus <tim@tideways-gmbh.com>
2025-07-27 09:40:22 +02:00
Shivam Mathur 720917f39a Merge branch 'PHP-8.4' 2025-06-25 02:03:18 +05:30
Shivam Mathur d2a30acf33 Merge branch 'PHP-8.3' into PHP-8.4 2025-06-25 02:01:59 +05:30
Shivam Mathur dc79f4c8c6 Merge branch 'PHP-8.2' into PHP-8.3 2025-06-25 02:01:24 +05:30
Shivam Mathur 91f2458020 Merge branch 'PHP-8.1' into PHP-8.2 2025-06-25 02:00:11 +05:30
Shivam Mathur 6233dc6210 Switch to windows-2022 in CI (#18927)
* Switch to windows-2022 in CI

windows-2019 runner will be dropped by GitHub on 2025-06-30.

* xfail test cases that fail on windows-2022
2025-06-25 01:57:07 +05:30
Saki Takamachi 23687672f3 Merge branch 'PHP-8.4'
* PHP-8.4:
  Fixed GH-17383 - pdo_firebird: PDOException has wrong code and message since PHP 8.4 (#18072)
2025-04-19 14:11:35 +09:00
Saki Takamachi 685baf77df Fixed GH-17383 - pdo_firebird: PDOException has wrong code and message since PHP 8.4 (#18072)
Closes #18072
Fixes #17383
2025-04-19 14:11:20 +09:00
Christoph M. Becker 08ace8409d Merge branch 'PHP-8.4'
* PHP-8.4:
  Prevent using system DLLs when running the tests
2025-02-16 23:08:21 +01:00
Christoph M. Becker 7a734caacc Merge branch 'PHP-8.3' into PHP-8.4
* PHP-8.3:
  Prevent using system DLLs when running the tests
2025-02-16 23:06:54 +01:00
Christoph M. Becker c7bc14dd6b Prevent using system DLLs when running the tests
The search order for DLLs on Windows is (simplified):

* the application folder
* the system folder
* all folders in the `PATH`

(The full details are documented on Microsoft Learn[1].)

As is, we're adding `deps\bin` to the `PATH` when running the tests,
but any DLLs in the system folder take precedence, so these would be
used instead of our intended dependencies.  To mitigate that, we copy
over all DLLs from `deps\bin` to our application folder (i.e. where
php.exe, php-cgi.exe and phpdbg.exe are placed).

Since we're doing this, there is no more need to attempt to remove the
OpenSSL DLLs in the system folder (what seems to be a bad idea anyway).

[1] <https://learn.microsoft.com/en-us/windows/win32/dlls/dynamic-link-library-search-order>

Closes GH-17805.
2025-02-16 23:06:04 +01:00
Christoph M. Becker ed9c283589 Fail build_task.bat if main nmake failed (GH-17820)
Otherwise we may not notice Windows CI build failures.

Fixes GH-17818.
2025-02-15 18:26:11 +01:00
Christoph M. Becker fe9c9049ef Elevate Windows CI to /W3 (sans C4018/C4267) (GH-17665)
C4018[1] is about unsigned/signed comparisons; C4267[2] is about
conversion from `size_t` to a "smaller" type.  We likely should resolve
these warnings in the long run, but for now, it seems like a no brainer
to elevate to `/W3` even if we have to exempt two additional categories
of warnings, since we can catch some others.  And we no longer need to
elevate C4010[3] to a higher level to catch it.

[1] <https://learn.microsoft.com/en-us/cpp/error-messages/compiler-warnings/compiler-warning-level-3-c4018>
[2] <https://learn.microsoft.com/en-us/cpp/error-messages/compiler-warnings/compiler-warning-level-3-c4267>
[3] <https://learn.microsoft.com/de-de/cpp/error-messages/compiler-warnings/compiler-warning-level-3-c4013>
2025-02-14 17:39:54 +01:00
Christoph M. Becker e4999275c2 Fix GH-17658: COMPersistHelper::LoadFromStream() can segfault (GH-17659)
* Fix GH-17658: COMPersistHelper::LoadFromStream() can segfault

The actual fix is trivial, but to be able to test the behavior we have
to introduce an own COM object, since existing persistable objects
likely implement `IPersistInit`, not only `IPersist`.  We also want to
avoid further test dependencies on possibly unavailable objects, such
as `Word.Application`.

To this purposes, we add a small COM in-process server, which may be
extended for other testing purposes.  We keep it simple by implementing
it in C++, but without using any more sophisticated frameworks like ATL.

This component needs to be built explicitly (`nmake comtest.dll`), and
also needs to be explicitly registered (`nmake register_comtest`).
When no longer needed, it is possible to unregister the component
(`nmake unregister_comtest`).
2025-02-11 12:42:25 +01:00
Christoph M. Becker a611be4c07 Elevate Windows CI to /W2 (sans C4146/C4244) (GH-17581)
C4146[1] is about unary minus applied to unsigned operands; that
behavior is well defined, and apparently used deliberately in the code
base.

C4244[2] is about possible loss of data when converting to another
arithmetic type.  This is addressed by another PR[3].

Anyhow, it seems like a no brainer to elevate to `/W2` even if we have
to exempt two categories of warnings, since we can catch some others.

[1] <https://learn.microsoft.com/en-us/cpp/error-messages/compiler-warnings/compiler-warning-level-2-c4146?view=msvc-170>
[2] <https://learn.microsoft.com/en-us/cpp/error-messages/compiler-warnings/compiler-warning-level-2-c4244>
[3] <https://github.com/php/php-src/pull/17076>
2025-02-01 12:25:24 +01:00
Jakub Zelenka 5ba299be18 Merge branch 'PHP-8.4' 2025-01-06 12:21:20 +01:00
Jakub Zelenka 35c03c165e Merge branch 'PHP-8.3' into PHP-8.4 2025-01-06 12:20:50 +01:00
Jakub Zelenka 3606701f48 Merge branch 'PHP-8.2' into PHP-8.3 2025-01-06 12:19:36 +01:00
Jakub Zelenka 5be673d29e Merge branch 'PHP-8.1' into PHP-8.2 2025-01-06 12:18:54 +01:00