Bug 120163 - itpp-3.9.0.ebuild - new ebuild for the IT++ library
Bug#: 120163 Product:  Gentoo Linux Version: 2005.1 Platform: All
OS/Version: Linux Status: RESOLVED Severity: enhancement Priority: P2
Resolution: FIXED Assigned To: sci@gentoo.org Reported By: ediap@users.sourceforge.net
Component: Ebuilds
URL:  http://itpp.sourceforge.net/
Summary: itpp-3.9.0.ebuild - new ebuild for the IT++ library
Keywords:  EBUILD
Status Whiteboard: 
Opened: 2006-01-24 04:05 0000
Description:   Opened: 2006-01-24 04:05 0000
Dear Gentoo Devs,

I have prepared an ebuild for a library named IT++, since it is not in portage
yet.

The IT++ library is a C++ library of mathematical, signal processing, speech
processing, and communications classes and functions. It is being developed by
researchers in these areas and is widely used by researchers, both in the
communications industry and universities.
The kernel of the IT++ library are templated vector and matrix classes, and
lots of functions for vectors and matrices. Such a kernel makes IT++ library
similar to Matlab or Octave.

The attached ebuild depends on a few sci-libs libraries (fftw, blas-atlas and
lapack), but can be compiled without them as well.

BTW, I am one of the developers and a Gentoo fan as well, so I will try to
maintain the ebuild in future.

Best regards,

/ediap

------- Comment #1 From Adam Piątyszek 2006-01-24 04:06:35 0000 -------
Created an attachment (id=77984) [details]
An ebuild for the IT++ 3.9.0 library

------- Comment #2 From George Shapovalov 2006-01-27 15:02:02 0000 -------
Adam,
Thanks for a submission!

I just glanced at ebuild and it seems reasonable, just two questions:

1. does it strictly require blas-atlas? Can it not work with blas-reference as
well? If yes it would be better to make it depend on virtual/blas instead.

2. if [ -z `which g77` ]; then  should probably be replaced with whatever plays
well with fortran.eclass. Unfortunately I did not follow its development
closely lately, so I'll leave the details to you and people involved with
eclass, however my understanding is that you need to use eclass provided tests
instead.

Unfortunately I cannot looks at this closer now, but you should have received
CC of my forwarding of your email already, so I won't reiterate..

George

------- Comment #3 From Adam Piątyszek 2006-01-27 15:21:27 0000 -------
George,

Thank you for having a look at this ebuild. Answering to your questions
comments:

1) The dependency on blas-atlas is due to the fact that it is recommended that
IT++ uses CBLAS, which is provided by atlas in Gentoo. Unfortunately CBLAS not
provided by virtual/blas. It is possible to compile the library without CBLAS,
but some internal functions will have reduced performance.
The best solution would be to add CBLAS interface to blas-reference package. Or
create a separate package, which will provide virtual/cblas and depend on
blas-reference.

2) I will look into this fortran.eclass and try to adapt the fortran compiler
checks using this...

BTW, a bug-fix release (version 3.9.1) should appear soon (we hope in January),
so I will try to fix issue 2) by the way of bumping the ebuild.

Best regards,

/ediap

------- Comment #4 From Markus Dittrich 2006-01-28 08:44:08 0000 -------
Created an attachment (id=78358) [details]
small changes to itpp-3.9.0.ebuild

Hi Adam,

I had a look at your ebuild and it looks fine besides a few small changes:

- I currently don't see why we need g77 to compile itpp; looking at the compile
  log I only see c++ code. Could you comment on this?
- With USE="doc" we need doxygen which I've added to DEPEND.

Please have a look at the changes, give it a a try and let me know what you
think.

Thanks,
Markus

------- Comment #5 From Adam Piątyszek 2006-01-28 13:48:20 0000 -------
Dear Markus,

Thanks for your comments and a patch. Concerning your questions:

- g77 or gfortran compiler is needed because it is recommended that IT++ usees
blas and lapack libraries. In order to link to these libraries one need to use
some special flags for linker. These flags are set in the FLIBS variable by the
autoconf's macro AC_F77_LIBRARY_LDFLAGS. And this macro requires a fortran
compiler; I guess, the same one, which blas and lapack libraries have been
compiled with.
Therefore, I readded the check for a fortran compiler. This time, I used
fortran.eclass's function `need_fortran()'.

- beside Doxygen, TeTeX and Ghostscript are also required to build the
documentation, so I added these packages to the DEPEND as well.

Please find the attached patch with my changes.

BTW, have you read my comment #3 concerning CBLAS? Is is possible to include
CBLAS interface to blas-reference library and provide an extra virtual for
CBLAS?

/ediap

------- Comment #6 From Adam Piątyszek 2006-01-28 13:51:29 0000 -------
Created an attachment (id=78373) [details]
patch for itpp-3.9.0.ebuild

------- Comment #7 From Markus Dittrich 2006-01-28 22:48:23 0000 -------
Hi Adam,

Thanks for the patch and it looks good with two minor corrections:
- no need to explictly call "need_fortran" since this is the default
  action of pkg_setup() when inheriting the fortran.eclass
- we don't need virtual/ghostscript in DEPEND since this gets
 pulled in by doxygen.

I'll test it once more tomorrow and then move it into the tree
unless you have any objections.

I will have a look at the cblas/blas-reference stuff. For now we
can just go with depending on blas-atlas.

Thanks,
Markus

------- Comment #8 From Adam Piątyszek 2006-01-29 04:48:18 0000 -------
Thanks Markus!

Because we released the IT++ 3.9.1 yesterday evening, I updated the ebuild,
taking your comments into account. I have added one more switch to econf
depending on blas flag, to assure that it is possible to totally switch off
linking IT++ to blas/cblas.

BR,

/ediap

------- Comment #9 From Adam Piątyszek 2006-01-29 04:49:45 0000 -------
Created an attachment (id=78417) [details]
itpp-3.9.1.ebuild - version bumped

------- Comment #10 From Markus Dittrich 2006-01-30 09:19:10 0000 -------
Hi Adam,

Thanks for the ebuild and all your help! I just committed the itpp-3.9.1.ebuild
to CVS and I'll maintain the package. It would be great if you could keep
us posted on any changes/updates.

Thanks,
Markus

------- Comment #11 From Adam Piątyszek 2006-01-30 14:43:29 0000 -------
Thanks again!

I will of course inform you about further changes in the IT++ package. BTW, I
look forward for any improvements in Gentoo concerning the CBLAS.

/ediap