]> git.ipfire.org Git - thirdparty/binutils-gdb.git/commitdiff
sim: common: version: add build & homepage info when interactive
authorMike Frysinger <vapier@gentoo.org>
Sun, 3 Jan 2021 08:06:28 +0000 (03:06 -0500)
committerMike Frysinger <vapier@gentoo.org>
Mon, 4 Jan 2021 23:10:40 +0000 (18:10 -0500)
This mirrors gdb behavior of dumping extra info when being run in
interactive mode.  It also gives us an excuse to use the otherwise
unused sim_print_config.

sim/common/ChangeLog
sim/common/sim-options.c

index 178154475ab6bb2ab6969cb3518766eaf842d7fe..1bd67413c8a5ed1a57fc115772f1299b24c37cf1 100644 (file)
@@ -1,3 +1,8 @@
+2021-01-04  Mike Frysinger  <vapier@gentoo.org>
+
+       * sim-options.c (sim_print_version): Print out more details when
+       is_command is non-zero.
+
 2021-01-04  Mike Frysinger  <vapier@gentoo.org>
 
        * sim-options.c (standard_option_handler): Call sim_print_version.
index 1d8abdaa05bf6d77274b9f39dc9a52da7854565c..e0de39adab76dab906635eb810b83ff688627a07 100644 (file)
@@ -835,6 +835,21 @@ sim_print_version (SIM_DESC sd, int is_command)
 License GPLv3+: GNU GPL version 3 or later <https://gnu.org/licenses/gpl.html>\
 \nThis is free software: you are free to change and redistribute it.\n\
 There is NO WARRANTY, to the extent permitted by law.\n");
+
+  if (!is_command)
+    return;
+
+  sim_io_printf (sd, "This SIM was configured as:\n");
+  sim_config_print (sd);
+
+  if (REPORT_BUGS_TO[0])
+    {
+      sim_io_printf (sd, "For bug reporting instructions, please see:\n\
+    %s.\n",
+                    REPORT_BUGS_TO);
+    }
+  sim_io_printf (sd, "Find the SIM homepage & other documentation resources \
+online at:\n    <https://sourceware.org/gdb/wiki/Sim/>.\n");
 }
 
 /* Utility of sim_args_command to find the closest match for a command.