Skip to content

Commit 5d7757b

Browse files
committed
Merge branch 'PHP-8.3' into PHP-8.4
2 parents f1fa653 + 80b00ef commit 5d7757b

File tree

9 files changed

+36
-123
lines changed

9 files changed

+36
-123
lines changed

bin/make-patches.sh

Lines changed: 0 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -13,22 +13,19 @@ patch-cmake-8.3-aspell
1313
patch-cmake-8.3-dmalloc
1414
patch-cmake-8.3-php-config
1515
patch-cmake-8.3-phpdbg-prompt
16-
patch-cmake-8.3-zend-vm-gen
1716
patch-cmake-8.4
1817
patch-cmake-8.4-asm
1918
patch-cmake-8.4-dmalloc
2019
patch-cmake-8.4-php-config
2120
patch-cmake-8.4-phpdbg-prompt
2221
patch-cmake-8.4-timelib
23-
patch-cmake-8.4-zend-vm-gen
2422
patch-cmake-8.5
2523
patch-cmake-8.5-asm
2624
patch-cmake-8.5-dmalloc
2725
patch-cmake-8.5-docs
2826
patch-cmake-8.5-php-config
2927
patch-cmake-8.5-phpdbg-prompt
3028
patch-cmake-8.5-timelib
31-
patch-cmake-8.5-zend-vm-gen
3229
"
3330

3431
# A list of supported PHP versions.

cmake/Zend/CMakeLists.txt

Lines changed: 26 additions & 20 deletions
Original file line numberDiff line numberDiff line change
@@ -468,29 +468,35 @@ endif()
468468
# Create files and set installation.
469469
################################################################################
470470

471-
if(PHPSystem_EXECUTABLE)
472-
set(PHP_EXECUTABLE ${PHPSystem_EXECUTABLE})
473-
elseif(NOT CMAKE_CROSSCOMPILING)
474-
set(PHP_EXECUTABLE "$<TARGET_FILE:php_cli>")
475-
elseif(CMAKE_CROSSCOMPILING AND CMAKE_CROSSCOMPILING_EMULATOR)
476-
set(PHP_EXECUTABLE "${CMAKE_CROSSCOMPILING_EMULATOR};$<TARGET_FILE:php_cli>")
477-
endif()
471+
# On 32-bit targets the zend_vm_gen.php script outputs deprecation warnings. As
472+
# 32-bit targets are not considered development oriented environments, where the
473+
# files need to be regenerated, executing this script is skipped.
474+
# See: https://github.com/php/php-src/issues/15899
475+
if(NOT CMAKE_SIZEOF_VOID_P EQUAL 4)
476+
if(PHPSystem_EXECUTABLE)
477+
set(PHP_EXECUTABLE ${PHPSystem_EXECUTABLE})
478+
elseif(NOT CMAKE_CROSSCOMPILING)
479+
set(PHP_EXECUTABLE "$<TARGET_FILE:php_cli>")
480+
elseif(CMAKE_CROSSCOMPILING AND CMAKE_CROSSCOMPILING_EMULATOR)
481+
set(PHP_EXECUTABLE "${CMAKE_CROSSCOMPILING_EMULATOR};$<TARGET_FILE:php_cli>")
482+
endif()
478483

479-
if(PHP_EXECUTABLE)
480-
# Run the Zend/zend_vm_gen.php script.
481-
add_custom_command(
482-
OUTPUT zend_vm
483-
COMMAND ${PHP_EXECUTABLE} ${CMAKE_CURRENT_SOURCE_DIR}/zend_vm_gen.php
484-
DEPENDS
485-
php_cli
486-
${CMAKE_CURRENT_SOURCE_DIR}/zend_vm_execute.skl
487-
COMMENT "[Zend] Regenerating zend_vm_execute.h and zend_vm_opcodes.{h,c}"
488-
VERBATIM
489-
)
484+
if(PHP_EXECUTABLE)
485+
# Run the Zend/zend_vm_gen.php script.
486+
add_custom_command(
487+
OUTPUT zend_vm
488+
COMMAND ${PHP_EXECUTABLE} ${CMAKE_CURRENT_SOURCE_DIR}/zend_vm_gen.php
489+
DEPENDS
490+
php_cli
491+
${CMAKE_CURRENT_SOURCE_DIR}/zend_vm_execute.skl
492+
COMMENT "[Zend] Regenerating zend_vm_execute.h and zend_vm_opcodes.{h,c}"
493+
VERBATIM
494+
)
490495

