Skip to content

Commit

Permalink
command: Make sure to output the identification string to the GDB use…
Browse files Browse the repository at this point in the history
…r and not the BMDA console when the user requests the version information, and tidied up how it's generated
  • Loading branch information
dragonmux committed Oct 6, 2024
1 parent df49eb4 commit 3a7f153
Showing 1 changed file with 4 additions and 5 deletions.
9 changes: 4 additions & 5 deletions src/command.c
Original file line number Diff line number Diff line change
Expand Up @@ -188,19 +188,18 @@ bool cmd_version(target_s *t, int argc, const char **argv)
#if PC_HOSTED == 1
char ident[256];
gdb_ident(ident, sizeof(ident));
DEBUG_WARN("%s\n", ident);
DEBUG_WARN("Copyright (C) 2010-2023 Black Magic Debug Project\n");
DEBUG_WARN("License GPLv3+: GNU GPL version 3 or later <http://gnu.org/licenses/gpl.html>\n\n");
gdb_out("Black Magic Debug App " FIRMWARE_VERSION "\n");
gdb_outf("Using a %s\n", ident);
#else
#ifndef PLATFORM_IDENT_DYNAMIC
gdb_out(BOARD_IDENT);
#else
gdb_outf(BOARD_IDENT, platform_ident());
#endif
gdb_outf(", Hardware Version %d\n", platform_hwversion());
gdb_out("Copyright (C) 2010-2023 Black Magic Debug Project\n");
gdb_out("License GPLv3+: GNU GPL version 3 or later <http://gnu.org/licenses/gpl.html>\n\n");
#endif
gdb_out("Copyright (C) 2010-2024 Black Magic Debug Project\n");
gdb_out("License GPLv3+: GNU GPL version 3 or later <http://gnu.org/licenses/gpl.html>\n\n");

return true;
}
Expand Down

0 comments on commit 3a7f153

Please sign in to comment.