CPP = cl
RSC = rc
LINK = link

target = finddata.exe
libs = 
includes = 
rscobjects =
objects = main.obj util.obj
#CFLAGS = /nologo /c /Op
CFLAGS = /nologo /c /Op /O2 /G5 /W3

.SUFFIXES: .obj .c .cpp .h .rc .res

all: $(target)

$(target): $(objects) $(rscobjects)
	$(LINK) /nologo $(libs) $(objects) $(rscobjects) /out:$(target) 

.c.obj:
	$(CPP) $(CFLAGS) $<

.cpp.obj:
	$(CPP) $(CFLAGS) $<

.rc.res:
	$(RSC) /l 0x409 /fo $@ $< 

clean:
	if exist *.obj del *.obj 
	if exist $(target) del $(target)

