1234567891011121314151617181920212223242526272829303132333435363738394041424344454647484950515253545556575859606162636465666768697071727374757677787980818283848586878889 |
- #! /bin/sh
- ######################################
- ##### Model Transformation Tools #####
- ######################################
- # Bourne shell script: mtt_versions
- # P.J.Gawthrop May 1998
- # Copyright (c) P.J.Gawthrop 1998
- ###############################################################
- ## Version control history
- ###############################################################
- ## $Id$
- ## $Log$
- ## Revision 1.6 2005/02/17 22:15:35 geraint
- ## Added missing quotes to conditional expression.
- ##
- ## Revision 1.5 2005/02/17 18:36:38 geraint
- ## Removed a bash-ism: replaced [[ conditional ]] with [ conditional ]
- ##
- ## Revision 1.4 2003/08/06 22:39:40 geraint
- ## Fixed reporting of non-existent software, no longer says "is OK and has version .".
- ##
- ## Revision 1.3 2002/04/28 18:41:26 geraint
- ## Fixed [ 549658 ] awk should be gawk.
- ## Replaced calls to awk with call to gawk.
- ##
- ## Revision 1.2 2000/11/13 21:40:26 peterg
- ## Sorted out the non-gnu
- ##
- ## Revision 1.1 1998/05/28 09:24:41 peterg
- ## Initial revision
- ##
- ###############################################################
- echo Versions of mtt and its components on `date`
- ## gnu standard --version
- mtt_version mtt
- echo Doing the GNU components
- mtt_version gawk
- mtt_version basename
- mtt_version cat
- mtt_version cp
- mtt_version dirname
- mtt_version gcc
- mtt_version grep
- mtt_version head
- mtt_version make
- mtt_version octave
- mtt_version sed
- mtt_version tail
- mtt_version tr
- ## Non standards
- echo Doing the non-GNU components
- print_version ()
- {
- program=${1:-"Error: unknown program"}
- shift;
- version=$*
- if [ "${version:-""}" ]; then
- echo is OK and has version $version.
- else
- echo $program does not exist.
- fi
- }
- echo Trying xfig ...
- xfig -help 2> mtt_junk; version=`grep Xfig mtt_junk`
- print_version xfig $version
- echo Trying fig2dev ...
- fig2dev -h > mtt_junk; version=`grep -i patchlevel mtt_junk`
- print_version fig2dev $version
- echo Trying reduce ...
- reduce -w >mtt_junk 2>1 <<EOF
- bye;
- EOF
- version=`grep -i REDUCE mtt_junk`
- print_version reduce $version
|