Prepare fuchsia script to coexist with v1 and v2 of fuchsia builders. (flutter/engine#46126)
Prepares fuchsia scripts to work correctly when both v1 and v2 of the fuchsia build are running in their respective environments. Bug: https://github.com/flutter/flutter/issues/126461 Bug: https://github.com/flutter/flutter/issues/135189 [C++, Objective-C, Java style guides]: https://github.com/flutter/engine/blob/main/CONTRIBUTING.md#style
This commit is contained in:
@@ -161,6 +161,7 @@ targets:
|
||||
- name: Linux Fuchsia
|
||||
recipe: engine/engine
|
||||
properties:
|
||||
add_recipes_cq: "true"
|
||||
build_fuchsia: "true"
|
||||
fuchsia_ctl_version: version:0.0.27
|
||||
# ensure files from pre-production Fuchsia SDK tests are purged from cache
|
||||
|
||||
@@ -122,7 +122,8 @@ The current list of supported magic variables is:
|
||||
folder where logs are being placed.
|
||||
* `${LUCI_WORKDIR}` - translated to the LUCI chroot working directory.
|
||||
* `${LUCI_CLEANUP}` - translated to the LUCI chroot temp directory.
|
||||
* `${REVISION}` - translated to the engine commit under test.
|
||||
* `${REVISION}` - translated to the engine commit in postsubmit. In presubmit
|
||||
it is translated to an empty string.
|
||||
|
||||
### Build
|
||||
|
||||
|
||||
@@ -164,6 +164,7 @@
|
||||
"parameters": [
|
||||
"--engine-version",
|
||||
"${REVISION}",
|
||||
"--upload",
|
||||
"--target-arch",
|
||||
"arm64",
|
||||
"--out-dir",
|
||||
@@ -181,6 +182,7 @@
|
||||
"parameters": [
|
||||
"--engine-version",
|
||||
"${REVISION}",
|
||||
"--upload",
|
||||
"--target-arch",
|
||||
"x64",
|
||||
"--out-dir",
|
||||
|
||||
@@ -495,9 +495,17 @@ def main():
|
||||
if args.copy_unoptimized_debug_artifacts and runtime_mode == 'debug' and optimized:
|
||||
CopyBuildToBucket(runtime_mode, arch, not optimized, product)
|
||||
|
||||
# Set revision to HEAD if empty and remove upload. This is to support
|
||||
# presubmit workflows.
|
||||
should_upload = args.upload
|
||||
engine_version = args.engine_version
|
||||
if not engine_version:
|
||||
engine_version = 'HEAD'
|
||||
should_upload = False
|
||||
|
||||
# Create and optionally upload CIPD package
|
||||
if args.cipd_dry_run or args.upload:
|
||||
ProcessCIPDPackage(args.upload, args.engine_version)
|
||||
ProcessCIPDPackage(should_upload, engine_version)
|
||||
|
||||
return 0
|
||||
|
||||
|
||||
@@ -214,7 +214,17 @@ def main():
|
||||
|
||||
arch = args.target_arch
|
||||
cipd_def = WriteCIPDDefinition(arch, out_dir, internal_symbol_dirs)
|
||||
ProcessCIPDPackage(args.upload, cipd_def, args.engine_version, out_dir, arch)
|
||||
|
||||
# Set revision to HEAD if empty and remove upload. This is to support
|
||||
# presubmit workflows. An empty engine_version means this script is running
|
||||
# on presubmit.
|
||||
should_upload = args.upload
|
||||
engine_version = args.engine_version
|
||||
if not engine_version:
|
||||
engine_version = 'HEAD'
|
||||
should_upload = False
|
||||
|
||||
ProcessCIPDPackage(should_upload, cipd_def, engine_version, out_dir, arch)
|
||||
return 0
|
||||
|
||||
|
||||
|
||||
Reference in New Issue
Block a user