You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

131 lines
6.0 KiB

  1. From: Thijs Kinkhorst <thijs@debian.org>
  2. Date: Wed, 15 Jun 2016 09:18:03 +0200
  3. Subject: Add patch to remove build timestamps from generated binaries.
  4. ---
  5. ext/standard/info.c | 1 -
  6. sapi/apache2handler/config.m4 | 15 +++------------
  7. sapi/cgi/cgi_main.c | 4 ++--
  8. sapi/cli/php_cli.c | 4 ++--
  9. sapi/fpm/fpm/fpm_main.c | 4 ++--
  10. sapi/litespeed/lsapi_main.c | 4 ++--
  11. sapi/phpdbg/phpdbg.c | 4 +---
  12. 7 files changed, 12 insertions(+), 24 deletions(-)
  13. diff --git a/ext/standard/info.c b/ext/standard/info.c
  14. index e6eaac3..024e5c9 100644
  15. --- a/ext/standard/info.c
  16. +++ b/ext/standard/info.c
  17. @@ -863,7 +863,6 @@ PHPAPI void php_print_info(int flag)
  18. php_info_print_box_end();
  19. php_info_print_table_start();
  20. php_info_print_table_row(2, "System", ZSTR_VAL(php_uname));
  21. - php_info_print_table_row(2, "Build Date", __DATE__ " " __TIME__);
  22. #ifdef COMPILER
  23. php_info_print_table_row(2, "Compiler", COMPILER);
  24. #endif
  25. diff --git a/sapi/apache2handler/config.m4 b/sapi/apache2handler/config.m4
  26. index f286b1a..fba92b8 100644
  27. --- a/sapi/apache2handler/config.m4
  28. +++ b/sapi/apache2handler/config.m4
  29. @@ -59,18 +59,9 @@ if test "$PHP_APXS2" != "no"; then
  30. APACHE_CFLAGS="$APACHE_CPPFLAGS -I$APXS_INCLUDEDIR $APR_CFLAGS $APU_CFLAGS -DZEND_ENABLE_STATIC_TSRMLS_CACHE=1"
  31. APXS_LIBEXECDIR='$(INSTALL_ROOT)'`$APXS -q LIBEXECDIR`
  32. - if test -z `$APXS -q SYSCONFDIR`; then
  33. - INSTALL_IT="\$(mkinstalldirs) '$APXS_LIBEXECDIR' && \
  34. - $APXS -S LIBEXECDIR='$APXS_LIBEXECDIR' \
  35. - -i -n php7"
  36. - else
  37. - APXS_SYSCONFDIR='$(INSTALL_ROOT)'`$APXS -q SYSCONFDIR`
  38. - INSTALL_IT="\$(mkinstalldirs) '$APXS_LIBEXECDIR' && \
  39. - \$(mkinstalldirs) '$APXS_SYSCONFDIR' && \
  40. - $APXS -S LIBEXECDIR='$APXS_LIBEXECDIR' \
  41. - -S SYSCONFDIR='$APXS_SYSCONFDIR' \
  42. - -i -a -n php7"
  43. - fi
  44. + INSTALL_IT="\$(mkinstalldirs) '$APXS_LIBEXECDIR' && \
  45. + $APXS -S LIBEXECDIR='$APXS_LIBEXECDIR' \
  46. + -i -n php7"
  47. case $host_alias in
  48. *aix*)
  49. diff --git a/sapi/cgi/cgi_main.c b/sapi/cgi/cgi_main.c
  50. index 8983b53..589e299 100644
  51. --- a/sapi/cgi/cgi_main.c
  52. +++ b/sapi/cgi/cgi_main.c
  53. @@ -2216,9 +2216,9 @@ consult the installation file that came with this distribution, or visit \n\
  54. SG(request_info).no_headers = 1;
  55. }
  56. #if ZEND_DEBUG
  57. - php_printf("PHP %s (%s) (built: %s %s) (DEBUG)\nCopyright (c) 1997-2016 The PHP Group\n%s", PHP_VERSION, sapi_module.name, __DATE__, __TIME__, get_zend_version());
  58. + php_printf("PHP %s (%s) (DEBUG)\nCopyright (c) 1997-2016 The PHP Group\n%s", PHP_VERSION, sapi_module.name, get_zend_version());
  59. #else
  60. - php_printf("PHP %s (%s) (built: %s %s)\nCopyright (c) 1997-2016 The PHP Group\n%s", PHP_VERSION, sapi_module.name, __DATE__, __TIME__, get_zend_version());
  61. + php_printf("PHP %s (%s)\nCopyright (c) 1997-2016 The PHP Group\n%s", PHP_VERSION, sapi_module.name, get_zend_version());
  62. #endif
  63. php_request_shutdown((void *) 0);
  64. fcgi_shutdown();
  65. diff --git a/sapi/cli/php_cli.c b/sapi/cli/php_cli.c
  66. index 978c8b3..3ee61a4 100644
  67. --- a/sapi/cli/php_cli.c
  68. +++ b/sapi/cli/php_cli.c
  69. @@ -682,8 +682,8 @@ static int do_cli(int argc, char **argv) /* {{{ */
  70. goto out;
  71. case 'v': /* show php version & quit */
  72. - php_printf("PHP %s (%s) (built: %s %s) ( %s)\nCopyright (c) 1997-2016 The PHP Group\n%s",
  73. - PHP_VERSION, cli_sapi_module.name, __DATE__, __TIME__,
  74. + php_printf("PHP %s (%s) ( %s)\nCopyright (c) 1997-2016 The PHP Group\n%s",
  75. + PHP_VERSION, cli_sapi_module.name,
  76. #if ZTS
  77. "ZTS "
  78. #else
  79. diff --git a/sapi/fpm/fpm/fpm_main.c b/sapi/fpm/fpm/fpm_main.c
  80. index 5adeb63..5e60255 100644
  81. --- a/sapi/fpm/fpm/fpm_main.c
  82. +++ b/sapi/fpm/fpm/fpm_main.c
  83. @@ -1757,9 +1757,9 @@ int main(int argc, char *argv[])
  84. SG(request_info).no_headers = 1;
  85. #if ZEND_DEBUG
  86. - php_printf("PHP %s (%s) (built: %s %s) (DEBUG)\nCopyright (c) 1997-2016 The PHP Group\n%s", PHP_VERSION, sapi_module.name, __DATE__, __TIME__, get_zend_version());
  87. + php_printf("PHP %s (%s) (DEBUG)\nCopyright (c) 1997-2016 The PHP Group\n%s", PHP_VERSION, sapi_module.name, get_zend_version());
  88. #else
  89. - php_printf("PHP %s (%s) (built: %s %s)\nCopyright (c) 1997-2016 The PHP Group\n%s", PHP_VERSION, sapi_module.name, __DATE__, __TIME__, get_zend_version());
  90. + php_printf("PHP %s (%s)\nCopyright (c) 1997-2016 The PHP Group\n%s", PHP_VERSION, sapi_module.name, get_zend_version());
  91. #endif
  92. php_request_shutdown((void *) 0);
  93. fcgi_shutdown();
  94. diff --git a/sapi/litespeed/lsapi_main.c b/sapi/litespeed/lsapi_main.c
  95. index b0ea105..4feb8f3 100644
  96. --- a/sapi/litespeed/lsapi_main.c
  97. +++ b/sapi/litespeed/lsapi_main.c
  98. @@ -811,9 +811,9 @@ static int cli_main( int argc, char * argv[] )
  99. case 'v':
  100. if (php_request_startup() != FAILURE) {
  101. #if ZEND_DEBUG
  102. - php_printf("PHP %s (%s) (built: %s %s) (DEBUG)\nCopyright (c) 1997-2016 The PHP Group\n%s", PHP_VERSION, sapi_module.name, __DATE__, __TIME__, get_zend_version());
  103. + php_printf("PHP %s (%s) (DEBUG)\nCopyright (c) 1997-2016 The PHP Group\n%s", PHP_VERSION, sapi_module.name, get_zend_version());
  104. #else
  105. - php_printf("PHP %s (%s) (built: %s %s)\nCopyright (c) 1997-2016 The PHP Group\n%s", PHP_VERSION, sapi_module.name, __DATE__, __TIME__, get_zend_version());
  106. + php_printf("PHP %s (%s)\nCopyright (c) 1997-2016 The PHP Group\n%s", PHP_VERSION, sapi_module.name, get_zend_version());
  107. #endif
  108. #ifdef PHP_OUTPUT_NEWAPI
  109. php_output_end_all();
  110. diff --git a/sapi/phpdbg/phpdbg.c b/sapi/phpdbg/phpdbg.c
  111. index 68a164c..82565d8 100644
  112. --- a/sapi/phpdbg/phpdbg.c
  113. +++ b/sapi/phpdbg/phpdbg.c
  114. @@ -1657,10 +1657,8 @@
  115. phpdbg_do_help(NULL);
  116. } else if (show_version) {
  117. phpdbg_out(
  118. - "phpdbg %s (built: %s %s)\nPHP %s, Copyright (c) 1997-2016 The PHP Group\n%s",
  119. + "phpdbg %s\nPHP %s, Copyright (c) 1997-2016 The PHP Group\n%s",
  120. PHPDBG_VERSION,
  121. - __DATE__,
  122. - __TIME__,
  123. PHP_VERSION,
  124. get_zend_version()
  125. );