This article provides a reference for all the B2G build, Gaia build, and Gecko build variables and commands you might need during Firefox OS-related build operations.
See the Gaia MakeFile for the definition of all these variables.
- Some commands can act on all of gaia or on one application only. This environment variable defines if we want a command to act on one app only, and if so, which app.
- Ensures that the system apps are installed on the system partition.
- This defines the folder where the profile will be generated. By default it's
gaia/profilefor normal profiles and
DEBUG=1profiles (see below.)
- When set to 1, the generated profile is suitable to be used with Firefox desktop or the Firefox OS simulator (B2G Desktop):
DEBUG=1 DESKTOP=0 make.
This includes the
httpd.jsextension and configured preferences so that you can access applications using
app://<appname>.gaiamobile.org/. Some applications are known to work like this, most notably the SMS application.
- This includes a set of extensions in the
DEBUGprofile to allow the Gaia System app to be loaded in Firefox. This is quite broken these days and deprecated in favor of Mulet. It's set to 1 by default when
DEBUG=1is used, but because this is really broken these days, so you'll want to disable it.
Be careful as this also doesn't work with the Firefox OS Simulator (B2G Desktop) at all.
- Enables a more developer-friendly experience: turns on adb debugging with devtools, disables the lock screen, and enables prefs to allow debugging of certified apps.
- When set to 0, this sets a preference in the profile to disable screen timeout.
- Essentially an alias for
- Creates a production build (rather than engineering); Facebook app id and some other production app ids are used with this. Alternatively
make productionwill work
- When set to 1 this runs optimization steps when building Gaia applications such as JS code minification. Not all gaia applications are affected by this, as the feature is opt-in.
- The pixel density of the target device. This affects which image and/or video assets are copied into the build. This defaults to 1, but higher spec devices need higher resolultion assets — for example the Flame should use a value of 1.5. It is aliased as
- Turns on Dogfood Gaia build.
- When nonzero, a Mozilla-branded build will be produced. The default is 0.
- Use this to specify a customized Gaia; see the Market customizations guide for more details.
- When set to 1, this sets a preference in the profile to disable the FTU.
- Enables performance marks and measures to output metadata to logcat. Usage:
RAPTOR=1 make reset-gaia
- Use this to turn on the privacy panel; the default is off, except in engineering builds.
The following is an abbreviated list of the most common commands you'll need. A much more detailed list can be found in the Gaia make options reference.
- Makes only the profile.
- Deletes the previous profile and installs a new Gaia profile.
- Installs Gaia on top without deleting anything.
- Does the same thing as
PRODUCTION=1 make reset-gaia.
- Removes the generated profile.
- Removes the generated profile and the directory's xul-runner; you should only run this when things are totally borked.
- Sets the build id to a specific build date/time.
- Specifies the Gecko variant you want to build. Valid types are detailed below:
This is the default flavor. A plain
This is the flavor intended for final release.
The same as
Note: This table is inspired by the Android Build Variants table.
- Makes build symbols for debugging; see Uploading symbols to Mozilla's symbol server.
- Creates an OTA mar file; see Firefox OS update packages.
- Creates a FOTA mar/zip based on files containing only a subset of files and directories; see Firefox OS update packages.
- Creates a FOTA mar/zip based on files; see Firefox OS update packages.
- Creates a FOTA mar/zip based on partitions; see Firefox OS update packages.