Skip to content

Commit b56b8d0

Browse files
committed
Merge branch 'PHP-8.5'
* PHP-8.5: Fix GH-20767: build failure with preserve_none attribute enabled on mac.
2 parents 6487049 + 95a8395 commit b56b8d0

File tree

1 file changed

+6
-3
lines changed

1 file changed

+6
-3
lines changed

Zend/zend_portability.h

Lines changed: 6 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -336,9 +336,12 @@ char *alloca();
336336
# define ZEND_PRESERVE_NONE __attribute__((preserve_none))
337337
#endif
338338

339-
#if __has_attribute(musttail)
340-
# define HAVE_MUSTTAIL
341-
# define ZEND_MUSTTAIL __attribute__((musttail))
339+
340+
#if !defined(__apple_build_version__) || (defined(__apple_build_version__) && __apple_build_version__ >= 17000404)
341+
# if __has_attribute(musttail)
342+
# define HAVE_MUSTTAIL
343+
# define ZEND_MUSTTAIL __attribute__((musttail))
344+
# endif
342345
#endif
343346

344347
#if (defined(__GNUC__) && __GNUC__ >= 3 && !defined(__INTEL_COMPILER) && !defined(__APPLE__) && !defined(__hpux) && !defined(_AIX) && !defined(__osf__)) || __has_attribute(noreturn)

0 commit comments

Comments
 (0)