On Fri, Oct 31, 2025 at 08:39:59PM +0000, Gavin Smith wrote:
> I think this is a good idea. I can't remember if this issue has ever
> come up before but I suspect it might have. I suspect there may have
> been an issue with the test suite and getting consistent test results
> but if so, that is something we should work around.
So I can see the directories are stripped off in Texinfo/ParserNonXS.pm
in _input_push_file. The directories are returned by the function but
not stored in the input structure ($self->{'input'}).
I checked the source code of Texinfo 5.2 and found the following in
parse_texi_file in Texinfo/Parser.pm:
my ($directories, $suffix);
($file_name, $directories, $suffix) = fileparse($file_name)
if ($self->{'TEST'});
There, the directories were only stripped off if "TEST" was set.
Eventually I found the following ChangeLog entry:
2020-10-21 Gavin Smith <[email protected]>
Remove TEST setting for parser
* tp/Texinfo/Common.pm (%default_customization_values):
Remove 'TEST'.
* tp/Texinfo/ParserNonXS.pm (parse_texi_text, parse_texi_file)
(parse_texi_line, _end_line):
Remove code referring to the TEST setting. This means that
the 'input_directory' value is always set and all leading
directory components will be removed from the input file name
in messages.
* tp/Texinfo/Convert/HTML.pm (_load_htmlxref_files): Make
adding the input directory to the search path for htmlxref.cnf
conditional on TEST.
(I had dimly remembered that this might have been a change I was
responsible for.)
Unfortunately it will not be a quick change for me to revert as
there has been a considerable amount of churn in the code since
then (and most of it exists in at least 2 versions, both C and Perl),
and I am now not very familiar with the code.
I will slowly start looking at how this could be fixed in the coming days,
but I will wait to see if Patrice has any suggestions first.