Optimierungslevel als Konstante rausgezogen, Output-Verzeichnisse bei Compile-Aufrufen ergänzt

This commit is contained in:
Drohne 307 2014-05-31 10:43:37 +02:00
parent 43d016e23e
commit 419055f90c
1 changed files with 29 additions and 26 deletions

53
make.sh
View File

@ -4,6 +4,8 @@
##D="-D __DEBUG -D __LANG_EN" ##D="-D __DEBUG -D __LANG_EN"
##D="-D __LANG_EN" ##D="-D __LANG_EN"
D="-D __LANG_DE" D="-D __LANG_DE"
OPT="-O a"
##OPT=""
# Pfade # Pfade
bin="../Bin" bin="../Bin"
@ -13,6 +15,7 @@ sdsys="${bin}/sdcard/system"
flash="${bin}/flash" flash="${bin}/flash"
libpath="lib" libpath="lib"
BSTC="bstc" BSTC="bstc"
##BSTC="../open-source-spin-compiler-read-only/openspin"
# ---------------------------------------------------------------- # ----------------------------------------------------------------
# Alte Versionen löschen # Alte Versionen löschen
@ -25,47 +28,47 @@ mkdir ${flash}
# Flashdateien erzeugen # Flashdateien erzeugen
# --> bin/flash # --> bin/flash
${BSTC} -L ${libpath} ${D} -D __ADM_FAT -D __ADM_HSS -D __ADM_HSS_PLAY -D __ADM_WAV -D __ADM_RTC -D __ADM_COM -b -O a flash/administra/admflash.spin ${BSTC} -L ${libpath} ${D} -D __ADM_FAT -D __ADM_HSS -D __ADM_HSS_PLAY -D __ADM_WAV -D __ADM_RTC -D __ADM_COM -b ${OPT} -o flash/administra/admflash.binary flash/administra/admflash.spin
cp admflash.binary ${flash} cp flash/administra/admflash.binary ${flash}
mv admflash.binary ${sdsys}/admsys.adm mv flash/administra/admflash.binary ${sdsys}/admsys.adm
${BSTC} -L ${libpath} ${D} -D __VGA -b -O a flash/bellatrix/belflash.spin ${BSTC} -L ${libpath} ${D} -D __VGA -b ${OPT} -o flash/bellatrix/belflash.binary flash/bellatrix/belflash.spin
cp belflash.binary ${flash} cp flash/bellatrix/belflash.binary ${flash}
mv belflash.binary ${sdsys}/vga.bel mv flash/bellatrix/belflash.binary ${sdsys}/vga.bel
${BSTC} -L ${libpath} ${D} -D __TV -b -O a flash/bellatrix/belflash.spin ${BSTC} -L ${libpath} ${D} -D __TV -b ${OPT} -o flash/bellatrix/belflash.binary flash/bellatrix/belflash.spin
mv belflash.binary ${sdsys}/tv.bel mv flash/bellatrix/belflash.binary ${sdsys}/tv.bel
${BSTC} -L ${libpath} ${D} -D regime -b -O a flash/regnatix/regflash.spin ${BSTC} -L ${libpath} ${D} -D regime -b ${OPT} -o flash/regnatix/regflash.binary flash/regnatix/regflash.spin
mv regflash.binary ${flash} mv flash/regnatix/regflash.binary ${flash}
${BSTC} -L ${libpath} ${D} -D forth -b -O a flash/regnatix/regflash.spin ${BSTC} -L ${libpath} ${D} -D forth -b ${OPT} -o flash/regnatix/regflash.binary flash/regnatix/regflash.spin
mv regflash.binary ${flash}/regforth.binary mv flash/regnatix/regflash.binary ${flash}/regforth.binary
# ---------------------------------------------------------------- # ----------------------------------------------------------------
# Startdateie erzeugen # Startdateie erzeugen
# reg.sys (Regime) # reg.sys (Regime)
# --> bin/sdcard\ # --> bin/sdcard\
${BSTC} -L ${libpath} ${D} -b -O a system/regnatix/regime.spin ${BSTC} -L ${libpath} ${D} -b ${OPT} -o system/regnatix/regime.binary system/regnatix/regime.spin
mv regime.binary ${sd}/reg.sys mv system/regnatix/regime.binary ${sd}/reg.sys
# ---------------------------------------------------------------- # ----------------------------------------------------------------
# Slave-Dateien erzeugen # Slave-Dateien erzeugen
# admsid, admay, admnet # admsid, admay, admnet
# htxt, g0key # htxt, g0key
${BSTC} -L ${libpath} ${D} -D __ADM_FAT -D __ADM_SID -b -O a flash/administra/admflash.spin ${BSTC} -L ${libpath} ${D} -D __ADM_FAT -D __ADM_SID -b ${OPT} -o flash/administra/admflash.binary flash/administra/admflash.spin
mv admflash.binary ${sdsys}/admsid.adm mv flash/administra/admflash.binary ${sdsys}/admsid.adm
${BSTC} -L ${libpath} ${D} -D __ADM_FAT -D __ADM_AYS -b -O a flash/administra/admflash.spin ${BSTC} -L ${libpath} ${D} -D __ADM_FAT -D __ADM_AYS -b ${OPT} -o flash/administra/admflash.binary flash/administra/admflash.spin
mv admflash.binary ${sdsys}/admay.adm mv flash/administra/admflash.binary ${sdsys}/admay.adm
${BSTC} -L ${libpath} ${D} -D __ADM_FAT -D __ADM_HSS -D __ADM_LAN -D __ADM_RTC -D __ADM_COM -b -O a flash/administra/admflash.spin ${BSTC} -L ${libpath} ${D} -D __ADM_FAT -D __ADM_HSS -D __ADM_LAN -D __ADM_RTC -D __ADM_COM -b ${OPT} -o flash/administra/admflash.binary flash/administra/admflash.spin
mv admflash.binary ${sdsys}/admnet.adm mv flash/administra/admflash.binary ${sdsys}/admnet.adm
${BSTC} -L ${libpath} ${D} -b -O a system/bellatrix/bel-htext/htext.spin ${BSTC} -L ${libpath} ${D} -b ${OPT} -o system/bellatrix/bel-htext/htext.binary system/bellatrix/bel-htext/htext.spin
mv htext.binary ${sdsys}/htext.bel mv system/bellatrix/bel-htext/htext.binary ${sdsys}/htext.bel
${BSTC} -L ${libpath} ${D} -b -O a system/bellatrix/bel-g0/g0key.spin ${BSTC} -L ${libpath} ${D} -b ${OPT} -o system/bellatrix/bel-g0/g0key.binary system/bellatrix/bel-g0/g0key.spin
mv g0key.binary ${sdsys}/g0key.bel mv system/bellatrix/bel-g0/g0key.binary ${sdsys}/g0key.bel
# ---------------------------------------------------------------- # ----------------------------------------------------------------
# Systemdateien erzeugen # Systemdateien erzeugen
@ -74,7 +77,7 @@ mv g0key.binary ${sdsys}/g0key.bel
# --> bin/sdcard/system/ # --> bin/sdcard/system/
for FILE in system/regnatix/*.spin ; do for FILE in system/regnatix/*.spin ; do
${BSTC} -L ${libpath} ${D} -b -O a ${FILE} ${BSTC} -L ${libpath} ${D} -b ${OPT} ${FILE}
BASE="`basename ${FILE} .spin`" BASE="`basename ${FILE} .spin`"
mv "${BASE}.binary" "${sdsys}/${BASE}.bin" mv "${BASE}.binary" "${sdsys}/${BASE}.bin"
done done