Re: [PATCH v2] docs: Detect variable fonts and suggest denylisting them

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



Akira Yokosawa <akiyks@xxxxxxxxx> writes:

> Fedora and openSUSE has started deploying "variable font" [1] format
> Noto CJK fonts [2, 3].  "CJK" here stands for "Chinese, Japanese,
> and Korean".
>
> Unfortunately, XeTeX/XeLaTeX doesn't understand those fonts for
> historical reasons and builds of translations.pdf end up in errors
> if such fonts are present on the build host.
>
> To help developers work around the issue, add a script to check the
> presence of "variable font" Noto CJK fonts and to emit suggestions.
> The script is invoked in the error path of "make pdfdocs" so that the
> suggestions are made only when a PDF build actually fails.
>
> The first suggestion is to denylist those "variable font" files by
> activating a per-user and command-local fontconfig setting.
>
> For further info and backgrounds, please refer to the header comment
> of scripts/check-variable-font.sh newly added in this commit.
>
> Link: [1] https://en.wikipedia.org/wiki/Variable_font
> Link: [2] https://fedoraproject.org/wiki/Changes/Noto_CJK_Variable_Fonts
> Link: [3] https://build.opensuse.org/request/show/1157217
> Reported-by: Jonathan Corbet <corbet@xxxxxxx>
> Link: https://lore.kernel.org/r/8734tqsrt7.fsf@xxxxxxxxxxxx/
> Reported-by: "Иван Иванович" <relect@xxxxx>
> Link: https://lore.kernel.org/linux-doc/1708585803.600323099@xxxxxxxxxxxxxx/
> Cc: Randy Dunlap <rdunlap@xxxxxxxxxxxxx>
> Signed-off-by: Akira Yokosawa <akiyks@xxxxxxxxx>
> ---
> Changes in v2:
>
> - Stop suggesting removal of variable-font packages. (Jon)
> - Rewrite changelog and add a couple of links for reference. (Randy)
> - Suggest denylisting "variable font" files for XeLaTeX in "make pdfdocs"
>   as a less invasive option.
> - Simplify message from check-variable-font.sh and expand the header
>   comments of the script.
> - Add template of fonts.conf for denylisting in the header comments.
> - Add rules for activating the XeLaTeX only fonts.conf in
>   Documentation/Makefile.

Thanks for working on this.

I've verified that the message comes up at the right time (though before
waiting a half-hour for things to fail would be better :) and that
following the advice in the script makes the build work.  I *did* have
to do a "make cleandocs" after adding the fonts.conf file, though,
before the build would succeed.

So I've applied this, for now at least, but I do wonder: might it be
better to stash this fonts.conf file in-tree somewhere and just pull it
in automatically?  Would that create problems for anybody if we were to
do so?  That might be a bit nicer than failing and making people set up
the workaround on their own.

Meanwhile, it occurred to me that it would be good to let the Fedora
folks know that this breaks, so I've filed a bug there; we'll see if
they have any thoughts on the matter as well.

Thanks,

jon





[Index of Archives]     [Kernel Newbies]     [Security]     [Netfilter]     [Bugtraq]     [Linux FS]     [Yosemite Forum]     [MIPS Linux]     [ARM Linux]     [Linux Security]     [Linux RAID]     [Samba]     [Video 4 Linux]     [Device Mapper]     [Linux Resources]

  Powered by Linux