Video Tutorial
If you prefer annotated videos to wiki pages, there is couple of videos available for Linux users.
- Setting up a Linux Firefox build environment by Brian
- How to Build Firefox by saurabh
Hardware
- 2G RAM with lots of available swap space. Additional RAM will significantly decrease build time.
- For debug builds: at least 8 GB free disk space
- For optimized builds: at least 1 GB free disk space (6 GB recommended)
Build Tools and Dependencies
Most Distros - One Line Bootstrap Command
Try to run the following to install all system prerequisites:
wget -O bootstrap.py https://hg.mozilla.org/mozilla-central/raw-file/default/python/mozboot/bin/bootstrap.py && python bootstrap.py
If you are behind proxy use the following method:
Set up your environment variables to appropriate proxy server address like this:
export http_proxy=https://username:password@PROXY_SERVER_ADDRESS/
export https_proxy=https://username:password@PROXY_SERVER_ADDRESS/
Now, run the wget command to install the system prerequisites:
wget -O --proxy-user=username --proxy-password=password bootstrap.py https://hg.mozilla.org/mozilla-central/raw-file/default/python/mozboot/bin/bootstrap.py && python bootstrap.py
If this doesn't work, continue on to one of the sections below.
Python
Note that Python3 is the default python
in e.g. Arch Linux, but Mozilla requires Python2, which is installed above. There are a few ways to work around this. One is to add
mk_add_options PYTHON=/usr/bin/python2
to your .mozconfig
file.
Other distros, and other Unix-based systems
On other systems, you can install the tools individually:
mkdir ~/bin ln -sf `which python2` ~/bin/python
- A recent POSIX Shell
- A C++ compiler. GCC 4.7 or higher is required. Again, please note that as of Firefox 38, GCC 4.6 and earlier are no longer supported, and will not work; your platform's native compiler may work, provided it supports those features of C++11 that the Firefox codebase relies on, which are listed here. (Firefox 37 requires GCC 4.6 or higher).
- Perl 5.6 or higher. Older perl versions may work if you upgrade File::Spec to version 0.8
- GNU make 3.80 or higher. Other varieties of "make" will not work.
- the GTK2 widget toolkit, version 2.10 or higher
- As of Firefox 42, the GTK3 widget toolkit, version 3.4 or higher
- libXt-devel for X11/Intrinsic.h, X11/Shell.h
- libIDL 0.6.3 or higher Source snapshots are available from Mozilla via ftp. If using the RPMs, you'll need both the regular rpm and the -devel rpm. If you already have ORBit installed, then you do not need to install libIDL as ORBit bundles libIDL. You may need to install the ORBit-devel package if you use packages.
- zip 2.3 (or higher)
- freetype 2.1.0 (or higher)
- fontconfig
- libgstreamer 0.10 (or higher) and its base plugins
- pkg-config 0.9.0 (or higher)
- dbus-1-glib-devel (Developer package for D-Bus/GLib bindings)
- libasound2-dev (needed for audio playback support)
- pulseaudio-libs-devel (preferred for audio over ALSA)
- libnotify-dev
- Yasm version 1.1.0 or newer.
- Python 2.7.3 or later. Python 3 will not work.
- autoconf-2.13 (requires GNU m4) - Autoconf 2.5x will not work. See bug 104642 for details.
- binutils-avr
To install autoconf-2.13 from source:
wget https://ftp.gnu.org/gnu/autoconf/autoconf-2.13.tar.gz tar -xvzf autoconf-2.13.tar.gz cd autoconf-2.13/ ./configure --program-suffix=2.13 make sudo make install
Additional Information
- For errors pertaining to alsa/ogg support: https://developer.mozilla.org/en-US/docs/alsa
Document Tags and Contributors
Tags:
Contributors to this page:
egberts,
mhoye_moz,
glandium,
sshagarwal,
wiml,
shianyow,
ahal,
bobowen,
crisron,
aki237,
raniere,
emol,
Richpercell,
chaddcw,
Rufflewind,
fqueze,
mdas,
WG9s,
anushbmx,
Sheppy,
edhel,
ananthulasrikar,
bits3rpent,
flying-sheep,
kscarfone,
Jez9999,
Kinetik,
gcp,
TarasGlek,
teoli,
estevamdf,
Kbrosnan,
jdm,
Heycam,
srh,
salehqt,
Imphil,
gregg.lind,
edulix,
Grubshka,
sawrubh,
BrianDiPalma,
WakeP,
ethertank,
gps,
chrisccoulson,
isaacaggrey,
shawnl,
stasm,
mcpherrinm,
IanN,
khuey,
bjacob,
jrmuizel,
jlebar,
Josh,
Nth10sd,
akuckartz,
cpearce,
Waldo,
csaltos,
altape,
Taken,
Ms2ger,
k2lp5p,
leftturnsolutions,
Fantasai,
AxelHecht,
Kray2,
Jorend,
BenjaminSmedberg,
MarkFinkle,
PWeilbacher,
Dholbert,
gandalf,
Bielawski,
Mike.wu,
Chipmunc56,
armenzg,
Tdog3140,
SteveLee,
George3,
DBaron,
Mgjbot,
Molla,
Leofiore,
Mook,
Mhs0,
Takenbot,
Simplex,
Preed,
Dria,
BenoitL,
Electrolysis
Last updated by:
egberts,