summaryrefslogtreecommitdiff
path: root/testing
diff options
context:
space:
mode:
authorBen Murdoch <benm@google.com>2013-07-10 11:40:50 +0100
committerBen Murdoch <benm@google.com>2013-07-10 11:40:50 +0100
commiteb525c5499e34cc9c4b825d6d9e75bb07cc06ace (patch)
treed908ce4bfe1717d2cd53f41327d8b9ba8304355f /testing
parent3c54152607de4272b3da0c146b71dcba8a0e5610 (diff)
downloadchromium_org-eb525c5499e34cc9c4b825d6d9e75bb07cc06ace.tar.gz
Merge from Chromium at DEPS revision r210036
This commit was generated by merge_to_master.py. Change-Id: Ib0e33a83ad5dfa541481e83d7acfc6970e68f471
Diffstat (limited to 'testing')
-rw-r--r--testing/android/OWNERS1
-rw-r--r--testing/gtest.gyp24
-rw-r--r--testing/gtest_prod.target.darwin-arm.mk95
-rw-r--r--testing/gtest_prod.target.darwin-mips.mk94
-rw-r--r--testing/gtest_prod.target.darwin-x86.mk98
-rw-r--r--testing/gtest_prod.target.linux-arm.mk95
-rw-r--r--testing/gtest_prod.target.linux-mips.mk94
-rw-r--r--testing/gtest_prod.target.linux-x86.mk98
-rwxr-xr-xtesting/test_env.py9
9 files changed, 556 insertions, 52 deletions
diff --git a/testing/android/OWNERS b/testing/android/OWNERS
index ab2f45f337..87d5d22497 100644
--- a/testing/android/OWNERS
+++ b/testing/android/OWNERS
@@ -1,3 +1,2 @@
bulach@chromium.org
-nileshagrawal@chromium.org
yfriedman@chromium.org
diff --git a/testing/gtest.gyp b/testing/gtest.gyp
index 42cf571364..0598e9b4c9 100644
--- a/testing/gtest.gyp
+++ b/testing/gtest.gyp
@@ -95,6 +95,30 @@
],
},
}],
+ ['OS=="ios" and asan==1', {
+ 'direct_dependent_settings': {
+ 'target_conditions': [
+ # Package the ASan runtime dylib into the test app bundles.
+ ['_type=="executable"', {
+ 'postbuilds': [
+ {
+ 'variables': {
+ # Define copy_asan_dylib_path in a variable ending in
+ # _path so that gyp understands it's a path and
+ # performs proper relativization during dict merging.
+ 'copy_asan_dylib_path':
+ '<(DEPTH)/build/mac/copy_asan_runtime_dylib.sh',
+ },
+ 'postbuild_name': 'Copy ASan runtime dylib',
+ 'action': [
+ '<(copy_asan_dylib_path)',
+ ],
+ },
+ ],
+ }],
+ ],
+ },
+ }],
['os_posix == 1', {
'defines': [
# gtest isn't able to figure out when RTTI is disabled for gcc
diff --git a/testing/gtest_prod.target.darwin-arm.mk b/testing/gtest_prod.target.darwin-arm.mk
index 88e05c5f8f..f36142cdd5 100644
--- a/testing/gtest_prod.target.darwin-arm.mk
+++ b/testing/gtest_prod.target.darwin-arm.mk
@@ -26,7 +26,7 @@ LOCAL_SRC_FILES :=
# Flags passed to both C and C++ files.
-MY_CFLAGS := \
+MY_CFLAGS_Debug := \
-fstack-protector \
--param=ssp-buffer-size=4 \
-fno-exceptions \
@@ -61,9 +61,7 @@ MY_CFLAGS := \
-fdata-sections \
-ffunction-sections
-MY_CFLAGS_C :=
-
-MY_DEFS := \
+MY_DEFS_Debug := \
'-DANGLE_DX11' \
'-D_FILE_OFFSET_BITS=64' \
'-DUSE_LINUX_BREAKPAD' \
@@ -85,18 +83,95 @@ MY_DEFS := \
'-DWTF_USE_DYNAMIC_ANNOTATIONS=1' \
'-D_DEBUG'
-LOCAL_CFLAGS := $(MY_CFLAGS_C) $(MY_CFLAGS) $(MY_DEFS)
# Include paths placed before CFLAGS/CPPFLAGS
-LOCAL_C_INCLUDES := \
+LOCAL_C_INCLUDES_Debug := \
+ $(PWD)/frameworks/wilhelm/include \
+ $(PWD)/bionic \
+ $(PWD)/external/stlport/stlport
+
+
+# Flags passed to only C++ (and not C) files.
+LOCAL_CPPFLAGS_Debug := \
+ -fno-rtti \
+ -fno-threadsafe-statics \
+ -fvisibility-inlines-hidden \
+ -Wno-deprecated \
+ -Wno-abi \
+ -Wno-error=c++0x-compat \
+ -Wno-non-virtual-dtor \
+ -Wno-sign-promo \
+ -Wno-non-virtual-dtor
+
+
+# Flags passed to both C and C++ files.
+MY_CFLAGS_Release := \
+ -fstack-protector \
+ --param=ssp-buffer-size=4 \
+ -fno-exceptions \
+ -fno-strict-aliasing \
+ -Wno-unused-parameter \
+ -Wno-missing-field-initializers \
+ -fvisibility=hidden \
+ -pipe \
+ -fPIC \
+ -Wno-format \
+ -fno-tree-sra \
+ -fuse-ld=gold \
+ -Wno-psabi \
+ -ffunction-sections \
+ -funwind-tables \
+ -g \
+ -fstack-protector \
+ -fno-short-enums \
+ -finline-limit=64 \
+ -Wa,--noexecstack \
+ -U_FORTIFY_SOURCE \
+ -Wno-extra \
+ -Wno-ignored-qualifiers \
+ -Wno-type-limits \
+ -Wno-address \
+ -Wno-format-security \
+ -Wno-return-type \
+ -Wno-sequence-point \
+ -Os \
+ -fno-ident \
+ -fdata-sections \
+ -ffunction-sections \
+ -fomit-frame-pointer
+
+MY_DEFS_Release := \
+ '-DANGLE_DX11' \
+ '-D_FILE_OFFSET_BITS=64' \
+ '-DUSE_LINUX_BREAKPAD' \
+ '-DNO_TCMALLOC' \
+ '-DDISABLE_NACL' \
+ '-DCHROMIUM_BUILD' \
+ '-DUSE_LIBJPEG_TURBO=1' \
+ '-DUSE_PROPRIETARY_CODECS' \
+ '-DENABLE_GPU=1' \
+ '-DUSE_OPENSSL=1' \
+ '-DENABLE_EGLIMAGE=1' \
+ '-DENABLE_LANGUAGE_DETECTION=1' \
+ '-DANDROID' \
+ '-D__GNU_SOURCE=1' \
+ '-DUSE_STLPORT=1' \
+ '-D_STLP_USE_PTR_SPECIALIZATIONS=1' \
+ '-DCHROME_BUILD_ID=""' \
+ '-DNDEBUG' \
+ '-DNVALGRIND' \
+ '-DDYNAMIC_ANNOTATIONS_ENABLED=0'
+
+
+# Include paths placed before CFLAGS/CPPFLAGS
+LOCAL_C_INCLUDES_Release := \
$(PWD)/frameworks/wilhelm/include \
$(PWD)/bionic \
$(PWD)/external/stlport/stlport
-LOCAL_C_INCLUDES := $(GYP_COPIED_SOURCE_ORIGIN_DIRS) $(LOCAL_C_INCLUDES)
# Flags passed to only C++ (and not C) files.
-LOCAL_CPPFLAGS := \
+LOCAL_CPPFLAGS_Release := \
-fno-rtti \
-fno-threadsafe-statics \
-fvisibility-inlines-hidden \
@@ -107,6 +182,10 @@ LOCAL_CPPFLAGS := \
-Wno-sign-promo \
-Wno-non-virtual-dtor
+
+LOCAL_CFLAGS := $(MY_CFLAGS_$(GYP_CONFIGURATION)) $(MY_DEFS_$(GYP_CONFIGURATION))
+LOCAL_C_INCLUDES := $(GYP_COPIED_SOURCE_ORIGIN_DIRS) $(LOCAL_C_INCLUDES_$(GYP_CONFIGURATION))
+LOCAL_CPPFLAGS := $(LOCAL_CPPFLAGS_$(GYP_CONFIGURATION))
### Rules for final target.
# Add target alias to "gyp_all_modules" target.
.PHONY: gyp_all_modules
diff --git a/testing/gtest_prod.target.darwin-mips.mk b/testing/gtest_prod.target.darwin-mips.mk
index 9e514b11fe..e1cdc8e6c9 100644
--- a/testing/gtest_prod.target.darwin-mips.mk
+++ b/testing/gtest_prod.target.darwin-mips.mk
@@ -26,7 +26,7 @@ LOCAL_SRC_FILES :=
# Flags passed to both C and C++ files.
-MY_CFLAGS := \
+MY_CFLAGS_Debug := \
-fstack-protector \
--param=ssp-buffer-size=4 \
\
@@ -61,9 +61,7 @@ MY_CFLAGS := \
-fdata-sections \
-ffunction-sections
-MY_CFLAGS_C :=
-
-MY_DEFS := \
+MY_DEFS_Debug := \
'-DANGLE_DX11' \
'-D_FILE_OFFSET_BITS=64' \
'-DNO_TCMALLOC' \
@@ -84,18 +82,16 @@ MY_DEFS := \
'-DWTF_USE_DYNAMIC_ANNOTATIONS=1' \
'-D_DEBUG'
-LOCAL_CFLAGS := $(MY_CFLAGS_C) $(MY_CFLAGS) $(MY_DEFS)
# Include paths placed before CFLAGS/CPPFLAGS
-LOCAL_C_INCLUDES := \
+LOCAL_C_INCLUDES_Debug := \
$(PWD)/frameworks/wilhelm/include \
$(PWD)/bionic \
$(PWD)/external/stlport/stlport
-LOCAL_C_INCLUDES := $(GYP_COPIED_SOURCE_ORIGIN_DIRS) $(LOCAL_C_INCLUDES)
# Flags passed to only C++ (and not C) files.
-LOCAL_CPPFLAGS := \
+LOCAL_CPPFLAGS_Debug := \
-fno-rtti \
-fno-threadsafe-statics \
-fvisibility-inlines-hidden \
@@ -106,6 +102,88 @@ LOCAL_CPPFLAGS := \
-Wno-sign-promo \
-Wno-non-virtual-dtor
+
+# Flags passed to both C and C++ files.
+MY_CFLAGS_Release := \
+ -fstack-protector \
+ --param=ssp-buffer-size=4 \
+ \
+ -fno-exceptions \
+ -fno-strict-aliasing \
+ -Wno-unused-parameter \
+ -Wno-missing-field-initializers \
+ -fvisibility=hidden \
+ -pipe \
+ -fPIC \
+ -Wno-format \
+ -EL \
+ -mhard-float \
+ -ffunction-sections \
+ -funwind-tables \
+ -g \
+ -fstack-protector \
+ -fno-short-enums \
+ -finline-limit=64 \
+ -Wa,--noexecstack \
+ -U_FORTIFY_SOURCE \
+ -Wno-extra \
+ -Wno-ignored-qualifiers \
+ -Wno-type-limits \
+ -Wno-address \
+ -Wno-format-security \
+ -Wno-return-type \
+ -Wno-sequence-point \
+ -Os \
+ -fno-ident \
+ -fdata-sections \
+ -ffunction-sections \
+ -fomit-frame-pointer
+
+MY_DEFS_Release := \
+ '-DANGLE_DX11' \
+ '-D_FILE_OFFSET_BITS=64' \
+ '-DNO_TCMALLOC' \
+ '-DDISABLE_NACL' \
+ '-DCHROMIUM_BUILD' \
+ '-DUSE_LIBJPEG_TURBO=1' \
+ '-DUSE_PROPRIETARY_CODECS' \
+ '-DENABLE_GPU=1' \
+ '-DUSE_OPENSSL=1' \
+ '-DENABLE_EGLIMAGE=1' \
+ '-DENABLE_LANGUAGE_DETECTION=1' \
+ '-DANDROID' \
+ '-D__GNU_SOURCE=1' \
+ '-DUSE_STLPORT=1' \
+ '-D_STLP_USE_PTR_SPECIALIZATIONS=1' \
+ '-DCHROME_BUILD_ID=""' \
+ '-DNDEBUG' \
+ '-DNVALGRIND' \
+ '-DDYNAMIC_ANNOTATIONS_ENABLED=0'
+
+
+# Include paths placed before CFLAGS/CPPFLAGS
+LOCAL_C_INCLUDES_Release := \
+ $(PWD)/frameworks/wilhelm/include \
+ $(PWD)/bionic \
+ $(PWD)/external/stlport/stlport
+
+
+# Flags passed to only C++ (and not C) files.
+LOCAL_CPPFLAGS_Release := \
+ -fno-rtti \
+ -fno-threadsafe-statics \
+ -fvisibility-inlines-hidden \
+ -Wno-deprecated \
+ -Wno-uninitialized \
+ -Wno-error=c++0x-compat \
+ -Wno-non-virtual-dtor \
+ -Wno-sign-promo \
+ -Wno-non-virtual-dtor
+
+
+LOCAL_CFLAGS := $(MY_CFLAGS_$(GYP_CONFIGURATION)) $(MY_DEFS_$(GYP_CONFIGURATION))
+LOCAL_C_INCLUDES := $(GYP_COPIED_SOURCE_ORIGIN_DIRS) $(LOCAL_C_INCLUDES_$(GYP_CONFIGURATION))
+LOCAL_CPPFLAGS := $(LOCAL_CPPFLAGS_$(GYP_CONFIGURATION))
### Rules for final target.
# Add target alias to "gyp_all_modules" target.
.PHONY: gyp_all_modules
diff --git a/testing/gtest_prod.target.darwin-x86.mk b/testing/gtest_prod.target.darwin-x86.mk
index 12345a1b92..074682cadc 100644
--- a/testing/gtest_prod.target.darwin-x86.mk
+++ b/testing/gtest_prod.target.darwin-x86.mk
@@ -26,7 +26,7 @@ LOCAL_SRC_FILES :=
# Flags passed to both C and C++ files.
-MY_CFLAGS := \
+MY_CFLAGS_Debug := \
--param=ssp-buffer-size=4 \
-fno-exceptions \
-fno-strict-aliasing \
@@ -63,9 +63,7 @@ MY_CFLAGS := \
-fdata-sections \
-ffunction-sections
-MY_CFLAGS_C :=
-
-MY_DEFS := \
+MY_DEFS_Debug := \
'-DANGLE_DX11' \
'-D_FILE_OFFSET_BITS=64' \
'-DUSE_LINUX_BREAKPAD' \
@@ -87,18 +85,98 @@ MY_DEFS := \
'-DWTF_USE_DYNAMIC_ANNOTATIONS=1' \
'-D_DEBUG'
-LOCAL_CFLAGS := $(MY_CFLAGS_C) $(MY_CFLAGS) $(MY_DEFS)
# Include paths placed before CFLAGS/CPPFLAGS
-LOCAL_C_INCLUDES := \
+LOCAL_C_INCLUDES_Debug := \
+ $(PWD)/frameworks/wilhelm/include \
+ $(PWD)/bionic \
+ $(PWD)/external/stlport/stlport
+
+
+# Flags passed to only C++ (and not C) files.
+LOCAL_CPPFLAGS_Debug := \
+ -fno-rtti \
+ -fno-threadsafe-statics \
+ -fvisibility-inlines-hidden \
+ -Wno-deprecated \
+ -Wno-error=c++0x-compat \
+ -Wno-non-virtual-dtor \
+ -Wno-sign-promo \
+ -Wno-non-virtual-dtor
+
+
+# Flags passed to both C and C++ files.
+MY_CFLAGS_Release := \
+ --param=ssp-buffer-size=4 \
+ -fno-exceptions \
+ -fno-strict-aliasing \
+ -Wno-unused-parameter \
+ -Wno-missing-field-initializers \
+ -fvisibility=hidden \
+ -pipe \
+ -fPIC \
+ -Wno-format \
+ -m32 \
+ -mmmx \
+ -march=pentium4 \
+ -msse2 \
+ -mfpmath=sse \
+ -fuse-ld=gold \
+ -ffunction-sections \
+ -funwind-tables \
+ -g \
+ -fno-short-enums \
+ -finline-limit=64 \
+ -Wa,--noexecstack \
+ -U_FORTIFY_SOURCE \
+ -Wno-extra \
+ -Wno-ignored-qualifiers \
+ -Wno-type-limits \
+ -Wno-address \
+ -Wno-format-security \
+ -Wno-return-type \
+ -Wno-sequence-point \
+ -fno-stack-protector \
+ -Os \
+ -fno-ident \
+ -fdata-sections \
+ -ffunction-sections \
+ -fomit-frame-pointer \
+ -fno-unwind-tables \
+ -fno-asynchronous-unwind-tables
+
+MY_DEFS_Release := \
+ '-DANGLE_DX11' \
+ '-D_FILE_OFFSET_BITS=64' \
+ '-DUSE_LINUX_BREAKPAD' \
+ '-DNO_TCMALLOC' \
+ '-DDISABLE_NACL' \
+ '-DCHROMIUM_BUILD' \
+ '-DUSE_LIBJPEG_TURBO=1' \
+ '-DUSE_PROPRIETARY_CODECS' \
+ '-DENABLE_GPU=1' \
+ '-DUSE_OPENSSL=1' \
+ '-DENABLE_EGLIMAGE=1' \
+ '-DENABLE_LANGUAGE_DETECTION=1' \
+ '-DANDROID' \
+ '-D__GNU_SOURCE=1' \
+ '-DUSE_STLPORT=1' \
+ '-D_STLP_USE_PTR_SPECIALIZATIONS=1' \
+ '-DCHROME_BUILD_ID=""' \
+ '-DNDEBUG' \
+ '-DNVALGRIND' \
+ '-DDYNAMIC_ANNOTATIONS_ENABLED=0'
+
+
+# Include paths placed before CFLAGS/CPPFLAGS
+LOCAL_C_INCLUDES_Release := \
$(PWD)/frameworks/wilhelm/include \
$(PWD)/bionic \
$(PWD)/external/stlport/stlport
-LOCAL_C_INCLUDES := $(GYP_COPIED_SOURCE_ORIGIN_DIRS) $(LOCAL_C_INCLUDES)
# Flags passed to only C++ (and not C) files.
-LOCAL_CPPFLAGS := \
+LOCAL_CPPFLAGS_Release := \
-fno-rtti \
-fno-threadsafe-statics \
-fvisibility-inlines-hidden \
@@ -108,6 +186,10 @@ LOCAL_CPPFLAGS := \
-Wno-sign-promo \
-Wno-non-virtual-dtor
+
+LOCAL_CFLAGS := $(MY_CFLAGS_$(GYP_CONFIGURATION)) $(MY_DEFS_$(GYP_CONFIGURATION))
+LOCAL_C_INCLUDES := $(GYP_COPIED_SOURCE_ORIGIN_DIRS) $(LOCAL_C_INCLUDES_$(GYP_CONFIGURATION))
+LOCAL_CPPFLAGS := $(LOCAL_CPPFLAGS_$(GYP_CONFIGURATION))
### Rules for final target.
# Add target alias to "gyp_all_modules" target.
.PHONY: gyp_all_modules
diff --git a/testing/gtest_prod.target.linux-arm.mk b/testing/gtest_prod.target.linux-arm.mk
index 88e05c5f8f..f36142cdd5 100644
--- a/testing/gtest_prod.target.linux-arm.mk
+++ b/testing/gtest_prod.target.linux-arm.mk
@@ -26,7 +26,7 @@ LOCAL_SRC_FILES :=
# Flags passed to both C and C++ files.
-MY_CFLAGS := \
+MY_CFLAGS_Debug := \
-fstack-protector \
--param=ssp-buffer-size=4 \
-fno-exceptions \
@@ -61,9 +61,7 @@ MY_CFLAGS := \
-fdata-sections \
-ffunction-sections
-MY_CFLAGS_C :=
-
-MY_DEFS := \
+MY_DEFS_Debug := \
'-DANGLE_DX11' \
'-D_FILE_OFFSET_BITS=64' \
'-DUSE_LINUX_BREAKPAD' \
@@ -85,18 +83,95 @@ MY_DEFS := \
'-DWTF_USE_DYNAMIC_ANNOTATIONS=1' \
'-D_DEBUG'
-LOCAL_CFLAGS := $(MY_CFLAGS_C) $(MY_CFLAGS) $(MY_DEFS)
# Include paths placed before CFLAGS/CPPFLAGS
-LOCAL_C_INCLUDES := \
+LOCAL_C_INCLUDES_Debug := \
+ $(PWD)/frameworks/wilhelm/include \
+ $(PWD)/bionic \
+ $(PWD)/external/stlport/stlport
+
+
+# Flags passed to only C++ (and not C) files.
+LOCAL_CPPFLAGS_Debug := \
+ -fno-rtti \
+ -fno-threadsafe-statics \
+ -fvisibility-inlines-hidden \
+ -Wno-deprecated \
+ -Wno-abi \
+ -Wno-error=c++0x-compat \
+ -Wno-non-virtual-dtor \
+ -Wno-sign-promo \
+ -Wno-non-virtual-dtor
+
+
+# Flags passed to both C and C++ files.
+MY_CFLAGS_Release := \
+ -fstack-protector \
+ --param=ssp-buffer-size=4 \
+ -fno-exceptions \
+ -fno-strict-aliasing \
+ -Wno-unused-parameter \
+ -Wno-missing-field-initializers \
+ -fvisibility=hidden \
+ -pipe \
+ -fPIC \
+ -Wno-format \
+ -fno-tree-sra \
+ -fuse-ld=gold \
+ -Wno-psabi \
+ -ffunction-sections \
+ -funwind-tables \
+ -g \
+ -fstack-protector \
+ -fno-short-enums \
+ -finline-limit=64 \
+ -Wa,--noexecstack \
+ -U_FORTIFY_SOURCE \
+ -Wno-extra \
+ -Wno-ignored-qualifiers \
+ -Wno-type-limits \
+ -Wno-address \
+ -Wno-format-security \
+ -Wno-return-type \
+ -Wno-sequence-point \
+ -Os \
+ -fno-ident \
+ -fdata-sections \
+ -ffunction-sections \
+ -fomit-frame-pointer
+
+MY_DEFS_Release := \
+ '-DANGLE_DX11' \
+ '-D_FILE_OFFSET_BITS=64' \
+ '-DUSE_LINUX_BREAKPAD' \
+ '-DNO_TCMALLOC' \
+ '-DDISABLE_NACL' \
+ '-DCHROMIUM_BUILD' \
+ '-DUSE_LIBJPEG_TURBO=1' \
+ '-DUSE_PROPRIETARY_CODECS' \
+ '-DENABLE_GPU=1' \
+ '-DUSE_OPENSSL=1' \
+ '-DENABLE_EGLIMAGE=1' \
+ '-DENABLE_LANGUAGE_DETECTION=1' \
+ '-DANDROID' \
+ '-D__GNU_SOURCE=1' \
+ '-DUSE_STLPORT=1' \
+ '-D_STLP_USE_PTR_SPECIALIZATIONS=1' \
+ '-DCHROME_BUILD_ID=""' \
+ '-DNDEBUG' \
+ '-DNVALGRIND' \
+ '-DDYNAMIC_ANNOTATIONS_ENABLED=0'
+
+
+# Include paths placed before CFLAGS/CPPFLAGS
+LOCAL_C_INCLUDES_Release := \
$(PWD)/frameworks/wilhelm/include \
$(PWD)/bionic \
$(PWD)/external/stlport/stlport
-LOCAL_C_INCLUDES := $(GYP_COPIED_SOURCE_ORIGIN_DIRS) $(LOCAL_C_INCLUDES)
# Flags passed to only C++ (and not C) files.
-LOCAL_CPPFLAGS := \
+LOCAL_CPPFLAGS_Release := \
-fno-rtti \
-fno-threadsafe-statics \
-fvisibility-inlines-hidden \
@@ -107,6 +182,10 @@ LOCAL_CPPFLAGS := \
-Wno-sign-promo \
-Wno-non-virtual-dtor
+
+LOCAL_CFLAGS := $(MY_CFLAGS_$(GYP_CONFIGURATION)) $(MY_DEFS_$(GYP_CONFIGURATION))
+LOCAL_C_INCLUDES := $(GYP_COPIED_SOURCE_ORIGIN_DIRS) $(LOCAL_C_INCLUDES_$(GYP_CONFIGURATION))
+LOCAL_CPPFLAGS := $(LOCAL_CPPFLAGS_$(GYP_CONFIGURATION))
### Rules for final target.
# Add target alias to "gyp_all_modules" target.
.PHONY: gyp_all_modules
diff --git a/testing/gtest_prod.target.linux-mips.mk b/testing/gtest_prod.target.linux-mips.mk
index 9e514b11fe..e1cdc8e6c9 100644
--- a/testing/gtest_prod.target.linux-mips.mk
+++ b/testing/gtest_prod.target.linux-mips.mk
@@ -26,7 +26,7 @@ LOCAL_SRC_FILES :=
# Flags passed to both C and C++ files.
-MY_CFLAGS := \
+MY_CFLAGS_Debug := \
-fstack-protector \
--param=ssp-buffer-size=4 \
\
@@ -61,9 +61,7 @@ MY_CFLAGS := \
-fdata-sections \
-ffunction-sections
-MY_CFLAGS_C :=
-
-MY_DEFS := \
+MY_DEFS_Debug := \
'-DANGLE_DX11' \
'-D_FILE_OFFSET_BITS=64' \
'-DNO_TCMALLOC' \
@@ -84,18 +82,16 @@ MY_DEFS := \
'-DWTF_USE_DYNAMIC_ANNOTATIONS=1' \
'-D_DEBUG'
-LOCAL_CFLAGS := $(MY_CFLAGS_C) $(MY_CFLAGS) $(MY_DEFS)
# Include paths placed before CFLAGS/CPPFLAGS
-LOCAL_C_INCLUDES := \
+LOCAL_C_INCLUDES_Debug := \
$(PWD)/frameworks/wilhelm/include \
$(PWD)/bionic \
$(PWD)/external/stlport/stlport
-LOCAL_C_INCLUDES := $(GYP_COPIED_SOURCE_ORIGIN_DIRS) $(LOCAL_C_INCLUDES)
# Flags passed to only C++ (and not C) files.
-LOCAL_CPPFLAGS := \
+LOCAL_CPPFLAGS_Debug := \
-fno-rtti \
-fno-threadsafe-statics \
-fvisibility-inlines-hidden \
@@ -106,6 +102,88 @@ LOCAL_CPPFLAGS := \
-Wno-sign-promo \
-Wno-non-virtual-dtor
+
+# Flags passed to both C and C++ files.
+MY_CFLAGS_Release := \
+ -fstack-protector \
+ --param=ssp-buffer-size=4 \
+ \
+ -fno-exceptions \
+ -fno-strict-aliasing \
+ -Wno-unused-parameter \
+ -Wno-missing-field-initializers \
+ -fvisibility=hidden \
+ -pipe \
+ -fPIC \
+ -Wno-format \
+ -EL \
+ -mhard-float \
+ -ffunction-sections \
+ -funwind-tables \
+ -g \
+ -fstack-protector \
+ -fno-short-enums \
+ -finline-limit=64 \
+ -Wa,--noexecstack \
+ -U_FORTIFY_SOURCE \
+ -Wno-extra \
+ -Wno-ignored-qualifiers \
+ -Wno-type-limits \
+ -Wno-address \
+ -Wno-format-security \
+ -Wno-return-type \
+ -Wno-sequence-point \
+ -Os \
+ -fno-ident \
+ -fdata-sections \
+ -ffunction-sections \
+ -fomit-frame-pointer
+
+MY_DEFS_Release := \
+ '-DANGLE_DX11' \
+ '-D_FILE_OFFSET_BITS=64' \
+ '-DNO_TCMALLOC' \
+ '-DDISABLE_NACL' \
+ '-DCHROMIUM_BUILD' \
+ '-DUSE_LIBJPEG_TURBO=1' \
+ '-DUSE_PROPRIETARY_CODECS' \
+ '-DENABLE_GPU=1' \
+ '-DUSE_OPENSSL=1' \
+ '-DENABLE_EGLIMAGE=1' \
+ '-DENABLE_LANGUAGE_DETECTION=1' \
+ '-DANDROID' \
+ '-D__GNU_SOURCE=1' \
+ '-DUSE_STLPORT=1' \
+ '-D_STLP_USE_PTR_SPECIALIZATIONS=1' \
+ '-DCHROME_BUILD_ID=""' \
+ '-DNDEBUG' \
+ '-DNVALGRIND' \
+ '-DDYNAMIC_ANNOTATIONS_ENABLED=0'
+
+
+# Include paths placed before CFLAGS/CPPFLAGS
+LOCAL_C_INCLUDES_Release := \
+ $(PWD)/frameworks/wilhelm/include \
+ $(PWD)/bionic \
+ $(PWD)/external/stlport/stlport
+
+
+# Flags passed to only C++ (and not C) files.
+LOCAL_CPPFLAGS_Release := \
+ -fno-rtti \
+ -fno-threadsafe-statics \
+ -fvisibility-inlines-hidden \
+ -Wno-deprecated \
+ -Wno-uninitialized \
+ -Wno-error=c++0x-compat \
+ -Wno-non-virtual-dtor \
+ -Wno-sign-promo \
+ -Wno-non-virtual-dtor
+
+
+LOCAL_CFLAGS := $(MY_CFLAGS_$(GYP_CONFIGURATION)) $(MY_DEFS_$(GYP_CONFIGURATION))
+LOCAL_C_INCLUDES := $(GYP_COPIED_SOURCE_ORIGIN_DIRS) $(LOCAL_C_INCLUDES_$(GYP_CONFIGURATION))
+LOCAL_CPPFLAGS := $(LOCAL_CPPFLAGS_$(GYP_CONFIGURATION))
### Rules for final target.
# Add target alias to "gyp_all_modules" target.
.PHONY: gyp_all_modules
diff --git a/testing/gtest_prod.target.linux-x86.mk b/testing/gtest_prod.target.linux-x86.mk
index 12345a1b92..074682cadc 100644
--- a/testing/gtest_prod.target.linux-x86.mk
+++ b/testing/gtest_prod.target.linux-x86.mk
@@ -26,7 +26,7 @@ LOCAL_SRC_FILES :=
# Flags passed to both C and C++ files.
-MY_CFLAGS := \
+MY_CFLAGS_Debug := \
--param=ssp-buffer-size=4 \
-fno-exceptions \
-fno-strict-aliasing \
@@ -63,9 +63,7 @@ MY_CFLAGS := \
-fdata-sections \
-ffunction-sections
-MY_CFLAGS_C :=
-
-MY_DEFS := \
+MY_DEFS_Debug := \
'-DANGLE_DX11' \
'-D_FILE_OFFSET_BITS=64' \
'-DUSE_LINUX_BREAKPAD' \
@@ -87,18 +85,98 @@ MY_DEFS := \
'-DWTF_USE_DYNAMIC_ANNOTATIONS=1' \
'-D_DEBUG'
-LOCAL_CFLAGS := $(MY_CFLAGS_C) $(MY_CFLAGS) $(MY_DEFS)
# Include paths placed before CFLAGS/CPPFLAGS
-LOCAL_C_INCLUDES := \
+LOCAL_C_INCLUDES_Debug := \
+ $(PWD)/frameworks/wilhelm/include \
+ $(PWD)/bionic \
+ $(PWD)/external/stlport/stlport
+
+
+# Flags passed to only C++ (and not C) files.
+LOCAL_CPPFLAGS_Debug := \
+ -fno-rtti \
+ -fno-threadsafe-statics \
+ -fvisibility-inlines-hidden \
+ -Wno-deprecated \
+ -Wno-error=c++0x-compat \
+ -Wno-non-virtual-dtor \
+ -Wno-sign-promo \
+ -Wno-non-virtual-dtor
+
+
+# Flags passed to both C and C++ files.
+MY_CFLAGS_Release := \
+ --param=ssp-buffer-size=4 \
+ -fno-exceptions \
+ -fno-strict-aliasing \
+ -Wno-unused-parameter \
+ -Wno-missing-field-initializers \
+ -fvisibility=hidden \
+ -pipe \
+ -fPIC \
+ -Wno-format \
+ -m32 \
+ -mmmx \
+ -march=pentium4 \
+ -msse2 \
+ -mfpmath=sse \
+ -fuse-ld=gold \
+ -ffunction-sections \
+ -funwind-tables \
+ -g \
+ -fno-short-enums \
+ -finline-limit=64 \
+ -Wa,--noexecstack \
+ -U_FORTIFY_SOURCE \
+ -Wno-extra \
+ -Wno-ignored-qualifiers \
+ -Wno-type-limits \
+ -Wno-address \
+ -Wno-format-security \
+ -Wno-return-type \
+ -Wno-sequence-point \
+ -fno-stack-protector \
+ -Os \
+ -fno-ident \
+ -fdata-sections \
+ -ffunction-sections \
+ -fomit-frame-pointer \
+ -fno-unwind-tables \
+ -fno-asynchronous-unwind-tables
+
+MY_DEFS_Release := \
+ '-DANGLE_DX11' \
+ '-D_FILE_OFFSET_BITS=64' \
+ '-DUSE_LINUX_BREAKPAD' \
+ '-DNO_TCMALLOC' \
+ '-DDISABLE_NACL' \
+ '-DCHROMIUM_BUILD' \
+ '-DUSE_LIBJPEG_TURBO=1' \
+ '-DUSE_PROPRIETARY_CODECS' \
+ '-DENABLE_GPU=1' \
+ '-DUSE_OPENSSL=1' \
+ '-DENABLE_EGLIMAGE=1' \
+ '-DENABLE_LANGUAGE_DETECTION=1' \
+ '-DANDROID' \
+ '-D__GNU_SOURCE=1' \
+ '-DUSE_STLPORT=1' \
+ '-D_STLP_USE_PTR_SPECIALIZATIONS=1' \
+ '-DCHROME_BUILD_ID=""' \
+ '-DNDEBUG' \
+ '-DNVALGRIND' \
+ '-DDYNAMIC_ANNOTATIONS_ENABLED=0'
+
+
+# Include paths placed before CFLAGS/CPPFLAGS
+LOCAL_C_INCLUDES_Release := \
$(PWD)/frameworks/wilhelm/include \
$(PWD)/bionic \
$(PWD)/external/stlport/stlport
-LOCAL_C_INCLUDES := $(GYP_COPIED_SOURCE_ORIGIN_DIRS) $(LOCAL_C_INCLUDES)
# Flags passed to only C++ (and not C) files.
-LOCAL_CPPFLAGS := \
+LOCAL_CPPFLAGS_Release := \
-fno-rtti \
-fno-threadsafe-statics \
-fvisibility-inlines-hidden \
@@ -108,6 +186,10 @@ LOCAL_CPPFLAGS := \
-Wno-sign-promo \
-Wno-non-virtual-dtor
+
+LOCAL_CFLAGS := $(MY_CFLAGS_$(GYP_CONFIGURATION)) $(MY_DEFS_$(GYP_CONFIGURATION))
+LOCAL_C_INCLUDES := $(GYP_COPIED_SOURCE_ORIGIN_DIRS) $(LOCAL_C_INCLUDES_$(GYP_CONFIGURATION))
+LOCAL_CPPFLAGS := $(LOCAL_CPPFLAGS_$(GYP_CONFIGURATION))
### Rules for final target.
# Add target alias to "gyp_all_modules" target.
.PHONY: gyp_all_modules
diff --git a/testing/test_env.py b/testing/test_env.py
index feca6094d3..ec98a11ce6 100755
--- a/testing/test_env.py
+++ b/testing/test_env.py
@@ -44,9 +44,12 @@ def enable_sandbox_if_required(env, verbose=False):
env[CHROME_SANDBOX_ENV] = chrome_sandbox_path
else:
if verbose:
- print 'Disabling sandbox. Setting environment variable:'
- print ' %s=""' % CHROME_SANDBOX_ENV
- env[CHROME_SANDBOX_ENV] = ''
+ print 'Sandbox not properly installed. Unsetting:'
+ print ' %s' % CHROME_SANDBOX_ENV
+ # The variable should be removed from the environment, making
+ # the variable empty silently disables the sandbox.
+ if env.get(CHROME_SANDBOX_ENV):
+ env.pop(CHROME_SANDBOX_ENV)
def fix_python_path(cmd):