On Sat, Sep 28, 2024 at 01:54:12PM +0100, Gavin Smith wrote: > New: > > ‘./’ > (the current directory) > > ‘leading input file path directory’ > If there is a leading directory and it is not the current > directory. For example, if the input file is > ‘some/dir/mymanual.texi’, ‘htmlxref.cnf’ is searched for in > ‘some/dir’. > > ‘./.texinfo/’ > (under the current directory) > > ‘XDG_CONFIG_HOME/texinfo’ > (with ‘XDG_CONFIG_HOME’ an environment variable) > > ‘~/.config/texinfo/’ > (where ‘~’ is the current user's home directory, only if > ‘XDG_CONFIG_HOME’ is not set) > > ‘SYSCONFDIR/xdg/texinfo/’ > (where SYSCONFDIR is the system configuration directory specified > at compile-time, e.g., ‘/usr/local/etc’) > > ‘XDG_CONFIG_DIRS/texinfo’ > (for each directory in the ‘:’ delimited ‘XDG_CONFIG_DIRS’ > environment variable) > > ‘DATADIR/texinfo/’ > (specified at compile time, e.g., ‘/usr/local/share’) > > Changes: > > * Remove XDG_DATA_DIRS completely. We do not need to allow or encourage > users to add files to /usr/share/texinfo or to add other directories to > check. It is enough to allow users to add configuration files > to /etc/xdg/texinfo, or to change XDG_CONFIG_DIRS.
Ok. I agree, and although in that case, setting XDG_DATA_DIRS cannot be used to help make DATADIR/texinfo/ a shared directory for diverse implementations it is not an issue, as it is simpler and having DATADIR/texinfo/ as a shared directory for diverse implementations should primilarily be achieved by setting using the same DATADIR accross software packages. > * Move SYSCONFDIR before XDG_CONFIG_DIRS. This allows a user-configured > value to take priority over a value set by a distribution at login. To me this goes somewhat against the spirit of the XDB base directory specification, but I think that it makes sense as it seems that in practice the distributions tend to make XDG_CONFIG_DIRS a system set variable, and it is not so easy to have the user set it, it seems somewhat uncommon, and in practice not to be clearly recommended. Another argument is that we do not install anything in SYSCONFDIR/xdg/texinfo/, so it is all the more relevant to set it before XDG_CONFIG_DIRS/texinfo where something may be installed by some other software/administrator. This is quite unrelated, but I still think that we should split current DATADIR/texinfo content in two, add DATADIR/texi2any for Perl modules, js files, Perl external modules, ext and init files shipped with texi2any. That way we can use DATADIR/texinfo only for files that could, at least theoretically, be shared across implementations. That would be htmlxref.cnf files, maybe the Texinfo DTD, could also be some icon images for directions, CSS files examples, and, in a distant future, even init files if they can be shared among implementations. -- Pat