Flutter Engine
The Flutter Engine
|
Ensure you have a valid checkout by following the Getting the source instructions.
In order to be able to run on all tests modify the ../.gclient
file by adding custom variables:
This configures the DEPS
to download various tools on the next gclient sync
invocation.
To build dart2wasm for local running & testing we use
This will
out/ReleaseX64/dart2wasm_platform.dill
Building the Dart SDK with
will allow you to run the compiler via dart compile wasm
.
For local development one can use two helper scripts to compile & run wasm apps:
This will
app.dart
with dart2wasm-O0
)-g
)(The reason those scripts have "benchmark" in their name is historic - due to them also being used by golem)
(The compilation can also be done using dart compile wasm
which accepts similar flags to compile_benchmark
)
To avoid re-building with tools/build.py ... dart2wasm
one run the compiler from source:
pkg/dart2wasm/tool/compile_benchmark --src ...
pkg/dart2wasm/tool/compile_benchmark --src --compiler-asserts ...
One can pass through any option to the dart2wasm compiler by adding --extra-compiler-option=--<option>=<value>
.
See available options via dart pkg/dart2wasm/bin/dart2wasm.dart --help
.
One can run dart2wasm tests as usual with
The test framwork will use the same two scripts to compile & run ( pkg/dart2wasm/tool/{compile,run}_benchmark
) as
(The test framework can be asked to use dart compile wasm
from the SDK instead using --use-sdk
(or update in tools/bots/test_matrix.json
))