emailler/apps/Makefile
Oliver Schmidt e1a29ae411 Added Telnet65 app.
The file telnet.s in the 'ip65' directory for sure wasn't belonging into a library as it contained a main loop. So I introduced an 'apps' directory for actual apps coming with IP65. The file telnet.s was moved to apps, renamed telnet65.s and heavily modified.

The file c64vt100.s was made up from several files taken from CaTer (www.opppf.de/Cater) and adjusted for the new use case. The was done before for KIPPERTERM. However this time I deliberately avoided unnecessary code reformatting to allow for as easy as possible integration of potential upcoming changes in CaTer.

The file a2vt100.s was copied from c64vt100.s and adjusted to the monochrome 80 column screen of the Apple //e. Again unnecessary code changes were avoided to allow to easily merge upcoming changes from c64vt100.s.

The files atrvt100.s and vic20vt100.s are for now just dummies to allow to successfully link Telnet65. Work for an actually functional Telnet65 would start with a copy of c64vt100.s (as it was done with a2vt100.s).
2017-05-19 00:12:42 +02:00

110 lines
2.6 KiB
Makefile

# Build for Cirrus Logic CS8900A based devices:
# make eth=cl
# Build for Standard Microsystems LAN91C96 based devices:
# make eth=sm
# Build for WIZnet W5100 based devices:
# make eth=wn
ifeq ($(eth),cl)
C64DRIVERLIB = ../drivers/c64rrnet.lib
A2DRIVERLIB = ../drivers/a2uther.lib
else ifeq ($(eth),sm)
C64DRIVERLIB = ../drivers/c64eth64.lib
A2DRIVERLIB = ../drivers/a2lancegs.lib
else ifeq ($(eth),wn)
C64DRIVERLIB = ../drivers/c64wiz811.lib
A2DRIVERLIB = ../drivers/a2uther2.lib
else
C64DRIVERLIB = ../drivers/c64combo.lib
A2DRIVERLIB = ../drivers/a2combo.lib
endif
ATRDRIVERLIB = ../drivers/atrdragon.lib
VICDRIVERLIB = ../drivers/vic20rrnet.lib
UDP =\
TCP =\
telnet65
all: $(UDP) $(TCP)
.PHONY: $(UDP) $(TCP)
$(addsuffix .prg,$(UDP)): IP65LIB = ../ip65/ip65.lib
$(addsuffix .prg,$(TCP)): IP65LIB = ../ip65/ip65_tcp.lib
$(addsuffix .bin,$(UDP)): IP65LIB = ../ip65/ip65.lib
$(addsuffix .bin,$(TCP)): IP65LIB = ../ip65/ip65_tcp.lib
$(addsuffix .com,$(UDP)): IP65LIB = ../ip65/ip65.lib
$(addsuffix .com,$(TCP)): IP65LIB = ../ip65/ip65_tcp.lib
$(addsuffix .vicprg,$(UDP)): IP65LIB = ../ip65/ip65.lib
$(addsuffix .vicprg,$(TCP)): IP65LIB = ../ip65/ip65_tcp.lib
$(foreach pgm,$(UDP) $(TCP),$(eval $(pgm): $(pgm).prg $(pgm).bin $(pgm).com $(pgm).vicprg))
INCFILES =\
../inc/common.i \
../inc/commonprint.i \
../inc/net.i
prg: $(addsuffix .prg,$(UDP) $(TCP))
bin: $(addsuffix .bin,$(UDP) $(TCP))
com: $(addsuffix .com,$(UDP) $(TCP))
vicprg: $(addsuffix .vicprg,$(UDP) $(TCP))
d64: ip65.d64
dsk: ip65.dsk
atr: ip65.atr
ip65:
make -C ../ip65
drivers:
make -C ../drivers
%.o: %.s
ca65 $<
%.prg: %.o ip65 drivers $(INCFILES)
ld65 -o $*.prg -C c64.cfg -m $*.c64.map -vm $< $(IP65LIB) $(C64DRIVERLIB) c64.lib
%.bin: %.o ip65 drivers $(INCFILES)
ld65 -o $*.bin -C apple2.cfg -m $*.a2.map -vm $< $(IP65LIB) $(A2DRIVERLIB) apple2.lib
%.com: %.o ip65 drivers $(INCFILES)
ld65 -o $*.com -C atari.cfg -m $*.atr.map -vm $< $(IP65LIB) $(ATRDRIVERLIB) atari.lib
%.vicprg: %.o ip65 drivers $(INCFILES)
ld65 -o $*.vicprg -C vic20-32k.cfg -m $*.vic.map -vm $< $(IP65LIB) $(VICDRIVERLIB) vic20.lib
ip65.d64: prg
$(C1541) -format ip65,00 d64 $@
$(C1541) -attach $@ -write telnet65.prg telnet65,p
ip65.dsk: bin
cp prodos.dsk $@
java -jar $(AC) -cc65 $@ telnet65 bin < telnet65.bin
ip65.atr: com
mkdir atr
cp dos.sys atr/dos.sys
cp dup.sys atr/dup.sys
cp telnet65.com atr/telnet65.com
$(DIR2ATR) -b Dos25 1040 $@ atr
rm -r atr
clean:
make -C ../ip65 clean
make -C ../drivers clean
-rm -f ../supplement/*.o
-rm -f *.o *.prg *.bin *.com *.vicprg *.map
-rm -f ip65.d64 ip65.dsk ip65.atr