#
!IFNDEF ESP_ROOT
!ERROR ESP_ROOT must be set -- Please fix the environment...
!ENDIF
#
IDIR  = $(ESP_ROOT)\include
!include $(IDIR)\$(ESP_ARCH).$(MSVC)
LDIR  = $(ESP_ROOT)\lib
!IFDEF ESP_BLOC
ODIR  = $(ESP_BLOC)\obj
TDIR  = $(ESP_BLOC)\test
!ELSE
ODIR  = .
TDIR  = $(ESP_ROOT)\bin
!ENDIF


$(LDIR)\tecplotWriter.dll:	tecplotWriter.def $(ODIR)\tecplotWriter.obj $(LDIR)\aimUtil.lib
	-del $(LDIR)\tecplotWriter.dll $(LDIR)\tecplotWriter.lib \
		$(LDIR)\tecplotWriter.exp
	 link /out:$(LDIR)\tecplotWriter.dll /dll /def:tecplotWriter.def \
		$(ODIR)\tecplotWriter.obj /LIBPATH:$(LDIR) aimUtil.lib \
		ocsm.lib egads.lib udunits2.lib
	$(MCOMP) /manifest $(LDIR)\tecplotWriter.dll.manifest \
		/outputresource:$(LDIR)\tecplotWriter.dll;2

$(ODIR)\tecplotWriter.obj:	tecplotWriter.c $(IDIR)\aimUtil.h $(IDIR)\capsTypes.h $(IDIR)\aimMesh.h
	cl /c $(COPTS) $(DEFINE) /I$(IDIR) tecplotWriter.c \
		/Fo$(ODIR)\tecplotWriter.obj
		
clean:
	-del $(ODIR)\tecplotWriter.obj

cleanall:	clean
	-del $(LDIR)\tecplotWriter.dll $(LDIR)\tecplotWriter.lib \
		$(LDIR)\tecplotWriter.exp
