Gentoo Websites Logo
Go to: Gentoo Home Documentation Forums Lists Bugs Planet Store Wiki Get Gentoo!
Bug 703156 - sci-mathematics/pari: new version 2.11.2
Summary: sci-mathematics/pari: new version 2.11.2
Status: RESOLVED FIXED
Alias: None
Product: Gentoo Linux
Classification: Unclassified
Component: Current packages (show other bugs)
Hardware: All Linux
: Normal normal (vote)
Assignee: Gentoo Science Mathematics related packages
URL:
Whiteboard:
Keywords:
Depends on:
Blocks: 703488
  Show dependency tree
 
Reported: 2019-12-16 23:01 UTC by Michael Orlitzky
Modified: 2020-01-03 04:00 UTC (History)
1 user (show)

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


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description Michael Orlitzky gentoo-dev 2019-12-16 23:01:44 UTC
The latest version of PARI/GP is 2.11.2:

  https://pari.math.u-bordeaux.fr/download.html

And luckily, François has already packaged it:

  https://github.com/cschwan/sage-on-gentoo/tree/master/sci-mathematics/pari

We've been making a lot of progress teaching SageMath to use the system packages in https://trac.sagemath.org/ticket/27330, so it's starting to become more important that the versions in ::gentoo are kept up to date. Otherwise -- as is the case here -- I can have pari installed but sage will decide to build its own copy anyway. This has the potential to benefit anyone who tries to compile sage without using sage-on-gentoo.

