online/Makefile

58 lines
1.4 KiB
Makefile
Raw Normal View History

# Require-mints:
#
# GNU make
# - To execute this make file
#
# merlin32
# - to assemble the source code
# https://www.brutaldeluxe.fr/products/crossdevtools/merlin/
#
# AppleCommander (included)
# - To create the Apple II disk image
#
# AppleWin
# - To load the disk and test the program
2017-09-07 19:24:17 +00:00
#
ifeq ($(OS),Windows_NT)
2018-10-17 18:40:01 +00:00
COPY=copy
APPLEWIN="c:\opt\AppleWin1.26.2.3\applewin.exe"
2017-09-07 19:24:17 +00:00
else
2018-10-17 18:40:01 +00:00
COPY=cp
APPLEWIN=applewin
2017-09-07 19:24:17 +00:00
endif
# It is necessary to use this older version of AppleCommander to support
# the PowerBook G4 and iBook G3. This version only requires Java 1.3.
2021-07-05 22:30:16 +00:00
MERLIN=merlin32
AC=java -jar AppleCommander-1.3.5-ac.jar
2017-09-07 19:24:17 +00:00
SRC=online.s
2018-10-17 18:40:01 +00:00
PGM=online
BASE_DSK=prodos-2.0.3-boot.dsk
2017-09-07 19:24:17 +00:00
VOL=$(PGM)
DSK=$(PGM).dsk
2018-10-17 18:40:01 +00:00
# There is some kind of problem with turning this into a boot disk
# after it is created by AppleCommander. So, copy an existing boot
# disk instead.
#$(AC) -pro140 $(DSK) $(VOL)
2021-07-06 04:37:45 +00:00
$(DSK): $(PGM) $(PGM).ver.bas $(PGM).gui.bas
2018-10-17 18:40:01 +00:00
$(COPY) $(BASE_DSK) $(DSK)
2018-11-18 23:45:48 +00:00
# Does not work on older AC
#$(AC) -n $(DSK) $(VOL)
2021-07-06 04:37:45 +00:00
#$(AC) -p $(DSK) $(PGM) SYS < $(PGM)
$(AC) -p $(DSK) $(PGM) BIN 0x2000 < $(PGM)
$(AC) -p $(DSK) $(PGM).VER BAS < $(PGM).ver.bas
$(AC) -p $(DSK) $(PGM).GUI BAS < $(PGM).gui.bas
#cat $(PGM).ver.bas | tr '\n' '\r' | $(AC) -p $(DSK) $(PGM).VER TXT
2018-11-18 23:45:48 +00:00
2021-07-05 22:30:16 +00:00
$(PGM): $(SRC)
$(MERLIN) $(SRC)
2018-11-18 23:45:48 +00:00
2017-09-07 19:24:17 +00:00
clean:
2018-11-18 23:45:48 +00:00
$(RM) $(DSK) $(PGM) *.zip _FileInformation.txt
2017-09-07 19:24:17 +00:00
2018-10-17 18:40:01 +00:00
test: $(DSK)
$(APPLEWIN) -d1 $(DSK)