diff --git a/CommandLines.cpp b/CommandLines.cpp index 060754b..2ed649a 100644 --- a/CommandLines.cpp +++ b/CommandLines.cpp @@ -5,7 +5,6 @@ #include "ketopt.h" #include -#define VERSION "0.3.0" #define DEFAULT_OUTPUT "hifiasm.asm" hifiasm_opt_t asm_opt; @@ -309,7 +308,7 @@ int CommandLine_process(int argc, char *argv[], hifiasm_opt_t* asm_opt) } else if (c == 'v') { - fprintf(stderr, "[Version] %s\n", VERSION); + puts(HA_VERSION); return 0; } else if (c == 'f') asm_opt->bf_shift = atoi(opt.arg); diff --git a/CommandLines.h b/CommandLines.h index 65978e0..29e02d3 100644 --- a/CommandLines.h +++ b/CommandLines.h @@ -3,6 +3,8 @@ #include +#define HA_VERSION "0.3.0-dirty-r175" + #define VERBOSE 0 #define VERBOSE_GFA 0 diff --git a/main.cpp b/main.cpp index a8219b0..2e1edc0 100644 --- a/main.cpp +++ b/main.cpp @@ -18,7 +18,7 @@ int main(int argc, char *argv[]) ha_ft_destroy(ha_flt_tab); destory_All_reads(&R_INF); destory_opt(&asm_opt); - fprintf(stderr, "[M::%s] Version: %s\n", __func__, "dummy"); + fprintf(stderr, "[M::%s] Version: %s\n", __func__, HA_VERSION); fprintf(stderr, "[M::%s] CMD:", __func__); for (i = 0; i < argc; ++i) fprintf(stderr, " %s", argv[i]);