fixed x64 (out-of-the-box) compiling, tweaked 'make clean'

This commit is contained in:
Roel Verdult 2009-09-29 22:01:17 +00:00
parent 8967e0f67f
commit 406b670418

View file

@ -8,8 +8,8 @@ VPATH=../src
############################################### ###############################################
CC = cl CC = cl
LD = link LD = link
CFLAGS = -O2 -GL -I "$(Include);$(INCLUDE)" -I "libusb" -I "stdint" -D "WIN32" -D "LIBNFC_EXPORTS" -MT -D "_CRT_SECURE_NO_WARNINGS" -D "HAVE_PCSC_LITE" -D "_WINDLL" -EHsc -W3 -nologo -c -Wp64 -TC -wd4996 -errorReport:prompt CFLAGS = -O2 -GL -I "$(Include);$(INCLUDE)" -I "libusb" -I "stdint" -D "WIN32" -MT -D "_CRT_SECURE_NO_WARNINGS" -D "HAVE_PCSC_LITE" -D "_WINDLL" -EHsc -W3 -nologo -TC -errorReport:prompt
LDFLAGS = -INCREMENTAL:NO -NOLOGO -LIBPATH:"libusb" -MANIFEST:NO -OPT:REF -OPT:ICF -LTCG -MACHINE:X86 -ERRORREPORT:PROMPT winscard.lib libusb.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 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
############################################### ###############################################
# Files # Files
@ -17,19 +17,18 @@ LDFLAGS = -INCREMENTAL:NO -NOLOGO -LIBPATH:"libusb" -MANIFEST:NO -OPT:REF -OPT:I
OBJS = dev_pn531.obj dev_pn533.obj dev_acr122.obj dev_arygon.obj bitutils.obj rs232.obj libnfc.obj OBJS = dev_pn531.obj dev_pn533.obj dev_acr122.obj dev_arygon.obj bitutils.obj rs232.obj libnfc.obj
HEADERS = dev_acr122.h bitutils.h defines.h libnfc.h HEADERS = dev_acr122.h bitutils.h defines.h libnfc.h
LIBNFC = libnfc LIBNFC = libnfc
EXES = anticol list emulate relay mftool EXES = nfc-anticol.exe nfc-list.exe nfc-emulate.exe nfc-relay.exe nfc-mftool.exe
all: $(LIBNFC) $(EXES) all: $(LIBNFC) $(EXES)
%.obj : %.c %.obj : %.c
$(CC) $(CFLAGS) $< $(CC) -c $(CFLAGS) $<
libnfc: $(OBJS) libnfc: $(OBJS)
$(LD) -OUT:$(LIBNFC).dll -DLL -DEF:"libnfc.def" -SUBSYSTEM:WINDOWS $(LDFLAGS) $(OBJS) $(LD) $(LDFLAGS) -OUT:$(LIBNFC).dll -DLL -DEF:"libnfc.def" -SUBSYSTEM:WINDOWS $(OBJS)
% : %.c $(LIBNFC) nfc-%.exe : %.c $(LIBNFC)
$(CC) $(CFLAGS) $< $(CC) $(CFLAGS) $< /link /OUT:$@ -SUBSYSTEM:CONSOLE $(LDFLAGS) $(OBJS)
$(LD) /OUT:nfc-$@.exe -SUBSYSTEM:CONSOLE $(LDFLAGS) $(OBJS) $@
clean: clean:
rm -f $(OBJS) $(LIBNFC) $(EXES) del /Q $(OBJS) $(LIBNFC).dll $(LIBNFC).exp $(LIBNFC).lib *.obj $(EXES)