Bug 1543323 - On Android, only build gtest tests archive on x86_64 builds; r=glandium
authorGeoff Brown <gbrown@mozilla.com>
Fri, 12 Apr 2019 00:17:45 +0000
changeset 469266 2e0165dcfdb1c104551d75c5ff4833cd064e6405
parent 469265 650ab6bfa91aca539aecc86fd73aff5d9e32b07e
child 469267 6b039311ee97a426700db0d7dd96e5d6b0c36ed0
push id112776
push usershindli@mozilla.com
push dateFri, 12 Apr 2019 16:20:17 +0000
treeherdermozilla-inbound@b4501ced5619 [default view] [failures only]
perfherder[talos] [build metrics] [platform microbench] (compared to previous push)
reviewersglandium
bugs1543323
milestone68.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 1543323 - On Android, only build gtest tests archive on x86_64 builds; r=glandium We only plan to run Android gtest in continuous integration on x86_64. Given the impact on build times, I think it best to limit the gtest archive builds to the variants where we will use it. Differential Revision: https://phabricator.services.mozilla.com/D26936
moz.configure
--- a/moz.configure
+++ b/moz.configure
@@ -315,25 +315,26 @@ def check_objdir_backend_reuse(build_env
                     build_env.topobjdir, prev)
 
 
 option('--disable-gtest-in-build',
        help='Force disable building the gtest libxul during the build.',
        when='--enable-compile-environment')
 
 # Determine whether to build the gtest xul. This happens in automation
-# on Android and Desktop platforms with the exception of Windows PGO, where
-# linking xul-gtest.dll takes too long.
+# on Android and Desktop platforms with the exception of:
+#  - Windows PGO, where linking xul-gtest.dll takes too long;
+#  - Android other than x86_64, where gtest is not required.
 @depends('MOZ_PGO', build_project, target, 'MOZ_AUTOMATION', '--disable-gtest-in-build',
          enable_tests, when='--enable-compile-environment')
 def build_gtest(pgo, build_project, target, automation, enabled, enable_tests):
     if not enable_tests or not enabled:
         return None
     if (automation and build_project in ('browser', 'mobile/android') and
-        not (pgo and target.os == 'WINNT')):
+        not ((pgo and target.os == 'WINNT') or (target.os == 'Android' and target.cpu != 'x86_64'))):
         return True
 
 set_config('LINK_GTEST_DURING_COMPILE', build_gtest)
 
 # Localization
 # ==============================================================
 option('--enable-ui-locale', default='en-US',
        help='Select the user interface locale (default: en-US)')