STDFILES= HEADER.INC MACROS.INC VARS.INC SOUNDEQU.INC STRUCTS.INC ALCS.INC \
 GILESALX.INC GILESALC.INC GILESAL.INC KALCS.INC DALCS.INC PALETTES.INC \
 TALCS.INC YALCS.INC PLAYER.INC KMACS.INC TMACROS.INC KVARS.INC MVARS.INC \
 SOUND.INC SOUND2.INC MYVARS.INC MTVARS.INC MKVARS.INC
STRATFILES= STRATMAC.INC STRATLIB.INC STRATEQU.INC SHMACS.INC STRATHDR.INC \
 WEAPONS.INC SCALEVAR.INC
ASM=ARGSFXX
ASMFLAGS=-efilelist=0
include symson.mak
LINK=arglink
LOPTS=-b30 -h1024
ANSI=

ALLFILES= bank0.sob bank1.sob bank2.sob \
 bank4.sob bank5.sob bank6.sob bank7.sob \
 bank8.sob bank10.sob bank11.sob shbanks.sob incbins.sob incbins2.sob

.asm.sob:
	@$(ASM) -m30 $(ANSI) $(SYMSON) $(ASMFLAGS) $< -v$*.SOB

all: finished.sg

     
finished.sg: $(ALLFILES)
	@$(LINK) $(LOPTS) -d @flist

sf.rom: $(ALLFILES)
	@$(LINK) $(LOPTS) -osf.rom @flist

info: $(ALLFILES)
	@$(LINK) $(LOPTS) -l1024 @flist

remote: $(ALLFILES)
	@$(LINK) $(LOPTS) -oromfile @flist
	@+ftprom.btm
	

## Bank 0
bank0.sob: bank0.asm $(STRATFILES) \
$(STDFILES) blink.asm data\etabs.dat sgtabs.asm \
data\nintendo.pal font_1.bin japanese.msg \
english.msg sgdata.asm istrats.asm \
ushapes.asm pshapes.asm pshapes2.asm pshapes3.asm shapes.asm \
shapes2.asm bshapes.asm wshapes.asm eshapes.asm \
eshapes2.asm mmj.bin mme.bin techdata.asm

## Bank 1
bank1.sob: bank1.asm shmacs.inc gamemsgs.inc \
$(STDFILES) mmacs.mc mshtab.mc mmaths.mc mwrot.mc \
mwcrot.mc mobj.mc mclip.mc mtxtclp.mc \
mdrawp.mc msprite.mc mgdots.mc mcircle.mc \
mscreen.mc mcursor.mc mdrawlis.mc mdecru.mc \
mtxtprt.mc mplanet.mc mdsprite.mc mpart.mc \
mbumwipe.mc mhud.mc mhofs.mc mdebug.mc \
mplanclp.mc mboxes.mc \
data\moji_d.fon data\moji_d.trn gametext.asm fontdata.asm \
defspr.asm data\p_col.col coltab.asm \
light.asm coltabs.asm mslopes.mc


## Bank 2, 3
bank2.sob: bank2.asm bgmacs.inc $(STRATFILES) olsmacs.inc mapmacs.inc mapstruc.inc sound.inc sound2.inc gamelist.inc\
$(STDFILES) irq.asm showview.asm hdmatabs.asm \
mem.asm ramsrou.asm colboxes.asm coldet.asm \
ramspr.asm mmtbl.asm soslist.asm kramcalc.asm ramsound.asm \
yajima.inc yjradar.asm raster.asm rammes.asm \
ramstuff.asm trans.asm main.asm game.asm \
obj.asm planets.asm world.asm sysstrat.asm \
stratrou.asm nmi.asm screen.asm intro.asm \
bgs.asm windows.asm sndtbl.asm sound.asm draw.asm \
mapscr.asm debug.asm bootnmi.asm kcalc.asm \
titlesub.asm

## Bank 4
bank4.sob: bank4.asm bgmacs.inc gamelist.inc\
$(STDFILES) sprites.asm sprsub.asm kscrdata.asm \
kscreen.asm  hvscroll.asm \
mismap.asm mismapsub.asm rammismap.asm mapanime.asm \
config.asm title.asm

## Bank 5, bank 13
bank5.sob: bank5.asm olsmacs.inc mapmacs.inc istrats.asm \
$(STDFILES) maps\MAPP.asm maps\titlemap.asm maps\mis\exp1.asm \
maps\mis\stg1.asm maps\mis\stg2.asm maps\mis\stg3.asm maps\mis\stg4.asm \
maps\mis\stg5.asm maps\mis\stg6.asm maps\mis\ext1.asm maps\mis\ext2.asm \
maps\mis\ext3.asm maps\mis\ext4.asm maps\mis\sos1.asm maps\mis\sos2.asm \
maps\mis\sos3.asm maps\mis\rdstg1.asm maps\bat\bat1.asm maps\bat\bat2.asm \
maps\bat\bat3.asm maps\mis\tra1.asm \
maps\maplist.asm \
maps\mis\demo0.asm maps\mis\demo1.asm maps\mis\demo2.asm maps\mis\demo3.asm \
maps\mis\demo4.asm maps\mis\demo5.asm maps\mis\demo6.asm maps\mis\demo7.asm \
maps\mis\demo8.asm maps\mis\demo9.asm \
maps\mis\test.asm

