cd %2
\Utils\Wladx\wla-65816.exe -i -D BuildSNS -o \BldSNS\cart.o %1 
if not "%errorlevel%"=="0" goto Abandon
\Utils\Wladx\wlalink -i -b \BldSNS\cart.txt \RelSNS\cart.sfc
if not "%errorlevel%"=="0" goto Abandon
@echo off

rem \Utils\64tass\64tass.exe %1 --long-address -x -o \BldSNS\cart.bld --list \BldSNS\Listing.txt


rem \Utils\Asw\bin\asw %1 -CPU 65816  -L -olist \BldSNS\Listing.txt  -D BuildSNS -o \BldSNS\cart.bld
rem \Utils\Asw\bin\p2bin \BldSNS\cart.bld \RelSNS\cart.sfc

rem \Utils\Vasm\vasm6502_oldstyle_win32.exe %1 -c02 -chklabels -nocase -Dvasm=1  -L \BldAP2\Listing.txt -DBuildVTX=1 -Fbin -o "\BldVTX\Prog.bin"



rem \Emu\Snes9x\snes9x.exe \RelSNS\cart.sfc
\Emu\mesen-s\Mesen-S.exe \RelSNS\cart.sfc


:Abandon
if "%3"=="nopause" exit
pause
