fixed windows compiling with 'free' Windows 7 SDK, currently dropped default libusb support
This commit is contained in:
parent
4179bb1918
commit
f8b3ba9ab6
14 changed files with 25 additions and 1712 deletions
|
|
@ -1,23 +1,28 @@
|
|||
###############################################
|
||||
# General settings
|
||||
###############################################
|
||||
VPATH=../src
|
||||
VERSION = 1.3.0
|
||||
SOURCE = ../src
|
||||
NFC_LIB = $(SOURCE)/lib
|
||||
NFC_INCLUDE = $(SOURCE)/include
|
||||
NFC_BUSES = $(NFC_LIB)/buses
|
||||
VPATH = $(SOURCE)/examples $(NFC_LIB) $(NFC_BUSES) $(NFC_LIB)/chips $(NFC_LIB)/drivers
|
||||
|
||||
###############################################
|
||||
# Compiler settings
|
||||
###############################################
|
||||
CC = cl
|
||||
LD = link
|
||||
CFLAGS = -O2 -GL -I "$(Include);$(INCLUDE)" -I "libusb" -I "stdint" -D "WIN32" -MT -D "_CRT_SECURE_NO_WARNINGS" -D "HAVE_PCSC_LITE" -D "HAVE_LIBUSB" -D "_WINDLL" -EHsc -W3 -nologo -TC -errorReport:prompt
|
||||
LDFLAGS = -INCREMENTAL:NO -NOLOGO -LIBPATH:"libusb" -MANIFEST:NO -OPT:REF -OPT:ICF -LTCG libusb.lib libusb_x64.lib winscard.lib kernel32.lib user32.lib gdi32.lib winspool.lib comdlg32.lib advapi32.lib shell32.lib ole32.lib oleaut32.lib uuid.lib odbc32.lib odbccp32.lib
|
||||
CFLAGS = -O2 -GL -I "$(Include);$(INCLUDE)" -I "$(NFC_INCLUDE)" -I "$(NFC_BUSES)" -I "stdint" -D "WIN32" -MT -D "_CRT_SECURE_NO_WARNINGS" -D "HAVE_PCSC_LITE" -D "PACKAGE_VERSION=\"$(VERSION)\"" -D "_WINDLL" -EHsc -W3 -nologo -TC -errorReport:prompt
|
||||
LDFLAGS = -INCREMENTAL:NO -NOLOGO -MANIFEST:NO -OPT:REF -OPT:ICF -LTCG winscard.lib kernel32.lib user32.lib gdi32.lib winspool.lib comdlg32.lib advapi32.lib shell32.lib ole32.lib oleaut32.lib uuid.lib odbc32.lib odbccp32.lib
|
||||
|
||||
###############################################
|
||||
# Files
|
||||
###############################################
|
||||
OBJS = dev_pn531.obj dev_pn533.obj dev_acr122.obj dev_arygon.obj bitutils.obj rs232.obj libnfc.obj
|
||||
OBJS = pn53x.obj pn532_uart.obj acr122.obj arygon.obj bitutils.obj uart.obj nfc.obj
|
||||
HEADERS = dev_acr122.h bitutils.h defines.h libnfc.h
|
||||
LIBNFC = libnfc
|
||||
EXES = nfc-anticol.exe nfc-list.exe nfc-emulate.exe nfc-relay.exe nfc-mftool.exe nfc-mfultool.exe nfc-initiator.exe nfc-target.exe
|
||||
EXES = nfc-anticol.exe nfc-list.exe nfc-emulate.exe nfc-relay.exe nfc-mfclassic.exe nfc-mfultralight.exe nfcip-initiator.exe nfcip-target.exe
|
||||
|
||||
all: $(LIBNFC) $(EXES)
|
||||
|
||||
|
|
@ -27,8 +32,8 @@ all: $(LIBNFC) $(EXES)
|
|||
libnfc: $(OBJS)
|
||||
$(LD) $(LDFLAGS) -OUT:$(LIBNFC).dll -DLL -DEF:"libnfc.def" -SUBSYSTEM:WINDOWS $(OBJS)
|
||||
|
||||
nfc-%.exe : %.c $(LIBNFC)
|
||||
$(CC) $(CFLAGS) $< /link /OUT:$@ -SUBSYSTEM:CONSOLE $(LDFLAGS) $(LIBNFC).lib
|
||||
%.exe : %.c $(LIBNFC)
|
||||
$(CC) $(CFLAGS) -I "$(NFC_LIB)" $< /link /OUT:$@ -SUBSYSTEM:CONSOLE $(LDFLAGS) $(LIBNFC).lib
|
||||
|
||||
clean:
|
||||
del /Q $(OBJS) $(LIBNFC).dll $(LIBNFC).exp $(LIBNFC).lib *.obj $(EXES)
|
||||
Loading…
Add table
Add a link
Reference in a new issue