Skip to content

Commit 53ae2b1

Browse files
committed
Merge branch 'PHP-8.0' into PHP-8.1
* PHP-8.0: fix #81656: GCC-11 silently ignores -R
2 parents 26e4244 + 1f38c00 commit 53ae2b1

File tree

2 files changed

+15
-14
lines changed

2 files changed

+15
-14
lines changed

NEWS

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -6,6 +6,7 @@ PHP NEWS
66
. Fixed bug #81216 (Nullsafe operator leaks dynamic property name). (Dmitry)
77
. Fixed bug #81684 (Using null coalesce assignment with $GLOBALS["x"] produces
88
opcode error). (ilutov)
9+
. Fixed bug #81656 (GCC-11 silently ignores -R). (Michael Wallner)
910

1011
- MBString:
1112
. Fixed bug #81693 (mb_check_encoding(7bit) segfaults). (cmb)

build/php.m4

Lines changed: 14 additions & 14 deletions
Original file line numberDiff line numberDiff line change
@@ -279,25 +279,25 @@ dnl
279279
dnl Checks for -R, etc. switch.
280280
dnl
281281
AC_DEFUN([PHP_RUNPATH_SWITCH],[
282-
AC_MSG_CHECKING([if compiler supports -R])
283-
AC_CACHE_VAL(php_cv_cc_dashr,[
282+
AC_MSG_CHECKING([if compiler supports -Wl,-rpath,])
283+
AC_CACHE_VAL(php_cv_cc_rpath,[
284284
SAVE_LIBS=$LIBS
285-
LIBS="-R /usr/$PHP_LIBDIR $LIBS"
286-
AC_LINK_IFELSE([AC_LANG_PROGRAM([], [])],[php_cv_cc_dashr=yes],[php_cv_cc_dashr=no])
285+
LIBS="-Wl,-rpath,/usr/$PHP_LIBDIR $LIBS"
286+
AC_LINK_IFELSE([AC_LANG_PROGRAM([], [])],[php_cv_cc_rpath=yes],[php_cv_cc_rpath=no])
287287
LIBS=$SAVE_LIBS])
288-
AC_MSG_RESULT([$php_cv_cc_dashr])
289-
if test $php_cv_cc_dashr = "yes"; then
290-
ld_runpath_switch=-R
288+
AC_MSG_RESULT([$php_cv_cc_rpath])
289+
if test $php_cv_cc_rpath = "yes"; then
290+
ld_runpath_switch=-Wl,-rpath,
291291
else
292-
AC_MSG_CHECKING([if compiler supports -Wl,-rpath,])
293-
AC_CACHE_VAL(php_cv_cc_rpath,[
292+
AC_MSG_CHECKING([if compiler supports -R])
293+
AC_CACHE_VAL(php_cv_cc_dashr,[
294294
SAVE_LIBS=$LIBS
295-
LIBS="-Wl,-rpath,/usr/$PHP_LIBDIR $LIBS"
296-
AC_LINK_IFELSE([AC_LANG_PROGRAM([], [])],[php_cv_cc_rpath=yes],[php_cv_cc_rpath=no])
295+
LIBS="-R /usr/$PHP_LIBDIR $LIBS"
296+
AC_LINK_IFELSE([AC_LANG_PROGRAM([], [])],[php_cv_cc_dashr=yes],[php_cv_cc_dashr=no])
297297
LIBS=$SAVE_LIBS])
298-
AC_MSG_RESULT([$php_cv_cc_rpath])
299-
if test $php_cv_cc_rpath = "yes"; then
300-
ld_runpath_switch=-Wl,-rpath,
298+
AC_MSG_RESULT([$php_cv_cc_dashr])
299+
if test $php_cv_cc_dashr = "yes"; then
300+
ld_runpath_switch=-R
301301
else
302302
dnl Something innocuous.
303303
ld_runpath_switch=-L

0 commit comments

Comments
 (0)