Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

build/pkgs/mathjax/distros/gentoo.txt: Fix #36145

Merged
merged 1 commit into from
Sep 1, 2023

Conversation

mkoeppe
Copy link
Member

@mkoeppe mkoeppe commented Aug 28, 2023

Fixes the build error in CI for 10.2.beta0
https://github.com/sagemath/sage/actions/runs/5992963191/job/16252928425#step:8:51

📝 Checklist

  • The title is concise, informative, and self-explanatory.
  • The description explains in detail what this PR is about.
  • I have linked a relevant issue or discussion.
  • I have created tests covering the changes.
  • I have updated the documentation accordingly.

⌛ Dependencies

@orlitzky
Copy link
Contributor

Is it possible to escape the >? It's necessary to make the whole thing a valid "atom," i.e. something you can give to the package manager:

$ emerge -pv dev-libs/mathjax-3
!!! 'dev-libs/mathjax-3' is not a valid package atom.
!!! Please check ebuild(5) for full details.

$ emerge -pv ">=dev-libs/mathjax-3"

These are the packages that would be merged, in order:

Calculating dependencies... done!
Dependency resolution took 8.37 s.

[ebuild  N     ] dev-libs/mathjax-3.2.2::gentoo  USE="-doc" 6047 KiB

In any case it's fine with me if you just want to change it to get the CI working again.

@mkoeppe
Copy link
Member Author

mkoeppe commented Aug 28, 2023

With shell-quoting, I am getting

Step 3/44 : RUN  emerge -DNut --with-bdeps=y --complete-graph=y  media-libs/gd dev-libs/gmp dev-util/ninja dev-python/tox sci-libs/fplll sci-mathematics/primesieve sci-libs/iml sci-libs/m4ri[png] sci-mathematics/gfan sci-mathematics/singular[readline] sci-libs/mpfi dev-util/cmake sci-libs/symmetrica dev-libs/mpfr sci-libs/cddlib sci-libs/libbraiding sci-libs/brial dev-libs/ppl sci-mathematics/sympow net-libs/zeromq dev-db/sqlite media-gfx/tachyon ">=dev-libs/mathjax-3" sys-apps/texinfo sci-libs/m4rie dev-util/meson sci-libs/openblas dev-libs/ntl sci-mathematics/glpk sci-libs/fflas-ffpack dev-libs/mpc sci-libs/gsl sys-devel/binutils sys-libs/binutils-libs sys-devel/make dev-scheme/guile dev-libs/libffi app-arch/tar sys-devel/gcc dev-libs/mpc sys-libs/glibc sys-kernel/linux-headers dev-lang/perl sys-devel/m4 sys-devel/bc dev-lang/python sys-devel/flex app-misc/ca-certificates dev-libs/libxml2 sys-apps/findutils sys-apps/which sys-apps/diffutils sci-mathematics/flint[ntl] dev-libs/boehm-gc sci-mathematics/arb sci-mathematics/pari sci-mathematics/pari-data sci-mathematics/cliquer sci-libs/libhomfly dev-util/gengetopt sci-mathematics/planarity sci-mathematics/lrcalc sci-mathematics/primecount sci-libs/amd sci-libs/cholmod sci-libs/suitesparseconfig sci-libs/umfpack sci-mathematics/maxima[ecls] sci-libs/givaro dev-lisp/ecls sci-mathematics/eclib[flint] sci-mathematics/lcalc dev-libs/libatomic_ops sci-libs/linbox media-libs/qhull sys-devel/autoconf sys-devel/automake sys-devel/libtool
 ---> Running in d8df5be9416c

These are the packages that would be merged, in reverse order:

Calculating dependencies  .... done!
Dependency resolution took 1.96 s.


emerge: there are no ebuilds to satisfy ">=dev-libs/mathjax-3".

@orlitzky
Copy link
Contributor

I only gave up on waiting and added mathjax-3.x to Gentoo 12 days ago:

commit 46560543c9d48506feb83de473a7b0bd0298ae83
Author: Michael Orlitzky <mjo@gentoo.org>
Date:   Wed Aug 16 10:24:02 2023 -0400

    dev-libs/mathjax: add 3.2.2

    Closes: https://bugs.gentoo.org/837722
    Signed-off-by: Michael Orlitzky <mjo@gentoo.org>

