Skip site navigation (1)Skip section navigation (2)
Date:      Wed, 15 Sep 2021 12:12:52 +0000
From:      bugzilla-noreply@freebsd.org
To:        ports-bugs@FreeBSD.org
Subject:   [Bug 258512] net/ifdepd: fix build with clang 13
Message-ID:  <bug-258512-7788@https.bugs.freebsd.org/bugzilla/>

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

            Bug ID: 258512
           Summary: net/ifdepd: fix build with clang 13
           Product: Ports & Packages
           Version: Latest
          Hardware: Any
                OS: Any
            Status: New
          Severity: Affects Some People
          Priority: ---
         Component: Individual Port(s)
          Assignee: ports-bugs@FreeBSD.org
          Reporter: dim@FreeBSD.org
                CC: alex@hugo.bmg.gv.at
                CC: alex@hugo.bmg.gv.at
             Flags: maintainer-feedback?(alex@hugo.bmg.gv.at)

During an exp-run for llvm 13 (see bug 258209), it turned out that net/ifde=
pd
fails to build with clang 13:

cc  -O2 -pipe  -fstack-protector-strong -fno-strict-aliasing  -Wall
-Wnested-externs -Wpointer-arith -Winline -Wcast-qual -Wredundant-decls -c
ifdepd.c -o ifdepd.o
ifdepd.c:420:4: warning: misleading indentation; statement is not part of t=
he
previous 'if' [-Wmisleading-indentation]
          free(d_ints);
          ^
ifdepd.c:418:2: note: previous statement is here
        if (D)
        ^
ifdepd.c:434:4: warning: misleading indentation; statement is not part of t=
he
previous 'if' [-Wmisleading-indentation]
          free(s_ints);
          ^
ifdepd.c:432:2: note: previous statement is here
        if (S)
        ^
2 warnings generated.
cc -O2 -pipe  -fstack-protector-strong -fno-strict-aliasing  -Wall
-Wnested-externs -Wpointer-arith -Winline -Wcast-qual -Wredundant-decls -o
ifdepd ifdepd.o
ld: error: undefined symbol: cleanup
>>> referenced by ifdepd.c
>>>               ifdepd.o:(main)
>>> referenced by ifdepd.c
>>>               ifdepd.o:(main)
>>> referenced by ifdepd.c
>>>               ifdepd.o:(main)
>>> referenced 1 more times
cc: error: linker command failed with exit code 1 (use -v to see invocation)
*** Error code 1

The warnings about misleading indentation are indicating an actual bug, whi=
ch
can be fixed by adding a few braces. The link error is because ifdepd uses =
an
inline function without either static or extern specifier.

--=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-258512-7788>