Add printable libhackrf and hackrf tools version strings

This commit is contained in:
Dominic Spill
2017-02-05 21:40:57 -07:00
parent 15a2c61568
commit 38c67f7e89
6 changed files with 45 additions and 5 deletions

View File

@@ -365,6 +365,22 @@ int ADDCALL hackrf_exit(void)
return HACKRF_SUCCESS;
}
#ifndef LIBRARY_VERSION
#define LIBRARY_VERSION "unknown"
#endif
const char* ADDCALL hackrf_library_version()
{
return LIBRARY_VERSION;
}
#ifndef LIBRARY_RELEASE
#define LIBRARY_RELEASE "unknown"
#endif
const char* ADDCALL hackrf_library_release()
{
return LIBRARY_RELEASE;
}
hackrf_device_list_t* ADDCALL hackrf_device_list()
{
ssize_t i;