commit | 5a8ef03c1fb665d15059d6f6075a9473ec9715df | [log] [tgz] |
---|---|---|
author | global-integration-roller <global-integration-roller@fuchsia-infra.iam.gserviceaccount.com> | Thu May 26 04:28:51 2022 +0000 |
committer | CQ Bot <fuchsia-internal-scoped@luci-project-accounts.iam.gserviceaccount.com> | Thu May 26 04:28:51 2022 +0000 |
tree | c915c902a6e53962f0a4ef284a417f21a4ecfea1 | |
parent | 64f709e51eca01581778207662250ab84e0d98bb [diff] |
[roll] Update submodules Roller-URL: https://ci.chromium.org/b/8813132485911460001 Cq-Cl-Tag: roller-builder:sdk-samples-fortune-teller-submodule-roller Cq-Cl-Tag: roller-bid:8813132485911460001 CQ-Do-Not-Cancel-Tryjobs: true Change-Id: I577893a6793af341f03327841034bf42f6f55b94 Reviewed-on: https://fuchsia-review.googlesource.com/c/sdk-samples/fortune-teller/+/683721 Commit-Queue: GI Roller <global-integration-roller@fuchsia-infra.iam.gserviceaccount.com>
This repository contains instructions and source code to build, package and run Fuchsia samples using only the Fuchsia SDK.
Install a Bazel version no older than the one defined in the WORKSPACE.bazel file, by following the instructions at https://bazel.build/install. In some Linux distributions, sudo apt-get install bazel
should be enough.
Make sure this repository has the required submodules:
git submodule update --recursive --init
Ensure that there are Fuchsia SSH keys in your host machine. You will need them for running the Fuchsia emulator.
[[ -f "${HOME}/.ssh/fuchsia_ed25519" ]] || ssh-keygen -P "" -t ed25519 -f "${HOME}/.ssh/fuchsia_ed25519" -C "${USER}@$(hostname -f) Shared SSH Key for Fuchsia" [[ -f "${HOME}/.ssh/fuchsia_authorized_keys" ]] || ssh-keygen -y -f "${HOME}/.ssh/fuchsia_ed25519" > "${HOME}/.ssh/fuchsia_authorized_keys"
Now the repository is ready to build the sample.
Fetch an emulator image and start an emulator
tools/ffx product-bundle get workstation.qemu-x64 tools/ffx emu start -H workstation.qemu-x64
(optional) watch the device log in a separate window
tools/ffx log
Run the fortune-teller component
bazel run --config=fuchsia_x64 //src/fortune_teller:pkg.component
Watch that your fortune is printed in the log.