[vlc-commits] [Git][videolan/vlc][master] 2 commits: configure: add extra code checks matching GCC 14
Steve Lhomme (@robUx4)
gitlab at videolan.org
Tue May 14 07:36:29 UTC 2024
Steve Lhomme pushed to branch master at VideoLAN / VLC
Commits:
f28df587 by Steve Lhomme at 2024-05-14T07:16:15+00:00
configure: add extra code checks matching GCC 14
In gcc 14 some warnings are now turned into errors by default [1].
So of these were already errors in VLC. But there's are some that we can use.
This will ensure the VLC code is ready for the GCC 14 move.
However there's a chance some contribs don't build anymore, especially the old
unmaintained ones.
[1] https://gcc.gnu.org/gcc-14/porting_to.html#warnings-as-errors
- - - - -
2825f83e by Steve Lhomme at 2024-05-14T07:16:15+00:00
meson: match configure extra C/C++ checks
- - - - -
2 changed files:
- configure.ac
- meson.build
Changes:
=====================================
configure.ac
=====================================
@@ -1188,9 +1188,9 @@ AC_ARG_ENABLE([extra_checks],
[Turn some warnings into compilation error (default disabled)]),,
[enable_extra_checks="no"])
AS_IF([test "${enable_extra_checks}" = "yes"], [
- AX_APPEND_COMPILE_FLAGS([-Werror=missing-field-initializers -Werror=format -Werror=incompatible-pointer-types -Werror=restrict -Werror=int-conversion -Werror=return-type], [CFLAGS])
+ AX_APPEND_COMPILE_FLAGS([-Werror=missing-field-initializers -Werror=format -Werror=incompatible-pointer-types -Werror=restrict -Werror=int-conversion -Werror=return-type -Werror=implicit-int -Werror=return-mismatch -Werror=declaration-missing-parameter-type], [CFLAGS])
AC_LANG_PUSH(C++)
- AX_APPEND_COMPILE_FLAGS([-Werror=missing-field-initializers -Werror=format -Werror=return-type], [CXXFLAGS])
+ AX_APPEND_COMPILE_FLAGS([-Werror=missing-field-initializers -Werror=format -Werror=return-type -Werror=return-mismatch], [CXXFLAGS])
AC_LANG_POP(C++)
])
=====================================
meson.build
=====================================
@@ -489,11 +489,16 @@ add_project_arguments(cc.get_supported_arguments([
if get_option('extra_checks')
add_project_arguments(cc.get_supported_arguments([
'-Werror=missing-field-initializers',
- '-Werror=format'
+ '-Werror=format',
+ '-Werror=return-type',
+ '-Werror=return-mismatch'
]), language: ['c', 'cpp'])
add_project_arguments(cc.get_supported_arguments([
'-Werror=incompatible-pointer-types',
- '-Werror=restrict'
+ '-Werror=restrict',
+ '-Werror=int-conversion',
+ '-Werror=implicit-int',
+ '-Werror=declaration-missing-parameter-type'
]), language: ['c'])
endif
View it on GitLab: https://code.videolan.org/videolan/vlc/-/compare/2ddd86c84418688ae977e981c5be31db40e470e2...2825f83e666521ef616f6f581735e06a201816db
--
This project does not include diff previews in email notifications.
View it on GitLab: https://code.videolan.org/videolan/vlc/-/compare/2ddd86c84418688ae977e981c5be31db40e470e2...2825f83e666521ef616f6f581735e06a201816db
You're receiving this email because of your account on code.videolan.org.
VideoLAN code repository instance
More information about the vlc-commits
mailing list