texlive-latex-polyglossia package empty

  • Done
  • quality assurance status badge
Details
3 participants
  • Josh Holland
  • Maxim Cournoyer
  • Ricardo Wurmus
Owner
unassigned
Submitted by
Josh Holland
Severity
normal
J
J
Josh Holland wrote on 17 May 2019 18:51
(address . bug-guix@gnu.org)
20190517165152.GA5797@spica.localdomain
Steps to reproduce:
$ guix build texlive-latex-polyglossia
$ tree /gnu/store/d9nndb33yd22pay1yyg76nb0i56qdmkq-texlive-latex-polyglossia-49435

Expected results:
Something containing the file polyglossia.sty

Actual results:
Only an empty directory share/texmf-dist/tex/latex/polyglossia exists.
J
J
Josh Holland wrote on 17 May 2019 23:23
[PATCH] attempt to fix polyglossia
(address . 35780@debbugs.gnu.org)(name . Josh Holland)(address . josh@inv.alid.pw)
20190517212351.8855-1-josh@inv.alid.pw
---
I had a quick look into fixing this myself, and made a little bit
of progress. Not being that familiar with how things work yet,
I'm going on what I can guess by looking at gnu/packages/tex.scm,
guix/build-system/texlive.scm and guix/build/texlive-build-system.scm
so I may well be misinterpreting some things.

The source for polyglossia comes in a single file, polyglossia.dtx.
The README embedded within it says to extract the files by running
xetex or luatex on it. I tried to convince the build system to do
this by this patch, which may or may not have been the right approach.
It does at least get a new error:

Generating file(s) ../README
! I can't write on file `../README.tex'.

It appears to be trying to write its README file to the directory above
the build directory, which is failing. Is there a way to make this
directory writeable, or to stop the build system from trying to generate
the README there?

gnu/packages/tex.scm | 3 ++-
1 file changed, 2 insertions(+), 1 deletion(-)

Toggle diff (16 lines)
diff --git a/gnu/packages/tex.scm b/gnu/packages/tex.scm
index c3ce80c8f5..0894148501 100644
--- a/gnu/packages/tex.scm
+++ b/gnu/packages/tex.scm
@@ -3249,7 +3249,8 @@ array environments; verbatim handling; and syntax diagrams.")
(base32
"03ma58z3ypsbp7zgkzb1ylpn2ygr27cxzkf042ns0rif4g8s491f"))))
(build-system texlive-build-system)
- (arguments '(#:tex-directory "latex/polyglossia"))
+ (arguments '(#:tex-directory "latex/polyglossia"
+ #:build-targets '("polyglossia.dtx")))
(home-page "https://www.ctan.org/pkg/polyglossia")
(synopsis "Alternative to babel for XeLaTeX and LuaLaTeX")
(description
--
2.21.0
R
R
Ricardo Wurmus wrote on 18 May 2019 05:50
(name . Josh Holland)(address . josh@inv.alid.pw)(address . 35780@debbugs.gnu.org)
87y334ctfu.fsf@elephly.net
Hi Josh,

Toggle quote (11 lines)
> I had a quick look into fixing this myself, and made a little bit
> of progress. Not being that familiar with how things work yet,
> I'm going on what I can guess by looking at gnu/packages/tex.scm,
> guix/build-system/texlive.scm and guix/build/texlive-build-system.scm
> so I may well be misinterpreting some things.
>
> The source for polyglossia comes in a single file, polyglossia.dtx.
> The README embedded within it says to extract the files by running
> xetex or luatex on it. I tried to convince the build system to do
> this by this patch, which may or may not have been the right approach.

Thanks for giving it a try. The build system works on “ins” files by
default. I guess it should try “dtx” files as well.

Toggle quote (10 lines)
> It does at least get a new error:
>
> Generating file(s) ../README
> ! I can't write on file `../README.tex'.
>
> It appears to be trying to write its README file to the directory above
> the build directory, which is failing. Is there a way to make this
> directory writeable, or to stop the build system from trying to generate
> the README there?

We can patch the dtx file in a build phase and replace “../README” with
just “README”. We can’t write to the parent of the build directory, and
extracting everything a level deeper seems wrong.

What do you think?

--
Ricardo
J
J
Josh Holland wrote on 21 Jun 2019 17:40
(name . Ricardo Wurmus)(address . rekado@elephly.net)
20190621154006.GA7268@sirius.localdomain
Hi,

(CCing guix-devel because I'm confused about this and more eyes can't
hurt)

On Sat, May 18, 2019 at 05:50:13AM +0200, Ricardo Wurmus wrote:
Toggle quote (3 lines)
> Thanks for giving it a try. The build system works on “ins” files by
> default. I guess it should try “dtx” files as well.

Should this be a patch to the build-system? Although maybe it's not
lists four files, incuding an "ins" file.

Toggle quote (3 lines)
> We can patch the dtx file in a build phase and replace “../README” with
> just “README”.

I tried patching the README path as Ricardo suggested. This got
somewhere, complaining of missing fonts, so I added texlive-fonts-cm
to native-inputs. With both these changes, the build now fails while
trying to build example-thai.tex, and the errors appear to indicate
trying to build a LaTeX file with plain TeX:

Processing file polyglossia.dtx (example-thai.tex) -> example-thai.tex
File polyglossia.dtx ended by \endinput.
Lines processed: 11224
Comments removed: 1600
Comments passed: 215
Codelines passed: 9209

! Undefined control sequence.
l.209 \documentclass
[11pt]{ltxdoc}
! Undefined control sequence.
l.210 \usepackage
{color}
! Undefined control sequence.
l.211 \usepackage
{xspace,fancyvrb}
! Undefined control sequence.
l.212 \usepackage
[neverdecrease]{paralist}
! Undefined control sequence.
l.213 \definecolor
{myblue}{rgb}{0.02,0.04,0.48}
! Undefined control sequence.
l.214 \definecolor
{lightblue}{rgb}{0.61,.8,.8}
! Undefined control sequence.
l.215 \definecolor
{myred}{rgb}{0.65,0.04,0.07}
! Undefined control sequence.

(and more...)

I'm not that familiar with the intricacies of properly building TeXLive
from source, but the difference between the file list on CTAN and what
comes from the Subversion repo via texlive-ref smells fishy to me. If I
manually run any permutation of `{xe,lua}tex polyglossia.{ins,dtx}`
it mostly seems to build OK, but to my surprise no polyglossia.sty
is produced! There's no actual build instructions in the README or the
polyglossia.pdf, so I'm rather lost here.

Thanks,

--
Josh Holland
M
M
Maxim Cournoyer wrote on 14 May 2022 07:22
Re: bug#35780: texlive-latex-polyglossia package empty
(name . Ricardo Wurmus)(address . rekado@elephly.net)
87r14wn0wl.fsf_-_@gmail.com
Hello,

The texlive-polyglossia is no longer empty, and works, at least with
XeLaTeX. You can see it in action building the doc of our
'python-ipython-documentation' package.

Closing!

Thanks,

Maxim
Closed
?