Index: mttroot/mtt/bin/mtt ================================================================== --- mttroot/mtt/bin/mtt +++ mttroot/mtt/bin/mtt @@ -15,10 +15,13 @@ ############################################################### ## Version control history ############################################################### ## $Header$ ## $Log$ +## Revision 1.348 2002/05/20 08:50:12 geraint +## Cleans _sfun_ae.mexglx. +## ## Revision 1.347 2002/05/20 07:12:05 gawthrop ## Trying to get oct files generated with -oct ## ## Revision 1.346 2002/05/17 11:15:38 gawthrop ## Messages about copying when using -dr now only appear in verbose (-v) mode. @@ -1207,10 +1210,20 @@ ## Revision 1.1 1996/08/04 17:29:42 peter ## Initial revision ## ############################################################### +set_oct() { +## Sets ${m} to oct if such a rep is supported + m=m + supported_reps="ae input logic numpar simpar state" + for supported_rep in ${supported_reps}; do + if [ "${rep}" = "${supported_rep}" ]; then + m=oct + fi + done +} #Check $MTTPATH has been set mtt_check_var "$MTTPATH" "MTTPATH" #Version @@ -1408,11 +1421,10 @@ shift;; -oct ) fixcc='-fixcc' mtt_switches="$mtt_switches $1"; using_oct=yes; - m=oct ;; -opt ) mtt_switches="$mtt_switches $1"; optimise='-optimise';; -partition ) mtt_switches="$mtt_switches $1"; partition='-partition'; @@ -1965,22 +1977,26 @@ Subsystem_rdae=$Subsystem"_rdae" Subsystem_dae=$Subsystem"_dae" Subsystem_subs=$Subsystem"_subs" Subsystem_cr=$Subsystem"_cr" Subsystem_cbg=$Subsystem"_cbg" + ## Create the make target name -#if [ -z "${using_oct}" ]; then -# target=${sys}_${rep}.${lang} -#else -# if [ "${lang}" = "m" ]; then -# target=${sys}_${rep}.oct -# else -# target=${sys}_${rep}.${lang} -# fi -#fi -target=${sys}_${rep}.${lang} +if [ -z "${using_oct}" ]; then + target=${sys}_${rep}.${lang} +else + set_oct; + if [ "${lang}" = "m" ]; then + target=${sys}_${rep}.${m} + else + target=${sys}_${rep}.${lang} + fi +fi + +##echo $target +##target=${sys}_${rep}.${lang} ## Arguments ARGS=$4; _ARGS=-$4; __ARGS=`echo $_ARGS | tr ',' '-'` # Save up the argument list in a file; but only if argument has changed