Or if you're already using tclconfig/tcl.m4 (part of TEA) and have already run TEA_LOAD_TCLCONFIG in your m4 script then you can just substitute these two variables:
echo $TCL_VERSION$TCL_PATCH_LEVEL 8.5.9 On Wed, Sep 7, 2011 at 11:29 AM, Ronnie Brunner <ronnie.brun...@netcetera.ch > wrote: > > > > admittedly I'm not a great shell programmer. I'm trying to figure out a > > way to determine in a m4 macro which patchlevel of Tcl we are compiling > > Rivet with by letting tclsh return in a shell variable the output of > > [info patchlevel]. We have other examples of Tcl-m4 cooperation but data > > go into files, I would like to get the same information into a shell > > variable, is there a way to do it? > > something like that? > > > /bin/sh > $ FOO=`echo puts [info patchlevel] | tclsh` > $ echo $FOO > 8.5.10 > $ > > hth > Ronnie > -- > Ronnie Brunner | ronnie.brun...@netcetera.ch | > T +41-44-247 79 79 | F +41-44-247 70 75 | > Netcetera AG | 8040 Zürich | Switzerland | http://netcetera.com > > --------------------------------------------------------------------- > To unsubscribe, e-mail: rivet-dev-unsubscr...@tcl.apache.org > For additional commands, e-mail: rivet-dev-h...@tcl.apache.org > >