Re: [Qemu-devel] [PATCH] ccid: use libcacard.h from 2.5.1

2015-12-18 Thread Gerd Hoffmann
On Fr, 2015-12-18 at 10:49 +0100, marcandre.lur...@redhat.com wrote:
> From: Marc-André Lureau 
> 
> This cleans up a bit libcacard headers inclusion.

Makes sense, but:  When was 2.5.1 released?  I suspect it is better to
wait a bit longer with this, to give distros some time to pick up the
package.  Maybe after 2.6 release?

cheers,
  Gerd




Re: [Qemu-devel] [PATCH] ccid: use libcacard.h from 2.5.1

2015-12-18 Thread Paolo Bonzini


On 18/12/2015 13:50, Marc-André Lureau wrote:
>>> > >  configure   | 7 ---
>>> > >  hw/usb/ccid-card-emulated.c | 5 +
>>> > >  hw/usb/ccid-card-passthru.c | 2 +-
>>> > >  3 files changed, 6 insertions(+), 8 deletions(-)
>> > 
>> > Are there any distros that have not packaged libcacard yet?  This will
>> > break compatibility with QEMU 2.4's libcacard, I think.
> I bumped libcacard requirement to 2.5.1 in the patch.

Yes, the question is whether distributions would have problems with that.

Paolo



Re: [Qemu-devel] [PATCH] ccid: use libcacard.h from 2.5.1

2015-12-18 Thread Marc-André Lureau
Hi

- Original Message -
> 
> 
> On 18/12/2015 10:49, marcandre.lur...@redhat.com wrote:
> > From: Marc-André Lureau 
> > 
> > This cleans up a bit libcacard headers inclusion.
> > 
> > Signed-off-by: Marc-André Lureau 
> > ---
> >  configure   | 7 ---
> >  hw/usb/ccid-card-emulated.c | 5 +
> >  hw/usb/ccid-card-passthru.c | 2 +-
> >  3 files changed, 6 insertions(+), 8 deletions(-)
> 
> Are there any distros that have not packaged libcacard yet?  This will
> break compatibility with QEMU 2.4's libcacard, I think.

I bumped libcacard requirement to 2.5.1 in the patch.



Re: [Qemu-devel] [PATCH] ccid: use libcacard.h from 2.5.1

2015-12-18 Thread Paolo Bonzini


On 18/12/2015 10:49, marcandre.lur...@redhat.com wrote:
> From: Marc-André Lureau 
> 
> This cleans up a bit libcacard headers inclusion.
> 
> Signed-off-by: Marc-André Lureau 
> ---
>  configure   | 7 ---
>  hw/usb/ccid-card-emulated.c | 5 +
>  hw/usb/ccid-card-passthru.c | 2 +-
>  3 files changed, 6 insertions(+), 8 deletions(-)

Are there any distros that have not packaged libcacard yet?  This will
break compatibility with QEMU 2.4's libcacard, I think.

Paolo



[Qemu-devel] [PATCH] ccid: use libcacard.h from 2.5.1

2015-12-18 Thread marcandre . lureau
From: Marc-André Lureau 

This cleans up a bit libcacard headers inclusion.

Signed-off-by: Marc-André Lureau 
---
 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 
-#include 
-#include 
-#include 
+#include 
 
 #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 
 
 #define DPRINTF(card, lvl, fmt, ...)\
 do {\
-- 
2.5.0