On 2009-04-24 21:40-0500 Geoffrey Furnish wrote:

> Andrew Ross writes:
> > On Fri, Apr 24, 2009 at 02:54:43PM -0500, Geoffrey Furnish wrote:
> > > Werner Smekal writes:
> > >  > I usually debug in the build tree. Add the "-DBUILD_TEST=ON" to the
> > >  > cmake options and all examples will be compiled in the built tree.
> > >
> > > Well, I must be missing something.  When I add this, I don't find the tk
> > > examples in the build tree.  There is an examples/tk directory, which
> > > has mostly Tcl stuff within.  The xtk01, and other Tk examples are not
> > > present, and thus not compiled in the build tree.  They did show up in
> > > the install tree when I did a make install.
> > >
> > > Is there a way to get the Tk examples/demos built in the build tree?
> >
> > I think that because the xtk?? examples are not part of the test suite
> > they were not included in the list of examples built when BUILD_TEST=ON is
> > set.  It can be done, but will require some cmake changes.
>
> Let me try to explain this part of my frustration.
>
> Some time ago, Alan told me I could exhibit the Tk segfault by going into the
> installed examples and running make test_interactive.
>
> That does "work", in the sense that it does allow me, after roughly 80
> clicks/returns, to see the fabled Tk segfault.


"make test_interactive" is essentially equivalent to building all examples
(including those in tk) and then running plplot-test-interactive.sh.  That
latter shell script is a good way to run a large number of interactive
tests, but once you have found a bug (such as the Tk segfaults) that way,
then you should look at plplot-test-interactive.sh to see how to run the
individual test that shows the bug.  That appears to be exactly what you did
below.

Alternatively, some more infrastructure should be put in
plplot-test-interactive.sh to single out, say, all the Tk tests.  Feel free
to make such a change to that script if you want.

>
> But the build flags (debug in this case) don't seem to carry over to the post
> install tests.

They certainly do for the libraries and executables like plserver if you
follow my environment variable suggestion.  However, in the above case
probably xtk?? will not be built with -g.  But that is easily fixed by
make clean in the tk directory, then modifying the build there to
put in -g (as apparently you have done below).

>
> Werner suggested -DBUILD_TEST=ON, and test in the build tree.  But the build
> tree doesn't actually contain the examples in question, though it has plenty
> of others.
>
> Frankly it does not make sense to me that you should have to install in order
> to be able to test.

I agree, but this is open-source software put together by a bunch of
volunteers including you.  Generally, each of us does what seems important
to us.  The fundamental problem here is Tk has not had any active developer
interested in it for a long time. Now that you are back in action, there is
a lot of minor fixup work to do on Tk such as learning how to build the Tk
examples in the build tree (and learning how to run them as well which is
quite complicated since libraries and key Tcl files are scattered all over
the build tree), making the install-tree experience smoother, etc.

So you will have to set priorities and decide what is the most important
problem you want to tackle first.  Do you want to implement a perfect
install-tree experience for Tk?  Do you want to implement a perfect
build-tree experience for Tk? Do you want to deal with the Tk segfault
before perfection of the other goals?  It is up to you.  What I am really
saying is that as one of the PLplot volunteers, you really shouldn't
complain about Tk, because you are the Tk-motivated guy that I am depending
on to fix it up, and I hate to see you beat yourself up.  :-)

Seriously, I think everybody here will be happy to help you get back up
to speed again with whatever you decide is your top priority.

> configure (cmake) a debug build  (lots of missteps there)
> figure out how to request verbosity
> make && make install  (to get debug libs)
> cd to install tree
> do another make, so I could see the build steps.
> Do the build of xtk01 again manually, adding in the missing options.

Your instincts are right on.  That is the only way right now to exercise the
Tk examples in a simple way, and I agree that path is rougher than it could
be.  So the question is whether you decide to work on smoothing that path
first or on the segfaults first or anything else you desire to do for PLplot.

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
__________________________

------------------------------------------------------------------------------
Crystal Reports - New Free Runtime and 30 Day Trial
Check out the new simplified licensign option that enables unlimited
royalty-free distribution of the report engine for externally facing 
server and web deployment.
http://p.sf.net/sfu/businessobjects
_______________________________________________
Plplot-devel mailing list
Plplot-devel@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/plplot-devel

Reply via email to