refactored picc_to_pcsc to support other drivers to send data via rfid. renamed to pcsc-relay.
git-svn-id: https://vsmartcard.svn.sourceforge.net/svnroot/vsmartcard@348 96b47cad-a561-4643-ad3b-153ac7d7599c
This commit is contained in:
@@ -2,8 +2,8 @@
|
||||
# Process this file with autoconf to produce a configure script.
|
||||
|
||||
AC_PREREQ([2.65])
|
||||
AC_INIT([picc_to_pcsc], [0.1], [http://sourceforge.net/projects/vsmartcard/support])
|
||||
AC_CONFIG_SRCDIR([src/picc_to_pcsc.c])
|
||||
AC_INIT([pcsc-relay], [0.2], [http://sourceforge.net/projects/vsmartcard/support])
|
||||
AC_CONFIG_SRCDIR([src/pcsc-relay.c])
|
||||
AC_CONFIG_HEADERS([config.h])
|
||||
AM_INIT_AUTOMAKE
|
||||
|
||||
@@ -17,17 +17,27 @@ PKG_PROG_PKG_CONFIG
|
||||
PKG_CHECK_EXISTS([libpcsclite],
|
||||
[PKG_CHECK_MODULES([PCSC], [libpcsclite])],
|
||||
[AC_MSG_WARN([libpcsclite not found by pkg-config])])
|
||||
# Checks for libraries.
|
||||
PKG_CHECK_EXISTS([libnfc >= 1.3.9],
|
||||
[PKG_CHECK_MODULES([LIBNFC], [libnfc >= 1.3.9])],
|
||||
[AC_MSG_WARN([libnfc >= 1.3.9 not found by pkg-config])])
|
||||
|
||||
|
||||
saved_CPPFLAGS="$CPPFLAGS"
|
||||
saved_LIBS="$LIBS"
|
||||
CPPFLAGS="$CPPFLAGS $PCSC_CFLAGS"
|
||||
LIBS="$LDFLAGS $PCSC_LIBS"
|
||||
CPPFLAGS="$CPPFLAGS $PCSC_CFLAGS $LIBNFC_CFLAGS"
|
||||
LIBS="$LDFLAGS $PCSC_LIBS $LIBNFC_LIBS"
|
||||
AC_CHECK_HEADERS(winscard.h, [], [ AC_MSG_ERROR([winscard.h not found, install PC/SC Lite or similar or use ./configure PCSC_CFLAGS=...]) ])
|
||||
AC_CHECK_HEADERS(reader.h, [AC_DEFINE(HAVE_READER_H, 1, [use reader.h from PC/SC Lite])], [])
|
||||
AC_CHECK_HEADERS(pcsclite.h, [AC_DEFINE(HAVE_PCSCLITE_H, 1, [use pcsclite.h from PC/SC Lite])], [])
|
||||
AC_MSG_CHECKING([for SCardEstablishContext])
|
||||
AC_TRY_LINK_FUNC(SCardEstablishContext, [ AC_MSG_RESULT([yes]) ],
|
||||
[ AC_MSG_ERROR([libpcsclite not found, use ./configure PCSC_LIBS=...]) ])
|
||||
AC_CHECK_HEADERS(nfc/nfc.h,,
|
||||
[ AC_MSG_ERROR([nfc/nfc.h not found, install libnfc >= 1.3.9 or use ./configure LIBNFC_CFLAGS=...]) ])
|
||||
AC_MSG_CHECKING([for nfc_initiator_select_passive_target])
|
||||
AC_TRY_LINK_FUNC(nfc_initiator_select_passive_target, [ AC_MSG_RESULT([yes]) ],
|
||||
[ AC_MSG_ERROR([libnfc >= 1.3.9 not found, use ./configure LIBNFC_LIBS=...]) ])
|
||||
CPPFLAGS="$saved_CPPFLAGS"
|
||||
LIBS="$saved_LIBS"
|
||||
|
||||
@@ -51,7 +61,7 @@ AC_FUNC_MALLOC
|
||||
|
||||
cat << EOF
|
||||
|
||||
picc_to_pcsc has been configured with following options:
|
||||
pcsc-relay has been configured with following options:
|
||||
|
||||
Version: ${PACKAGE_VERSION}
|
||||
User binaries: $(eval eval eval echo "${bindir}")
|
||||
@@ -67,6 +77,8 @@ Linker flags: ${LDFLAGS}
|
||||
Libraries: ${LIBS}
|
||||
PCSC_CFLAGS: ${PCSC_CFLAGS}
|
||||
PCSC_LIBS: ${PCSC_LIBS}
|
||||
LIBNFC_CFLAGS: ${LIBNFC_CFLAGS}
|
||||
LIBNFC_LIBS: ${LIBNFC_LIBS}
|
||||
|
||||
EOF
|
||||
|
||||
|
||||
Reference in New Issue
Block a user