[Spice-devel] [PATCH 02/12] build-sys: add --enable-pcsc

Marc-André Lureau mlureau at redhat.com
Fri Oct 9 07:30:03 PDT 2015



----- Original Message -----
> On Thu, Oct 08, 2015 at 05:40:31PM +0200, marcandre.lureau at redhat.com wrote:
> > From: Marc-André Lureau <marcandre.lureau at redhat.com>
> > 
> > Signed-off-by: Marc-André Lureau <marcandre.lureau at redhat.com>
> > ---
> >  configure.ac | 26 ++++++++++++++++++++++++++
> >  1 file changed, 26 insertions(+)
> > 
> > diff --git a/configure.ac b/configure.ac
> > index b841ec1..b878526 100644
> > --- a/configure.ac
> > +++ b/configure.ac
> > @@ -36,9 +36,35 @@ AX_CODE_COVERAGE()
> >  PKG_CHECK_MODULES(CACARD, [glib-2.0 >= 2.22 nss >= 3.12.8])
> >  PKG_CHECK_MODULES(GTHREAD, [gthread-2.0])
> >  
> > +dnl === --enable-pcsc
> > ==========================================================
> > +
> > +AC_ARG_ENABLE([pcsc],
> > +              AS_HELP_STRING([--disable-pcsc],
> > +                             [do not build passthrough support]),,
> > +              enable_pcsc=auto)
> 
> I think there could be a few more [] around enable_pcsc=auto...
> 
> 
> 
> > +if test "x$enable_pcsc" != "xno"; then
> > +   PKG_CHECK_MODULES(PCSC, libpcsclite, have_pcsc=yes, have_pcsc=no)
> 
> ...and around the args here (though I never know when there should be []
> or not).

I think it's unneeded most of the time, except perhaps for later concatenation: FOO -> FOO_CFLAGS..

> I'm fine if you keep the patch this way.
> 
> Christophe
> 
> > +   if test "x$have_pcsc" = "xno" -a "x$enable_pcsc" = "xyes"; then
> > +      AC_MSG_ERROR([pcsc support explicitly requested, but libpcsclite
> > couldn't be found])
> > +   fi
> > +   if test "x$have_pcsc" = "xyes"; then
> > +      enable_pcsc=yes
> > +   fi
> > +fi
> > +AM_CONDITIONAL(ENABLE_PCSC, test "x$enable_pcsc" = "xyes")
> > +
> >  AC_CONFIG_FILES([
> >  Makefile
> >  src/Makefile
> >  libcacard.pc
> >  ])
> >  AC_OUTPUT
> > +
> > +AC_MSG_NOTICE([
> > +
> > +libcacard - $VERSION
> > +
> > +• Prefix: $prefix
> > +• PCSC enabled: $enable_pcsc
> > +
> > +])
> > --
> > 2.4.3
> > 
> > _______________________________________________
> > Spice-devel mailing list
> > Spice-devel at lists.freedesktop.org
> > http://lists.freedesktop.org/mailman/listinfo/spice-devel
> 


More information about the Spice-devel mailing list