Skip to content

utils::sqlite: restore static on test helpers - #328

Merged
ngie-eign merged 1 commit into
freebsd:masterfrom
daeho-ro:fix-gcc-build-post-312
Oct 10, 2026
Merged

ngie-eign merged 1 commit into
freebsd:masterfrom
daeho-ro:fix-gcc-build-post-312

Conversation

@daeho-ro

Copy link
Copy Markdown
Contributor

157fb89 replaced UTILS_UNUSED with [[maybe_unused]] but dropped static from the forward declarations of create_test_table() and verify_test_table(), while their definitions are still static. GCC rejects this ("was declared 'extern' and later 'static'"), so building with --enable-atf fails on Linux. CI only builds with clang, which accepts it.

Restore static and place the attribute after the declarator, as done elsewhere in 157fb89.

Fixes: 157fb89 ("Replace KYUA_ATTRIBUTE_{NORETURN,UNUSED}} ...")

@ngie-eign

Copy link
Copy Markdown
Contributor

Would you please add “Signed-off-by” to the commit? Thanks!

157fb89 replaced UTILS_UNUSED with [[maybe_unused]] but dropped
`static` from the forward declarations of create_test_table() and
verify_test_table(), while their definitions are still static.  GCC
rejects this ("was declared 'extern' and later 'static'"), so building
with --enable-atf fails on Linux.  CI only builds with clang, which
accepts it.

Restore `static` and place the attribute after the declarator, as done
elsewhere in 157fb89.

Fixes:	157fb89 ("Replace KYUA_ATTRIBUTE_{NORETURN,UNUSED}} ...")
Signed-off-by: Daeho Ro <40587651+daeho-ro@users.noreply.github.com>
@daeho-ro
daeho-ro force-pushed the fix-gcc-build-post-312 branch from 41222b1 to b7c9349 Compare October 10, 2026 15:52
@ngie-eign

Copy link
Copy Markdown
Contributor

I'm going to merge the change, but next time -- please use a non-relayed email address. In the event you deleted your GitHub account, we wouldn't be able to get a hold of you.

@ngie-eign
ngie-eign merged commit 246cc47 into freebsd:master Oct 10, 2026
8 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants