Index: scd/ccid-driver.c =================================================================== --- scd/ccid-driver.c.orig +++ scd/ccid-driver.c @@ -75,8 +75,6 @@ # include #endif -#if defined(HAVE_LIBUSB) || defined(TEST) - #include #include #include @@ -91,7 +89,14 @@ #include "ccid-driver.h" #define DRVNAME "ccid-driver: " - +static int debug_level; /* Flag to control the debug output. + 0 = No debugging + 1 = USB I/O info + 2 = T=1 protocol tracing + */ + +#if defined(HAVE_LIBUSB) || defined(TEST) +#include /* Depending on how this source is used we either define our error output to go to stderr or to the jnlib based logging functions. We @@ -250,11 +255,7 @@ struct ccid_driver_s static int initialized_usb; /* Tracks whether USB has been initialized. */ -static int debug_level; /* Flag to control the debug output. - 0 = No debugging - 1 = USB I/O info - 2 = T=1 protocol tracing - */ + static unsigned int compute_edc (const unsigned char *data, size_t datalen,