
#   --------------------------------------------------------------------------
#
#   MAKE file for JMODEM, the 'C' version.
#   JMODEM                              Richard B. Johnson
#                                       405 Broughton Drive
#                                       Beverly, Massachusetts 01915
#                                       BBS (508) 922-3166
#
#   Turbo C Makefile created 21-Apr-90  Brad Smith
#                                       141 Riggs Street
#                                       Jacksonville, North Carolina 28540
#                                       BBS (919) 455-5972 12/24/9600+ 24 hrs
#
#   Modified:
#   21-NOV-1991			Richard B. Johnson
#   Added support for the external assembly routines in JMODEM_G.ASM. I
#   did not have a copy of TASM, so I used old-fashion MASM instead.
#
#   Execute MAKE JMODEMTC
#
#   Note:  TurboC Version of JModem.exe generates a null pointer assignment
#          on small model ONLY??
#
#   --------------------------------------------------------------------------
#
#   --------------------------------------------------------------------------
#   headers common to all
#   --------------------------------------------------------------------------
HEADERS = jmodem.h jmodemtc

#   --------------------------------------------------------------------------
#   exe object dependancy list
#   --------------------------------------------------------------------------
OBJECTS = jmodem_a.obj jmodem_b.obj jmodem_c.obj \
          jmodem_d.obj jmodem_e.obj jmodem_f.obj jmodem_g.obj

#   --------------------------------------------------------------------------
#   couple of dumb macros
#   --------------------------------------------------------------------------

env = e:\turboc
CMP = tcc -w -G -O -Z -d -N- -k -K -ms -c -DTURBOC -I$(env)\include -L$(env)\lib
ASM = MASM
LNK = tlink @jmodemtc.rsp

#   --------------------------------------------------------------------------
#   implicit build rule for .c files
#   --------------------------------------------------------------------------
.c.obj :
   $(CMP) $<

#   --------------------------------------------------------------------------
#   implicit build rule for .asm files
#   --------------------------------------------------------------------------

.asm.obj:
   $(ASM) $<;

#   --------------------------------------------------------------------------
#   Turbo make NEEDS the final result as the FIRST target! I Believe...
#   --------------------------------------------------------------------------
jmodem.exe   : $(OBJECTS)
    $(LNK)

#   --------------------------------------------------------------------------
#   dependancy list -- implicit build rule specified above will build'm
#   --------------------------------------------------------------------------
jmodem_a.obj : $(HEADERS) jmodem_a.c
jmodem_b.obj : $(HEADERS) jmodem_b.c
jmodem_c.obj : $(HEADERS) jmodem_c.c
jmodem_d.obj : $(HEADERS) jmodem_d.c
jmodem_e.obj : $(HEADERS) jmodem_e.c uart.h
jmodem_f.obj : $(HEADERS) jmodem_f.c screen.h
jmodem_g.obj : $(HEADERS) jmodem_g.asm
