summaryrefslogtreecommitdiff
path: root/gdb/top.h
diff options
context:
space:
mode:
authorTom Tromey <tom@tromey.com>2018-05-11 12:21:03 -0600
committerTom Tromey <tom@tromey.com>2018-06-05 11:47:50 -0600
commitc61b06a19a34baab66e3809c7b41b0c31009ed9f (patch)
treee15238ee1c30840aa5b761cc8663bd079f51e4a8 /gdb/top.h
parent115f7325b5b76450b9a1d16848a2a54f54e49747 (diff)
downloadbinutils-gdb-c61b06a19a34baab66e3809c7b41b0c31009ed9f.tar.gz
Remove some text from --version output
I happened to notice recently that "gdb --version" says: GNU gdb (GDB) 8.0.50.20170911-git Copyright (C) 2017 Free Software Foundation, Inc. License GPLv3+: GNU GPL version 3 or later <http://gnu.org/licenses/gpl.html> This is free software: you are free to change and redistribute it. There is NO WARRANTY, to the extent permitted by law. Type "show copying" and "show warranty" for details. This GDB was configured as "x86_64-pc-linux-gnu". Type "show configuration" for configuration details. For bug reporting instructions, please see: <http://www.gnu.org/software/gdb/bugs/>. Find the GDB manual and other documentation resources online at: <http://www.gnu.org/software/gdb/documentation/>. For help, type "help". Type "apropos word" to search for commands related to "word". This is a bit on the wordy side, but also references interactive commands, which I think doesn't really make sense for --version. This patch removes some text from --version, while leaving it in the "show version" output. It also adds a newline between the URLs and the "For help, ..." text, because I thought that was easier to read. Finally, it indents one of the URLs, since that was simpler to read, but not the other URL, because the current format is specified by the GNU coding standards section on "--version". Now the --version output looks like: GNU gdb (GDB) 8.1.50.20180511-git Copyright (C) 2018 Free Software Foundation, Inc. License GPLv3+: GNU GPL version 3 or later <http://gnu.org/licenses/gpl.html> This is free software: you are free to change and redistribute it. There is NO WARRANTY, to the extent permitted by law. Tested by the buildbot. gdb/ChangeLog 2018-06-05 Tom Tromey <tom@tromey.com> * cli/cli-cmds.c (show_version): Update. * top.c (print_gdb_version): Add "interactive" parameter. Update. * main.c (captured_main_1): Update. * top.h (print_gdb_version): Add "interactive" parameter and a comment. gdb/testsuite/ChangeLog 2018-06-05 Tom Tromey <tom@tromey.com> * gdb.base/default.exp: Update expected "show version" output.
Diffstat (limited to 'gdb/top.h')
-rw-r--r--gdb/top.h8
1 files changed, 7 insertions, 1 deletions
diff --git a/gdb/top.h b/gdb/top.h
index d54b6f15c46..b34defa1f29 100644
--- a/gdb/top.h
+++ b/gdb/top.h
@@ -222,7 +222,13 @@ extern int confirm;
extern int inhibit_gdbinit;
extern const char gdbinit[];
-extern void print_gdb_version (struct ui_file *);
+/* Print the GDB version banner to STREAM. If INTERACTIVE is false,
+ then information referring to commands (e.g., "show configuration")
+ is omitted; this mode is used for the --version command line
+ option. If INTERACTIVE is true, then interactive commands are
+ mentioned. */
+extern void print_gdb_version (struct ui_file *stream, bool interactive);
+
extern void print_gdb_configuration (struct ui_file *);
extern void read_command_file (FILE *);