#
# $Id: //devel/tools/main/winforms/makefile#1 $
#
# written by :  Stephen J Friedl
#               Software Consultant
#		http://www.unixwiz.net/tools/
#
# This is the makefile for the "winforms" program used to do
# management of the Win32 forms system. THis makefile requires
# GNU make.
#

OBJS	= winforms.obj
LIBS	= winspool.lib gdi32.lib

CFLAGS  =
CFLAGS += /Gz		# use __stdcall calling convention
CFLAGS += /GF		# enable read-only string pooling
CFLAGS += /W4		# set max warnings
CFLAGS += /WX		# warnings are errors
CFLAGS += /MD		# link with MSVCRT DLL
CFLAGS += /YXwindows.h	# precompile up to windows.h

CLEAN   = *.obj *.pch winforms.exe

all : winforms.exe

winforms.exe : $(OBJS)
	link /nologo /out:$@ $(OBJS) $(LIBS)

winforms.obj : makefile

%.obj : %.cpp
	$(strip cl /nologo $(CFLAGS) /c $*.cpp)

clobber : clean
clean :
	rm -f $(CLEAN)

# ------------------------------------------------------------------------
# PC-LINT
#
# We use the outstanding PC-Lint tool from Gimpel Software to make our
# code cleaner, and this is where we do that processing. You don't care
# about this if you've not purchased the product.
#
ifdef PCLINTDIR

CLEAN += lint.out

lint :
	$(strip lint-nt local.lnt $(OBJS:.$O=.cpp) > lint.out)

endif

# "webupdate.mk" includes the code that updates my website with
# this source, and I don't distribute it. The "-" in front is
# used by GNU make to indicate that the file need not exist.

-include webupdate.mk
