Gentoo Websites Logo
Go to: Gentoo Home Documentation Forums Lists Bugs Planet Store Wiki Get Gentoo!
Bug 204524 - sci-libs/plplot-5.9.0 version bump request
Summary: sci-libs/plplot-5.9.0 version bump request
Status: RESOLVED FIXED
Alias: None
Product: Gentoo Linux
Classification: Unclassified
Component: New packages (show other bugs)
Hardware: All Linux
: High normal (vote)
Assignee: Gentoo Science Related Packages
URL: http://plplot.sourceforge.net/index.html
Whiteboard:
Keywords:
: 212681 (view as bug list)
Depends on:
Blocks: tcltk-8.5
  Show dependency tree
 
Reported: 2008-01-06 09:15 UTC by George Shapovalov (RETIRED)
Modified: 2008-10-21 11:51 UTC (History)
5 users (show)

See Also:
Package list:
Runtime testing required: ---


Attachments
zeroth order ebuild for plplot-5.9.0 (plplot-5.9.0.ebuild,1.57 KB, text/plain)
2008-03-26 00:25 UTC, Markus Dittrich (RETIRED)
Details
ebuild for version 5.8.0 (upstream stable) (plplot-5.8.0-r4.ebuild,2.75 KB, text/plain)
2008-03-26 10:33 UTC, Joshua Rich
Details
patch to find and set-up correct compiling/linking with freetype on Gentoo (plplot-5.8.0-findfreetype.patch,3.39 KB, patch)
2008-03-26 10:34 UTC, Joshua Rich
Details | Diff

Note You need to log in before you can comment on or make changes to this bug.
Description George Shapovalov (RETIRED) gentoo-dev 2008-01-06 09:15:31 UTC
Has more drivers and bindings at least. Also, transitioned to CMake. Autotools are still provided but are deprecated and a quick bump did not work, so, likely, adjusting ebuild to use CMake is necessary.
I'll try to do this some time soon (btw, it has Ada bindings, thus CC ada@g.o), but anybody is surely wellcome to do this as well.

George
Comment 1 Jakub Moc (RETIRED) gentoo-dev 2008-03-08 09:08:49 UTC
*** Bug 212681 has been marked as a duplicate of this bug. ***
Comment 2 Markus Dittrich (RETIRED) gentoo-dev 2008-03-26 00:25:14 UTC
Created attachment 147324 [details]
zeroth order ebuild for plplot-5.9.0

Please note that this ebuild needs quite a bit more work.
That said, it does compile for me with most useflags.

Things that are currently non-functional include

1) octave bindings do not work for octave-3.* (need
   to look at included debian patches)
2) freetype stuff doesn't compile
3) ditto for wxWindows/wxGTK 

Please give it a spin and report additional problems.
Patches to fix issues (such as the above) are of
course also welcome.

cheers,
Markus
Comment 3 Joshua Rich 2008-03-26 10:32:12 UTC
Damn, I'm one day too late!  I had been sitting on my own plplot
ebuild for version 5.8.0 (the version marked stable upstream) for a
while, and I've been gradually getting more and more drivers and
features working in it. I might as well just post it now in the hopes
it will be useful to the other people working on 5.9.0.  I've also
tried to document what I've done, what works, and what doesn't, so
excuse the long post.  At least I now have a functional plplot-5.8.0
ebuild that compiles most drivers and works pretty well.  Read on for
gory details.

It has the following USE flags:

"X agg cxx fortran gnome ifc itcl itk octave pango
pdf python qhull svg tetex tcl tk threads truetype java
wxwindows"

I had the following USE flags set when building:

"X cxx fortran gnome java pango pdf python svg threads truetype
wxwindows"

The following list contains the drivers that I managed to build:

 < 1> xwin       X-Window (Xlib)
 < 2> gcw        Gnome Canvas Widget
 < 3> ps         PostScript File (monochrome)
 < 4> psc        PostScript File (color)
 < 5> xfig       Fig file
 < 6> hp7470     HP 7470 Plotter File (HPGL Cartridge, Small Plotter)
 < 7> hp7580     HP 7580 Plotter File (Large Plotter)
 < 8> lj_hpgl    HP Laserjet III, HPGL emulation mode
 < 9> pbm        PDB (PPM) Driver
 <10> png        PNG file
 <11> jpeg       JPEG file
 <12> null       Null device
 <13> mem        User-supplied memory device
 <14> gif        GIF file
 <15> wxwidgets  wxWidgets DC
 <16> psttf      PostScript File (monochrome)
 <17> psttfc     PostScript File (color)
 <18> svg        Scalable Vector Graphics (SVG 1.1)
 <19> xcairo     Cairo X Windows Driver
 <20> pdfcairo   Cairo PDF Driver
 <21> pscairo    Cairo PS Driver
 <22> pngcairo   Cairo PNG Driver

