Fix -Wshadow.

This still disables the warning for glmark2 instead of fixing it, to
avoid needing to upstream a patch.

Bug: chromium:794619
Change-Id: Ice602996041d6090c9b09ee81c8ed095c4fa6b2e
Reviewed-on: https://chromium-review.googlesource.com/c/angle/angle/+/3179860
Reviewed-by: Shahbaz Youssefi <syoussefi@chromium.org>
Commit-Queue: Shahbaz Youssefi <syoussefi@chromium.org>
This commit is contained in:
Peter Kasting
2021-09-23 09:50:46 -07:00
committed by Angle LUCI CQ
parent e1a9af6ae1
commit 4f2b299521
9 changed files with 141 additions and 87 deletions

View File

@@ -42,6 +42,12 @@ raw_glmark_data_path = rebase_path(glmark_data_path, root_build_dir)
config("glmark2_common_config") {
defines = [ "GLMARK_DATA_PATH=\"${raw_glmark_data_path}\"" ]
include_dirs = [ "src/src" ]
cflags = []
if (is_clang) {
cflags += [ "-Wno-shadow" ]
}
if (is_win) {
include_dirs += [ "src/src/include" ]
@@ -49,7 +55,7 @@ config("glmark2_common_config") {
defines += [ "_USE_MATH_DEFINES" ]
if (!is_clang) {
cflags = [
cflags += [
# MSVC warns about the copyright character being illegal.
"/wd4828",