Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Compilation will fail in future (-Werror=deprecated-non-prototype issues are forbidden in C23 (C2x) #206

Open
ConiKost opened this issue Nov 13, 2022 · 0 comments

Comments

@ConiKost
Copy link

Starting with Clang-16, there is a warning, which will be in future a fatal and cause compilation to fail.

-Werror=deprecated-non-prototype issues are forbidden in C23 (C2x) so at the latest, this will become a problem for us when compilers switch in ~2025/2026/2027 to C23 as default, but it might become a problem sooner if Clang decides to change.

mkdir -p /var/tmp/portage/dev-lua/luaossl-20220711/work/luaossl-rel-20220711-lua5-1/src/5.1
mkdir -p /var/tmp/portage/dev-lua/luaossl-20220711/work/luaossl-rel-20220711-lua5-1/src/5.1
clang -std=gnu99 -fPIC -g -Wall -Wextra -Wno-missing-field-initializers -Wno-initializer-overrides -Wno-unused -Wno-dollar-in-identifier-extension -pipe -march=native -fno-diagnostics-color -O2 -Werror=implicit-function-declaration -Werror=implicit-int  -I/usr/include/lua5.1  -DHAVE_CONFIG_H -DCOMPA
clang -std=gnu99 -fPIC -g -Wall -Wextra -Wno-missing-field-initializers -Wno-initializer-overrides -Wno-unused -Wno-dollar-in-identifier-extension -pipe -march=native -fno-diagnostics-color -O2 -Werror=implicit-function-declaration -Werror=implicit-int  -I/usr/include/lua5.1  -DHAVE_CONFIG_H -DCOMPA
/var/tmp/portage/dev-lua/luaossl-20220711/work/luaossl-rel-20220711-lua5-1/src/openssl.c:1188:18: error: passing arguments to a function without a prototype is deprecated in all versions of C and is not supported in C2x [-Werror,-Wdeprecated-non-prototype]
                if (0 == optcmp(optlist[i], optname))
@ConiKost ConiKost changed the title Compilation will fail in future Compilation will fail in future (-Werror=deprecated-non-prototype issues are forbidden in C23 (C2x) Nov 13, 2022
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

2 participants