Macaulay2 / M2

The primary source code repository for Macaulay2, a system for computing in commutative algebra, algebraic geometry and related fields.
https://macaulay2.com
345 stars 231 forks source link

get Macaulay2 into Debian #286

Closed DanGrayson closed 3 years ago

DanGrayson commented 9 years ago

Doug Torrance dtorrance@monmouthcollege.edu is working on that now, see https://bugs.debian.org/cgi-bin/bugreport.cgi?bug=439888 and https://groups.google.com/forum/#!topic/macaulay2/jxtKZFRDKDA .

d-torrance commented 9 years ago

We're currently waiting on a number of build dependencies to make it into Debian before Macaulay2 can be uploaded. Currently in the NEW queue are singular, frobby, and memtailor. Once memtailor goes in, we'll upload mathic and then mathicgb. Packages often sit in the NEW queue for months, so this will take some time.

My packaging work so far can be seen at https://github.com/d-torrance/M2/tree/master. Currently there's an issue with gmp (See #285).

d-torrance commented 9 years ago

Dependency update: memtailor has been accepted into Debian unstable.

mikestillman commented 9 years ago

Great!

On Jun 8, 2015, at 9:48 PM, Doug Torrance notifications@github.com wrote:

Dependency update: memtailor has been accepted into Debian unstable.

— Reply to this email directly or view it on GitHub https://github.com/Macaulay2/M2/issues/286#issuecomment-110194223.

d-torrance commented 9 years ago

Dependency update: mathic has been accepted into Debian unstable.

DanGrayson commented 9 years ago

Good progress, thanks!

How does one get into "stable"?

d-torrance commented 9 years ago

Debian packages are first uploaded to "unstable", then migrate to "testing" after a few days (10 in mathic's case). At some point in the future, "testing" is frozen and becomes the next "stable" release. Debian just did this recently (Debian 8, or "jessie", was released in April), so the next release (Debian 9, or "stretch") will probably occur in 2 years or so.

Ubuntu moves much more quickly. They migrate packages directly from Debian unstable and release every 6 months. So mathic should be in 15.10 (Wily Werewolf), which will be released in October.

dimpase commented 9 years ago

I wonder if anyone is involved in updating Fedora M2 packages. It's still version 1.5.

DanGrayson commented 9 years ago

Maybe Rex Dieter fell behind or stopped? See http://www.math.illinois.edu/Macaulay2/Downloads/GNU-Linux/Fedora/index.html

On Fri, Jul 10, 2015 at 9:24 AM Dmitrii Pasechnik notifications@github.com wrote:

I wonder if anyone is involved in updating Fedora M2 packages. It's still version 1.5.

— Reply to this email directly or view it on GitHub https://urldefense.proofpoint.com/v2/url?u=https-3A__github.com_Macaulay2_M2_issues_286-23issuecomment-2D120410191&d=AwMCaQ&c=8hUWFZcy2Z-Za5rBPlktOQ&r=PAZ_jTPLrSb1btCfAu4RkycWe57N0sGyzbjgeOn2wN0&m=Wej3yI2zW7KJZ9huOAE-50HfsfKuhnCik-jATizgnn0&s=du6FB5lsWXZxnl0DAZvJEP0baaXYx8j749My4-eMtMs&e= .

rdieter commented 9 years ago

Fedora 22 ships Macaulay2-1.6

I've been fighting trying to get more recent versions unsuccessfully. Will probably be pinging this group for help/advice sometime soon. On Jul 8, 2015 11:23 AM, "Doug Torrance" notifications@github.com wrote:

Dependency update: mathic has been accepted into Debian unstable.

— Reply to this email directly or view it on GitHub https://github.com/Macaulay2/M2/issues/286#issuecomment-119648350.

d-torrance commented 9 years ago

Dependency update: mathicgb has been accepted into Debian unstable.

d-torrance commented 9 years ago

Dependency update: frobby has been accepted into Debian unstable.

DanGrayson commented 9 years ago

Thanks!

rdieter commented 9 years ago

Last I knew, frobby's licensing was nonfree (is why it's not in fedora at least), has the situation changed?

On Fri, Jul 24, 2015 at 12:49 PM, Daniel R. Grayson < notifications@github.com> wrote:

Thanks!

— Reply to this email directly or view it on GitHub https://github.com/Macaulay2/M2/issues/286#issuecomment-124597780.

