]> granicus.if.org Git - php/commitdiff
- MFH Show the exact version
authorMarcus Boerger <helly@php.net>
Sun, 22 Jan 2006 22:09:54 +0000 (22:09 +0000)
committerMarcus Boerger <helly@php.net>
Sun, 22 Jan 2006 22:09:54 +0000 (22:09 +0000)
sapi/cli/php_cli.c

index e196ff32694d98b83de0323cfa42aa1b9d5332ae..83bfc70b00d95deb8878317f3e0eefe7bf0b809b 100644 (file)
@@ -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;