Most of my testing has been through the Perl interface
(PDL::Graphics::PLplot), but I have built the example programs for C,
C++, Java, Fortran 77/95 and Python installed in
/usr/share/plplot5.8.0/examples by the ebuild, and these work. The C++
bindings also allow some limited testing of the wxwidgets bindings,
and these also seem to work.  The plplot canvas widget is also built
and works.  The gcw driver segfaults for me when trying to save a
hard-copy, but viewing the plots works fine.  Tcl/Tk drivers have not
been tested, nor the octave driver.  Also not tested: using the agg
and qhull libraries.  These were next on my plplot agenda.  

Note: more thorough testing by knowledgeable people needed!
Particularly people who would use plplot through langauges other than
Perl! Maybe add testing functionality to the ebuild?

So most, if not all of the dependencies were taken from the ebuild for
the previous version, so the list may need to be checked and updated
where appropriate.  I've tried to do this from reading various READMEs
located in the source and from the output of cmake and my compilation
attempts, but it should most definitely be checked.  Indeed, I think
some dependencies are sub-dependencies of others while others are
conditional dependencies - basically it appears to be quite a mess so
guidance would be greatly appreciated.  

I've got an ebuild for the LASi library, which allows one to build
drivers that render postscript with truetype fonts.  This also
requires pango.  Default postscript drivers are built regardless (and
cairo ps/pdf drivers are built if you have cairo installed).  I will
attach the LASi ebuild to a separate bug and link to it from here.

I had to write a dirty dirty patch to get plplot to find, build
and link against freetype.  Most of the inspiration and success comes
from a random Google search that turned up a FindFreeType.cmake module
file which is part of the FlowVR project, which instead of searching
for freetype header files just used the output of the command
freetype-config.  The other parts of the patch are my dirty hacks
being a complete novice with cmake to glue it all back together.

I'm unsure about the handling of various supported fortran compilers.
Not being a fortran user this part of the ebuild could do with some
love from a person knowledgeable in that.

So in summary: plplot 5.8.0 works, compiles and some core bindings
work.  Hopefully it will work for other people. Ebuild needs lots of
work in sorting dependencies, consolidating patches and driver
testing.

Use at your own risk ;)

Happy plotting,

Joshua Rich
Comment 4 Joshua Rich 2008-03-26 10:33:41 UTC
Created attachment 147365 [details]
ebuild for version 5.8.0 (upstream stable)

Ebuild for version 5.8.0, hopefully will be of use for getting 5.9.0 working.
Comment 5 Joshua Rich 2008-03-26 10:34:18 UTC
Created attachment 147366 [details, diff]
patch to find and set-up correct compiling/linking with freetype on Gentoo
Comment 6 Joshua Rich 2008-03-26 10:44:47 UTC
See bug #214846 for the ebuild for the LASi library required for the ebuild  of plplot 5.8.0 attached to this bug.
Comment 7 Markus Dittrich (RETIRED) gentoo-dev 2008-03-26 12:52:11 UTC
Hi Joshua,

Thanks a lot and it looks like our two attempts
look pretty similar overall ;) I'll merge
the best of both into a new revision for 5.9.0
and we can then go from there. Do you think
there's any point in keeping the png/jpeg useflags?
AFAICT there's no switch any more to turn these 
on or off.

cheers,
Markus 
Comment 8 Joshua Rich 2008-03-26 22:35:21 UTC
(In reply to comment #7)
> Hi Joshua,
> 
> Thanks a lot and it looks like our two attempts
> look pretty similar overall ;) I'll merge
> the best of both into a new revision for 5.9.0
> and we can then go from there. Do you think
> there's any point in keeping the png/jpeg useflags?
> AFAICT there's no switch any more to turn these 
> on or off.
> 
> cheers,
> Markus 
> 

Hi Markus,

