Bug: On Windows, Unicode file name not supported by tex binaries

Akira Kakuto kakuto at jcom.zaq.ne.jp
Tue Nov 14 23:54:40 CET 2023


On 2023/11/14 22:36, ttk at t-lab.opal.ne.jp wrote:
> Thank you for your reports and helpful discussion.
> 
> I have confirmed the error with plain tex inputs on Msys2 mingw64, Windows 11.
> However, the results were found also on Windows Subsystem for Linux (Ubuntu).
> 
> engine:
> (A) pdftex -ini -interaction nonstopmode -jobname=foo BananaXXX.tex
> (B) euptex -ini -interaction nonstopmode -jobname=foo BananaXXX.tex
> (C) xetex -ini -interaction nonstopmode -jobname=foo BananaXXX.tex
> 
> file name:
> (1) Bananaбанан.tex (2byte UTF-8)
> (2) Bananaバナナ.tex (3byte UTF-8)
> (3) Banana🍌.tex (4byte UTF-8)
> 
> The input file is plain tex with UTF-8 text ::
> ```
> \catcode`\{=1
> \catcode`\}=2
> \immediate\write16{Bananaбананバナナ🍌}
> \end
> ```
> 
> The results on my environment (both Msys2, WSL)
> (A) : OK for (1)(2)(3)
> (B) : OK for (1)(2)(3)
> (C) : OK for (1)(2), fail for (3)
> 
> The treatment of Unicode file name on Windows are very different from that of Linux.
> However, the error seems not caused by the difference.
> More study is required.

Probably xetex does not support unicode characters >= U+10000 as an input file name.
See name_of_file in xetex.ch.

Best,
Akira



More information about the tex-live mailing list.