Alon,
What is the benefit of using:
PKG_CHECK_EXISTS(
[libpcsclite],
[PKG_CHECK_MODULES([PCSC], [libpcsclite])]
instead of just:
PKG_CHECK_MODULES([PCSC], [libpcsclite])
Is it because PCSC_CFLAGS and PCSC_LIBS are erased in the second case
if pkg-config can't find libpcsclite?
2009/2/3 <[email protected]>:
> Revision: 3650
> Author: alonbl
> Date: 2009-02-03 20:11:30 +0000 (Tue, 03 Feb 2009)
>
> Log Message:
> -----------
> Default PCSC CFLAGS from pkg-config
>
> Modified Paths:
> --------------
> trunk/configure.ac
> Modified: trunk/configure.ac
> ===================================================================
> --- trunk/configure.ac 2009-02-01 08:26:30 UTC (rev 3649)
> +++ trunk/configure.ac 2009-02-03 20:11:30 UTC (rev 3650)
> @@ -547,16 +547,21 @@
> fi
>
> if test "${enable_pcsc}" = "yes"; then
> - AC_ARG_VAR([PCSC_CFLAGS], [C compiler flags for pcsc])
> -
> - case "${host}" in
> - *-*-darwin*)
> - test -z "${PCSC_CFLAGS}" &&
> PCSC_CFLAGS="-I/System/Library/Frameworks/PCSC.framework/Headers"
> - ;;
> - esac
> -
> if test "${WIN32}" != "yes"; then
> - test -z "${PCSC_CFLAGS}" && PCSC_CFLAGS="-I/usr/include/PCSC"
> + PKG_CHECK_EXISTS(
> + [libpcsclite],
> + [PKG_CHECK_MODULES([PCSC], [libpcsclite])]
> + )
> + if test -z "${PCSC_CFLAGS}"; then
> + case "${host}" in
> + *-*-darwin*)
> +
> PCSC_CFLAGS="-I/System/Library/Frameworks/PCSC.framework/Headers"
> + ;;
> + *)
> + PCSC_CFLAGS="-I/usr/include/PCSC"
> + ;;
> + esac
> + fi
> fi
>
> saved_CFLAGS="${CFLAGS}"
>
--
Dr. Ludovic Rousseau
_______________________________________________
opensc-devel mailing list
[email protected]
http://www.opensc-project.org/mailman/listinfo/opensc-devel