.SUFFIXES: .o .c .c++ .s

CC        = cc
CPP       = _C++ c++
LINK      = DRLink

ILIBS     = CathLibCPP:,OS:,CLib:
STUBS     = CathLibCPP:o.Stubs
LLIBS     = CathLibCPP:o.CathLibCPP OSLib:o.OSLib ${STUBS}

CFLAGS    = -zo -fw -ff -throwback -I${ILIBS} -c -depend !Depend -D__swi=extern
CPPFLAGS  = ${CFLAGS} -C++ -DUSING_OSLIB
AFLAGS    = -desktop ^ -depend !Depend -throwback -nocache
LFLAGS    = -throwback -nounused -leaveweak -C++
#LFLAGS    = -throwback -nounused -leaveweak -C++ -areamap map -s symbols -revmap

ALL       = thellow tistream tofstream tostream tmixture tseek tsstream tstring

#ALL       = tsstream

TARGETS   = ${ALL}

all: ${TARGETS}

thellow: o.thellow ${LLIBS}
   ${LINK} ${LFLAGS} -o $@ o.thellow ${LLIBS}

tistream: o.tistream ${LLIBS}
   ${LINK} ${LFLAGS} -o $@ o.tistream ${LLIBS}

tofstream: o.tofstream ${LLIBS}
   ${LINK} ${LFLAGS} -o $@ o.tofstream ${LLIBS}

tostream: o.tostream ${LLIBS}
   ${LINK} ${LFLAGS} -o $@ o.tostream ${LLIBS}

tmixture: o.tmixture ${LLIBS}
   ${LINK} ${LFLAGS} -o $@ o.tmixture ${LLIBS}

tseek: o.tseek ${LLIBS}
   ${LINK} ${LFLAGS} -o $@ o.tseek ${LLIBS}

tsstream: o.tsstream ${LLIBS}
   ${LINK} ${LFLAGS} -o $@ o.tsstream ${LLIBS}

tstring: o.tstring ${LLIBS}
   ${LINK} ${LFLAGS} -o $@ o.tstring ${LLIBS}

.c.o:; ${CC} ${CFLAGS} -o $@ $<
.c++.o:; ${CPP} ${CPPFLAGS} -o $@ $<
.s.o:; objasm ${AFLAGS} $< $@



