#
# NOTE: This is a gnu make file, NOT a Microsoft nmake  file,
#       but you should run make from a cmd shell, not a bash shell.
#
# You need to run the batch file VCVARS32.BAT before using make.
#
# Use "cl /help" to see all of the compiler command line options
# Use "link" to see all of the linker command line options
# To get ALL warnings, use /W4
# To statically link the (debug) version of LIBC, use /MLd
CC = cl
CFLAGS = /Zi /W1 /nologo /MDd /Fa$*.asm /FAsc
LINKFLAGS = /link /PDB:NONE

.SUFFIXES: .c .exe

# See Section 5.4.3 of "GNU Make Manual"
# 08 July 2002, GNU make Version 3.80.
all: $(patsubst %.c,%.exe,$(wildcard *.c))

# use a simple suffix rule
.c.exe:
	$(CC) $(CFLAGS) $< $(LINKFLAGS)

clean:
	cmd /c del *.exe
	cmd /c del *.obj
	cmd /c del *.asm
	cmd /c del *.pdb


