[clang_toolchain] Fix clang_toolchain.git_revision property of canary builds
This was meant to be the llvm revision, not the fuchsia.git revision.
Fixed: 43680
Change-Id: Ie3346da3476ac8ba00c2234ac8709f90ed2d0239
diff --git a/recipes/clang_toolchain.py b/recipes/clang_toolchain.py
index b1446b1..cb19121 100644
--- a/recipes/clang_toolchain.py
+++ b/recipes/clang_toolchain.py
@@ -166,8 +166,9 @@
cipd_dir = api.path['start_dir'].join('cipd')
pkgs = api.cipd.EnsureFile()
if api.platform.arch == 'arm' and api.platform.bits == 64:
- pkgs.add_package('fuchsia/third_party/clang/${platform}',
- 'git_revision:ea93d7d6421612e9ea51b321eaf97fbdd64fe39b')
+ pkgs.add_package(
+ 'fuchsia/third_party/clang/${platform}',
+ 'git_revision:ea93d7d6421612e9ea51b321eaf97fbdd64fe39b')
pkgs.add_package('fuchsia/sdk/core/linux-amd64', 'latest', 'sdk')
else:
pkgs.add_package('fuchsia/third_party/clang/${platform}', 'goma')
@@ -216,19 +217,20 @@
step_result = api.step(
'xcrun', ['xcrun', '--show-sdk-path'],
stdout=api.raw_io.output(name='sdk-path', add_output_log=True),
- step_test_data=
- lambda: api.raw_io.test_api.stream_output('/some/xcode/path'))
+ step_test_data=lambda: api.raw_io.test_api.stream_output(
+ '/some/xcode/path'))
target_sysroot = host_sysroot = step_result.stdout.strip()
else: # pragma: no cover
assert False, 'unsupported platform'
env = {
- 'CC': ('%s %s' % (api.goma.goma_dir.join('gomacc'),
- cipd_dir.join('bin', 'clang')))
- if use_goma else cipd_dir.join('bin', 'clang'),
+ 'CC':
+ ('%s %s' %
+ (api.goma.goma_dir.join('gomacc'), cipd_dir.join('bin', 'clang')))
+ if use_goma else cipd_dir.join('bin', 'clang'),
'CFLAGS':
- '-O3 -fPIC --target=%s --sysroot=%s' % (target_triple,
- target_sysroot),
+ '-O3 -fPIC --target=%s --sysroot=%s' %
+ (target_triple, target_sysroot),
'AR':
cipd_dir.join('bin', 'llvm-ar'),
'NM':
@@ -498,7 +500,7 @@
project = 'fuchsia'
refs = api.gitiles.refs('https://%s/%s' % (host, project))
ref = 'refs/heads/master'
- revision = refs.get(ref, 'HEAD')
+ fuchsia_rev = refs.get(ref, 'HEAD')
# Do a full integration build. This will use the just-built toolchain
# to build all of Fuchsia to check whether there are any regressions.
@@ -507,7 +509,7 @@
properties={
'clang_toolchain': {
'git_repository': repository,
- 'git_revision': revision,
+ 'git_revision': fuchsia_rev,
},
'build.clang_toolchain': {
'type': 'isolated',
@@ -516,7 +518,8 @@
},
tags={
'buildset':
- 'commit/gitiles/%s/%s/+/%s' % (host, project, revision),
+ 'commit/gitiles/%s/%s/+/%s' %
+ (host, project, fuchsia_rev),
'gitiles_ref':
ref,
}),
@@ -539,17 +542,17 @@
bucket='ci',
git_repo='https://fuchsia.googlesource.com/third_party/llvm-project',
revision='a' * 40,
- ) + api.runtime(is_luci=True, is_experimental=False) + api.platform.name(os)
- + api.properties(platform=os + '-amd64'))
+ ) + api.runtime(is_luci=True, is_experimental=False) +
+ api.platform.name(os) + api.properties(platform=os + '-amd64'))
yield (api.test('prod-%s-x64' % os) + api.buildbucket.ci_build(
project='fuchsia',
bucket='prod',
git_repo='https://fuchsia.googlesource.com/third_party/llvm-project',
revision='a' * 40,
- ) + api.runtime(is_luci=True, is_experimental=False) + api.platform.name(os)
- + api.properties(platform=os + '-amd64') + api.gitiles.refs(
- 'refs', ('refs/heads/master', 'b' * 40)))
+ ) + api.runtime(is_luci=True, is_experimental=False) +
+ api.platform.name(os) + api.properties(platform=os + '-amd64') +
+ api.gitiles.refs('refs', ('refs/heads/master', 'b' * 40)))
yield (api.test('linux-arm64') + api.buildbucket.ci_build(
project='fuchsia',