Sounds great. The png/jpeg USE flags were copied over from the older
plplot ebuild. You are right though, there is no switches to
enable/disable this support. Maybe they can be merged to the 'gd' USE
flag, so that people who don't want jpeg/png output can still disable
this support? See the FindGD.cmake and gd.cmake files in the
cmake/modules directory of the source, it looks like the configure
step will do the right thing if gd isn't found. I'll leave it up to
you though.

Let me know if you need some informal testing done. I can at least
test the Perl bindings, as well as compile and run the example
programs as before.

Another thing, I think in order to get the wxwidgets bindings/driver
to build I had to run the eselect module for wxwidgets.  I have wxGTK
2.6.4.0-r3 and 2.8.7.1-r1 installed, and selected
gtk2-unicode-release-2.8 through the eselect module.  I don't know
whether this is required, but I think the compilation failed unless I
did this.  

Thanks and regards,

Joshua

Comment 9 Sébastien Fabbro (RETIRED) gentoo-dev 2008-03-27 02:05:16 UTC
Folks,

I was also working on some fixes after the first post from Markus. I tried to update them and put all the changes in the science overlay.
I also tried to regroup some use flags. I'm not sure of the utility of the X one when there are so many of them pulling the X libraries.
I tried the ebuild with all the use flags turned off, and all turned on except ada (200 packages to pull...). There are so many use flags I tried to choose some decent default ones. Still some work to do:
* include some debian patches?
* ada tests
* freetype: I did not need the patch so it might be flaky
* doc generation to check
* not sure if we can add svgalib
I'm only using this package for gdl, so I'm not a good tester.
Feel free to modify the package in the overlay and report here.



Comment 10 Joshua Rich 2008-03-29 10:25:15 UTC
(In reply to comment #9)
> Folks,
> 
> I was also working on some fixes after the first post from Markus. I tried to
> update them and put all the changes in the science overlay.
> I also tried to regroup some use flags. I'm not sure of the utility of the X
> one when there are so many of them pulling the X libraries.
> I tried the ebuild with all the use flags turned off, and all turned on except
> ada (200 packages to pull...). There are so many use flags I tried to choose
> some decent default ones. Still some work to do:
> * include some debian patches?
> * ada tests
> * freetype: I did not need the patch so it might be flaky
> * doc generation to check
> * not sure if we can add svgalib
> I'm only using this package for gdl, so I'm not a good tester.
> Feel free to modify the package in the overlay and report here.
> 

Hi Sébastien,

I've compiled and tested your ebuild for version 5.9.0 from the
science overlay.  I compiled all the demos (for all the languages I
compiled: Java, Fortran 77/95, Perl, C, C++) and randomly ran
a few examples from a few languages and outputting to random drivers,
all seems to work really well! I did have a couple of issues:

- I get a warning in the cmake configure output that it can't find the
freetype fonts, but freetype postscript output is available (and
works) in the compiled and installed package.  So I think this is a
false warning.  You don't need the patch I made for 5.8.0 to get
freetype support.

- The gcw driver still segfaults when trying to save a hardcopy of a
plot (when running one of the compiled examples).  Can anyone confirm
this or is it just me?

That is about it though!

Thanks and regards,

Joshua
Comment 11 juantxorena@gmail.com 2008-03-30 15:08:56 UTC
It seems that these ebuilds depends on numeric when using python flag. As per bug #181653 numeric is deprecated and it should be removed from the tree sometime. dev-python/numpy is its subsitute, and it should be used instead of numeric. PlPlot supports numpy, and is prefered over numeric.
Comment 12 Joshua Rich 2008-04-03 10:30:12 UTC
plplot-5.9.0.ebuild is missing the 'truetype' USE flag in IUSE.  Only discovered this when running emerge --pretend --depclean and the lasi and freefont packages were to be removed.

Cheers,

Joshua
Comment 13 Jochen Trumpf 2008-04-27 01:01:46 UTC
Hi,

thanks for the new ebuild. I think, the built_with_use calls in pkg_setup should be conditional on use flags. The package doesn't install for me since I haven't got wxGTK installed (the use flag wxwindows is not set). pkg_setup fails when it tries to call built_with_use on wxGTK.

Cheers, Jochen 
Comment 14 Sébastien Fabbro (RETIRED) gentoo-dev 2008-10-21 11:51:45 UTC
plplot-5.9.0 now in main tree with many fixes. Please test it. If any bug or suggestion, open a new bug.
Thanks all for your work