If you have followed the instructions below and are still having trouble, seeContact information.
Building and running on Linux is officially supported, mac build is not. If you are willing to run emulator based tests locally, KVM is required. You may check if/dev/kvm
exists on the system, or follow theEnable KVM section.
Follow upchromium for linux to setup chromium environment.
Edit your.gclient
to addfuchsia
to thetarget_os
list. The file should look similar to this:
solutions = [ { "url": "https://chromium.googlesource.com/chromium/src.git", "managed": False, "name": "src", "custom_deps": {}, "custom_vars": {} }]target_os = ['fuchsia']
Rungclient sync
Create a build directory:
$ gn genout/fuchsia--args="is_debug=false dcheck_always_on=true is_component_build=false target_os=\"fuchsia\""
You can add many of the usual GN arguments likeuse_remoteexec = true
. In particular, when working with devices, consider usingis_debug = false
andis_component_build = false
since debug and component builds can drastically increase run time and used space.
Build the target as you would for any other platform, you may specify the targets to build at the end of the command line:
$ autoninja-Cout/fuchsia
out/fuchsia/bin/run_***_unittests
, e.g.$out/fuchsia/bin/run_base_unittests
It starts a fresh new emulator instance and executes the tests on it under the hood. Also see theRunning test suites section for other types of tests.
Under Linux, if your host and target CPU architectures are the same (e.g. you‘re building for Fuchsia/x64 on a Linux/x64 host) then you can benefit from QEMU’s support for the KVM hypervisor:
$ sudo apt-get install qemu-system-common
$ sudo adduser<user> kvm$exit[login again]
There are four types of tests available to run on Fuchsia:
Check the documentations to learn more about how to run these tests.
Documentation for the underlying testing scripts work can be foundhere.