BASH script to build and boot Google Fuchsia
#!/bin/sh
clear
# Preparing the build environment
# https://github.com/fuchsia-mirror/manifest#prerequisites
# https://github.com/fuchsia-mirror/magenta/blob/master/docs/getting_started.md#preparing-the-build-environment
sudo apt-get install golang git-all curl texinfo libglib2.0-dev autoconf libtool libsdl-dev build-essential
# Creating a new checkout (https://github.com/fuchsia-mirror/manifest#creating-a-new-checkout)
curl -s https://raw.githubusercontent.com/vanadium/go.jiri/master/scripts/bootstrap_jiri | bash -s fuchsia
cd fuchsia
export PATH=`pwd`/.jiri_root/scripts:$PATH
jiri import fuchsia https://fuchsia.googlesource.com/manifest
jiri update
# Building Fuchsia (https://github.com/fuchsia-mirror/manifest#building-fuchsia)
./packages/gn/gen.py
./buildtools/ninja -C out/debug-x86-64
# Build Magenta (https://github.com/fuchsia-mirror/magenta/blob/master/docs/getting_started.md#build-magenta)
cd magenta
make -j32 magenta-pc-x86-64
# Boot Fuchsia (https://github.com/fuchsia-mirror/manifest#building-fuchsia)
# Updated 21 August 2016 to run with a graphical framebuffer
./scripts/run-magenta-x86-64 -g -x ../out/debug-x86-64/user.bootfs