# Dynamic dependencies:
tmixture:	c++.tmixture
tmixture:	CathLibCPP:h.iostream
tmixture:	CathLibCPP:h.config
tmixture:	CathLibCPP:h.istream
tmixture:	CathLibCPP:h.bool
tmixture:	CathLibCPP:h.ios
tmixture:	CathLibCPP:h.exception
tmixture:	CathLibCPP:h.ptypeinfo
tmixture:	CathLibCPP:h.iosfwd
tmixture:	CathLibCPP:h.string
tmixture:	CathLibCPP:h.iterator
tmixture:	CathLibCPP:h.newcasts
tmixture:	CathLibCPP:h.typeinfo
tmixture:	CathLibCPP:h.ostream
o.thellow:	c++.thellow
o.thellow:	CathLibCPP:h.iostream
o.thellow:	CathLibCPP:h.config
o.thellow:	CathLibCPP:h.istream
o.thellow:	CathLibCPP:h.bool
o.thellow:	CathLibCPP:h.ios
o.thellow:	CathLibCPP:h.exception
o.thellow:	CathLibCPP:h.ptypeinfo
o.thellow:	CathLibCPP:h.iosfwd
o.thellow:	CathLibCPP:h.string
o.thellow:	CathLibCPP:h.iterator
o.thellow:	CathLibCPP:h.newcasts
o.thellow:	CathLibCPP:h.typeinfo
o.thellow:	CathLibCPP:h.ostream
o.tistream:	c++.tistream
o.tistream:	CathLibCPP:h.iostream
o.tistream:	CathLibCPP:h.config
o.tistream:	CathLibCPP:h.istream
o.tistream:	CathLibCPP:h.bool
o.tistream:	CathLibCPP:h.ios
o.tistream:	CathLibCPP:h.exception
o.tistream:	CathLibCPP:h.ptypeinfo
o.tistream:	CathLibCPP:h.iosfwd
o.tistream:	CathLibCPP:h.string
o.tistream:	CathLibCPP:h.iterator
o.tistream:	CathLibCPP:h.newcasts
o.tistream:	CathLibCPP:h.typeinfo
o.tistream:	CathLibCPP:h.ostream
o.tistream:	CathLibCPP:h.iomanip
o.tofstream:	c++.tofstream
o.tofstream:	CathLibCPP:h.fstream
o.tofstream:	CathLibCPP:h.config
o.tofstream:	CathLibCPP:h.istream
o.tofstream:	CathLibCPP:h.bool
o.tofstream:	CathLibCPP:h.ios
o.tofstream:	CathLibCPP:h.exception
o.tofstream:	CathLibCPP:h.ptypeinfo
o.tofstream:	CathLibCPP:h.iosfwd
o.tofstream:	CathLibCPP:h.string
o.tofstream:	CathLibCPP:h.iterator
o.tofstream:	CathLibCPP:h.newcasts
o.tofstream:	CathLibCPP:h.typeinfo
o.tofstream:	CathLibCPP:h.ostream
o.tofstream:	CathLibCPP:h.stdiobuf
o.tofstream:	CathLibCPP:h.streambuf
o.tofstream:	CathLibCPP:h.stream
o.tofstream:	CathLibCPP:h.iomanip
o.tostream:	c++.tostream
o.tostream:	CathLibCPP:h.iostream
o.tostream:	CathLibCPP:h.config
o.tostream:	CathLibCPP:h.istream
o.tostream:	CathLibCPP:h.bool
o.tostream:	CathLibCPP:h.ios
o.tostream:	CathLibCPP:h.exception
o.tostream:	CathLibCPP:h.ptypeinfo
o.tostream:	CathLibCPP:h.iosfwd
o.tostream:	CathLibCPP:h.string
o.tostream:	CathLibCPP:h.iterator
o.tostream:	CathLibCPP:h.newcasts
o.tostream:	CathLibCPP:h.typeinfo
o.tostream:	CathLibCPP:h.ostream
o.tostream:	CathLibCPP:h.iomanip
o.tostream:	CathLibCPP:h.streambuf
o.tmixture:	c++.tmixture
o.tmixture:	CathLibCPP:h.iostream
o.tmixture:	CathLibCPP:h.config
o.tmixture:	CathLibCPP:h.istream
o.tmixture:	CathLibCPP:h.bool
o.tmixture:	CathLibCPP:h.ios
o.tmixture:	CathLibCPP:h.exception
o.tmixture:	CathLibCPP:h.ptypeinfo
o.tmixture:	CathLibCPP:h.iosfwd
o.tmixture:	CathLibCPP:h.string
o.tmixture:	CathLibCPP:h.iterator
o.tmixture:	CathLibCPP:h.newcasts
o.tmixture:	CathLibCPP:h.typeinfo
o.tmixture:	CathLibCPP:h.ostream
o.tmixture:	CathLibCPP:h.streambuf
o.tseek:	c++.tseek
o.tseek:	CathLibCPP:h.iomanip
o.tseek:	CathLibCPP:h.config
o.tseek:	CathLibCPP:h.istream
o.tseek:	CathLibCPP:h.bool
o.tseek:	CathLibCPP:h.ios
o.tseek:	CathLibCPP:h.exception
o.tseek:	CathLibCPP:h.ptypeinfo
o.tseek:	CathLibCPP:h.iosfwd
o.tseek:	CathLibCPP:h.string
o.tseek:	CathLibCPP:h.iterator
o.tseek:	CathLibCPP:h.newcasts
o.tseek:	CathLibCPP:h.typeinfo
o.tseek:	CathLibCPP:h.ostream
o.tseek:	CathLibCPP:h.iostream
o.tseek:	CathLibCPP:h.stdiobuf
o.tseek:	CathLibCPP:h.streambuf
o.tsstream:	c++.tsstream
o.tsstream:	CathLibCPP:h.iostream
o.tsstream:	CathLibCPP:h.config
o.tsstream:	CathLibCPP:h.istream
o.tsstream:	CathLibCPP:h.bool
o.tsstream:	CathLibCPP:h.ios
o.tsstream:	CathLibCPP:h.exception
o.tsstream:	CathLibCPP:h.ptypeinfo
o.tsstream:	CathLibCPP:h.iosfwd
o.tsstream:	CathLibCPP:h.string
o.tsstream:	CathLibCPP:h.iterator
o.tsstream:	CathLibCPP:h.newcasts
o.tsstream:	CathLibCPP:h.typeinfo
o.tsstream:	CathLibCPP:h.ostream
o.tsstream:	CathLibCPP:h.sstream
o.tsstream:	CathLibCPP:h.streambuf
o.tsstream:	CathLibCPP:h.stream
o.tstring:	c++.tstring
o.tstring:	CathLibCPP:h.iostream
o.tstring:	CathLibCPP:h.config
o.tstring:	CathLibCPP:h.istream
o.tstring:	CathLibCPP:h.bool
o.tstring:	CathLibCPP:h.ios
o.tstring:	CathLibCPP:h.exception
o.tstring:	CathLibCPP:h.ptypeinfo
o.tstring:	CathLibCPP:h.iosfwd
o.tstring:	CathLibCPP:h.string
o.tstring:	CathLibCPP:h.iterator
o.tstring:	CathLibCPP:h.newcasts
o.tstring:	CathLibCPP:h.typeinfo
o.tstring:	CathLibCPP:h.ostream
o.tstring:	CathLibCPP:h.iomanip
