The purpose of this article is to compare the software build tools used by the open source applications presented on the kezacode website. This article will be enriched over time.
The following software will be compared:
The build steps are similar, although it can be observed that each application relies on different, even specific, tools. Several phases can be distinguished:
This article does not cover the code download phase, the testing phase, or continuous integration infrastructure in general.
| Application | Configuration | Specific ? |
|---|---|---|
| Chromium | GN Build configuration | Yes |
| Firefox | Mozconfig ( + configure.py ) | Yes |
| Thunderbird | Mozconfig ( + configure.py ) | Yes |
| Libreoffice | GNU Autoconf ( + M4 scripts) | No |
| VLC | GNU Autoconf ( + M4 scripts ) | No |
| Linux Kernel | kconfig | Yes |
Android uses a envsetup.sh script and then the lunch tool to configure the target device. See here
Chromium relies on GN configuration: GN Build configuration. There is the args.gn file which contains the configuration chosen by the developer, and the main BUILDCONFIG.Gn file (which calls many others) for autoconfiguration.
Firefox and thunderbird use Mozconfig, see for example the configuration for thunderbird. Note an initial configuration script written in python (configure.py): it is not explicitly called by the developer who simply runs the BUILD with the [Mach] tool (https://firefox-source-docs.mozilla.org/setup/linux_build.html). Mach supports the configure option: mach configure
LibreOffice uses Autoconf (configure.ac), which generates a configure shell script which in turn generates a makefile containing all the configuration needed for compilation. Note that autoconf is based on the GNU M4 scripting language.
Videolan media player (VLC) uses Autoconf too.
Linux uses kconfig, the kernel configuration system. It allows developers to enable/disable/set kernel features. The result of the configuration step can affect the C code (enabling or disabling features via the preprocessor) and the make compilation (option considered by the makefile).
Most projects use a software build front-end, or a software meta-build tool. These tools simplify and automate the building of large projects. They facilitate abstraction from the target platform, facilitate dependency management, while providing good performance (depending on the solution). They often generate lower level build files (e.g. Make, Ninja) that are used to generate the final software.
| Application | Build Description | Specific ? | Compilation |
|---|---|---|---|
| Android | Google Soong | Yes | Ninja + Miscellaneous |
| Android (2) | Bazel | No | Miscellaneous |
| Firefox | Moz.build | Yes | Make, Visual Studio... |
| Thunderbird | Moz.build | Yes | Make, Visual Studio... |
| Libreoffice | GBuild (Macros Make) | Yes | N/A (Make) |
| VLC | GNU Automake | Non | Make |
| Linux Kernel | N/A | - | kbuild (Make) |
Chromium mainly uses Google GN (GN: Generate Ninja), which generates Ninja build files (the back end of software building, a more powerful and simpler equivalent to Make). Some Chromium components also use Bazel (see below).
Android mainly uses the [Soong] build front end (https://source.android.com/docs/setup/build), designed for Android. It uses the Android.bp (blueprint) build files. Soong and the build rules are written in the Go (or GoLang) language. Soong generates Ninja files, but also Make, Visual Studio, etc.
Android should gradually migrate from Soong to Bazel. Bazel is also an open source build system developed by Google and used by other open source projects. It supports more languages than Soong and provides a caching system to reuse the results of previous builds.
Firefox and Thunderbird use a meta-build system specific to Mozilla's needs, based on Moz.build (Front-end) and Python files. This allows for the generation of back-end build files such as GNU Make and Microsoft Visual Studio. Note that Thunderbird is built from the Firefox source code.
LibreOffice uses GBuild which is specifically designed for the needs of OpenOffice or LibreOffice. GBuild relies directly on Make through the use of advanced macros.
The Videolan Media Player (VLC) uses Automake (makefile.am files), an open-source solution from the GNU ecosystem that simplifies and automates the creation of Makefiles. Automake is designed specifically for C and C++.
Linux uses kbuild which relies on make. Makefiles are fed by the configuration generated by kconfig. The .config files define the options chosen. A makefile will take this into account when building a module for example.
This step is not detailed, as it is more traditional.