## Bank 6
bank6.sob: bank6.asm \
$(STDFILES) $(STRATFILES) players.inc player.asm \
tstrats.asm tplayer.asm kplayer.asm gakki.asm egdata.asm 

## Bank 7
bank7.sob: bank7.asm \
$(STDFILES) $(STRATFILES) players.inc views.asm \
curdat.asm display.asm voffset.asm \
xplayer.asm dstrats.asm kstrats.asm 

## Bank 8
bank8.sob: bank8.asm pathmacs.inc \
$(STDFILES) $(STRATFILES) pathdata.asm dpathdat.asm \
tpathdat.asm paths.asm kpathdat.asm bpathdat.asm ppathdat.asm gpathdat.asm \
paths2.asm slopes.asm mapcode.asm weapons.asm \
chart.asm fonts.asm data\arctan.asm \
result.asm

## Bank 10
bank10.sob: bank10.asm \
$(STDFILES) $(STRATFILES) \
pathkern.asm friends.asm slopedef.asm

## Bank 11
bank11.sob: bank11.asm \
$(STDFILES) $(STRATFILES) mmacs.mc mytest.mc \
mmessage.mc mkawa.mc \
oamlist.asm oamdata.asm \
wipepaus.asm oamface.asm oamplane.asm \
wipedoor.asm wipeconf.asm wipegame.asm wipepsel.asm \
wipemap.asm wipebsel.asm wipebatt.asm wipe.asm wipebeam.asm\
missobj.asm gameover.asm continue.asm gameobj.asm \
wipetitl.asm \
yjdebug.asm hell.asm yjmap.asm pselect.asm \
clear.asm pausemap.asm \
yajima.inc mapexp.asm oamset.asm pselect2.asm titleobj.asm \
bestscore.asm nameset.asm mesdata.asm



## Banks 12, 13, 14, 15, 16, 17
shbanks.sob: shbanks.asm shmacs.inc stratequ.inc \
$(STDFILES) $(STRATFILES) shapes.asm shapes2.asm \
eshapes2.asm eshapes.asm bshapes.asm wshapes.asm \
ushapes.asm pshapes.asm pshapes2.asm 


## Banks 18, 19, 20, 21, 22, 23, 24, 25, 26, 27, 28, 29, 30, 31
incbins.sob: incbins.asm \
$(STDFILES) msprites\spt_01.bin msprites\spt_23.bin msprites\spt_45.bin \
data\a0.pcr data\a0.ccr data\a1.pcr data\a1.ccr \
data\a2.pcr data\a2.ccr data\a3.pcr data\a3.ccr \
data\a4.pcr data\a5.pcr data\a5.ccr data\a6.pcr \
data\a6.ccr data\a7.pcr data\a7.ccr data\a8.ccr \
data\a8.pcr data\a9.ccr data\a9.pcr data\a10.ccr \
data\a10.pcr data\a11.ccr data\a11.pcr data\a12.pcr \
data\a13.ccr data\a13.pcr data\a14.ccr data\a14.pcr \
data\a15.ccr data\a15.pcr data\a16.pcr data\a17.pcr \
data\a18.pcr data\a19.pcr data\a20.pcr data\a21.pcr data\a22.pcr \
data\a23.pcr data\a24.pcr data\a25.pcr \
data\e0.ccr data\e1.ccr data\e2.ccr \
data\e3.ccr data\e4.ccr data\e5.ccr data\e6.ccr data\e7.ccr \
data\w0.ccr data\w1.cgx data\w2.cgx data\b0.ccr \
data\b1.ccr data\b7.ccr data\b8.ccr \
data\b9.ccr data\b14.ccr data\b16.ccr data\b0.pcr \
data\b1.pcr data\b2.pcr data\b3.pcr data\b4.pcr \
data\b5.pcr data\b6.pcr data\b7.pcr data\b8.pcr \
data\b10.pcr data\b11.pcr data\b12.pcr data\b13.pcr \
data\b14.pcr data\b15.pcr data\b16.pcr \
data\allcols.pac data\kawaguti.cgx \
data\moji_2.fon mdata.mc d3_3.asm sprdata.asm

## Banks 26, 27, 28, 29, 30, 31
incbins2.sob: incbins2.asm \
$(STDFILES) sound\fox2snd.bin sound\sdse1.bin sound\sdse2.bin \
sound\ffset1.bin sound\ffset2.bin \
sound\spset1.bin sound\spset2.bin sound\ggset1.bin \
sound\ggset2.bin sound\music01.bin sound\music02.bin sound\music03.bin \
sound\music04.bin sound\music05.bin sound\music06.bin sound\music07.bin \
sound\music08.bin sound\music09.bin sound\music10.bin sound\music11.bin \
sound\music12.bin sound\music13.bin sound\music14.bin sound\music17.bin \
sound\music18.bin sound\music18b.bin \
sound\music20.bin sound\music21.bin sound\music22.bin sound\music23.bin \
sound\music24.bin sound\music25.bin \
sound\sdgrd1.bin sound\sdgrd2.bin sound\sdgrd3.bin \
sound\sdend1.bin sound\sdspac.bin \
sound\sdinf.bin sound\sdcnt.bin sound\sdovr.bin \
sound\sddis.bin sound\sdtlk.bin \
sound\sdst1.bin sound\sdst2.bin \
sound\sdst3.bin sound\sdst4.bin sound\sdst5.bin sound\sdst6.bin \

