#
#  System Configuration Editor Makefile
# 
#
#
.autodepend
.swap

!if !$d(TPROOT)
TPROOT=\TP7
!endif

!if !$d(ARCTOOL)
ARCTOOL=\PKZIP
!endif

!if !$d(CCROOT)
CCROOT=\TC
!endif

#ASM=a86
ARC=$(ARCTOOL)\PKZIP
ARCOPTIONS=
#CC=$(CCROOT)\bin\tcc
PC = $(TPROOT)\bin\tpc
COPTIONS=-c -ml -wrvl -p -k- -r- -u- -zCCODE -zP -zA -zRCONST -zS -zT -zDDATA -zG -zB
POPTIONS=/Uc:\tp7\units
!if !$d(CCONFIG)
CCONFIG=\projects\tedit\ctopas.cfg
!endif

!if !$d(PCONFIG)
PCONFIG=\tp7\bin
!endif

!if !$d(INCLUDE)
INCLUDE=\tc\include;.\\
!endif

!if !$d(LIBS)
LIBS=\tc\lib;\dev\lib
!endif

# General make rules

.pas.tpu:
  $(PC) $< /T$(PCONFIG)

.pas.exe:
  $(PC) $< /T$(PCONFIG)                                              

.c.obj:
  $(CC) +$(CCONFIG) -I$(INCLUDE) -L$(LIBS) $<

.cpp.obj:
  $(CC) +$(CCONFIG) -I$(INCLUDE) -L$(LIBS) $<

.asm.obj:
  $(ASM) $<,$*.obj;

sce.exe: seconst.tpu seui.tpu sce.pas  

distpkg :
 @$(ARC) $(ARCOPTIONS) dist\sce sce.exe *.doc copying sce.lsm
 @$(ARC) $(ARCOPTIONS) dist\scesrc sce.pas seui.pas seconst.pas copying makefile


seconst.tpu : seconst.pas

seui.tpu : seui.pas

depend : seconst.tpu seui.tpu

all : seconst.tpu seui.tpu sce.exe

clean :
 @echo Performing cleanup...please wait...
 @if exist *.map del *.map > nul
 @del *.tpu > nul
 @del *.exe > nul
 @del *.bak > nul
 @del dist\*.*  /y > nul
