From ab8af9a3059aea8cd1854548fc8b684708388ba6 Mon Sep 17 00:00:00 2001 From: Remi Collet Date: Wed, 30 Jul 2025 14:13:30 +0200 Subject: fix build with PHP 8.5.0alpha3 using patch from https://github.com/bukka/phpc/pull/4 --- 4.patch | 37 +++++++++++++++++++++++++++++++++++++ 1 file changed, 37 insertions(+) create mode 100644 4.patch (limited to '4.patch') diff --git a/4.patch b/4.patch new file mode 100644 index 0000000..0c9f1f9 --- /dev/null +++ b/4.patch @@ -0,0 +1,37 @@ +From e9ad43262a6b036bf2f81013f23783eec619a537 Mon Sep 17 00:00:00 2001 +From: Remi Collet +Date: Wed, 30 Jul 2025 14:02:25 +0200 +Subject: [PATCH] use Zend/zend_smart_string.h + +--- + phpc.h | 8 ++++++++ + 1 file changed, 8 insertions(+) + +diff --git a/phpc.h b/phpc.h +index 93d5cca..075bbad 100644 +--- a/phpc.h ++++ b/phpc.h +@@ -266,7 +266,11 @@ typedef int phpc_str_size_t; + + /* Smart string */ + #if defined(PHPC_SMART_STR_INCLUDE) || defined(PHPC_SMART_CSTR_INCLUDE) ++#if PHP_VERSION_ID < 70200 + #include "ext/standard/php_smart_str.h" ++#else ++#include "Zend/zend_smart_str.h" ++#endif + + #ifdef PHPC_SMART_CSTR_INCLUDE + /* smart_str for C string has been renamed in PHP 7 so we have to wrap it */ +@@ -929,7 +933,11 @@ typedef size_t phpc_str_size_t; + #endif /* PHPC_SMART_STR_INCLUDE */ + + #ifdef PHPC_SMART_CSTR_INCLUDE ++#if PHP_VERSION_ID < 70200 + #include "ext/standard/php_smart_string.h" ++#else ++#include "Zend/zend_smart_string.h" ++#endif + /* smart_str for C string has been renamed in PHP 7 so we have to wrap it */ + #define phpc_smart_cstr smart_string + #define phpc_smart_cstr_alloc smart_string_alloc -- cgit