This document describes how to get started with the infrastructure provided by O.S. Systems for you to develop your products based on the Yocto Project.
O.S. Systems' development server (
code.ossystems.com.br) uses Gerrit
to manage source code of its internal, public and customers
projects. Gerrit is a web-based code review system, facilitating
online code reviews for projects using the Git version control system.
To be able to use O.S. Systems' Gerrit, you need to create a profile. The next section describes the steps to do it and some hints to configure your development machine to easily communicate with the development server.
Gerrit setup and registration
To get access to the server you need to register; for it, please go to http://code.ossystems.com.br/login/register and follow the steps presented there.
Set your username
Go to http://code.ossystems.com.br/settings/ and set your username. Please choose something which is easy for you to remeber. It is case sensitive!
Set your contact information
Go to http://code.ossystems.com.br/#/settings/contact and add all e-mail addresses you will be using to send patches. This is required by Gerrit; otherwise it will deny the upload of changes as it will not be able to link the change to you, as author.
Add your SSH key
Go to http://code.ossystems.com.br/#/settings/ssh-keys and add your SSH key. It is used for authentication when fetching the source throught SSH.
If you don’t yet have an SSH key, follow the steps at http://en.wikipedia.org/wiki/Ssh-keygen to create one.
Configuring your development machine
Create or edit your
~/.ssh/config file and add:
Host code.ossystems.com.br User <username>
Create or edit your
~/.gitconfig file and add:
[review "code.ossystems.com.br"] username = <username>
Downloading the source code for your project
In this section we describe how to download the source code for your
project and how to set up the environment to build images. It assumes
you’ve create an account on
code.ossystems.com.br (see the Gerrit
setup and registration section).
Downloading and setting up
repo is a tool to manage
multiple git repositories. O.S. Systems uses
repo to manage the
repositories that compose your BSP platform. Here are the suggested
steps to download and set up
$ mkdir -p ~/bin $ wget http://commondatastorage.googleapis.com/git-repo-downloads/repo -O ~/bin/repo $ chmod 755 ~/bin/repo $ export PATH=$PATH:~/bin
Downloading the actual source code for your project
repo has been installed, we can use it to actually download
the source code for the BSP platform:
$ mkdir -p <customer>/<project>/yocto $ cd <customer>/<project>/yocto $ repo init -u ssh://code.ossystems.com.br/<customer>/<project>/yocto-platform $ repo sync
Contact the O.S. Systems team to know the proper values for
Setting up the build environment
In order to run Yocto Project, you’ll need a recent Linux distribution. For more detailed information see the “Required Packages for the Host Development System” section at the Yocto Project’s documentation.
After the requirements have been installed and source code have been downloaded, we can proceed to set up the build environment:
$ cd <customer>/<project>/yocto $ MACHINE=<machine> source setup-environment <build dir>
<build dir> can be any valid directory name (typically,
<machine> is the machine you’ll buid the image for. Consult the
O.S. Systems team for the value for it.
Once the environment has been set up, you can proceed to build images. Your product will probably have a custom image, so consult the O.S. Systems team for instructions on how to build and deploy your image.
Suggested hardware for running Yocto
Yocto can be quite demanding with regard to resources usage, so it is recommended to use a powerful machine to run it. Specifying a minimum requirement is hard, since it all depends on what you’ll be building and the productivity you expect. The faster your machine, the better your productivity will be.
Despite the subjective nature of hardware specification for Yocto tasks, we recommend as minimal hardware this configuration:
an Intel i5 quad core processor
4GB of RAM
200GB of storage space
For a better productivity, we recommend a more powerful machine, such as:
an Intel i7 quad core processor with HyperThreading running at a reasonable clock for today’s standards (e.g., 2.4GHz)
12GB of RAM
200GB of storage space
Keep in mind that faster processors (or with more cores) and more RAM will probably speed things up. The faster your hardware is, the sooner your build will be finished.