Skip site navigation (1)Skip section navigation (2)
Date:      Thu, 14 Jul 2022 15:07:00 +0000
From:      bugzilla-noreply@freebsd.org
To:        ports-bugs@FreeBSD.org
Subject:   [Bug 265213] textproc/flex
Message-ID:  <bug-265213-7788@https.bugs.freebsd.org/bugzilla/>

next in thread | raw e-mail | index | archive | help
https://bugs.freebsd.org/bugzilla/show_bug.cgi?id=3D265213

            Bug ID: 265213
           Summary: textproc/flex
           Product: Ports & Packages
           Version: Latest
          Hardware: Any
                OS: Any
            Status: New
          Severity: Affects Only Me
          Priority: ---
         Component: Individual Port(s)
          Assignee: mandree@FreeBSD.org
          Reporter: tobias@strongswan.org
          Assignee: mandree@FreeBSD.org
             Flags: maintainer-feedback?(mandree@FreeBSD.org)

The skeleton file (flex.skl) contains some weird indentation that causes
compiler warnings, or errors if compiled with -Werror:

lex.yy.c:673:13: error: misleading indentation; statement is not part of=20
the previous 'if' [-Werror,-Wmisleading-indentation]
             if ( ! (yy_state_buf) )
             ^
lex.yy.c:671:9: note: previous statement is here
         if ( ! (yy_state_buf) )
         ^
lex.yy.c:1107:3: error: misleading indentation; statement is not part of=20
the previous 'if' [-Werror,-Wmisleading-indentation]
                 return yy_is_jam ? 0 : yy_current_state;
                 ^
lex.yy.c:1104:2: note: previous statement is here
         if ( ! yy_is_jam )

This is the case for both versions of flex, the port and the one included in
the base system (both are based on 2.6.4).  The skeleton file has been fixe=
d in
master, but three hasn't been a flex release since 2017, so not sure how/if=
 you
want to fix it.

I noticed this issue when running a configure script that uses the AC_PROG_=
LEX
macro while I had "-Werror" in CFLAGS. The macro tries to check if any libr=
ary
is required when using flex, and since the above warnings/errors made the c=
heck
fail, LEX wasn't set and the lexers were later not generated causing the bu=
ild
to fail (note that's with a configure script generated with Autoconf 2.71, =
it
isn't a problem when using Autoconf 2.69):

   checking for flex... flex
   checking for lex output file root... lex.yy
   checking for lex library... not found
   configure: WARNING: required lex library not found; giving up on flex

--=20
You are receiving this mail because:
You are the assignee for the bug.=



Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?bug-265213-7788>