<pre style='margin:0'>
Ryan Schmidt (ryandesign) pushed a commit to branch master
in repository macports-ports.
</pre>
<p><a href="https://github.com/macports/macports-ports/commit/6223b017e474c9bdcda958c618553136c681da8d">https://github.com/macports/macports-ports/commit/6223b017e474c9bdcda958c618553136c681da8d</a></p>
<pre style="white-space: pre; background: #F8F8F8">The following commit(s) were added to refs/heads/master by this push:
<span style='display:block; white-space:pre;color:#404040;'> new 6223b01 php: Fix php-opcache when compiled with clang 6+
</span>6223b01 is described below
<span style='display:block; white-space:pre;color:#808000;'>commit 6223b017e474c9bdcda958c618553136c681da8d
</span>Author: Ryan Schmidt <ryandesign@macports.org>
AuthorDate: Mon Feb 25 10:31:38 2019 -0600
<span style='display:block; white-space:pre;color:#404040;'> php: Fix php-opcache when compiled with clang 6+
</span><span style='display:block; white-space:pre;color:#404040;'>
</span><span style='display:block; white-space:pre;color:#404040;'> Closes: https://trac.macports.org/ticket/58119
</span>---
lang/php/Portfile | 12 ++++++----
lang/php/files/patch-php55-Zend-EX_TMP_VAR.diff | 32 +++++++++++++++++++++++++
lang/php/files/patch-php56-Zend-EX_TMP_VAR.diff | 32 +++++++++++++++++++++++++
3 files changed, 72 insertions(+), 4 deletions(-)
<span style='display:block; white-space:pre;color:#808080;'>diff --git a/lang/php/Portfile b/lang/php/Portfile
</span><span style='display:block; white-space:pre;color:#808080;'>index 5141f70..188f785 100644
</span><span style='display:block; white-space:pre;background:#e0e0ff;'>--- a/lang/php/Portfile
</span><span style='display:block; white-space:pre;background:#e0e0ff;'>+++ b/lang/php/Portfile
</span><span style='display:block; white-space:pre;background:#e0e0e0;'>@@ -337,8 +337,8 @@ subport ${php} {
</span> 5.2.17 {revision 14}
5.3.29 {revision 4}
5.4.45 {revision 3}
<span style='display:block; white-space:pre;background:#ffe0e0;'>- 5.5.38 {revision 3}
</span><span style='display:block; white-space:pre;background:#ffe0e0;'>- 5.6.40 {revision 1}
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+ 5.5.38 {revision 4}
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+ 5.6.40 {revision 2}
</span> 7.0.33 {revision 1}
7.1.26 {revision 1}
7.2.15 {revision 0}
<span style='display:block; white-space:pre;background:#e0e0e0;'>@@ -350,6 +350,10 @@ subport ${php} {
</span> select.group php
select.file ${filespath}/${subport}
<span style='display:block; white-space:pre;background:#e0ffe0;'>+ if {[vercmp ${branch} 5.5] >= 0 && [vercmp ${branch} 7.0] < 0} {
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+ patchfiles-append patch-${php}-Zend-EX_TMP_VAR.diff
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+ }
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+
</span> post-patch {
# Ensure the build date is the same for all universal archs.
reinplace "s|^PHP_BUILD_DATE=.*$|PHP_BUILD_DATE=[clock format [clock seconds] -format {%Y-%m-%d}]|g" ${worksrcpath}/configure
<span style='display:block; white-space:pre;background:#e0e0e0;'>@@ -1295,8 +1299,8 @@ subport ${php}-odbc {
</span> if {[vercmp ${branch} 5.5] >= 0} {
subport ${php}-opcache {
switch -- ${version} {
<span style='display:block; white-space:pre;background:#ffe0e0;'>- 5.5.38 {revision 0}
</span><span style='display:block; white-space:pre;background:#ffe0e0;'>- 5.6.40 {revision 0}
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+ 5.5.38 {revision 1}
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+ 5.6.40 {revision 1}
</span> 7.0.33 {revision 0}
7.1.26 {revision 0}
7.2.15 {revision 0}
<span style='display:block; white-space:pre;color:#808080;'>diff --git a/lang/php/files/patch-php55-Zend-EX_TMP_VAR.diff b/lang/php/files/patch-php55-Zend-EX_TMP_VAR.diff
</span>new file mode 100644
<span style='display:block; white-space:pre;color:#808080;'>index 0000000..6f6a863
</span><span style='display:block; white-space:pre;background:#ffe0e0;'>--- /dev/null
</span><span style='display:block; white-space:pre;background:#e0e0ff;'>+++ b/lang/php/files/patch-php55-Zend-EX_TMP_VAR.diff
</span><span style='display:block; white-space:pre;background:#e0e0e0;'>@@ -0,0 +1,32 @@
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+Fix crash when php55-opcache is compiled with clang 6 or later.
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+https://bugs.freebsd.org/bugzilla/show_bug.cgi?id=227723
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+--- a/Zend/zend_compile.h
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>++++ b/Zend/zend_compile.h
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+@@ -401,9 +401,6 @@
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+ #define EX(element) execute_data.element
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+-#define EX_TMP_VAR(ex, n) ((temp_variable*)(((char*)(ex)) + ((int)(n))))
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+-#define EX_TMP_VAR_NUM(ex, n) (EX_TMP_VAR(ex, 0) - (1 + (n)))
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+-
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+ #define EX_CV_NUM(ex, n) (((zval***)(((char*)(ex))+ZEND_MM_ALIGNED_SIZE(sizeof(zend_execute_data))))+(n))
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+--- a/Zend/zend_execute.h
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>++++ b/Zend/zend_execute.h
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+@@ -71,6 +71,15 @@
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+ ZEND_API char * zend_verify_arg_class_kind(const zend_arg_info *cur_arg_info, ulong fetch_type, const char **class_name, zend_class_entry **pce TSRMLS_DC);
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+ ZEND_API int zend_verify_arg_error(int error_type, const zend_function *zf, zend_uint arg_num, const char *need_msg, const char *need_kind, const char *given_msg, const char *given_kind TSRMLS_DC);
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>++static zend_always_inline temp_variable *EX_TMP_VAR(void *ex, int n)
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>++{
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>++ return (temp_variable *)((zend_uintptr_t)ex + n);
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>++}
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>++static inline temp_variable *EX_TMP_VAR_NUM(void *ex, int n)
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>++{
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>++ return (temp_variable *)((zend_uintptr_t)ex - (1 + n) * sizeof(temp_variable));
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>++}
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>++
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+ static zend_always_inline void i_zval_ptr_dtor(zval *zval_ptr ZEND_FILE_LINE_DC)
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+ {
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+ if (!Z_DELREF_P(zval_ptr)) {
</span><span style='display:block; white-space:pre;color:#808080;'>diff --git a/lang/php/files/patch-php56-Zend-EX_TMP_VAR.diff b/lang/php/files/patch-php56-Zend-EX_TMP_VAR.diff
</span>new file mode 100644
<span style='display:block; white-space:pre;color:#808080;'>index 0000000..bb3d22d
</span><span style='display:block; white-space:pre;background:#ffe0e0;'>--- /dev/null
</span><span style='display:block; white-space:pre;background:#e0e0ff;'>+++ b/lang/php/files/patch-php56-Zend-EX_TMP_VAR.diff
</span><span style='display:block; white-space:pre;background:#e0e0e0;'>@@ -0,0 +1,32 @@
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+Fix crash when php56-opcache is compiled with clang 6 or later.
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+https://bugs.freebsd.org/bugzilla/show_bug.cgi?id=227723
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+--- a/Zend/zend_compile.h
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>++++ b/Zend/zend_compile.h
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+@@ -414,9 +414,6 @@ struct _zend_execute_data {
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+ #define EX(element) execute_data.element
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+-#define EX_TMP_VAR(ex, n) ((temp_variable*)(((char*)(ex)) + ((int)(n))))
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+-#define EX_TMP_VAR_NUM(ex, n) (EX_TMP_VAR(ex, 0) - (1 + (n)))
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+-
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+ #define EX_CV_NUM(ex, n) (((zval***)(((char*)(ex))+ZEND_MM_ALIGNED_SIZE(sizeof(zend_execute_data))))+(n))
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+--- a/Zend/zend_execute.h
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>++++ b/Zend/zend_execute.h
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+@@ -71,6 +71,15 @@ ZEND_API int zend_eval_stringl_ex(char *str, int str_len, zval *retval_ptr, char
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+ ZEND_API char * zend_verify_arg_class_kind(const zend_arg_info *cur_arg_info, ulong fetch_type, const char **class_name, zend_class_entry **pce TSRMLS_DC);
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+ ZEND_API int zend_verify_arg_error(int error_type, const zend_function *zf, zend_uint arg_num, const char *need_msg, const char *need_kind, const char *given_msg, const char *given_kind TSRMLS_DC);
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>++static zend_always_inline temp_variable *EX_TMP_VAR(void *ex, int n)
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>++{
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>++ return (temp_variable *)((zend_uintptr_t)ex + n);
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>++}
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>++static inline temp_variable *EX_TMP_VAR_NUM(void *ex, int n)
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>++{
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>++ return (temp_variable *)((zend_uintptr_t)ex - (1 + n) * sizeof(temp_variable));
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>++}
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>++
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+ static zend_always_inline void i_zval_ptr_dtor(zval *zval_ptr ZEND_FILE_LINE_DC TSRMLS_DC)
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+ {
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+ if (!Z_DELREF_P(zval_ptr)) {
</span></pre><pre style='margin:0'>
</pre>