On 2010-05-12 11:22-0500 Geoffrey Furnish wrote:

> Alan W. Irwin writes:
> > Hi Geoffrey:
> >
> > Your recent revision (I am using revision 10991) to make a plstransform
> > wrapper to Tcl builds okay, but actual use of plstransform for example 19
> > does not work for me.  I get
> >
> > Unable to evaluate Tcl-side coordinate transform.
> >
> > repeated 13557 times in examples/x19t_psc.txt, the file that captures stdout
> > for the tcl version of example 19.  That message is apparently coming
> > from Tcl_transform defined in bindings/tcl/tclAPI.c.
> >
> > I am running the development version of Tcl-8.4 (package tcl8.4-dev version
> > 8.4.19-2) for Debian Lenny.  The relevant lines from cmake output
> > are
> >
> > -- TCL_TCLSH = /usr/bin/tclsh
> > -- TCL_INCLUDE_PATH = /usr/include/tcl8.4
> > -- TCL_LIBRARY = /usr/lib/libtcl8.4.so
> >
> > If you try Tcl-8.4 do you get the same error?
>
> BTW, taking a cue from the wiki, I added some options on the cmake line like
> this:
>
> % cmake -DCMAKE_INSTALL_PREFIX=$HOME/devel/8.4/prefix
-DCMAKE_INCLUDE_PATH=$HOME/devel/8.4/prefix/include
-DCMAKE_LIBRARY_PATH=$HOME/devel/8.4/prefix/lib ..

That CMAKE_INCLUDE_PATH is incorrect; you should append /tcl8.4 to it.

> ...
> -- Looking for include paths and libraries for Tcl/Tk
> -- Found Tclsh: /home/furnish/devel/8.4/prefix/bin/tclsh
> -- Found TCL: /usr/lib64/libtcl.so
> -- Found TCLTK: /usr/lib64/libtcl.so
> -- Found TK: /usr/lib64/libtk.so
> -- Looking for include paths and libraries for Tcl/Tk - found
> -- Looking for tclsh
> -- Looking for tclsh - found
> -- TCL_TCLSH = /home/furnish/devel/8.4/prefix/bin/tclsh
> -- TCL_INCLUDE_PATH = /home/furnish/devel/8.4/prefix/include
> -- TCL_LIBRARY = /usr/lib64/libtcl.so
> -- Itcl not available or not compatible with current Tcl shell
> -- TK_INCLUDE_PATH = /home/furnish/devel/8.4/prefix/include;/usr/include
> -- TK_LIBRARY = 
> /usr/lib64/libtk.so;/usr/lib64/libSM.so;/usr/lib64/libICE.so;/usr/lib64/libX11.so;/usr/lib64/libXext.so
>
> But, it still picks up Tcl/Tk libs from /usr/lib64, even though the ones we
> need are right there in the named library dir:
>
> % ls $HOME/devel/8.4/prefix/lib
> libtcl8.4.so     libtk8.4.so     tcl8.4        tk8.4
> libtclstub8.4.a  libtkstub8.4.a  tclConfig.sh  tkConfig.sh

Hmm. I set the _environment variables_ CMAKE_LIBRARY_PATH and
CMAKE_INCLUDE_PATH and that works for me whenever I want to find something
installed in a non-standard path.  For example, right now I have

softw...@raven> printenv |grep CMAKE
CMAKE_LIBRARY_PATH=/home/software/qhull/install/lib:/home/software/libharu/install/lib:/home/software/test_fake_tcltk/install/lib
CMAKE_INCLUDE_PATH=/home/software/qhull/install/include:/home/software/libharu/install/include:/usr/lib/gcc/x86_64-linux-gnu/4.3/include:/home/software/test_fake_tcltk/install/include/tcl8.4

where I have appended /home/software/test_fake_tcltk/install variants of the
library and include paths.  That test directory is set up as follows:

/home/software/test_fake_tcltk/install
/home/software/test_fake_tcltk/install/bin
/home/software/test_fake_tcltk/install/bin/tclsh
/home/software/test_fake_tcltk/install/lib
/home/software/test_fake_tcltk/install/lib/libitk3.2.so
/home/software/test_fake_tcltk/install/lib/libtk8.4.so
/home/software/test_fake_tcltk/install/lib/libtcl8.4.so
/home/software/test_fake_tcltk/install/lib/libitcl3.2.so
/home/software/test_fake_tcltk/install/include
/home/software/test_fake_tcltk/install/include/tcl8.4
/home/software/test_fake_tcltk/install/include/tcl8.4/itclDecls.h
/home/software/test_fake_tcltk/install/include/tcl8.4/tcl.h
[...]

where everything in bin and lib is a symlink to the system version and
everything in tcl8.4 was generated by "cp -a" from the system version.
I also made sure /home/software/test_fake_tcltk/install/bin/tclsh was
the first version on my PATH.

Here is the relevant cmake output for this test setup:

-- Looking for include paths and libraries for Tcl/Tk
-- Found Tclsh: /home/software/test_fake_tcltk/install/bin/tclsh
-- Found TCL: /home/software/test_fake_tcltk/install/lib/libtcl8.4.so
-- Found TCLTK: /home/software/test_fake_tcltk/install/lib/libtcl8.4.so
-- Found TK: /home/software/test_fake_tcltk/install/lib/libtk8.4.so
-- Looking for include paths and libraries for Tcl/Tk - found
-- Looking for tclsh
-- Looking for tclsh - found
-- TCL_TCLSH = /home/software/test_fake_tcltk/install/bin/tclsh
-- TCL_INCLUDE_PATH = /home/software/test_fake_tcltk/install/include/tcl8.4
-- TCL_LIBRARY = /home/software/test_fake_tcltk/install/lib/libtcl8.4.so
-- Looking for itcl.h
-- Looking for itcl.h - found
-- Looking for itcl library
-- Looking for itcl library - found
-- ITCL_INCLUDE_PATH = /home/software/test_fake_tcltk/install/include/tcl8.4
-- ITCL_LIBRARY = /home/software/test_fake_tcltk/install/lib/libitcl3.2.so
-- TK_INCLUDE_PATH =
/home/software/test_fake_tcltk/install/include/tcl8.4;/usr/include
-- TK_LIBRARY =
/home/software/test_fake_tcltk/install/lib/libtk8.4.so;/usr/lib/libSM.so;/usr/lib/libICE.so;/usr/lib/libX11.so;/usr/lib/libXext.so
-- Looking for itk.h
-- Looking for itk.h - found
-- Looking for itk library
-- Looking for itk library - found
-- ITK_INCLUDE_PATH = /home/software/test_fake_tcltk/install/include/tcl8.4
-- ITK_LIBRARY = /home/software/test_fake_tcltk/install/lib/libitk3.2.so

So cmake finds the special /home/software/test_fake_tcltk/install location
with ease.  The documentation also says that the cmake options
CMAKE_LIBRARY_PATH and CMAKE_INCLUDE_PATH (which you have used) play the
same role as the CMAKE_LIBRARY_PATH and CMAKE_INCLUDE_PATH environment
variables so once you make the syntax correction I suggested above, and if
your special version of the Tcl and Tk libraries are in the same relative
paths as in /home/software/test_fake_tcltk/install above, then I believe
everything should work for you.  But if it doesn't, please try the
environment variable approach because I _know_ from the above experiment
that it should work.

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
__________________________

------------------------------------------------------------------------------

_______________________________________________
Plplot-devel mailing list
Plplot-devel@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/plplot-devel

Reply via email to