From: Marc-André Lureau <marcandre.lur...@redhat.com> This cleans up a bit libcacard headers inclusion.
Signed-off-by: Marc-André Lureau <marcandre.lur...@redhat.com> --- configure | 7 ++++--- hw/usb/ccid-card-emulated.c | 5 +---- hw/usb/ccid-card-passthru.c | 2 +- 3 files changed, 6 insertions(+), 8 deletions(-) diff --git a/configure b/configure index b9552fd..65dc5ed 100755 --- a/configure +++ b/configure @@ -3981,17 +3981,18 @@ EOF fi # check for smartcard support +libcacard_version=2.5.1 smartcard_cflags="" if test "$smartcard" != "no"; then - if $pkg_config libcacard; then + if $pkg_config "libcacard >= $libcacard_version"; then libcacard_cflags=$($pkg_config --cflags libcacard) libcacard_libs=$($pkg_config --libs libcacard) - QEMU_CFLAGS="$QEMU_CFLAGS $libcacard_cflags" + QEMU_CFLAGS= $QEMU_CFLAGS $libcacard_cflags"" libs_softmmu="$libs_softmmu $libcacard_libs" smartcard="yes" else if test "$smartcard" = "yes"; then - feature_not_found "smartcard" "Install libcacard devel" + feature_not_found "smartcard" "Install libcacard(>=$libcacard_version) devel" fi smartcard="no" fi diff --git a/hw/usb/ccid-card-emulated.c b/hw/usb/ccid-card-emulated.c index 869a63c..25d3e3f 100644 --- a/hw/usb/ccid-card-emulated.c +++ b/hw/usb/ccid-card-emulated.c @@ -26,10 +26,7 @@ * the db parameter. */ -#include <eventt.h> -#include <vevent.h> -#include <vreader.h> -#include <vcard_emul.h> +#include <libcacard.h> #include "qemu/thread.h" #include "sysemu/char.h" diff --git a/hw/usb/ccid-card-passthru.c b/hw/usb/ccid-card-passthru.c index 9f49c05..f4c276f 100644 --- a/hw/usb/ccid-card-passthru.c +++ b/hw/usb/ccid-card-passthru.c @@ -12,7 +12,7 @@ #include "qemu/error-report.h" #include "qemu/sockets.h" #include "ccid.h" -#include "cacard/vscard_common.h" +#include <libcacard.h> #define DPRINTF(card, lvl, fmt, ...) \ do { \ -- 2.5.0