mirror of
https://github.com/mpv-player/mpv.git
synced 2024-09-20 12:02:23 +02:00
configure: Use -Werror-implicit-function-declaration with GCC
Add -Werror-implicit-function-declaration to the default compiled flags used with GCC. Add the option through a new variable ERRORFLAGS instead of the existing WARNFLAGS to avoid using it in configure tests. I think it's overall preferable not to fail tests because of the warning - in some case this could cause a compilation failure later, but on the other hand it could be just an unreliable test triggering the warning and even if it does fail those are likely cases worth closer investigation.
This commit is contained in:
parent
6075b4d4b2
commit
b7f5744053
5
configure
vendored
5
configure
vendored
@ -2321,6 +2321,7 @@ elif test -z "$CFLAGS" ; then
|
||||
else
|
||||
CFLAGS="-O2 $_march $_mcpu $_pipe -ffast-math -fomit-frame-pointer"
|
||||
WARNFLAGS="-Wall -Wno-switch -Wno-parentheses -Wpointer-arith -Wredundant-decls"
|
||||
ERRORFLAGS="-Werror-implicit-function-declaration"
|
||||
extra_ldflags="$extra_ldflags -ffast-math"
|
||||
fi
|
||||
else
|
||||
@ -6654,8 +6655,8 @@ INSTALL = $_install
|
||||
INSTALLSTRIP = $_install_strip
|
||||
WINDRES = $_windres
|
||||
|
||||
CFLAGS = $WARNFLAGS $WARN_CFLAGS $CFLAGS $extra_cflags
|
||||
CXXFLAGS = $WARNFLAGS $CXXFLAGS $extra_cflags $extra_cxxflags
|
||||
CFLAGS = $WARNFLAGS $ERRORFLAGS $WARN_CFLAGS $CFLAGS $extra_cflags
|
||||
CXXFLAGS = $WARNFLAGS $ERRORFLAGS $CXXFLAGS $extra_cflags $extra_cxxflags
|
||||
DEPFLAGS = $DEPFLAGS
|
||||
|
||||
CFLAGS_LIBDVDCSS = $cflags_libdvdcss
|
||||
|
Loading…
Reference in New Issue
Block a user