[DTrace-devel] [PATCH v2 03/23] lexer: work around bug in flex <= 2.6.0

Nick Alcock nick.alcock at oracle.com
Tue Jan 16 13:07:06 UTC 2024


On 16 Jan 2024, Nick Alcock via DTrace-devel spake thusly:
> That's doable -- and also means we can build without flex at all. Maybe
> we should be consistent and include pregenerated bison output too, for
> the same reason. (Unlike the way Autoconf does it, I'll stuff the
> pregenerated output in a subdir and explicitly copy it into place iff
> needed, to avoid problems where flex or bison *is* new enough but
> timestamps stop it being used -- I think we should use them if they're
> present, to pick up any other fixes that postdate our pregenerated
> skeletons.)
>
> I'll change things accordingly.

Done, but I'm really uncertain about it -- it's noticeably more complex
than the patching approach and means we include hundreds of KiB of
pregenerated skeletons and *also* means we have to remember to update
them periodically, maybe right before release (I've arranged that doing
so is no harder than a make UPDATE_PREBUILT=t, but it's still something
we might otherwise forget). (I considered having a successful bison/flex
run with non-buggy tools do the update automatically, but that means any
of us with different tool versions -- say, running our last test on a
different distro version -- would re-commit hundreds of KiB of skeleton
unless we took care not to, each time.)

Testing on OL7, anyway: I'll post the patch, minus the generated
skeletons, as a followup once that's done. But after seeing how ugly
this is I much prefer just patching the bug out of the buggy skeleton.
One line patch versus hundreds of KiB of generated tool output allowing
for the absence of tools you need to have installed to build the kernel
anyway? No contest in my eyes...

-- 
NULL && (void)



More information about the DTrace-devel mailing list