summaryrefslogtreecommitdiff
path: root/sapi/cli/php_cli.c
diff options
context:
space:
mode:
authorMarcus Boerger <helly@php.net>2006-01-22 22:09:54 +0000
committerMarcus Boerger <helly@php.net>2006-01-22 22:09:54 +0000
commitcb27823e821126308250c7f2733c2bbbb336fd36 (patch)
treebe2b059b9b3edef9e2a5b87e1bf2842ef6ea5578 /sapi/cli/php_cli.c
parent813a5651c1468de0cd70747323f2abc4c7d8cbc2 (diff)
downloadphp-git-cb27823e821126308250c7f2733c2bbbb336fd36.tar.gz
- MFH Show the exact version
Diffstat (limited to 'sapi/cli/php_cli.c')
-rw-r--r--sapi/cli/php_cli.c17
1 files changed, 13 insertions, 4 deletions
diff --git a/sapi/cli/php_cli.c b/sapi/cli/php_cli.c
index e196ff3269..83bfc70b00 100644
--- a/sapi/cli/php_cli.c
+++ b/sapi/cli/php_cli.c
@@ -747,14 +747,23 @@ int main(int argc, char *argv[])
goto out;
case 'v': /* show php version & quit */
- if (php_request_startup(TSRMLS_C)==FAILURE) {
+ if (php_request_startup(TSRMLS_C) == FAILURE) {
goto err;
}
-#if ZEND_DEBUG
- php_printf("PHP %s (%s) (built: %s %s) (DEBUG)\nCopyright (c) 1997-2006 The PHP Group\n%s", PHP_VERSION, sapi_module.name, __DATE__, __TIME__, get_zend_version());
+
+ php_printf("PHP %s (%s) (built: %s %s) %s\nCopyright (c) 1997-2006 The PHP Group\n%s",
+ PHP_VERSION, sapi_module.name, __DATE__, __TIME__,
+#if ZEND_DEBUG && defined(HAVE_GCOV)
+ "(DEBUG GCOV)",
+#elif ZEND_DEBUG
+ "(DEBUG)",
+#elif defined(HAVE_GCOV)
+ "(GCOV)",
#else
- php_printf("PHP %s (%s) (built: %s %s)\nCopyright (c) 1997-2006 The PHP Group\n%s", PHP_VERSION, sapi_module.name, __DATE__, __TIME__, get_zend_version());
+ "",
#endif
+ get_zend_version()
+ );
php_end_ob_buffers(1 TSRMLS_CC);
exit_status=0;
goto out;