29141d
29141d
Drop "Configure Command" from phpinfo as it doesn't
29141d
provide any useful information.
29141d
The available extensions are not related to this command.
29141d
29141d
Replace full GCC name by gcc in php -v output
29141d
29141d
29141d
Also apply
29141d
29141d
From 9bf43c45908433d382f0499d529849172d0d8206 Mon Sep 17 00:00:00 2001
29141d
From: Remi Collet <remi@remirepo.net>
29141d
Date: Mon, 28 Dec 2020 08:33:09 +0100
29141d
Subject: [PATCH] rename COMPILER and ARCHITECTURE macro (too generic)
29141d
29141d
---
29141d
 configure.ac             |  4 ++--
29141d
 ext/standard/info.c      |  8 ++++----
29141d
 sapi/cli/php_cli.c       |  8 ++++----
29141d
 win32/build/confutils.js | 10 +++++-----
29141d
 4 files changed, 15 insertions(+), 15 deletions(-)
29141d
29141d
diff --git a/configure.ac b/configure.ac
29141d
index 9d9c8b155b07..143dc061346b 100644
29141d
--- a/configure.ac
29141d
+++ b/configure.ac
29141d
@@ -1289,10 +1289,10 @@ if test -n "${PHP_BUILD_PROVIDER}"; then
29141d
   AC_DEFINE_UNQUOTED(PHP_BUILD_PROVIDER,"$PHP_BUILD_PROVIDER",[build provider])
29141d
 fi
29141d
 if test -n "${PHP_BUILD_COMPILER}"; then
29141d
-  AC_DEFINE_UNQUOTED(COMPILER,"$PHP_BUILD_COMPILER",[used compiler for build])
29141d
+  AC_DEFINE_UNQUOTED(PHP_BUILD_COMPILER,"$PHP_BUILD_COMPILER",[used compiler for build])
29141d
 fi
29141d
 if test -n "${PHP_BUILD_ARCH}"; then
29141d
-  AC_DEFINE_UNQUOTED(ARCHITECTURE,"$PHP_BUILD_ARCH",[build architecture])
29141d
+  AC_DEFINE_UNQUOTED(PHP_BUILD_ARCH,"$PHP_BUILD_ARCH",[build architecture])
29141d
 fi
29141d
 
29141d
 PHP_SUBST_OLD(PHP_INSTALLED_SAPIS)
29141d
diff --git a/ext/standard/info.c b/ext/standard/info.c
29141d
index 153cb6cde014..8ceef31d9fe4 100644
29141d
--- a/ext/standard/info.c
29141d
+++ b/ext/standard/info.c
29141d
@@ -798,11 +798,11 @@ PHPAPI ZEND_COLD void php_print_info(int flag)
29141d
 #ifdef PHP_BUILD_PROVIDER
29141d
 		php_info_print_table_row(2, "Build Provider", PHP_BUILD_PROVIDER);
29141d
 #endif
29141d
-#ifdef COMPILER
29141d
-		php_info_print_table_row(2, "Compiler", COMPILER);
29141d
+#ifdef PHP_BUILD_COMPILER
29141d
+		php_info_print_table_row(2, "Compiler", PHP_BUILD_COMPILER);
29141d
 #endif
29141d
-#ifdef ARCHITECTURE
29141d
-		php_info_print_table_row(2, "Architecture", ARCHITECTURE);
29141d
+#ifdef PHP_BUILD_ARCH
29141d
+		php_info_print_table_row(2, "Architecture", PHP_BUILD_ARCH);
29141d
 #endif
29141d
 #ifdef CONFIGURE_COMMAND
29141d
 		php_info_print_table_row(2, "Configure Command", CONFIGURE_COMMAND );
29141d
diff --git a/sapi/cli/php_cli.c b/sapi/cli/php_cli.c
29141d
index 5092fb0ffd68..9d296acec631 100644
29141d
--- a/sapi/cli/php_cli.c
29141d
+++ b/sapi/cli/php_cli.c
29141d
@@ -640,12 +640,12 @@ static int do_cli(int argc, char **argv) /* {{{ */
29141d
 #else
29141d
 					"NTS "
29141d
 #endif
29141d
-#ifdef COMPILER
29141d
-					COMPILER
29141d
+#ifdef PHP_BUILD_COMPILER
29141d
+					PHP_BUILD_COMPILER
29141d
 					" "
29141d
 #endif
29141d
-#ifdef ARCHITECTURE
29141d
-					ARCHITECTURE
29141d
+#ifdef PHP_BUILD_ARCH
29141d
+					PHP_BUILD_ARCH
29141d
 					" "
29141d
 #endif
29141d
 #if ZEND_DEBUG
29141d
29141d
diff -up ./ext/standard/info.c.phpinfo ./ext/standard/info.c
29141d
--- ./ext/standard/info.c.phpinfo	2020-07-21 10:49:31.000000000 +0200
29141d
+++ ./ext/standard/info.c	2020-07-21 11:41:56.295633523 +0200
29141d
@@ -804,9 +804,6 @@ PHPAPI ZEND_COLD void php_print_info(int
29141d
 #ifdef PHP_BUILD_ARCH
29141d
 		php_info_print_table_row(2, "Architecture", PHP_BUILD_ARCH);
29141d
 #endif
29141d
-#ifdef CONFIGURE_COMMAND
29141d
-		php_info_print_table_row(2, "Configure Command", CONFIGURE_COMMAND );
29141d
-#endif
29141d
 
29141d
 		if (sapi_module.pretty_name) {
29141d
 			php_info_print_table_row(2, "Server API", sapi_module.pretty_name );
29141d
diff -up ./ext/standard/tests/general_functions/phpinfo.phpt.phpinfo ./ext/standard/tests/general_functions/phpinfo.phpt
29141d
--- ./ext/standard/tests/general_functions/phpinfo.phpt.phpinfo	2020-07-21 10:49:31.000000000 +0200
29141d
+++ ./ext/standard/tests/general_functions/phpinfo.phpt	2020-07-21 11:41:56.296633522 +0200
29141d
@@ -17,7 +17,6 @@ PHP Version => %s
29141d
 
29141d
 System => %s
29141d
 Build Date => %s%a
29141d
-Configure Command => %s
29141d
 Server API => Command Line Interface
29141d
 Virtual Directory Support => %s
29141d
 Configuration File (php.ini) Path => %s
29141d
diff -up ./sapi/cli/php_cli.c.phpinfo ./sapi/cli/php_cli.c
29141d
--- ./sapi/cli/php_cli.c.phpinfo	2020-07-21 11:43:38.812475300 +0200
29141d
+++ ./sapi/cli/php_cli.c	2020-07-21 11:43:45.783464540 +0200
29141d
@@ -641,8 +641,7 @@ static int do_cli(int argc, char **argv)
29141d
 					"NTS "
29141d
 #endif
29141d
 #ifdef PHP_BUILD_COMPILER
29141d
-					PHP_BUILD_COMPILER
29141d
-					" "
29141d
+					"gcc "
29141d
 #endif
29141d
 #ifdef PHP_BUILD_ARCH
29141d
 					PHP_BUILD_ARCH