mirror of
https://github.com/Genymobile/scrcpy
synced 2025-08-30 22:05:12 +00:00
Print libusb version on --version
This commit is contained in:
@@ -6,6 +6,9 @@
|
|||||||
#ifdef HAVE_V4L2
|
#ifdef HAVE_V4L2
|
||||||
# include <libavdevice/avdevice.h>
|
# include <libavdevice/avdevice.h>
|
||||||
#endif
|
#endif
|
||||||
|
#ifdef HAVE_USB
|
||||||
|
# include <libusb-1.0/libusb.h>
|
||||||
|
#endif
|
||||||
|
|
||||||
void
|
void
|
||||||
scrcpy_print_version(void) {
|
scrcpy_print_version(void) {
|
||||||
@@ -54,4 +57,11 @@ scrcpy_print_version(void) {
|
|||||||
AV_VERSION_MINOR(avdevice),
|
AV_VERSION_MINOR(avdevice),
|
||||||
AV_VERSION_MICRO(avdevice));
|
AV_VERSION_MICRO(avdevice));
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
|
#ifdef HAVE_USB
|
||||||
|
const struct libusb_version *usb = libusb_get_version();
|
||||||
|
// The compiled version may not be known
|
||||||
|
printf(" - libusb: - / %u.%u.%u\n",
|
||||||
|
(unsigned) usb->major, (unsigned) usb->minor, (unsigned) usb->micro);
|
||||||
|
#endif
|
||||||
}
|
}
|
||||||
|
Reference in New Issue
Block a user