X-Git-Url: https://sigrok.org/gitweb/?p=sigrok-cli.git;a=blobdiff_plain;f=show.c;h=1c5aad09f47760e4d6752a5236311da58926b374;hp=62a1ac44cafdc2243f8c4663944733d23ff4c303;hb=6293db8aea090170eced25d6f92c348b013ea475;hpb=2b5d1ae678011075ca0413d36395313f7f001f26 diff --git a/show.c b/show.c index 62a1ac4..1c5aad0 100644 --- a/show.c +++ b/show.c @@ -57,6 +57,18 @@ static gint sort_pds(gconstpointer a, gconstpointer b) #endif void show_version(void) +{ + printf("sigrok-cli %s\n\n", SC_PACKAGE_VERSION_STRING); + + printf("Using libsigrok %s (lib version %s).\n", + sr_package_version_string_get(), sr_lib_version_string_get()); +#ifdef HAVE_SRD + printf("Using libsigrokdecode %s (lib version %s).\n\n", + srd_package_version_string_get(), srd_lib_version_string_get()); +#endif +} + +void show_supported(void) { struct sr_dev_driver **drivers, *driver; const struct sr_input_module **inputs, *input; @@ -69,15 +81,6 @@ void show_version(void) struct srd_decoder *dec; #endif - printf("sigrok-cli %s\n\n", SC_PACKAGE_VERSION_STRING); - - printf("Using libsigrok %s (lib version %s).\n", - sr_package_version_string_get(), sr_lib_version_string_get()); -#ifdef HAVE_SRD - printf("Using libsigrokdecode %s (lib version %s).\n\n", - srd_package_version_string_get(), srd_lib_version_string_get()); -#endif - printf("Supported hardware drivers:\n"); drivers = sr_driver_list(sr_ctx); for (sl = NULL, i = 0; drivers[i]; i++)