Skip to content

Use AC_SUBST instead of PHP_SUBST_OLD where possible #13993

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Merged
merged 1 commit into from
Apr 18, 2024
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
7 changes: 3 additions & 4 deletions configure.ac
Original file line number Diff line number Diff line change
Expand Up @@ -1464,6 +1464,9 @@ AC_SUBST(EXPANDED_SYSCONFDIR)
AC_SUBST(EXPANDED_LOCALSTATEDIR)
AC_SUBST(EXPANDED_PHP_CONFIG_FILE_PATH)
AC_SUBST(EXPANDED_PHP_CONFIG_FILE_SCAN_DIR)
AC_SUBST([PHP_INSTALLED_SAPIS])
AC_SUBST([SAPI_LIBNAME_SHARED])
AC_SUBST([SAPI_LIBNAME_STATIC])

PHP_UTILIZE_RPATHS

Expand All @@ -1490,8 +1493,6 @@ if test -n "${PHP_BUILD_ARCH}"; then
AC_DEFINE_UNQUOTED(PHP_BUILD_ARCH,"$PHP_BUILD_ARCH",[build architecture])
fi

PHP_SUBST_OLD(PHP_INSTALLED_SAPIS)

PHP_SUBST(PHP_FASTCGI_OBJS)
PHP_SUBST(PHP_SAPI_OBJS)
PHP_SUBST(PHP_BINARY_OBJS)
Expand Down Expand Up @@ -1553,8 +1554,6 @@ PHP_SUBST(SHELL)
PHP_SUBST(PHP_FRAMEWORKS)
PHP_SUBST(PHP_FRAMEWORKPATH)
PHP_SUBST(INSTALL_HEADERS)
PHP_SUBST_OLD(SAPI_LIBNAME_SHARED)
PHP_SUBST_OLD(SAPI_LIBNAME_STATIC)

old_CC=$CC

Expand Down
8 changes: 4 additions & 4 deletions ext/odbc/config.m4
Original file line number Diff line number Diff line change
Expand Up @@ -454,10 +454,10 @@ if test -n "$ODBC_TYPE"; then
PHP_SUBST(ODBC_SHARED_LIBADD)
PHP_SUBST(ODBC_INCDIR)
PHP_SUBST(ODBC_LIBDIR)
PHP_SUBST_OLD(ODBC_CFLAGS)
PHP_SUBST_OLD(ODBC_LIBS)
PHP_SUBST_OLD(ODBC_LFLAGS)
PHP_SUBST_OLD(ODBC_TYPE)
AC_SUBST([ODBC_CFLAGS])
AC_SUBST([ODBC_LIBS])
AC_SUBST([ODBC_LFLAGS])
AC_SUBST([ODBC_TYPE])

PHP_NEW_EXTENSION(odbc, php_odbc.c odbc_utils.c, $ext_shared,, [$ODBC_CFLAGS -DZEND_ENABLE_STATIC_TSRMLS_CACHE=1])
else
Expand Down
2 changes: 1 addition & 1 deletion sapi/embed/config.m4
Original file line number Diff line number Diff line change
Expand Up @@ -29,7 +29,7 @@ if test "$PHP_EMBED" != "no"; then
PHP_INSTALL_HEADERS([sapi/embed], [php_embed.h])
fi
AC_MSG_RESULT([$PHP_EMBED_TYPE])
PHP_SUBST_OLD(PHP_EMBED_TYPE)
AC_SUBST([PHP_EMBED_TYPE])
else
AC_MSG_RESULT(no)
fi
12 changes: 6 additions & 6 deletions sapi/fpm/config.m4
Original file line number Diff line number Diff line change
Expand Up @@ -550,7 +550,7 @@ if test "$PHP_FPM" != "no"; then
CFLAGS="$CFLAGS_save"
fi

PHP_SUBST_OLD(php_fpm_systemd)
AC_SUBST([php_fpm_systemd])
AC_DEFINE_UNQUOTED(PHP_FPM_SYSTEMD, "$php_fpm_systemd", [fpm systemd service type])

if test -z "$PHP_FPM_USER" || test "$PHP_FPM_USER" = "yes" || test "$PHP_FPM_USER" = "no"; then
Expand All @@ -565,14 +565,14 @@ if test "$PHP_FPM" != "no"; then
php_fpm_group="$PHP_FPM_GROUP"
fi

PHP_SUBST_OLD(php_fpm_user)
PHP_SUBST_OLD(php_fpm_group)
AC_SUBST([php_fpm_user])
AC_SUBST([php_fpm_group])
php_fpm_sysconfdir=`eval echo $sysconfdir`
PHP_SUBST_OLD(php_fpm_sysconfdir)
AC_SUBST([php_fpm_sysconfdir])
php_fpm_localstatedir=`eval echo $localstatedir`
PHP_SUBST_OLD(php_fpm_localstatedir)
AC_SUBST([php_fpm_localstatedir])
php_fpm_prefix=`eval echo $prefix`
PHP_SUBST_OLD(php_fpm_prefix)
AC_SUBST([php_fpm_prefix])

AC_DEFINE_UNQUOTED(PHP_FPM_USER, "$php_fpm_user", [fpm user name])
AC_DEFINE_UNQUOTED(PHP_FPM_GROUP, "$php_fpm_group", [fpm group name])
Expand Down