Opened 3 weeks ago
Closed 2 weeks ago
#6077 closed enhancement (fixed)
flex-2.6.11
| Reported by: | Bruce Dubbs | Owned by: | lfs-book |
|---|---|---|---|
| Priority: | normal | Milestone: | 13.2 |
| Component: | Book | Version: | git |
| Severity: | normal | Keywords: | |
| Cc: |
Description
New point version.
Change History (10)
comment:1 by , 3 weeks ago
comment:4 by , 3 weeks ago
| Summary: | flex-2.6.10 → flex-2.6.11 |
|---|
comment:5 by , 3 weeks ago
This breaks the build of iproute2:
emp_ematch.l:35:69: error: macro 'yyunput' passed 2 arguments, but takes just 1
35 | static void __attribute__ ((unused)) yyunput (int c,char *buf_ptr );
| ^
emp_ematch.lex.c:466:9: note: macro 'yyunput' defined here
466 | #define yyunput(c) yyunput_r( c, (yytext_ptr) )
| ^~~~~~~
emp_ematch.l:35:39: error: variable or field 'yyunput' declared void
35 | static void __attribute__ ((unused)) yyunput (int c,char *buf_ptr );
| ^~~~~~~
emp_ematch.lex.c:1841:13: warning: 'yyunput_r' defined but not used [-Wunused-function]
1841 | static void yyunput_r (int c, char * yy_bp )
| ^~~~~~~~~
make[1]: *** [../config.mk:40: emp_ematch.lex.o] Error 1
There's also a report that it breaks GCC snapshot builds: https://github.com/westes/flex/issues/856
comment:6 by , 3 weeks ago
Another report of more breakage: https://github.com/westes/flex/issues/858
comment:7 by , 3 weeks ago
I'm planning on doing an update to LFS tomorrow, but will omit the flex update until this is fixed by upstream.
comment:8 by , 2 weeks ago
Now version 2.6.13.
Tests no longer fail. The build issues with iproute2 and doxygen are fixed. Doing a build of libreoffice now to test that.
comment:9 by , 2 weeks ago
flex NEWS
* Noteworthy changes in release 2.6.13 (2026-11-14) [stable]
** scanner
*** A scanner built with %array no longer reads or writes before the
start of its input buffer when yymore() is used after the scanner
switches buffers, after unput() has pushed text back to the start
of the buffer, or after the program has lengthened yytext. Since
flex 2.6.5 the scanner could point yytext before the buffer, and the
next refill or yyless() then went outside it. The text saved by
yymore() now ends at the start of the buffer.
*** A scanner with a very large set of rules is built correctly again.
Since flex 2.6.5, some of its tables could be given an element type
too small for the numbers stored in them. A C++ compiler rejected
the generated file with "narrowing conversion" errors. A C compiler
only warned, and in our test the scanner then looped forever.
Doxygen's code scanner is one example. Flex now chooses the types
as 2.6.4 did, and for a table of offsets or indexes by the largest
value it can hold. Two other tables of such a scanner are also half
the size they had become.
*** A scanner that loads its tables from a file works again on 32-bit
systems. Since flex 2.6.5 the loader took a table of indexes for a
table of integers where a pointer is four bytes wide, and refused
the file with "table id not found in map". The tests for tables
files failed on i686 and on 32-bit ARM.
* Noteworthy changes in release 2.6.12 (2026-11-14) [stable]
** scanner
*** A program can declare yyunput() itself again, as it could with
flex 2.6.4. Flex 2.6.5 made yyunput a one-argument macro, so a
declaration such as "static void yyunput (int c, char *buf_ptr);",
which some programs write to silence an unused-function warning,
no longer compiled. The scanner's function is called yyunput again,
with the arguments it had in 2.6.4, and in a C++ scanner it is the
yyFlexLexer member of that name again. The macro is gone from the
default back end. In a rule's action, yyunput(c) is still accepted
and works as unput(c); anywhere else, use unput(c).
*** A program can have its own functions named yybegin, yyecho,
yystart, yyatbol or yysetbol, as GCC does with yybegin, and they
compile again. Flex 2.6.5 defined these names as macros, which
rewrote the program's declarations and definitions. The default
back end no longer defines them. Inside a rule's action flex still
accepts them and writes the old interface in their place: BEGIN,
ECHO, YY_START, YY_AT_BOL() and yy_set_bol(). Outside an action,
use the old interface.
*** A C++ scanner built with %option nodefault compiles again. Flex
2.6.5 and later generated a call to yypanic(), which a C++ scanner
does not have, for input that no rule matches. It now goes through
YY_FATAL_ERROR, and so to LexerError(), as in 2.6.4.
*** A program can call yy_fatal_error(), the 2.6.4 name of yypanic(),
again. YY_BUF_SIZE and YY_READ_BUF_SIZE are defined before the
scanner's first section again, so the program can use them there.
*** A non-reentrant C scanner whose rules never need backing up no
longer declares the two unused variables yy_last_accepting_state
and yy_last_accepting_cpos. Flex 2.6.5 and later declared them
anyway, so building such a scanner, for example one made with
%option full, stopped a program that compiles with -Werror, such
as the Kconfig lexer in the Xen hypervisor.
** test
*** "make check" now tests only the build of flex. The tests of the
maintainer scripts in tools/ were part of it, and three of them
build small git repositories, so a build from a tarball failed
where git was not installed. They now run with "make check-tools".
* Noteworthy changes in release 2.6.11 (2026-11-12) [stable]
** scanner
*** A C++ scanner now frees every buffer left on its buffer stack when
it is destroyed. Before, it freed only the top one, so each buffer
added with yypush_buffer_state() and not yet removed leaked its
memory. The C scanners already did this in yylex_destroy().
** test
*** The scan_length tests could fail on some architectures, such as
aarch64, because two variables in each test could hold wrong values
after the test recovered from the expected fatal error. They are
now declared so that the compiler cannot do that.
* Noteworthy changes in release 2.6.10 (2026-11-12) [stable]
** scanner
*** A generated scanner compiles again where the C library's <stdio.h>
does not define BUFSIZ, as in a freestanding build such as GRUB's.
Flex 2.6.5 and later sized each read with BUFSIZ, so the scanner
failed to compile there. It now uses BUFSIZ when it is defined and
8192 when it is not, in both the default and the c99 back end. In
the default back end, a definition of YY_READ_BUF_SIZE still takes
precedence over both.
* Noteworthy changes in release 2.6.9 (2026-11-11) [stable]
** scanner
*** Four names that programs used with flex 2.6.4, and that flex 2.6.5
changed, work again. The global debug flag is again called
yy_flex_debug (with a prefix, the prefix followed by _flex_debug),
so a program that declares it with its own extern declaration links
again; in a C++ scanner it is again the yy_flex_debug member of
yyFlexLexer. The buffer structure's member that records whether the
scanner is at the beginning of a line is again called yy_at_bol. A
definition of YY_READ_BUF_SIZE in the scanner file is used again.
Defining FLEXINT_H again keeps the scanner from declaring its own
integer types, for a program that supplies them. The new names
yyflexdebug and yyatbol() continue to work.
*** A generated scanner compiles again in a program that declares
YY_BUFFER_STATE itself, guarded by YY_TYPEDEF_YY_BUFFER_STATE, as it
did with flex 2.6.4. Flex 2.6.5 declared its new yybuffer type under
that same guard, so such a program got no yybuffer and the scanner
failed to compile. The two types now have separate guards.
* Noteworthy changes in release 2.6.8 (2026-11-11) [stable]
** build
*** Flex now builds when configured with --disable-nls. It failed to
compile with a compiler that treats a call to an undeclared function
as an error, because the report of backing-up states used a function
that is only declared when translations are enabled.
* Noteworthy changes in release 2.6.7 (2026-11-11) [stable]
** scanner
*** A generated scanner now compiles when the program is built in a
strict ISO C mode, such as -std=c99, with a compiler that treats a
call to an undeclared function as an error (GCC 14 and later, Clang
16 and later). Those modes hide a function the scanner needs to tell
whether its input is a terminal, and the scanner now declares it
itself. This also fixes "make check" failing in flex 2.6.6 with
those compilers.
* Noteworthy changes in release 2.6.6 (2026-11-11) [stable]
** build
*** tools/bootstrap-flex now builds flex 2.6.5 and checks its signature
against the flex release key, as well as its hash. It needs gpg.
** scanner
*** A generated scanner no longer fails to compile in a program that
defines a macro named fallthrough, as the Linux kernel's headers do.
Flex 2.6.5 wrote the fall-through marker with that plain name, so
the macro was expanded inside the scanner. The scanner now uses the
reserved spelling __fallthrough__ for the attribute.
* Noteworthy changes in release 2.6.5 (2026-11-10) [stable]
** build
*** The ChangeLog that tools/git2cl writes is now valid UTF-8. Author
names with accented characters used to come out in a different
encoding from the rest of the file, and the script printed "Wide
character in print" warnings.
*** The ChangeLog in the nightly distribution tarballs is no longer
empty, and the nightly build now fails if it would be.
*** The script that updates the translations from the Translation
Project now converts any .po file that is not in UTF-8 to UTF-8, so
every translation in the source tree uses the same encoding.
*** The version and date in the header of each release's section of this
NEWS file, and the version in configure.ac, are now set together by
a script when the release is made. A release candidate gets its own
header in the same way.
*** Regenerating the build files now needs gettext 0.23 or later. The
po/ directory can then be built in parallel with make -j. Building
from a release tarball is not affected.
*** A new script, tools/bootstrap-flex, builds and installs the previous
release of flex. Building flex from a git checkout needs a flex that
is already installed, and the script lets a system without one get
started.
*** Building flex no longer rewrites the .po translation files.
*** A race condition that could build flex twice at the same time during
a parallel make has been fixed.
*** Releases are now made and signed by a GitHub workflow. Each release
has a detached signature for the tarballs and for a SHA256SUMS file,
and a copy of the public key. The key is new and is not connected to
the key that signed 2.6.4. The new key's fingerprint is 56D6 64C7
0CC2 364C F516 4914 B7DF E8BB 6C24 1FED. It is published on
keys.openpgp.org, at flexlexer.org, and in the README.
*** Source files now carry SPDX license identifiers.
*** The replacement malloc in lib/ now has a full prototype.
*** Automated builds now run on GitHub Actions instead of travis-ci, and
nightly distribution tarballs are built there.
*** The configure script accepts the space that AC_PROG_LEX puts before
the parentheses when checking for yymore and yyreject. It also no
longer uses obsolete Autoconf macros, and the macro that finds the C
compiler for the build machine has been updated to fix problems with
*** The replacement malloc in lib/ now has a full prototype.
executable file names when cross compiling.
*** Various edge cases, mostly involving out-of-tree builds have been
accounted for in the autotools build system.
*** The build now has flex build its own scanner a second time and fails
if the result differs from the first. This check runs only for
native builds.
*** The GitHub Actions workflows now use pinned versions of the actions,
have read-only permissions, and are kept up to date by dependabot.
*** The minimum versions of the Autotools needed to build flex are now
correct and documented, and autogen.sh is more reliable in finding
libtoolize.
*** Flex no longer searches PATH for m4 itself and leaves that to the
system. This avoids a failure on 32-bit systems that read file
systems with 64-bit inode numbers.
Note:
See TracTickets
for help on using tickets.

Three tests fail in LFS because the lack of git: