Browse Source

Revert "Find libusb-1.0 using pkg-config and correct the libusb.h #include path"

This reverts commit 171c3d0c72.

Rollback breakage.
nfactor-troky
Con Kolivas 12 years ago
parent
commit
e55ef04df6
  1. 12
      configure.ac
  2. 2
      libztex.h
  3. 2
      miner.h

12
configure.ac

@ -343,14 +343,16 @@ if test "x$bitforce$modminer" != xnono; then
fi fi
AM_CONDITIONAL([HAVE_LIBUDEV], [test x$libudev != xno]) AM_CONDITIONAL([HAVE_LIBUDEV], [test x$libudev != xno])
PKG_PROG_PKG_CONFIG()
if test "x$ztex" != xno; then if test "x$ztex" != xno; then
PKG_CHECK_MODULES(LIBUSB, libusb-1.0, [AC_DEFINE(HAVE_LIBUSB, 1, [Define if you have libusb-1.0])], [AC_MSG_ERROR([Could not find usb library - please install libusb-1.0])]) AC_CHECK_LIB(usb-1.0, libusb_init, ,
USB_LIBS="$LIBUSB_LIBS" AC_MSG_ERROR([Could not find usb library - please install libusb]))
USB_FLAGS="$LIBUSB_CFLAGS" AC_DEFINE([HAVE_LIBUSB], [1], [Defined to 1 if libusb is wanted])
USB_LIBS="-lusb-1.0"
USB_FLAGS=""
fi fi
PKG_PROG_PKG_CONFIG()
PKG_CHECK_MODULES([LIBCURL], [libcurl >= 7.18.2], ,[AC_MSG_ERROR([Missing required libcurl dev >= 7.18.2])]) PKG_CHECK_MODULES([LIBCURL], [libcurl >= 7.18.2], ,[AC_MSG_ERROR([Missing required libcurl dev >= 7.18.2])])
AC_SUBST(LIBCURL_LIBS) AC_SUBST(LIBCURL_LIBS)

2
libztex.h

@ -22,7 +22,7 @@
#ifndef __LIBZTEX_H__ #ifndef __LIBZTEX_H__
#define __LIBZTEX_H__ #define __LIBZTEX_H__
#include <libusb.h> #include <libusb-1.0/libusb.h>
#define LIBZTEX_MAX_DESCRIPTORS 512 #define LIBZTEX_MAX_DESCRIPTORS 512
#define LIBZTEX_SNSTRING_LEN 10 #define LIBZTEX_SNSTRING_LEN 10

2
miner.h

@ -103,7 +103,7 @@ static inline int fsync (int fd)
#endif #endif
#ifdef HAVE_LIBUSB #ifdef HAVE_LIBUSB
#include <libusb.h> #include <libusb-1.0/libusb.h>
#endif #endif
#ifdef USE_ZTEX #ifdef USE_ZTEX

Loading…
Cancel
Save