Skip to content

[et] Build for android_x64 emulator on x64 host #156598

@dcharkes

Description

@dcharkes

How do I build for an x64 emulator on a Linux x64 host with et?

Using ci/android_debug_x64 leads to a search for ci/host_debug.

$ flutter run -d emu --local-engine=ci/android_debug_x64 --local-engine-host=host_debug --local-engine-src-path=$HOME/flt/engine/src
Launching lib/main.dart on sdk gphone16k x86 64 in debug mode...
Unable to find a built dart sdk at: "/usr/local/google/home/dacoharkes/flt/engine/src/out/ci/host_debug/dart-sdk" or a
prebuilt dart sdk at: "/usr/local/google/home/dacoharkes/flt/engine/src/out/flutter/prebuilts/linux-x64/dart-sdk"

However ci/host_debug can't be built with a non-prebuilt Dart:

Running `dart /usr/local/google/home/dacoharkes/flt/engine/src/flutter/tools/engine_tool/bin/et.dart build --build-dart-full --rbe -c ci/host_debug` in /usr/local/google/home/dacoharkes/flt/engine/src/.
  [2024-10-11T16:36:28.700][ci/host_debug: GN]: STARTING     
  [2024-10-11T16:36:32.279][ci/host_debug: GN]: OK
  [2024-10-11T16:36:32.708][ci/host_debug: RBE startup]: STARTING     
  [2024-10-11T16:36:36.497][ci/host_debug: RBE startup]: Proxy started successfully.
  [2024-10-11T16:36:36.498][ci/host_debug: ninja]: STARTING     
  [2024-10-11 16:36:36.820278][ci/host_debug: ninja]: FAILED
COMMAND:
/usr/local/google/home/dacoharkes/flt/engine/src/flutter/third_party/ninja/ninja -C /usr/local/google/home/dacoharkes/flt/engine/src/out/ci/host_debug -j 1000 flutter:unittests flutter/build/archives:artifacts flutter/build/archives:dart_sdk_archive flutter/build/archives:embedder flutter/build/archives:flutter_patched_sdk flutter/build/dart:copy_dart_sdk flutter/tools/font_subset
STDOUT:
ninja: Entering directory `/usr/local/google/home/dacoharkes/flt/engine/src/out/ci/host_debug'

STDERR:
ninja: error: unknown target 'flutter/build/dart:copy_dart_sdk'

non ci/ host_debug can be built with a custom Dart:

Running `dart /usr/local/google/home/dacoharkes/flt/engine/src/flutter/tools/engine_tool/bin/et.dart build --build-dart-full --rbe -c host_debug` in /usr/local/google/home/dacoharkes/flt/engine/src/.
[... succeeds]

But there is no non ci/ android_debug_x64 config

Running `dart /usr/local/google/home/dacoharkes/flt/engine/src/flutter/tools/engine_tool/bin/et.dart build --build-dart-full --rbe -c android_debug_x64` in /usr/local/google/home/dacoharkes/flt/engine/src/.
  [2024-10-11 16:39:13.359667] ERROR: "android_debug_x64" is not an allowed value for option "config".

Is building a custom engine for android_x64 with custom Dart not supported on linux_x64 hosts?

(The flow for android_arm64 on an M1 works fine, an without any ci/ configurations.)

Metadata

Metadata

Assignees

No one assigned

    Labels

    P3Issues that are less important to the Flutter projecte: engine-toolEngine-specific tooling (i.e. `tools/engine_tool`).team-engineOwned by Engine teamtriaged-engineTriaged by Engine team

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions