Bug 1354350 - libyuv should not build with NVALGRIND under MOZ_VALGRIND builds; r=drno
authorDan Minor <dminor@mozilla.com>
Tue, 30 May 2017 15:33:55 -0400
changeset 412030 dced7b9bcc5bd8ea3bc907536f3c1665788fd9fd
parent 412029 283eeb11b8f72c7f13c34244f97be699839bf93b
child 412031 dd37a9cce28d8ce293cddc6e499c19d0397aac0d
push id1490
push usermtabara@mozilla.com
push dateMon, 31 Jul 2017 14:08:16 +0000
treeherdermozilla-release@70e32e6bf15e [default view] [failures only]
perfherder[talos] [build metrics] [platform microbench] (compared to previous push)
reviewersdrno
bugs1354350, 1354207
milestone55.0a1
first release with
nightly linux32
nightly linux64
nightly mac
nightly win32
nightly win64
last release without
nightly linux32
nightly linux64
nightly mac
nightly win32
nightly win64
Bug 1354350 - libyuv should not build with NVALGRIND under MOZ_VALGRIND builds; r=drno This applies the fix from Bug 1354207 to the libyuv moz.build.
media/libyuv/moz.build
--- a/media/libyuv/moz.build
+++ b/media/libyuv/moz.build
@@ -4,26 +4,35 @@
 # License, v. 2.0. If a copy of the MPL was not distributed with this
 # file, You can obtain one at http://mozilla.org/MPL/2.0/.
 
 with Files("**"):
     BUG_COMPONENT = ("Core", "Graphics")
 
 include('/build/gyp.mozbuild')
 
+# Set gyp vars that libyuv needs when building under various analysis tools.
+gyp_vars_copy = gyp_vars.copy()
+if CONFIG['MOZ_VALGRIND']:
+    gyp_vars_copy.update(build_for_tool="memcheck")
+elif CONFIG['MOZ_ASAN']:
+    gyp_vars_copy.update(build_for_tool="asan")
+elif CONFIG['MOZ_TSAN']:
+    gyp_vars_copy.update(build_for_tool="tsan")
+
 libyuv_non_unified_sources = [
     'libyuv/source/convert.cc',
     'libyuv/source/convert_from.cc',
     'libyuv/source/mjpeg_decoder.cc',
     'libyuv/source/rotate_argb.cc',
     'libyuv/source/row_common.cc',
     'libyuv/source/scale.cc',
     'libyuv/source/scale_common.cc',
 ]
 
 GYP_DIRS += ['libyuv']
 GYP_DIRS['libyuv'].input = 'libyuv/libyuv.gyp'
-GYP_DIRS['libyuv'].variables = gyp_vars
+GYP_DIRS['libyuv'].variables = gyp_vars_copy
 GYP_DIRS['libyuv'].sandbox_vars['FINAL_LIBRARY'] = 'xul'
 GYP_DIRS['libyuv'].non_unified_sources += libyuv_non_unified_sources
 
 # We allow warnings for third-party code that can be updated from upstream.
 GYP_DIRS['libyuv'].sandbox_vars['ALLOW_COMPILER_WARNINGS'] = True