made vpcd.c/vpcd.h windows-compatible

This commit is contained in:
Frank Morgner
2013-05-19 04:08:44 +02:00
parent fd6fdd8b01
commit bae3f07045
4 changed files with 46 additions and 8 deletions

View File

@@ -5,8 +5,20 @@ AC_PREREQ([2.65])
AC_INIT([PC/SC Relay], [0.4], [http://sourceforge.net/projects/vsmartcard/support], [pcsc-relay], [http://vsmartcard.sourceforge.net/pcsc-relay/README.html])
AC_CONFIG_SRCDIR([src/pcsc-relay.c])
AC_CONFIG_HEADERS([config.h])
AC_CONFIG_MACRO_DIR([m4])
AM_INIT_AUTOMAKE
dnl Check for windows build
case "${host}" in
*-mingw*|*-winnt*)
WIN32="yes"
;;
*-cygwin*)
WIN32="yes"
;;
esac
AM_CONDITIONAL([WIN32], [test "${WIN32}" = "yes"])
# Checks for programs.
AC_PROG_CC
AM_PROG_CC_C_O

View File

@@ -32,6 +32,10 @@ pcsc_relay_SOURCES = pcsc-relay.c pcsc.c vpcd.c vpcd-driver.c opicc.c lnfc.c $(B
pcsc_relay_LDADD = $(PCSC_LIBS) $(LIBNFC_LIBS)
pcsc_relay_CFLAGS = $(PCSC_CFLAGS) $(LIBNFC_CFLAGS)
if WIN32
pcsc_relay_LDADD += -lws2_32
endif
noinst_HEADERS = pcsc-relay.h vpcd.h
pcsc-relay.c: $(BUILT_SOURCES)