#!/bin/bash

# Build tools
echo "BLD/PLASM";    atftp --option "disable windowsize" $1 --put -l rel/PLASM#FE1000   -r $2/BLD/PLASM#FE1000
echo "BLD/CODEOPT";  atftp --option "disable windowsize" $1 --put -l rel/CODEOPT#FE1000 -r $2/BLD/CODEOPT#FE1000

#Build incs
echo "BLD/INC/ARGS.PLH";     atftp --option "disable windowsize" $1 --put -l inc/args.plh    -r $2/BLD/INC/ARGS.PLH#040000
echo "BLD/INC/MATCHFILES.PLH"; atftp --option "disable windowsize" $1 --put -l inc/matchfiles.plh -r $2/BLD/INC/MATCHFILES.PLH#040000
echo "BLD/INC/CMDSYS.PLH";   atftp --option "disable windowsize" $1 --put -l inc/cmdsys.plh  -r $2/BLD/INC/CMDSYS.PLH#040000
echo "BLD/INC/CONIO.PLH";    atftp --option "disable windowsize" $1 --put -l inc/conio.plh   -r $2/BLD/INC/CONIO.PLH#040000
echo "BLD/INC/LINES.PLH";    atftp --option "disable windowsize" $1 --put -l inc/lines.plh -r $2/BLD/INC/LINES.PLH#040000
echo "BLD/INC/HGRTILE.PLH";  atftp --option "disable windowsize" $1 --put -l inc/hgrtile.plh -r $2/BLD/INC/HGRTILE.PLH#040000
echo "BLD/INC/HGRFONT.PLH";  atftp --option "disable windowsize" $1 --put -l inc/hgrfont.plh -r $2/BLD/INC/HGRFONT.PLH#040000
echo "BLD/INC/HGRSPRITE.PLH";atftp --option "disable windowsize" $1 --put -l inc/hgrsprite.plh -r $2/BLD/INC/HGRSPRITE.PLH#040000
echo "BLD/INC/HGRLIB.PLH";   atftp --option "disable windowsize" $1 --put -l inc/hgrlib.plh   -r $2/BLD/INC/HGRLIB.PLH#040000
echo "BLD/INC/GRLIB.PLH";    atftp --option "disable windowsize" $1 --put -l inc/grlib.plh   -r $2/BLD/INC/GRLIB.PLH#040000
echo "BLD/INC/DGRLIB.PLH";   atftp --option "disable windowsize" $1 --put -l inc/dgrlib.plh  -r $2/BLD/INC/DGRLIB.PLH#040000
echo "BLD/INC/FIBER.PLH";    atftp --option "disable windowsize" $1 --put -l inc/fiber.plh   -r $2/BLD/INC/FIBER.PLH#040000
echo "BLD/INC/FILEIO.PLH";   atftp --option "disable windowsize" $1 --put -l inc/fileio.plh  -r $2/BLD/INC/FILEIO.PLH#040000
echo "BLD/INC/INT32.PLH";    atftp --option "disable windowsize" $1 --put -l inc/int32.plh   -r $2/BLD/INC/INT32.PLH#040000
echo "BLD/INC/FPSTR.PLH";    atftp --option "disable windowsize" $1 --put -l inc/fpstr.plh   -r $2/BLD/INC/FPSTR.PLH#040000
echo "BLD/INC/FPU.PLH";      atftp --option "disable windowsize" $1 --put -l inc/fpu.plh     -r $2/BLD/INC/FPU.PLH#040000
echo "BLD/INC/GRAFIX.PLH";   atftp --option "disable windowsize" $1 --put -l inc/grafix.plh  -r $2/BLD/INC/GRAFIX.PLH#040000
echo "BLD/INC/JOYBUZZ.PLH";  atftp --option "disable windowsize" $1 --put -l inc/joybuzz.plh -r $2/BLD/INC/JOYBUZZ.PLH#040000
echo "BLD/INC/INET.PLH";     atftp --option "disable windowsize" $1 --put -l inc/inet.plh    -r $2/BLD/INC/INET.PLH#040000
echo "BLD/INC/LONGJUMP.PLH"; atftp --option "disable windowsize" $1 --put -l inc/longjmp.plh -r $2/BLD/INC/LONGJUMP.PLH#040000
echo "BLD/INC/LZ4.PLH";      atftp --option "disable windowsize" $1 --put -l inc/lz4.plh     -r $2/BLD/INC/LZ4.PLH#040000
echo "BLD/INC/MEMMGR.PLH";   atftp --option "disable windowsize" $1 --put -l inc/memmgr.plh  -r $2/BLD/INC/MEMMGR.PLH#040000
echo "BLD/INC/MOUSE.PLH";    atftp --option "disable windowsize" $1 --put -l inc/mouse.plh   -r $2/BLD/INC/MOUSE.PLH#040000
echo "BLD/INC/PORTIO.PLH";   atftp --option "disable windowsize" $1 --put -l inc/portio.plh  -r $2/BLD/INC/PORTIO.PLH#040000
echo "BLD/INC/SANE.PLH";     atftp --option "disable windowsize" $1 --put -l inc/sane.plh    -r $2/BLD/INC/SANE.PLH#040000
echo "BLD/INC/SDFAT.PLH";    atftp --option "disable windowsize" $1 --put -l inc/sdfat.plh   -r $2/BLD/INC/SDFAT.PLH#040000
echo "BLD/INC/SNDSEQ.PLH";   atftp --option "disable windowsize" $1 --put -l inc/sndseq.plh  -r $2/BLD/INC/SNDSEQ.PLH#040000
echo "BLD/INC/SPIPORT.PLH";  atftp --option "disable windowsize" $1 --put -l inc/spiport.plh -r $2/BLD/INC/SPIPORT.PLH#040000
echo "BLD/INC/TESTLIB.PLH";  atftp --option "disable windowsize" $1 --put -l inc/testlib.plh -r $2/BLD/INC/TESTLIB.PLH#040000

