Building FSO

From Openmoko

Jump to: navigation, search
Key pages on:
FSO

(Other distributions)


The freesmartphone.org (FSO) image is based on the OpenEmbedded distribution. OpenEmbedded is not part of Openmoko, and targets many different devices.

FSO's source tree, documentation and bug tracker are not hosted at openmoko.org. This wiki page simply points to the relevant portions of OpenEmbedded's documentation. Openembedded.org and freesmartphone.org contain more complete documentation.

Contents

FsoMakefile

There are two ways to build an FSO image.

The first approach uses FsoMakefile to automatically download and configure the build environment, and is the easiest way to build an image:

wget http://downloads.freesmartphone.org/Makefile
make fso-gta02-testing-image

This is the process used by the build servers to create new images.

Ubuntu can throw up errors Talk:MokoMakefile

See http://downloads.freesmartphone.org/ for more information. Note that FsoMakefile and MokoMakefile are separate entities, and target different images.

You can access the FsoMakefile directly from the git repository with this command (there is no difference between this and the above once the build starts):

git clone git://git.freesmartphone.org/fso-makefile common
ln -s common/Makefile Makefile
make fso-gta02-testing-image

You can also use alternative FSO git repository

Building manually

While convenient, building with FsoMakefile does not tell you much about what is going on under the hood. FsoMakefile automatically downloads an OpenEmbedded build tree, configures it to build FSO and then builds the image.

NOTE: The output from running the FsoMakefile is *exactly* the same output you get from running bitbake commands manually. And the configuration files produced by the 'setup' target in the FsoMakefile are *exactly* the same configuration files you would create manually. So I just don't get why people say that using a Makefile doesn't tell you much about what is going on under the hood. I think the difference is whether someone actually cares to look at what is going on or not. - RodWhitby


OpenEmbedded's manual build directions at http://wiki.openembedded.net/index.php/Getting_Started describe the process in more detail. They also explain how to build individual packages, and describe bitbake, which manages OpenEmbedded builds.

OpenEmbedded targets a number of devices, and their package database can produce a number of different images. Therefore, as you follow their directions, you will need to modify them to build FSO for your device.

First, when you edit the targets in local.conf, you need to set it to build an Openmoko distribution.

If you wanted to build FSO for a Neo1973, you would write this:

BBFILES = "/stuff/org.openembedded.dev/packages/*/*.bb"
DISTRO = "openmoko"
MACHINE = "om-gta01"

To build FSO for a FreeRunner, you would write this:

BBFILES = "/stuff/org.openembedded.dev/packages/*/*.bb"
DISTRO = "openmoko"
MACHINE = "om-gta02"

If you want to build FSO's unstable branch then include the following two lines at the end of local.conf:

require conf/distro/include/fso-autorev.inc
require conf/distro/include/moko-autorev.inc

These two .inc files tell bitbake to use the most recent versions of each package, instead of the (hopefully tested) preferred versions.

Once you've finished setting up the build environment, you can build the FSO image with the command:

cd /stuff/build && bitbake fso-image
NOTE: If you want to run manual bitbake commands after setting things up using the FsoMakefile, then don't forget to source the setup-env file first.


Configuration

NOTE: This section should be it's own page...


GTK

Currently GTK is not well supported in the FSO build. To use GTK applications you'll most likely have to install the gtk library, and the Openmoko theme.

Step 1) Install the ipk-packages

opkg install openmoko-icon-theme-standard2 moko-gtk-engine

Step 2) Enable Theme

nano /etc/gtk-2.0/gtkrc

Add this line to the top:

include "/usr/share/themes/Moko/gtk-2.0/gtkrc"

Step 3) Set icon theme

nano /etc/gtk-2.0/gtkrc
Add the line:
gtk-icon-theme-name="openmoko-standard"

Step 4) Third party themes (optional)

Add one line per 'third-party' gtk theme you've installed. For example, openmoko-mediaplayer is not packaged with FSO:

include "/usr/share/themes/Moko/gtk-2.0/openmoko-mediaplayer"

Step 5) Other tweaks

To get "2007.2-style" icons (no text, smaller), so that all the terminal buttons fit on the screen at once:

gtk-toolbar-style = GTK_TOOLBAR_ICONS
gtk-icon-sizes = "gtk-button=32,32:gtk-small-toolbar=16,16:gtk-large-toolbar=24,24"

And make any other changes you like. I don't like double arrows on the tops and bottoms of sliders:

GtkScrollbar::has_secondary_backward_stepper = 0
GtkScrollbar::has_secondary_forward_stepper = 0

Look at existing gtkrc files for more options (if you find the manual, add a link).

Personal tools