diff options
author | oharboe <oharboe@b42882b7-edfa-0310-969c-e2dbd0fdcd60> | 2008-10-22 07:55:45 +0000 |
---|---|---|
committer | oharboe <oharboe@b42882b7-edfa-0310-969c-e2dbd0fdcd60> | 2008-10-22 07:55:45 +0000 |
commit | d740e66ccdc69c619483e32a9f9706ec8193d2f4 (patch) | |
tree | cae47e4fc751bd3d6a12d529c0d5195d6cd1b745 | |
parent | 6eeab625cd9e3467c75b382b23d161bb321aaa72 (diff) | |
download | openocd_libswd-d740e66ccdc69c619483e32a9f9706ec8193d2f4.tar.gz openocd_libswd-d740e66ccdc69c619483e32a9f9706ec8193d2f4.tar.bz2 openocd_libswd-d740e66ccdc69c619483e32a9f9706ec8193d2f4.tar.xz openocd_libswd-d740e66ccdc69c619483e32a9f9706ec8193d2f4.zip |
version number keyword expansion handling
git-svn-id: svn://svn.berlios.de/openocd/trunk@1086 b42882b7-edfa-0310-969c-e2dbd0fdcd60
-rw-r--r-- | src/ecosboard.c | 6 |
1 files changed, 4 insertions, 2 deletions
diff --git a/src/ecosboard.c b/src/ecosboard.c index 61cfada7..dfe30059 100644 --- a/src/ecosboard.c +++ b/src/ecosboard.c @@ -101,7 +101,7 @@ struct tftpd_fileops fileops = #define ZYLIN_TIME __TIME__ /* hmmm.... we can't pick up the right # during build if we've checked this out * in Eclipse... arrggghh...*/ -#define ZYLIN_OPENOCD $Revision$ +#define ZYLIN_OPENOCD "$Revision$" #define ZYLIN_OPENOCD_VERSION "Zylin JTAG ZY1000 " ZYLIN_VERSION " " ZYLIN_DATE " " ZYLIN_TIME #define ZYLIN_CONFIG_DIR "/config/settings" @@ -321,7 +321,9 @@ int handle_zy1000_version_command(struct command_context_s *cmd_ctx, char *cmd, command_print(cmd_ctx, ZYLIN_OPENOCD_VERSION); } else if (strcmp("openocd", args[0])==0) { - command_print(cmd_ctx, "%d", ZYLIN_OPENOCD); + int revision; + revision=atol(ZYLIN_OPENOCD+strlen("XRevision: ")); + command_print(cmd_ctx, "%d", revision); } else if (strcmp("zy1000", args[0])==0) { command_print(cmd_ctx, "%s", ZYLIN_VERSION); |