[tlbuild] hitex build failure
Johannes Hielscher
jhielscher at posteo.de
Thu Feb 24 21:35:38 CET 2022
Sorry. My source tree somehow still had been on TL SVN -r62159, where
said YYDEBUG safeguard block had been missing in hishrink.c . But your
-r62160 indeed fixed this. Now, hitex builds fine again for me here too.
Thanks! & sorry for the noise
Johannes
> Can you check that in hilexer.c and hishrink.c and
> hiparser.c you find #ifdef DEBUG
> #define YYDEBUG 1
> extern int yydebug;
> #else
> #define YYDEBUG 0
> #endif
>
> before
>
> #include "hiparser.h"
>
> and before any #if YYDEBUG
>
> and that your use of -DDEBUG is consistent. I.e not compiling
> hishrink.c with -DDEBUG and hiparser.c without -DDEBUG ?
>
> Regards
> Martin
>
> On 2/24/22 14:03, Johannes Hielscher wrote:
> > Confirmed (aarch64-linux). Martin did push an attempt to fix this
> > (TeXLive SVN -r62160), but the build failure persists.
> >
> > The immediate reason for the broken compile (not its root cause) is
> > the changed default value of YYDEBUG from 0 to 1:
> > https://tug.org/svn/texlive/trunk/Build/source/texk/web2c/hitexdir/hiparser.h?r1=61723&r2=62150&pathrev=62160
> > Reverting this one-liner change makes the builds pass. But of course
> > there is an issue underneath -- changing debug settings shouldn't
> > break a build.
> >
> > A peek into hishrink.c (created by ctangle from hiformat.w during
> > the build) shows that the CPP macro YYDEBUG is sourced from
> > hiparser.h . The variable "yydebug" is only ever declared, but
> > defined nowhere.
> >
> > When YYDEBUG==0, the preprocessor deletes this buggy code branch as
> > a whole.
> >
> > A definition of "yydebug" happens in hiparser.c:1446, however, upon
> > superficial investigation, it seems that the preprocessor somehow
> > deletes this definition too: the variable "yydebug" does not appear
> > in the object file hishrink-hiparser.o (nm finds many "yy*"
> > variables, but "yydebug" is none of them), and the final linker
> > call rightfully complains about this.
> > I don't fully understand what happens there, and why. It seems to me
> > that the extent/scoping of the YYDEBUG preprocessor conditional
> > within hiparser.c might be off, or its logical state not propagated
> > properly.
> >
> > Best,
> > Johannes
> >
> >
> > Am Wed, 23 Feb 2022 22:31:07 +0000
> > schrieb Richard Koch <koch at uoregon.edu>:
> >
> >> Same problem on macOS for arm:
> >>
> >> Undefined symbols for architecture arm64:
> >> "_yydebug", referenced from:
> >> _main in hishrink-hishrink.o
> >> ld: symbol(s) not found for architecture arm64
> >>
> >> Dick Koch
> >
>
>
More information about the tlbuild
mailing list.