mirror of
https://github.com/radareorg/radare2.git
synced 2024-11-23 13:19:54 +00:00
Show 'release' instead of '9999999' in r2 -v
This commit is contained in:
parent
5fa9601abe
commit
a50dd5ecbb
3
Makefile
3
Makefile
@ -12,7 +12,8 @@ ZIP=zip
|
||||
|
||||
R2VC=$(shell git rev-list --all --count 2>/dev/null)
|
||||
ifeq ($(R2VC),)
|
||||
R2VC=9999999
|
||||
# release
|
||||
R2VC=0
|
||||
endif
|
||||
|
||||
STRIP?=strip
|
||||
|
@ -524,11 +524,15 @@ static int cmd_help(void *data, const char *input) {
|
||||
}
|
||||
break;
|
||||
case 0:
|
||||
#if R2_VERSION_COMMIT == 0
|
||||
r_cons_printf ("%s release\n", R2_VERSION);
|
||||
#else
|
||||
if (!strcmp (R2_VERSION, R2_GITTAP)) {
|
||||
r_cons_printf ("%s %d\n", R2_VERSION, R2_VERSION_COMMIT);
|
||||
} else {
|
||||
r_cons_printf ("%s aka %s commit %d\n", R2_VERSION, R2_GITTAP, R2_VERSION_COMMIT);
|
||||
}
|
||||
#endif
|
||||
break;
|
||||
case 'j':
|
||||
r_cons_printf ("{\"system\":\"%s-%s\"", R_SYS_OS, R_SYS_ARCH);
|
||||
|
@ -269,7 +269,8 @@ R_API int r_lib_open_ptr (RLib *lib, const char *file, void *handler, RLibStruct
|
||||
|
||||
if (stru->version) {
|
||||
if (strcmp (stru->version, R2_VERSION)) {
|
||||
eprintf ("Module version mismatch %s\n", file);
|
||||
eprintf ("Module version mismatch %s (%s) vs (%s)\n",
|
||||
file, stru->version, R2_VERSION);
|
||||
return R_FAIL;
|
||||
}
|
||||
}
|
||||
|
Loading…
Reference in New Issue
Block a user