diff options
Diffstat (limited to 'lib/print_version.c')
| -rw-r--r-- | lib/print_version.c | 16 |
1 files changed, 16 insertions, 0 deletions
diff --git a/lib/print_version.c b/lib/print_version.c new file mode 100644 index 00000000..1cf1215f --- /dev/null +++ b/lib/print_version.c @@ -0,0 +1,16 @@ +#include <stdio.h> + +#include "scs_version.h" +#include "wsjtx_config.h" + +void print_version(const char *prog_name) +{ + printf(" Program: %s %d.%d.%d%s", prog_name, + PROJECT_VERSION_MAJOR, PROJECT_VERSION_MINOR, PROJECT_VERSION_PATCH, + BUILD_TYPE_REVISION); + if (SCS_VERSION_STR[0] != '\0') { + printf(" (revision %s)\n", SCS_VERSION_STR); + } else { + puts(" (revision unavailable)"); + } +} |