491-
add_custom_target(zend_generate_vm ALL DEPENDS zend_vm)
496+
add_custom_target(zend_generate_vm ALL DEPENDS zend_vm)
492497

493-
set_property(SOURCE zend_vm PROPERTY SYMBOLIC TRUE)
498+
set_property(SOURCE zend_vm PROPERTY SYMBOLIC TRUE)
499+
endif()
494500
endif()
495501

496502
if(NOT CMAKE_SYSTEM_NAME STREQUAL "Windows")

cmake/cmake/modules/PHP/Install.cmake

Lines changed: 8 additions & 10 deletions
Original file line numberDiff line numberDiff line change
@@ -1,13 +1,16 @@
11
#[=============================================================================[
22
Set the `CMAKE_INSTALL_*` variables inside the `install(CODE|SCRIPT)`.
33
4-
This is built on top of the CMake's `GNUInstallDirs` module. At the time of
5-
writing, CMake documentation mentions special cases where, for example, the
6-
`CMAKE_INSTALL_FULL_SYSCONFDIR` variable becomes the `/etc`, when the install
7-
prefix is `/usr`, and similar.
4+
This is built on top of the CMake's
5+
[`GNUInstallDirs`](https://cmake.org/cmake/help/latest/module/GNUInstallDirs.html)
6+
module and the
7+
[`install()`](https://cmake.org/cmake/help/latest/command/install.html) command.
8+
At the time of writing, CMake documentation mentions special cases where, for
9+
example, the `CMAKE_INSTALL_FULL_SYSCONFDIR` variable becomes the `/etc`, when
10+
the install prefix is `/usr`, and similar.
811
912
However, some of these special cases aren't taken into account when using the
10-
`install()` commands.
13+
`install()` commands. See: https://gitlab.kitware.com/cmake/cmake/-/issues/25852
1114
1215
This module exposes the following function:
1316
@@ -24,11 +27,6 @@ php_install(CODE "
2427
message(STATUS \"CMAKE_INSTALL_SYSCONFDIR=\${CMAKE_INSTALL_SYSCONFDIR}\")
2528
")
2629
```
27-
28-
See:
29-
30-
* https://cmake.org/cmake/help/latest/module/GNUInstallDirs.html
31-
* https://cmake.org/cmake/help/latest/command/install.html
3230
#]=============================================================================]
3331

3432
include_guard(GLOBAL)

cmake/sapi/fpm/CMakeLists.txt

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -444,7 +444,7 @@ php_configure_file(
444444
EXPANDED_SYSCONFDIR "$<PATH:ABSOLUTE_PATH,NORMALIZE,${CMAKE_INSTALL_SYSCONFDIR},$<INSTALL_PREFIX>>"
445445
)
446446

447-
install(TARGETS php_fpm DESTINATION ${CMAKE_INSTALL_SBINDIR})
447+
install(TARGETS php_fpm RUNTIME DESTINATION ${CMAKE_INSTALL_SBINDIR})
448448

449449
php_install(CODE "
450450
# Create log and run directories on installation.

cmake/sapi/phpdbg/CMakeLists.txt

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -271,7 +271,6 @@ install(
271271

272272
# Create log and run directories on installation.
273273
php_install(CODE "
274-
# Create log and run directories on installation.
275274
file(
276275
MAKE_DIRECTORY
277276
\"\$ENV{DESTDIR}\${CMAKE_INSTALL_FULL_LOCALSTATEDIR}/log\"

patches/8.3/aspell.patch

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -43,7 +43,7 @@ index 879300f992..de820684fb 100644
4343
libsasl2-dev:i386 \
4444
libsodium-dev:i386 \
4545
diff --git a/.github/actions/apt-x64/action.yml b/.github/actions/apt-x64/action.yml
46-
index 8f2f608278..c3ae0ada63 100644
46+
index bc2aa00df2..739abf8fe5 100644
4747
--- a/.github/actions/apt-x64/action.yml
4848
+++ b/.github/actions/apt-x64/action.yml
4949
@@ -34,7 +34,6 @@ runs:

patches/8.3/zend-vm-gen.patch

Lines changed: 0 additions & 29 deletions
This file was deleted.

patches/8.4/zend-vm-gen.patch

Lines changed: 0 additions & 29 deletions
This file was deleted.

patches/8.5/zend-vm-gen.patch

Lines changed: 0 additions & 29 deletions
This file was deleted.

0 commit comments

Comments
 (0)