#	name		Lattice makefile
#	author		Anthony Hay, John Linney Digital Research (UK) Ltd.
#
# 	purpose		Build the DOS Plus 3.x / Concurrent DOS 6.x utilities.
#
#	history
#	13-Jan-88 JFL	Dos 3.3 COMP utility
#	24-MAR-87 ACH	Work started.
#	22-Jun-88 JC	Conversion to TURBOC
#

RASMFLG = $$szpznc

#INC	= $(MWCINC)
#CSLIB	= $(MWCLIB)\SMALL\HCSE.LIB
#
#.SET: IPATH=$(INC)\;$(APPS)\\

#
#	Configuration parameters for Borland Turbo C
#
INC	= $(TCCINC)
CSLIB	= $(TCCLIB)\CS.LIB
TCCSTART = $(TCCLIB)\C0S.OBJ+

.c.obj:
#       $(MSC) $(MSCFLG) $*.C,$@;
#       $(MWC) $* -obj $@ $(MWCFLG)
	$(TCC) $(TCCFLG) -I$(APPS) -o$@ $*.c 

all:		comp

# COMP 	###############################################################
comp:	$(MSG)\comp.com

$(MSG)\comp.com:	comp.obj fcomp.obj $(MSG)\compmsg.obj $(APPS)\appslib.lib
	$(LINK) @<<(backup.inp)
$(TCCSTART)comp+fcomp+$(MSG)\compmsg /EXEPACK
$(MSG)\comp.com

$(APPS)\appslib+$(CSLIB)
<
	$(PIFED) $@ $(PIFLARGE)
	
comp.obj:	comp.c comp.h i:portab.h 

$(MSG)\compmsg.obj:	$(MSG)\compmsg.c

fcomp.obj:	fcomp.asm

###############################################################################
#	The following targets control the archival system. Targets have
#	been declared to ARCHIVE, EXTRACT, VERSION and REPORT on the
#	COMMAND.COM product and its history.
#
THREAD =			# Thread must be defined before the
				# ASSIGN target is used.
EXTPARM = -OWLRlatest		# Extract Target Options
ASSPARM = -LXRlatest		# Assign Target Options
ARCPARM = -LCUSQ		# Archive Target Options

ARCLIST	= ..\*.*

extract:
	$(TOOLS)\dget.exe $(EXTPARM) $(ARCLIST)

assign:
	$(TOOLS)\dget.exe -A$(THREAD) $(ASSPARM) $(ARCLIST)

archive:
	$(TOOLS)\dgen.exe $(ARCPARM) -Nn7000 -nB7000 $(ARCLIST)

report:
        $(TOOLS)\dlist -PL60 -PO00 -FF $(FOOTER) -AD:01/01/86\
		$(FMT) $(ARCLIST)

######################   E N D   O F   M A K E F I L E    #####################
