diff --git a/.github/actions/build/action.yaml b/.github/actions/build/action.yaml index ee6157299833..173e948cc4d2 100644 --- a/.github/actions/build/action.yaml +++ b/.github/actions/build/action.yaml @@ -10,11 +10,14 @@ runs: - name: Get depot tools run: git clone https://chromium.googlesource.com/chromium/tools/depot_tools.git shell: bash - - name: Add directory to PATH + - name: Add depot tools to PATH run: echo "$GITHUB_WORKSPACE/depot_tools" >> $GITHUB_PATH shell: bash + - name: Disable Chromium client side build telemetry + run: build_telemetry opt-out + shell: bash - name: Generate gclient file - run: gclient config --name=src https://github.com/${{ github.repository }} + run: gclient config --name=src https://github.com/${{ github.repository }} --custom-var=download_remoteexec_cfg=True shell: bash - name: Set target OS for Android if: ${{ contains(matrix.platform, 'android') }} @@ -22,18 +25,15 @@ runs: echo "target_os=['android']" >> .gclient gclient validate shell: bash - - name: Gclient sync + - name: gclient sync run: gclient sync -v --shallow --no-history -r ${{ github.sha }} shell: bash - - name: sccache check - run: sccache -s - shell: bash - - name: gn gen + - name: GN gen run: | cd src cobalt/build/gn.py -p ${{ matrix.platform }} -C ${{ matrix.config }} shell: bash - - name: Dump GN args + - name: List GN args run: | cd src gn args --list --short --overrides-only out/${{ matrix.platform }}_${{ matrix.config }} @@ -44,10 +44,7 @@ runs: run: | set -x cd src - ninja -C out/${{ matrix.platform }}_${{ matrix.config }} $(echo "${TARGETS}" | tr -d '"') - shell: bash - - name: Dump sccache stats - run: sccache -s + time autoninja -C out/${{ matrix.platform }}_${{ matrix.config }} $(echo "${TARGETS}" | tr -d '"') shell: bash - name: Archive Android APKs if: startsWith(matrix.platform, 'android') && matrix.config == 'qa' diff --git a/DEPS b/DEPS index 495a46e737a1..4f2abbd77bb6 100644 --- a/DEPS +++ b/DEPS @@ -261,7 +261,7 @@ vars = { # Fetch configuration files required for the 'use_remoteexec' gn arg 'download_remoteexec_cfg': False, # RBE instance to use for running remote builds - 'rbe_instance': Str('projects/rbe-chrome-untrusted/instances/default_instance'), + 'rbe_instance': Str('projects/cobalt-actions-prod/instances/default_instance'), # RBE project to download rewrapper config files for. Only needed if # different from the project used in 'rbe_instance' 'rewrapper_cfg_project': Str(''), diff --git a/buildtools/reclient_cfgs/fetch_reclient_cfgs.py b/buildtools/reclient_cfgs/fetch_reclient_cfgs.py index 98c8290db189..fc6b2d5e82f2 100755 --- a/buildtools/reclient_cfgs/fetch_reclient_cfgs.py +++ b/buildtools/reclient_cfgs/fetch_reclient_cfgs.py @@ -48,6 +48,9 @@ class CipdError(Exception): def CipdEnsure(pkg_name, ref, directory, quiet): logging.info('ensure %s %s in %s' % (pkg_name, ref, directory)) log_level = 'warning' if quiet else 'debug' + auth = [] + if os.getenv('IS_CI', default='0') == '1': + auth = ['-service-account-json', ':gce'] ensure_file = """ $ParanoidMode CheckPresence {pkg} {ref} @@ -55,7 +58,7 @@ def CipdEnsure(pkg_name, ref, directory, quiet): try: output = subprocess.check_output( ' '.join(['cipd', 'ensure', '-log-level=' + log_level, - '-root', directory, '-ensure-file', '-']), + '-root', directory, '-ensure-file', '-'] + auth), shell=True, input=ensure_file, stderr=subprocess.STDOUT, universal_newlines=True) logging.info(output) diff --git a/buildtools/reclient_cfgs/rewrapper_linux_link.cfg b/buildtools/reclient_cfgs/rewrapper_linux_link.cfg index 31aa6b62ee55..c8afa1051fb8 100644 --- a/buildtools/reclient_cfgs/rewrapper_linux_link.cfg +++ b/buildtools/reclient_cfgs/rewrapper_linux_link.cfg @@ -3,7 +3,7 @@ # on remote linking performance. # ${revision} -platform=container-image=docker://gcr.io/chops-private-images-prod/rbe/chromium-browser-clang/linux-link@sha256:f138e0a336d48a34bf2537796215acd8e7a626ac1ebddb22674f2d4cd713ec2b,label:linktype=small +platform=container-image=docker://gcr.io/chops-public-images-prod/rbe/siso-chromium/linux@sha256:26de99218a1a8b527d4840490bcbf1690ee0b55c84316300b60776e6b3a03fe1,label:action_default=1 server_address=unix:///tmp/reproxy.sock labels=type=link,tool=clang exec_strategy=remote_local_fallback diff --git a/cobalt/build/gn.py b/cobalt/build/gn.py index 8e34d4e2b7c7..651650dca5cc 100755 --- a/cobalt/build/gn.py +++ b/cobalt/build/gn.py @@ -85,7 +85,7 @@ def write_build_args(build_args_path, original_lines, dict_settings, f'The following args cannot be set in configs: {controlled_args}') gen_comment = '# Set by gn.py' with open(build_args_path, 'w', encoding='utf-8') as f: - if os.getenv('IS_CI', default='0') == '1': + if os.getenv('USE_CC_WRAPPER', default='0') == '1': f.write(f'cc_wrapper = "{CC_WRAPPER}" {gen_comment}\n') else: f.write(f'use_remoteexec = true {gen_comment}\n')