On 2010-01-28 14:23+0100 Arjen Markus wrote:

> Hi Alan,
>
> no, I did not - PLplot builds fine., but you may be correct
> about it not being enough - I will look further (no time right
> now, I am afraid)

Hi Arjen:

I decided to have a look at this because like Andrew and you I have several
versions of tcl available (in my case tcl8.3 and tcl8.4 for Debian Lenny).

As root I used 
update-alternatives --config tclsh

to select tclsh8.3.

However, it turns out I cannot even generate the tcl bindings source code
with tclsh8.3! Here is the relevant trailing part of the output of "make
VERBOSE=1".

[ 10%] Generating tclgen.h, tclgen_s.h, tclgen.c
cd "/home/software/plplot svn/HEAD/build_dir/bindings/tcl" && /usr/bin/tclsh 
/home/software/plplot\ svn/HEAD/plplot_cmake_qt/bindings/tcl/pltclgen.tcl 
/home/software/plplot\ svn/HEAD/plplot_cmake_qt/bindings/tcl
syntax error in expression " [string first & $vtype] >= 0 || $vtype eq "char *" 
"
     ("if" test expression)
     while compiling
"if { [string first & $vtype] >= 0 || $vtype eq "char *" } {
                set refargs 1
                set argref($nargs) 1
            }"
     ("if" then script line 18)
     while compiling
"if { [regexp {^(\w+)\s+(.*)$} $line ==> vname vtype] > 0 } {
             set defval ""
             if { $verbose } {
                puts "vname=$vname..."
     ("while" body line 7)
     while compiling
"while { [gets $SPECFILE line] >= 0 } {

         if { $line == "" } {
             break
         }

         if { [regexp {^(\w+)\s+(.*)$} $line ==> vnam..."
     (compiling body of proc "process_pltclcmd", line 20)
     invoked from within
"process_pltclcmd $cmd $rtype"
     ("while" body line 6)
     invoked from within
"while { [gets $SPECFILE line] >= 0 } {
     regsub {#.*$} $line {} line
     if { $line == "" } continue

     if { [regexp {^pltclcmd (\w+) (.*)} $line ..."
     (file "/home/software/plplot 
svn/HEAD/plplot_cmake_qt/bindings/tcl/pltclgen.tcl" line 341)
make[2]: *** [bindings/tcl/tclgen.h] Error 1
make[2]: Leaving directory `/home/software/plplot svn/HEAD/build_dir'
make[1]: *** [bindings/tcl/CMakeFiles/plplottcltkd.dir/all] Error 2
make[1]: Leaving directory `/home/software/plplot svn/HEAD/build_dir'
make: *** [all] Error 2

When I use update-alternatives to select tclsh8.4 the above issue disappears,
everything builds with "make" or "make all", and all tests run successfully
with "make test_noninteractive".

I double-checked with ldd that tclsh8.3 was properly linked to
libtcl8.3.so.1 on my system.

Also, I checked on the command line that

/usr/bin/tclsh8.3 \
/home/software/plplot\ svn/HEAD/plplot_cmake_qt/bindings/tcl/pltclgen.tcl \
/home/software/plplot\ svn/HEAD/plplot_cmake_qt/bindings/tcl

generated the above error messages while

/usr/bin/tclsh8.4 \
/home/software/plplot\ svn/HEAD/plplot_cmake_qt/bindings/tcl/pltclgen.tcl \
/home/software/plplot\ svn/HEAD/plplot_cmake_qt/bindings/tcl

worked fine.  The above issue cannot have anything to do with incompatible
library versions since all it does is process some input to create some
output.  Thus, I think pltclgen.tcl must have some code in it that depends
on the tclsh version being 8.4 or higher.

Arjen, it sounds like you are pretty busy at the moment, but will you put
this issue on your ToDo list for PLplot? If you can confirm this issue in
your pltclgen.tcl script with tclsh8.3, then I think it is important that
you fix it. Geoffrey has made the point a number of times that the so-called
"enterprise" versions of Linux have really old versions of software packages
in them. Thus, I think it is likely that some of our potential Tcl users
will still be using Tcl8.3 and will quietly ignore PLplot because of the
above issue.

Meanwhile, the above issue keeps my from participating in tests about
whether tclsh can have an inconsistent version with the libraries (say
tclsh8.4 versus Tcl8.5 libraries).  I have grepped through our build system
for where tclsh is invoked, and it is almost entirely used to generate stuff
(such as the code for the tcl bindings as above) rather than to run
examples.  Thus, my current guess is for teclsh8.4 (or higher) and some
incompatible Tcl library version, "make test_noninteractive" and "make
"test_interactive" would work fine.

I did find one instance of a test recommended in
examples/tcl/README.tcldemos that uses tclsh.  My guess is incompatible
versions of tclsh and the Tcl libraries would wreak havoc on that particular
test.  However, to check that you will have to run that particular test from
the command line because I haven't yet (although I hope to do so in future)
included it in the test_noninteractive and/or test_interactive targets.

Alan
__________________________
Alan W. Irwin

Astronomical research affiliation with Department of Physics and Astronomy,
University of Victoria (astrowww.phys.uvic.ca).

Programming affiliations with the FreeEOS equation-of-state implementation
for stellar interiors (freeeos.sf.net); PLplot scientific plotting software
package (plplot.org); the libLASi project (unifont.org/lasi); the Loads of
Linux Links project (loll.sf.net); and the Linux Brochure Project
(lbproject.sf.net).
__________________________

Linux-powered Science
__________________________

------------------------------------------------------------------------------
The Planet: dedicated and managed hosting, cloud storage, colocation
Stay online with enterprise data centers and the best network in the business
Choose flexible plans and management services without long-term contracts
Personal 24x7 support from experience hosting pros just a phone call away.
http://p.sf.net/sfu/theplanet-com
_______________________________________________
Plplot-devel mailing list
Plplot-devel@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/plplot-devel

Reply via email to