* Usage - COMPILE <SRC> <EXE>

* This script compiles all the files on SRC disk (default is A)
* and copies the resultant modules to the EXE disk (default B)

&SRC = A
&EXE = B


&IF &INDEX EQ 0 &GOTO -FINARGS
&SRC = &1
&ARGS &2 &3 &4 &5 &6 &7 &8 &9

&IF &INDEX EQ 0 &GOTO -FINARGS
&EXE = &1

-FINARGS


EXEC GCCE BWBASIC C &SRC (PARM STDBWB
EXEC GCCE BWB_INT C &SRC (PARM STDBWB
EXEC GCCE BWB_TBL C &SRC (PARM STDBWB
EXEC GCCE BWB_CMD C &SRC (PARM STDBWB
EXEC GCCE BWB_PRN C &SRC (PARM STDBWB
EXEC GCCE BWB_EXP C &SRC (PARM STDBWB
EXEC GCCE BWB_VAR C &SRC (PARM STDBWB
EXEC GCCE BWB_INP C &SRC (PARM STDBWB
EXEC GCCE BWB_FNC C &SRC (PARM STDBWB
EXEC GCCE BWB_CND C &SRC (PARM STDBWB
EXEC GCCE BWB_DIO C &SRC (PARM STDBWB
EXEC GCCE BWB_STR C &SRC (PARM STDBWB
EXEC GCCE BWB_STC C &SRC (PARM STDBWB
EXEC GCCE BWX_TTY C &SRC (PARM STDBWB
EXEC GCCE BWD_CMD C &SRC (PARM STDBWB
EXEC GCCE BWD_FUN C &SRC (PARM STDBWB
EXEC GCCE UNIXIO C &SRC (PARM STDBWB


&STACK HT
LOAD BWBASIC (NOAUTO
INCLUDE BWB_INT (NOAUTO
INCLUDE BWB_TBL (NOAUTO
INCLUDE BWB_CMD (NOAUTO
INCLUDE BWB_PRN (NOAUTO
INCLUDE BWB_EXP (NOAUTO
INCLUDE BWB_VAR (NOAUTO
INCLUDE BWB_INP (NOAUTO
INCLUDE BWB_FNC (NOAUTO
INCLUDE BWB_CND (NOAUTO
INCLUDE BWB_DIO (NOAUTO
INCLUDE BWB_STR (NOAUTO
INCLUDE BWB_STC (NOAUTO
INCLUDE BWX_TTY (NOAUTO
INCLUDE BWD_CMD (NOAUTO
INCLUDE BWD_FUN (NOAUTO
&STACK RT
INCLUDE UNIXIO (NOAUTO

GENMOD BWBASIC
COPY BWBASIC MODULE &SRC = = &EXE (REPLACE
COPY PROFILE BAS &SRC = = &EXE (REPLACE


* Quick test of bwbasic
BWBASIC "EXAMPLE BAS"
