Add compiler warning flag -Wextra and fix related warnings.

Note: some of these warnings are enabled by a combination of -Wunused
(added earlier) and -Wextra.

Cherry-picked from aomedia/master: 4790a69

Change-Id: I322a1366bd4fd6c0dec9e758c2d5e88e003b1cbf
This commit is contained in:
Urvang Joshi
2016-07-14 12:33:48 -07:00
parent bffc0b5748
commit d71a231c49
21 changed files with 85 additions and 48 deletions

4
configure vendored
View File

@@ -617,6 +617,10 @@ process_toolchain() {
check_add_cflags -Wuninitialized
check_add_cflags -Wunused
check_add_cflags -Wsign-compare
# Enabling the following warning (in combination with -Wunused above)
# for C++ generates errors in third_party code including googletest and
# libyuv. So enable it only for C code.
check_cflags "-Wextra" && add_cflags_only "-Wextra"
# Enabling the following warning for C++ generates some useless warnings
# about some function parameters shadowing class member function names.
# So, only enable this warning for C code.