When was the package tree last synced on that host (does it sync as part of the build)?

@mkoeppe
Copy link
Member Author

mkoeppe commented Aug 28, 2023

@sheerluck

@sheerluck
Copy link
Contributor

file gentoo.txt should contain dev-libs/mathjax without -3, I will add mathjax-3.2.2 to latest-py10 latest-py11 today

@sheerluck
Copy link
Contributor

Step 3/44 : RUN  emerge -DNut ... dev-libs/mathjax ...  
...
-----------------------------------------------------------------------------
Checking whether SageMath should install SPKG mathjax...
checking for MathJax-3.x... /usr/share/mathjax
configure: will use system package and not install SPKG mathjax
-----------------------------------------------------------------------------
...
mathjax:                        using system package; SPKG will not be installed

I am docker push -ing both of them in a moment

@sheerluck
Copy link
Contributor

Done. Test with

--- a/build/pkgs/mathjax/distros/gentoo.txt
+++ b/build/pkgs/mathjax/distros/gentoo.txt
@@ -1 +1 @@
->=dev-libs/mathjax-3
+dev-libs/mathjax

@orlitzky
Copy link
Contributor

Done. Test with

--- a/build/pkgs/mathjax/distros/gentoo.txt
+++ b/build/pkgs/mathjax/distros/gentoo.txt
@@ -1 +1 @@
->=dev-libs/mathjax-3
+dev-libs/mathjax

That should work for the CI with ~arch keywords, but for end users, it will also accept mathjax-2.x. I can think of two scenarios where that might happen:

  1. mathjax-2.x is the stable version, so emerge dev-libs/mathjax will always install 2.x until 3.x is stabilized
  2. Even after 3.x is stabilized, we have several other packages in the tree that want mathjax-2.x. If you install, say, net-wireless/gnuradio, it will pull in mathjax-2.x. But then emerge dev-libs/mathjax will do nothing because you already have some version of mathjax.

@sheerluck
Copy link
Contributor

Those docker images are for Github Actions only, end users will get only those versions that sage-on-gentoo overlay dictates them to get.

@orlitzky
Copy link
Contributor

Those docker images are for Github Actions only, end users will get only those versions that sage-on-gentoo overlay dictates them to get.

Yeah the docker image will be fine, I was thinking instead about the ./configure output giving users the command to install mathjax. Without the version specifier, it may suggest to them something that will install the wrong version of mathjax (or do nothing) on Gentoo.

@sheerluck
Copy link
Contributor

we should encourage people to use overlay, not ./configure

@orlitzky
Copy link
Contributor

we should encourage people to use overlay, not ./configure

I don't disagree, but distros/gentoo.txt is irrelevant for those people, isn't it?

@sheerluck
Copy link
Contributor

Well, then it seems that ">=dev-libs/mathjax-3" (with quotes) in gentoo.txt is the best solution.

@github-actions
Copy link

Documentation preview for this PR (built with commit 0ffc189; changes) is ready! 🎉

@mkoeppe
Copy link
Member Author

mkoeppe commented Aug 29, 2023

Thanks @sheerluck for the new image. I've tested with tox -e docker-gentoo-standard -- config.status, and system mathjax is recognized.

Let's get this PR in

Copy link
Contributor

@orlitzky orlitzky left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

If CI is happy, I'm happy.

Do you want to fix the doc preview at the same time? The same PR de-duplicated all of the mathjax javascript files (tex-chtml.js) which, as a side effect, makes the documentation directories not self-contained. An easy fix is to use the CDN on github: #36098 (comment)

@mkoeppe
Copy link
Member Author

mkoeppe commented Aug 30, 2023

Do you want to fix the doc preview at the same time?

No

@orlitzky
Copy link
Contributor

Do you want to fix the doc preview at the same time?

No

Good guess, it was fixed in #36160 when I woke up.

@vbraun vbraun merged commit d6b045f into sagemath:develop Sep 1, 2023
10 of 13 checks passed
@mkoeppe mkoeppe added this to the sage-10.2 milestone Sep 1, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

4 participants