diff options
author | libdlo <libdlo@displaylink.com> | 2009-05-14 09:59:06 -0700 |
---|---|---|
committer | libdlo <libdlo@displaylink.com> | 2009-05-14 09:59:06 -0700 |
commit | d0a9f4b60ba9eb5d962a87e4c23a384c8eb96f4c (patch) | |
tree | b3a0e8a5ec6461626c4a820707f5cfe5c9458e54 | |
parent | 2ba4ded43963550bf2cf55d34ad365540b9c3a08 (diff) |
Improve checking for libusb. Nice error messages when not found
-rw-r--r-- | configure.ac | 4 |
1 files changed, 3 insertions, 1 deletions
diff --git a/configure.ac b/configure.ac index 46d88f1..fcd1524 100644 --- a/configure.ac +++ b/configure.ac @@ -39,7 +39,9 @@ AC_TYPE_UINT64_T AC_TYPE_UINT8_T # Checks for library functions. -PKG_CHECK_MODULES(LIBUSB, libusb >= 0.1.12) +AC_CHECK_LIB(usb,usb_open) +AC_CHECK_FUNC([usb_get_driver_np],,[AC_MSG_ERROR([Can't find libusb. On ubuntu, try sudo apt-get install libusb-dev])]) +AC_CHECK_FUNC([usb_get_configuration],[AC_MSG_ERROR([libdlo currently uses libusb-0.12 or 0.13. You appear to have 1.0])]) AC_FUNC_MALLOC AC_FUNC_REALLOC AC_CHECK_FUNCS([gettimeofday strchr]) |