[tlbuild] kpsesafe tests failing on macOS since last commit

Karl Berry karl at freefriends.org
Tue Jan 30 00:34:52 CET 2024


        https://tug.org/svn/texlive?view=revision&revision=69615
    broke the kpsesafe test on macOS (both on legacy 10.6/x86_64 as well
    as on 11/arm64):
        https://build.contextgarden.net/#/builders/46/builds/20/steps/4/logs/stdio

I added a new check in kpsesafe.test in that commit. Can either/both of you
just run by hand, in any convenient TL (e.g., the current release, not
necessarily the new binary):
  kpsewhich --safe-out-name=.ifoo.tex && echo bad

And I suspect it will echo bad. I.e., it's not about my change to the
code in tex-file.c (which should not have affected the result of this
test), but the test would have failed all along. That's my first
hypothesis, anyway.

For extra credit, try running the above command by hand with the
newly-built kpsewhich in ./Work. You can avoid the uselessly verbose
warning about no texmf.cnf with, e.g.,
  env KPATHSEA_WARNING=0 ./kpsewhich --safe-out-name=.ifoo.tex && echo bad

Thus the question is why the code fails to reject the filename on the
mac and is ok everywhere(?) else.  At least I don't see failures with
Norbert's autobuilds, or of course on my own machines, or presumably
with your other builds, or you would have mentioned it.

Maybe the symbol "unix" is not predefined by the mac compiler?
I suspect that would cause a lot more problems, though.
There is nothing else system-specific in that code, so far as I can see.

Probably have to run kpsewhich under a debugger, put a breakpoint at
kpathsea_name_ok, and see what is happening. The code that should reject
.ifoo.tex as an output filename is (around line 1268)
    const_string q;
    const_string qq = fname;
    while ((q = strchr (qq, '.'))) {            /* at each dot              */
      if ((q == fname || IS_DIR_SEP (*(q - 1))) /* start or / precedes dot? */
          ...
      goto not_ok;

(Or add a bunch of print statements.)

If I can log in to any of your machines, let me know ... --thanks, karl.


More information about the tlbuild mailing list.