On Sun, Feb 20, 2022 at 02:44:13PM +0000, Gavin Smith wrote: > > > The only thorough solution, IMO, is to assume the file names are > > encoded in the filesystem as specified by the locale's codeset. That, > > too, can be false, but at least in the absolute majority of use cases > > it will be true. The only better solution is to let the user specify > > the file-name encoding. > > The locale codeset could very easily be incorrect. Suppose somebody sets > a Latin-1 locale, should they then be unable to build Texinfo manuals > with non-ASCII UTF-8 filenames?
I checked, and, for example ls uses the locale. So a Texinfo manual with non-ASCII UTF-8 filenames will come out incorrect with ls. So I think that decoding from the locale and using the locale encoding for file names is the best. We could also use someting different for input and output file names encoding, as we can do for Texinfo, but I do not think that it would be really interesting. In GNU/Linux there should not be any issue, anyway, UTF-8 locales are preferred since quite a long time. -- Pat
