Bug 1460781 - Add non debug build coverage build to taskcluster draft
authorRaymond FOrbes <rforbes@mozilla.com>
Thu, 10 May 2018 18:13:45 -0700
changeset 795486 4e3b6648fc02d85d3b01c648dcebabc4f18fd9f5
parent 795256 cf3ee14023483cbbb57129479537c713e22c1980
child 795487 6da71cba0d77fe5141ab35e65bb710ef392603b3
push id109993
push userbmo:rforbes@mozilla.com
push dateTue, 15 May 2018 21:18:09 +0000
bugs1460781
milestone62.0a1
Bug 1460781 - Add non debug build coverage build to taskcluster MozReview-Commit-ID: H3AjJ20uspC
browser/config/mozconfigs/linux64/code-coverage-opt
taskcluster/ci/build/linux.yml
testing/mozharness/configs/builds/releng_sub_linux_configs/64_code_coverage_opt.py
testing/mozharness/mozharness/mozilla/building/buildbase.py
new file mode 100644
--- /dev/null
+++ b/browser/config/mozconfigs/linux64/code-coverage-opt
@@ -0,0 +1,13 @@
+. "$topsrcdir/browser/config/mozconfigs/linux64/nightly"
+
+TOOLTOOL_DIR=${TOOLTOOL_DIR:-$topsrcdir}
+
+ac_add_options --disable-install-strip
+ac_add_options --disable-elf-hack
+ac_add_options --disable-sandbox
+ac_add_options --disable-profiling
+ac_add_options --enable-coverage
+
+export CFLAGS="--coverage"
+export CXXFLAGS="--coverage"
+export LDFLAGS="--coverage -L$TOOLTOOL_DIR/gtk3/usr/local/lib"
--- a/taskcluster/ci/build/linux.yml
+++ b/taskcluster/ci/build/linux.yml
@@ -861,16 +861,44 @@ linux64-ccov/debug:
         custom-build-variant-cfg: code-coverage
         tooltool-downloads: public
         need-xvfb: true
     toolchains:
         - linux64-clang-4
         - linux64-rust
         - linux64-gcc
 
+linux64-ccov/opt:
+    description: "Linux64-CCov Opt"
+    index:
+        product: firefox
+        job-name: linux64-ccov-opt
+    treeherder:
+        platform: linux64-ccov/opt
+        symbol: Bo
+    run-on-projects: []
+    worker-type: aws-provisioner-v1/gecko-{level}-b-linux
+    worker:
+        max-run-time: 36000
+    run:
+        using: mozharness
+        actions: [get-secrets build check-test update]
+        config:
+            - builds/releng_base_firefox.py
+            - builds/releng_base_linux_64_builds.py
+        script: "mozharness/scripts/fx_desktop_build.py"
+        secrets: true
+        custom-build-variant-cfg: code-coverage-opt
+        tooltool-downloads: public
+        need-xvfb: true
+    toolchains:
+        - linux64-clang-4
+        - linux64-rust
+        - linux64-gcc
+
 linux64-add-on-devel/opt:
     description: "Linux64 add-on-devel"
     index:
         product: firefox
         job-name: linux64-add-on-devel
     treeherder:
         platform: linux64-add-on-devel/opt
         symbol: B
new file mode 100644
--- /dev/null
+++ b/testing/mozharness/configs/builds/releng_sub_linux_configs/64_code_coverage_opt.py
@@ -0,0 +1,28 @@
+import os
+
+config = {
+    'default_actions': [
+        'clobber',
+        'build',
+        'check-test',
+        'update',  # decided by query_is_nightly()
+    ],
+    'stage_platform': 'linux64-ccov',
+    #### 64 bit build specific #####
+    'env': {
+        'MOZBUILD_STATE_PATH': os.path.join(os.getcwd(), '.mozbuild'),
+        'DISPLAY': ':2',
+        'HG_SHARE_BASE_DIR': '/builds/hg-shared',
+        'MOZ_OBJDIR': '%(abs_obj_dir)s',
+        'TINDERBOX_OUTPUT': '1',
+        'TOOLTOOL_CACHE': '/builds/tooltool_cache',
+        'TOOLTOOL_HOME': '/builds',
+        'MOZ_CRASHREPORTER_NO_REPORT': '1',
+        'LC_ALL': 'C',
+        ## 64 bit specific
+        'PATH': '/usr/local/bin:/bin:\
+/usr/bin:/usr/local/sbin:/usr/sbin:/sbin',
+    },
+    'mozconfig_variant': 'code-coverage-opt',
+    #######################
+}
--- a/testing/mozharness/mozharness/mozilla/building/buildbase.py
+++ b/testing/mozharness/mozharness/mozilla/building/buildbase.py
@@ -416,16 +416,17 @@ class BuildOptionParser(object):
         'cross-fuzzing-asan': 'builds/releng_sub_%s_configs/%s_cross_fuzzing_asan.py',
         'cross-artifact': 'builds/releng_sub_%s_configs/%s_cross_artifact.py',
         'debug': 'builds/releng_sub_%s_configs/%s_debug.py',
         'fuzzing-debug': 'builds/releng_sub_%s_configs/%s_fuzzing_debug.py',
         'asan-and-debug': 'builds/releng_sub_%s_configs/%s_asan_and_debug.py',
         'asan-tc-and-debug': 'builds/releng_sub_%s_configs/%s_asan_tc_and_debug.py',
         'stat-and-debug': 'builds/releng_sub_%s_configs/%s_stat_and_debug.py',
         'code-coverage': 'builds/releng_sub_%s_configs/%s_code_coverage.py',
+        'code-coverage-opt': 'builds/releng_sub_%s_configs/%s_code_coverage-opt.py',
         'source': 'builds/releng_sub_%s_configs/%s_source.py',
         'noopt-debug': 'builds/releng_sub_%s_configs/%s_noopt_debug.py',
         'api-16-gradle-dependencies': 'builds/releng_sub_%s_configs/%s_api_16_gradle_dependencies.py',
         'api-16': 'builds/releng_sub_%s_configs/%s_api_16.py',
         'api-16-artifact': 'builds/releng_sub_%s_configs/%s_api_16_artifact.py',
         'api-16-debug': 'builds/releng_sub_%s_configs/%s_api_16_debug.py',
         'api-16-debug-artifact': 'builds/releng_sub_%s_configs/%s_api_16_debug_artifact.py',
         'api-16-gradle': 'builds/releng_sub_%s_configs/%s_api_16_gradle.py',