(I'm willing to act as a middle man for these merges, but in the long term we really need to recruit François.)
Comment 1 François Bissey 2019-12-16 23:44:55 UTC
And that ebuild is not just revision bump. Quite a bit of cleaning up in there. And upstream included some of my doc building fix and building fixes.

You will want to bump pari-data as well, available in the overlay as well.
Comment 2 Michael Orlitzky gentoo-dev 2019-12-16 23:49:01 UTC
(In reply to François Bissey from comment #1)
> And that ebuild is not just revision bump. Quite a bit of cleaning up in
> there. And upstream included some of my doc building fix and building fixes.
> 
> You will want to bump pari-data as well, available in the overlay as well.

I actually just did that on my own, thinking it was the only reason that SageMath couldn't detect my pari/galpol. It was half the problem, but some of the necessary functions weren't added until PARI-2.10.1 according to

  https://pari.math.u-bordeaux.fr/archives/pari-announce-18/msg00005.html
Comment 3 François Bissey 2019-12-17 00:32:19 UTC
(In reply to Michael Orlitzky from comment #2)
> (In reply to François Bissey from comment #1)
> > And that ebuild is not just revision bump. Quite a bit of cleaning up in
> > there. And upstream included some of my doc building fix and building fixes.
> > 
> > You will want to bump pari-data as well, available in the overlay as well.
> 
> I actually just did that on my own, thinking it was the only reason that
> SageMath couldn't detect my pari/galpol. It was half the problem, but some
> of the necessary functions weren't added until PARI-2.10.1 according to
> 
>   https://pari.math.u-bordeaux.fr/archives/pari-announce-18/msg00005.html

Of course. Main tree is still at the last stable branch (2.9.x).

In any case feel free to steal any of my ebuilds. I just like to be notified of when it happens to clean the overlay as much as possible.
Comment 4 François Bissey 2019-12-26 00:58:07 UTC
Location of pari.cfg has been a bit of a headache. I think it is much better in the sage-on-gentoo overlay ebuild.

I am happy to proxy maintain pari as well. If I ever complete my quizzes I am expecting pari to be one of the first packages handed to me directly.
Comment 5 Larry the Git Cow gentoo-dev 2019-12-28 13:58:29 UTC
The bug has been closed via the following commit(s):

https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=e3fd7bb8cfe64cd5b92cbf5d758ffb8aeddf8f8e

commit e3fd7bb8cfe64cd5b92cbf5d758ffb8aeddf8f8e
Author:     Michael Orlitzky <mjo@gentoo.org>
AuthorDate: 2019-12-28 13:22:33 +0000
Commit:     Michael Orlitzky <mjo@gentoo.org>
CommitDate: 2019-12-28 13:57:35 +0000

    sci-mathematics/pari: new version 2.11.2.
    
    This new version was imported from the sage-on-gentoo overlay where
    François Bissey has been maintaining it for use with SageMath. I've
    made a few changes:
    
      * Moved the virtual/latex-base dependency into BDEPEND, because
        those tools are run on the build host to create the documentation.
    
      * Used the existing patches (with different names) where possible.
    
      * Edited pari-2.10-no-automagic.patch to not mess with PLOTLIBS
        when USE=fltk is set. My build was failing because this patch
        resulted in -lstdc++ being stripped from the linker flags.
    
      * Dropped empty variable "${mymake}" in a few places.
    
      * Enabled the full test suite, which passes for me if I lie to pari
        about the number of columns my terminal has (???).
    
      * Installed some extra documentation by setting DOCS and calling
        the default implementation of src_install.
    
      * Used "usex" instead of an "if" statement for a ./Configure flag.
    
      * Changed "export CPLUSPLUS=$(tc-getCXX)" to "tc-export CXX". The
        CPLUSPLUS variable doesn't appear anywhere in the source, so I
        doubt this was doing anything. It may not even be necessary to
        export CC/CXX any longer.
    
      * Added RESTRICT="!test? ( test )" now that we run the test suite.
    
      * Added myself and François as maintainers.
    
    Closes: https://bugs.gentoo.org/703156
    Package-Manager: Portage-2.3.79, Repoman-2.3.16
    Signed-off-by: Michael Orlitzky <mjo@gentoo.org>

 sci-mathematics/pari/Manifest                      |   1 +
 .../pari/files/pari-2.11.2-Makefile-LDFLAGS.patch  |  13 +++
 .../files/pari-2.11.2-Makefile-docinstall.patch    |  25 +++++
 .../pari/files/pari-2.11.2-no-automagic.patch      |  74 ++++++++++++++
 sci-mathematics/pari/metadata.xml                  |  16 +++
 sci-mathematics/pari/pari-2.11.2.ebuild            | 111 +++++++++++++++++++++
 6 files changed, 240 insertions(+)
Comment 6 François Bissey 2019-12-28 19:17:37 UTC
Thanks and a few comments

(In reply to Larry the Git Cow from comment #5)
>       * Edited pari-2.10-no-automagic.patch to not mess with PLOTLIBS
>         when USE=fltk is set. My build was failing because this patch
>         resulted in -lstdc++ being stripped from the linker flags.

I rescued pari from a state where enabling fltk was either pretending to do something (but not doing anything) or breaking the build (newer version). I am surprised there was more to do. 

>       * Enabled the full test suite, which passes for me if I lie to pari
>         about the number of columns my terminal has (???).

I have searched for that one for a long time. For me the test suite passes when not run by portage (in my 132 columns terminal) but failed as soon as I ran it from portage. I thought about COLUMNS but I couldn't see it in the portage environment or in pari's code.

>       * Changed "export CPLUSPLUS=$(tc-getCXX)" to "tc-export CXX". The
>         CPLUSPLUS variable doesn't appear anywhere in the source, so I
>         doubt this was doing anything. It may not even be necessary to
>         export CC/CXX any longer.

This, may be a last remnant of the qt(4) option.

A last note about the forced optimization, for fun. We force -O2 which is fine with gcc and clang. But with the intel compiler - no optimizations are safe - if you want the test suite to pass with icc you need -O0.
Comment 7 Michael Orlitzky gentoo-dev 2019-12-30 13:20:17 UTC
(In reply to François Bissey from comment #6)
> 
> >       * Enabled the full test suite, which passes for me if I lie to pari
> >         about the number of columns my terminal has (???).
> 
> I have searched for that one for a long time. For me the test suite passes
> when not run by portage (in my 132 columns terminal) but failed as soon as I
> ran it from portage. I thought about COLUMNS but I couldn't see it in the
> portage environment or in pari's code.

It took me several hours to find. The test suite always passes when run manually, but not from portage. Through portage, it passes, but only if I leave my terminal at its default size with 80 columns.

After full-screening the terminal, they fail through portage consistently. But, I was pretty sure that I did see them pass once when I first copied the ebuild, so I started digging. I was looking in another direction when I noticed that the "--test" flag is supposed to ignore some stuff about your terminal. For example, CHANGES-2.2 says,

   18- when called as 'gp --test', disregard actual terminal dimensions

That got me thinking that maybe there was a bug in the --test flag, and I eventually figured out that resizing my terminal could trigger the failures. I'm still not sure where the bug is (I'd like to report it to upstream), but passing COLUMNS=80 seems to fix it, so the term_width() function in src/language/es.c is likely implicated.
Comment 8 François Bissey 2020-01-03 04:00:19 UTC
I'll dig a bit more when I have time and let you know. The worst part of this is that I was the only to whom that seemed to happen. When I asked on gentoo-science if it happened to anyone else, I got silence.