rdieter commented 9 years ago

Hrm, looking closer I was mistaken here, sorry for the noise.

On Wed, Jul 29, 2015 at 12:06 PM, Rex Dieter rdieter@gmail.com wrote:

Last I knew, frobby's licensing was nonfree (is why it's not in fedora at least), has the situation changed?

On Fri, Jul 24, 2015 at 12:49 PM, Daniel R. Grayson < notifications@github.com> wrote:

Thanks!

— Reply to this email directly or view it on GitHub https://github.com/Macaulay2/M2/issues/286#issuecomment-124597780.

d-torrance commented 9 years ago

Belated dependency update: singular was accepted into Debian unstable on August 3.

At this point, I believe all of the dependencies are now in Debian.

DanGrayson commented 9 years ago

Thanks!

d-torrance commented 8 years ago

Status update:

I'm able to successfully build a Debian package using only Debian libraries if I pass --disable-pari to configure and patch out the pari functions giving problems in #396.

Note that this of course breaks these functions which rely on pari, and I don't intend to upload the package until #285 is resolved. But we're getting closer!

DanGrayson commented 8 years ago

Thanks, that makes #285 more important.

On Tue, Apr 12, 2016 at 6:57 AM, Doug Torrance notifications@github.com wrote:

Status update:

I'm able to successfully build a Debian package using only Debian libraries if I pass --disable-pari to configure and patch out the pari functions giving problems in #396 https://urldefense.proofpoint.com/v2/url?u=https-3A__github.com_Macaulay2_M2_issues_396&d=BQMCaQ&c=8hUWFZcy2Z-Za5rBPlktOQ&r=PAZ_jTPLrSb1btCfAu4RkycWe57N0sGyzbjgeOn2wN0&m=vcAnxJs_V2oxwvYUnhD3wF3-F5pa2kXKfTspJC96obg&s=NOagxvsa5kvR7QRuIfQi3bnGbKhp3iaBV21onm_w4zo&e= .

Note that this of course breaks these functions which rely on pari, and I don't intend to upload the package until #285 https://urldefense.proofpoint.com/v2/url?u=https-3A__github.com_Macaulay2_M2_issues_285&d=BQMCaQ&c=8hUWFZcy2Z-Za5rBPlktOQ&r=PAZ_jTPLrSb1btCfAu4RkycWe57N0sGyzbjgeOn2wN0&m=vcAnxJs_V2oxwvYUnhD3wF3-F5pa2kXKfTspJC96obg&s=JyuGkrAIwGA3so_Pj9wRz00pFwgels1T15AFEyMN_6k&e= is resolved. But we're getting closer!

— You are receiving this because you authored the thread. Reply to this email directly or view it on GitHub https://urldefense.proofpoint.com/v2/url?u=https-3A__github.com_Macaulay2_M2_issues_286-23issuecomment-2D208864722&d=BQMCaQ&c=8hUWFZcy2Z-Za5rBPlktOQ&r=PAZ_jTPLrSb1btCfAu4RkycWe57N0sGyzbjgeOn2wN0&m=vcAnxJs_V2oxwvYUnhD3wF3-F5pa2kXKfTspJC96obg&s=oLhKMir7qOJ346RfT1hQIXlng0V_Apexw7_KOsHCVPs&e=

d-torrance commented 8 years ago

Also, a question:

