sagemath / sage

Main repository of SageMath
https://www.sagemath.org
Other
1.39k stars 473 forks source link

sage.misc.latex: Replace have_... functions by Features #32650

Closed mkoeppe closed 2 years ago

mkoeppe commented 3 years ago

... or more generally, replacing all uses of sage.misc.os_tools.have_program by Executable

Depends on #32634

CC: @kwankyu

Component: refactoring

Author: Sébastien Labbé

Branch: 2ea4d9e

Reviewer: Matthias Koeppe

Issue created by migration from https://trac.sagemath.org/ticket/32650

slel commented 2 years ago
comment:38

There does not seem to be a Cygwin package for pdf2svg.

At least I could not find one by searching Cygwin packages via

and the command apt-cyg install pdf2svg fails.

slel commented 2 years ago

Changed commit from 2ea4d9e to none

seblabbe commented 2 years ago
comment:39

Do you mean that the file build/pkgs/pdf2svg/distros/cygwin.txt should be removed?

slel commented 2 years ago
comment:40

Yes, otherwise configure ends with a recommendation to run apt-cyg install pdf2svg.

slel commented 2 years ago
comment:41

Or package pdf2svg for Cygwin... : )

seblabbe commented 2 years ago
comment:42

I created #32931 to deal with this issue.

slel commented 2 years ago
comment:43

A request on the Cygwin mailing list to package pdf2svg was answered as follows:

The pdf2svg home page recommends instead pdftocairo from the poppler package, which does the same and is maintained as part of the package, rather than being a standalone utility which integrates the two, and is not as well maintained:

$ pdftocairo --help
[...]

That suggests pdftocairo --svg file.pdf will transform file.pdf to file.svg.

It seems poppler is widely packaged:

seblabbe commented 2 years ago
comment:44

Then, should we replace pdf2svg feature by pdftocairo?

seblabbe commented 2 years ago
comment:45

Replying to @mkoeppe:

While at it, also dummy script packages for ffmpeg and imagemagick could be added (see #30930)

I just created #32956 for that. I will work on it tomorrow.

seblabbe commented 2 years ago
comment:46

Replying to @seblabbe:

Remainings usage of have_program are:

I created #32957 to deal with remaining usage of have_program

seblabbe commented 2 years ago
comment:47

Replying to @slel:

That suggests pdftocairo --svg file.pdf will transform file.pdf to file.svg.

It seems poppler is widely packaged:

I created #33005 to add the feature pdftocairo.

dimpase commented 1 year ago

why do we have has_xelatex and have_xelatex ?! (which seem to be doing the same thing, no?)