Revive Amiga port for NetHack 3.7
Update the Amiga Intuition window port (AMII/AMIV) for the 3.7 window_procs API. Key changes: - Update all window function signatures for 3.7 - Add assembly trampolines for AmigaOS register-based callbacks - Convert all K&R function definitions to C99 - Add cross-compilation build system (cross-pre1/pre2/post.370) using bebbo's m68k-amigaos-gcc with -noixemul -std=gnu17 -m68000 - Clipping fixes: viewport centering, simplified ScrollRaster, duplicate Ctrl-R suppression, glyph buffer invalidation - Add menucolor support in menu rendering - Move native txt2iff.c and xpm2iff.c to outdated/ - Add nethack.cnf and README.amiga
This commit is contained in:
@@ -229,6 +229,76 @@ mipspkg: dodata $(GAMEBIN) $(TARGETPFX)recover
|
||||
@echo MIPS package zip file $(TARGETPFX)nh370mips.zip
|
||||
endif # CROSS_TO_MIPS
|
||||
|
||||
|
||||
ifdef CROSS_TO_AMIGA
|
||||
$(TARGETPFX)amidos.o : ../sys/amiga/amidos.c $(HACK_H)
|
||||
$(TARGETPFX)amigst.o : ../sys/amiga/amigst.c $(HACK_H)
|
||||
$(TARGETPFX)amirip.o : ../sys/amiga/amirip.c $(HACK_H)
|
||||
$(TARGETPFX)amistack.o : ../sys/amiga/amistack.c $(HACK_H)
|
||||
$(TARGETPFX)amitty.o : ../sys/amiga/amitty.c $(HACK_H)
|
||||
$(TARGETPFX)amiwind.o : ../sys/amiga/amiwind.c \
|
||||
../sys/amiga/amimenu.c $(HACK_H)
|
||||
$(TARGETPFX)winami.o : ../sys/amiga/winami.c $(HACK_H)
|
||||
$(TARGETPFX)winchar.o : ../sys/amiga/winchar.c tile.c $(HACK_H)
|
||||
$(TARGETPFX)winfuncs.o : ../sys/amiga/winfuncs.c $(HACK_H)
|
||||
$(TARGETPFX)winkey.o : ../sys/amiga/winkey.c $(HACK_H)
|
||||
$(TARGETPFX)winamenu.o : ../sys/amiga/winamenu.c $(HACK_H)
|
||||
$(TARGETPFX)winreq.o : ../sys/amiga/winreq.c \
|
||||
../sys/amiga/colorwin.c \
|
||||
../sys/amiga/clipwin.c $(HACK_H)
|
||||
$(TARGETPFX)winstr.o : ../sys/amiga/winstr.c $(HACK_H)
|
||||
$(GAMEBIN) : $(HOBJ) $(LUACROSSLIB)
|
||||
$(TARGET_LINK) $(TARGET_LFLAGS) -o $(GAMEBIN) \
|
||||
$(HOBJ) $(WINLIB) $(TARGET_LIBS)
|
||||
#
|
||||
# Host-side IFF tile conversion tools (run on Linux, produce Amiga IFF files)
|
||||
#
|
||||
AMISRC = ../sys/amiga
|
||||
|
||||
$(TARGETPFX)xpm2iff_host: $(AMISRC)/xpm2iff_host.c
|
||||
$(CC) $(CFLAGS) -o $@ $<
|
||||
$(TARGETPFX)tomb.iff: $(AMISRC)/grave16.xpm $(TARGETPFX)xpm2iff_host
|
||||
$(TARGETPFX)xpm2iff_host $(AMISRC)/grave16.xpm $@
|
||||
|
||||
$(TARGETPFX)bmp2iff_host: $(AMISRC)/bmp2iff_host.c
|
||||
$(CC) $(CFLAGS) -o $@ $<
|
||||
$(TARGETPFX)tiles16.iff: ../dat/nhtiles.bmp $(TARGETPFX)bmp2iff_host
|
||||
$(TARGETPFX)bmp2iff_host -planes 4 ../dat/nhtiles.bmp $@
|
||||
$(TARGETPFX)tiles32.iff: ../dat/nhtiles.bmp $(TARGETPFX)bmp2iff_host
|
||||
$(TARGETPFX)bmp2iff_host -planes 5 ../dat/nhtiles.bmp $@
|
||||
|
||||
AMITILES = $(TARGETPFX)tiles16.iff $(TARGETPFX)tiles32.iff $(TARGETPFX)tomb.iff
|
||||
|
||||
.PHONY: amigapkg amitiles
|
||||
amitiles: $(AMITILES)
|
||||
|
||||
amigapkg: $(AMITILES)
|
||||
mkdir -p $(TARGETPFX)pkg/tiles $(TARGETPFX)pkg/hack
|
||||
cp $(GAMEBIN) $(TARGETPFX)pkg/nethack
|
||||
cp ../dat/nhdat $(TARGETPFX)pkg/nhdat
|
||||
cp ../dat/license $(TARGETPFX)pkg/license
|
||||
cp ../dat/symbols $(TARGETPFX)pkg/symbols
|
||||
cp $(TARGETPFX)tiles16.iff $(TARGETPFX)pkg/tiles/tiles16.iff
|
||||
cp $(TARGETPFX)tiles32.iff $(TARGETPFX)pkg/tiles/tiles32.iff
|
||||
cp $(TARGETPFX)tomb.iff $(TARGETPFX)pkg/tomb.iff
|
||||
cp ../sys/msdos/sysconf $(TARGETPFX)pkg/sysconf
|
||||
cp ../doc/nethack.txt $(TARGETPFX)pkg/nethack.txt
|
||||
( cd $(TARGETPFX)pkg && uudecode ../../../sys/amiga/amifont8.uu && mv 8 hack/8 )
|
||||
( cd $(TARGETPFX)pkg && uudecode ../../../sys/amiga/amifont.uu )
|
||||
cp $(AMISRC)/nethack.cnf $(TARGETPFX)pkg/nethack.cnf
|
||||
-( cd $(TARGETPFX)pkg && test -f ../../../sys/amiga/dflticon.uu && \
|
||||
uudecode ../../../sys/amiga/dflticon.uu )
|
||||
-( cd $(TARGETPFX)pkg && test -f ../../../sys/amiga/NHinfo.uu && \
|
||||
uudecode ../../../sys/amiga/NHinfo.uu )
|
||||
-( cd $(TARGETPFX)pkg && test -f ../../../sys/amiga/NewGame.uu && \
|
||||
uudecode ../../../sys/amiga/NewGame.uu )
|
||||
-( cd $(TARGETPFX)pkg && test -f ../../../sys/amiga/HackWB.uu && \
|
||||
uudecode ../../../sys/amiga/HackWB.uu )
|
||||
touch $(TARGETPFX)pkg/record
|
||||
( cd $(TARGETPFX)pkg && zip -9r ../NH370AMI.ZIP * )
|
||||
@echo amiga package zip file $(TARGETPFX)NH370AMI.ZIP
|
||||
endif # CROSS_TO_AMIGA
|
||||
|
||||
ifdef CROSS_SHARED
|
||||
# shared file dependencies
|
||||
$(TARGETPFX)pcmain.o : ../sys/share/pcmain.c $(HACK_H)
|
||||
|
||||
Reference in New Issue
Block a user