/usr/share/doc/Macaulay2/*/example-output/*.out and /usr/lib/Macaulay2/$MACHINE/*/cache/*.db are installed by default and included in the *.deb packages on the M2 website.

If I'm understanding the code (which I certainly may not be), it looks like these files are intermediate steps in generating the documentation. Are they still needed after the initial installation?

d-torrance commented 8 years ago

I just realized these files must be used by the help function.

DanGrayson commented 8 years ago

The .out files are retained in case someone wants to regenerate the documentation. The .db files allow quick loading of the documentation.

d-torrance commented 8 years ago

Makes sense. Thanks for clarifying!

d-torrance commented 8 years ago

Status update:

The freeze for the next version of Debian (version 9, codename "stretch") is 2017-01-05. It would be great if M2 could be uploaded by then. However, #285 is still the big blocker, as we need M2 to build against the Debian gmp package.

I also need to package a few Javascript libraries used by the new Visualize package.

d-torrance commented 7 years ago

Status update:

I noticed recently that cohomCalg and TOPCOM are now both installed by M2. I've packaged cohomCalg for Debian, and it was just uploaded (currently in the NEW queue pending approval by the FTP masters). I'll work on TOPCOM next. I also still need to package the Javascript libraries used by Visualize.

As for M2 itself, it currently won't build using the Debian packages of givaro and fflas-ffpack (both the latest upstream versions), so I'm waiting for #513. I imagine #285 is still a problem as well, but my builds don't get that far. :)

mikestillman commented 7 years ago

I am working on updating M2 to use the newest givaro, ffpack. The interfaces for these packages appear to have changed quite a bit, and it is taking longer to get it to work.

DanGrayson commented 7 years ago

Thanks, Doug!

alexmyczko commented 6 years ago

What's the current state, then?

d-torrance commented 6 years ago

Thanks for the bump. I haven't looked at this in a while while I waited for #513 and for the latest version of PARI to be uploaded to Debian so that I could implement the fix for #285. But it looks like both of these things have happened. :)

I should have some time over the holidays to see where we're at.

alexmyczko commented 6 years ago

Happy New Year... the holidays? Ping...

d-torrance commented 6 years ago

I did have some time to see where things are at.

After applying a patch to M2/Macaulay2/d/pari-c.c, we do get past #285. (I'll submit a pull request for this in the near future.)

However, then I ran into another problem. Since we're using the dynamically-linked Debian givaro package and not a statically-linked local copy of givaro, we run into #460.

A new version of givaro was released recently. I updated the givaro package in Debian, hoping that it might fix things. But it didn't. :(

So that's where things stand now.

d-torrance commented 4 years ago

Time for an update. With the changes coming in #1096, I'm hopeful that a Debian Macaulay2 package might be around the corner!

I have a draft package that builds based on that branch, but there are some issues:

DanGrayson commented 4 years ago

Doug, thanks for working on this!

d-torrance commented 4 years ago

If anyone is interested, my packaging work so far is at: https://salsa.debian.org/science-team/macaulay2

I'm keeping track of what still needs to be done at: https://salsa.debian.org/science-team/macaulay2/-/blob/master/debian/TODO.md

DanGrayson commented 4 years ago

Thanks!

Just the other day I complained to our audience that the top directory in our repository seemed to have no use. But you have found a use.

How does a file such as debian/macaulay2-common.doc-base get updated when we add a package?

If our configure script build process is deprecated in favor of cmake, can you cope?

d-torrance commented 4 years ago

I should be able to use wildcards for the .info files, just like the .html ones, for doc-base. I haven't touched that file in 4 years, so it's very out of date!

cmake should be fine. debhelper is set up to deal with most common build systems out of the box. I'd just need to switch any patches of configure.ac over to CMakeLists.txt.

DanGrayson commented 4 years ago

Is it the custom for downstream debian package building files ever to get incorporated upstream?

d-torrance commented 4 years ago

It's not very common, but it's not unheard of. Of the various packages I help maintain in Debian, Window Maker is the only one that has a copy of debian directory upstream.

dimpase commented 4 years ago

IMHO a copy of debian directory in M2 source would add to confusion (that's extra synchronisation to do following some yet to determine rules, too, and it is going to be not always the same for different versions of Debian...).

Sagemath used to have such a directory, then its Debian package got broken, people got worried whether it's something that may be fixed by using data in debian/ directory of Sagemath source, etc. Now debian/ is gone (Debian package is back to life, meanwhile), and this leads to less Debian-specific things asked in general Sagemath forums (and more in a specific "packaging" forum), which is actually better.

d-torrance commented 4 years ago

Update: mpsolve has been uploaded to Debian. It will likely sit in the NEW queue for a while before it will be available for Macaulay2 to use.

There are three more packages that still need to get into Debian before it will be ready for Macaulay2:

We also need flint 2.6, which is supposed to be released officially tomorrow. The Debian maintainer of flint is active and I expect that it will be uploaded while we wait for the others.

dimpase commented 4 years ago

flint 2.6 will do one more rc before the release, as there are a couple of minor hiccups left.

d-torrance commented 4 years ago

Update:

d-torrance commented 4 years ago

topcom was accepted quickly!

We're still waiting on the following packages:

If I can't find a sponsor for the two Javascript packages by the time 1.16 is released (and mpsolve is accepted), then I should be able to just include them in Macaulay2 itself for the time being (provided that I include an un-minified version of noUiSlider).

DanGrayson commented 4 years ago

I didn't realize that the Visualize package has minimized javascript files. Maybe we should just unminimize them all upstream.

There are 12 of them -- why are you concerned about only 2? Are the other 10 already to be found in debian?

d-torrance commented 4 years ago

There are 12 of them -- why are you concerned about only 2? Are the other 10 already to be found in debian?

Yes, exactly.

d-torrance commented 4 years ago

The Debian package is in pretty good shape, I think, with the exception of no roots function since mpsolve is still sitting in the NEW queue.

My plan is that once the release-1.16 branch is stable and the new version is announced, I'll ask for sponsorship to get Macaulay2 uploaded to the NEW queue. This should increase the chances of getting it into Ubuntu 20.10. (Ubuntu will automatically migrate packages from Debian unstable until August 27.)

Hopefully, by the time it goes through the NEW queue, mpsolve will have also gone through and I can restore roots on the second upload.

Also, I've split off the emacs files from macaulay2-common into their own binary package, macaulay2-emacs, inspired by the Why install M2-mode without Macaulay2? section of the M2-emacs README.

DanGrayson commented 4 years ago

Can you point the debian package at a commit number? Or should we make a tag for you?

I'm building on Debian 10 today, so if that goes okay, you might base it on the commit at that time. I have further problems on CentOS.

DanGrayson commented 4 years ago

By the way, I asked Mike whether I could simplify the build of mathicgb and friends, since libtool and automake are causing problems. I assume you can adapt to that easily.

Is it required, for Debian, that a package such as mathicgb be able to make shareable libraries? I'd like to not bother with that at all.

DanGrayson commented 4 years ago

Update:

  • flint 2.6 is now in Debian

How do I get to use it?

debian$ sudo apt-get install libflint-dev
The following packages were automatically installed and are no longer required:
  bliss libbliss2 liblrs0 libpolymake-dev-common libppl14 libterm-readkey-perl libxml-libxslt-perl libxml-writer-perl libxslt1.1
  ninja-build polymake-common sketch
Use 'sudo apt autoremove' to remove them.
The following additional packages will be installed:
  libflint-2.5.2
The following NEW packages will be installed:
  libflint-2.5.2 libflint-dev
0 upgraded, 2 newly installed, 0 to remove and 1 not upgraded.
Need to get 1,159 kB/2,075 kB of archives.
After this operation, 12.9 MB of additional disk space will be used.
Do you want to continue? [Y/n] y
Get:1 http://ftp.us.debian.org/debian stable/main amd64 libflint-dev amd64 2.5.2-19 [1,159 kB]
Fetched 1,159 kB in 1s (1,249 kB/s)
debconf: unable to initialize frontend: Dialog
debconf: (Dialog frontend will not work on a dumb terminal, an emacs shell buffer, or without a controlling terminal.)
debconf: falling back to frontend: Readline
Selecting previously unselected package libflint-2.5.2.
(Reading database ... 112695 files and directories currently installed.)
Preparing to unpack .../libflint-2.5.2_2.5.2-19_amd64.deb ...
Unpacking libflint-2.5.2 (2.5.2-19) ...
Selecting previously unselected package libflint-dev.
Preparing to unpack .../libflint-dev_2.5.2-19_amd64.deb ...
Unpacking libflint-dev (2.5.2-19) ...
Setting up libflint-2.5.2 (2.5.2-19) ...
Setting up libflint-dev (2.5.2-19) ...
Processing triggers for libc-bin (2.28-10) ...
d-torrance commented 4 years ago

Can you point the debian package at a commit number? Or should we make a tag for you?

I wrote a script that finds the most recent release-X.Y branch, builds a tarball from it using git archive, and builds a small webpage for use by Debian's uscan tool, which checks for version bumps and downloads tarballs. So I'm all set on that end!

d-torrance commented 4 years ago

Update:

  • flint 2.6 is now in Debian

How do I get to use it?

It's only in Debian unstable right now. Apparently it's not building on 32 bit architectures (#964109), so it hasn't migrated to testing (Debian 11) yet. It likely won't become available for Debian 10, since stable releases just get security updates.