# Sample sources
echo "BLD/SAMPLES/HELLO.PLA";     atftp --option "disable windowsize" $1 --put -l samplesrc/hello.pla     -r $2/BLD/SAMPLES/HELLO.PLA#040000
echo "BLD/SAMPLES/TESTLIB.PLA";   atftp --option "disable windowsize" $1 --put -l samplesrc/testlib.pla   -r $2/BLD/SAMPLES/TESTLIB.PLA#040000
echo "BLD/SAMPLES/TEST.PLA";      atftp --option "disable windowsize" $1 --put -l samplesrc/test.pla      -r $2/BLD/SAMPLES/TEST.PLA#040000
echo "BLD/SAMPLES/MOUSETEST.PLA"; atftp --option "disable windowsize" $1 --put -l samplesrc/mousetest.pla -r $2/BLD/SAMPLES/MOUSETEST.PLA#040000
echo "BLD/SAMPLES/FIBERTEST.PLA"; atftp --option "disable windowsize" $1 --put -l samplesrc/fibertest.pla -r $2/BLD/SAMPLES/FIBERTEST.PLA#040000
echo "BLD/SAMPLES/ROD.PLA";       atftp --option "disable windowsize" $1 --put -l samplesrc/rod.pla       -r $2/BLD/SAMPLES/ROD.PLA#040000
echo "BLD/SAMPLES/INT32TEST.PLA"; atftp --option "disable windowsize" $1 --put -l samplesrc/int32test.pla -r $2/BLD/SAMPLES/INT32TEST.PLA#040000
echo "BLD/SAMPLES/HGRTEST.PLA";   atftp --option "disable windowsize" $1 --put -l samplesrc/hgrtest.pla    -r $2/BLD/SAMPLES/HGRTEST.PLA#040000
echo "BLD/SAMPLES/GRTEST.PLA";    atftp --option "disable windowsize" $1 --put -l samplesrc/grtest.pla    -r $2/BLD/SAMPLES/GRTEST.PLA#040000
echo "BLD/SAMPLES/DGRTEST.PLA";   atftp --option "disable windowsize" $1 --put -l samplesrc/dgrtest.pla   -r $2/BLD/SAMPLES/DGRTEST.PLA#040000
echo "BLD/SAMPLES/TILETEST.PLA";  atftp --option "disable windowsize" $1 --put -l samplesrc/tiletest.pla   -r $2/BLD/SAMPLES/TILETEST.PLA#040000
echo "BLD/SAMPLES/HGRTEST.PLA";   atftp --option "disable windowsize" $1 --put -l samplesrc/hgrtest.pla   -r $2/BLD/SAMPLES/HGRTEST.PLA#040000
echo "BLD/SAMPLES/PLAYSEQ.PLA";   atftp --option "disable windowsize" $1 --put -l samplesrc/playseq.pla   -r $2/BLD/SAMPLES/PLAYSEQ.PLA#040000
echo "BLD/SAMPLES/RPNCALC.PLA";   atftp --option "disable windowsize" $1 --put -l samplesrc/rpncalc.pla   -r $2/BLD/SAMPLES/RPNCALC.PLA#040000
echo "BLD/SAMPLES/SIEVE.PLA";     atftp --option "disable windowsize" $1 --put -l samplesrc/sieve.pla     -r $2/BLD/SAMPLES/SIEVE.PLA#040000
echo "BLD/SAMPLES/MEMTEST.PLA";   atftp --option "disable windowsize" $1 --put -l samplesrc/memtest.pla   -r $2/BLD/SAMPLES/MEMTEST.PLA#040000
echo "BLD/SAMPLES/FATCAT.PLA";    atftp --option "disable windowsize" $1 --put -l samplesrc/fatcat.pla    -r $2/BLD/SAMPLES/FATCAT.PLA#040000
echo "BLD/SAMPLES/GFXDEMO.PLA";   atftp --option "disable windowsize" $1 --put -l samplesrc/gfxdemo.pla   -r $2/BLD/SAMPLES/GFXDEMO.PLA#040000
echo "BLD/SAMPLES/LZ4CAT.PLA";    atftp --option "disable windowsize" $1 --put -l samplesrc/lz4cat.pla    -r $2/BLD/SAMPLES/LZ4CAT.PLA#040000
echo "BLD/SAMPLES/SFM.PLA";       atftp --option "disable windowsize" $1 --put -l samplesrc/sfm.pla       -r $2/BLD/SAMPLES/SFM.PLA#040000
echo "BLD/SAMPLES/SFMSPRT.PLA";   atftp --option "disable windowsize" $1 --put -l samplesrc/sfmsprt.pla   -r $2/BLD/SAMPLES/SFMSPRT.PLA#040000
echo "BLD/SAMPLES/FPPOW.PLA";     atftp --option "disable windowsize" $1 --put -l samplesrc/fppow.pla     -r $2/BLD/SAMPLES/FPPOW.PLA#040000
echo "BLD/SAMPLES/MON.PLA";       atftp --option "disable windowsize" $1 --put -l utilsrc/apple/mon.pla   -r $2/BLD/SAMPLES/MON.PLA#040000