Current build and test status:
The following build combinations are tested automatically for each PR (the current config only allows to generate 1 summary badge, for everything):
- all supported Yocto versions (Kirkstone, Scarthgap, Styhead, Walnascar/master)
- both ESR and latest Firefox version
- glibc and musl
- 4 arches: arm, aarch64, riscv-64 and x86-64
All combinations of the above are tested, except for RISC-V@Kirkstone combinations, which are not tested.
This layer provides web browser recipes for use with OpenEmbedded and/or Yocto.
This layer depends on oe-core (poky), meta-oe and meta-clang. Additionally, the Rust version shipped with Kirkstone and Scarthgap oe-core is out of date, which can be remediated by other third-party layers: for Kirkstone and Scarthgap version the corresponding branch of meta-lts-mixins is required for up to date Rust compiler. It is fairly easy to make meta-rust layer work also, however there is no out of box support for it anymore.
For the tested revision/release combinations, see meta-firefox-test repository, especially the kas folder - that contains all the branch/revision information used for testing.
meta-clang
layer requires libstdc++
to be installed on the build machine - make sure to
install it, in case it is missing (e.g. on Debian based systems install libstdc++-dev
or
on Fedora install libstdc++-devel
)
Note: Firefox requires at least Rust 1.76 starting from version 127, and Rust 1.82 from version 137.
At this time the state of Rust in the Yocto ecosystem is not the best. Master/Walnascar provides 1.83 - so this works for all Firefox. meta-lts-mixins layers however are below 1.82 for both Kirkstone and Scarthgap, and until this doesn't change, meta-rust layer should be used.
For Styhead there is no up to date Rust available officially.
When using meta-rust, make sure to add the following to a bbappend or local.conf:
# when using a bbappend
RUST_HOST = "${BUILD_SYS}"
RUST_TARGET = "${TARGET_SYS}"
# when using local.conf
RUST_HOST:pn-firefox = "${BUILD_SYS}"
RUST_TARGET:pn-firefox = "${TARGET_SYS}"
Due to this, the selection of Rust provider needs some caution. Testing is performed using the following combinations (the "latest" version should also be able to compile "ESR"):
Yocto version | Rust version ESR | Rust version latest |
---|---|---|
Kirkstone | Rust 1.80.1 from meta-lts-mixins (kirkstone/rust branch) | Rust 1.82.0 from meta-rust |
Scarthgap | Rust 1.81.0 from meta-lts-mixins (scarthgap/rust branch) | Custom Rust 1.82 - Note1 |
Styhead | Rust 1.79 from oe-core | N/A - Note2 |
Walnascar | Rust 1.83.0 from oe-core | Rust 1.83.0 from oe-core |
Note1: The latest available Rust for Scarthgap is 1.81.0 in meta-lts-mixins layer. Meta-rust layer claims to have version 1.82.0 and is compatible with Scarthgap, however unfortunately in practice it throws various errors. I expect meta-lts-mixins to be updated in the foreseeable future, however until then I have backported some relevant patches from oe-core master to a fork of meta-lts-mixins: https://github.com/OldManYellsAtCloud/meta-lts-mixins Testing was performed successfully using this Rust version. Note that this fork mostly for testing, and while I am willing to support it to build Firefox, in general it shouldn't be used for other things than experimenting.
Note2: The latest available Rust for Styhead is 1.79 at the time of writing this, and that branch is only weeks away from being EOL. Due to this, the latest Firefox version was not tested with it. In case you find up-to-date enough recipes for Rust that work on Styhead, Firefox should work also. In case support is needed, I can only provide very limited about for this combination.
The preferred way to contribute to this layer is to send GitHub pull requests or report problems in GitHub's issue tracker.
Classic patch submissions via email are not accepted for this layer.
- OldManYellsAtCloud/Gyorgy Sarvari skandigraun@gmail.com
recipes-browser/firefox: Firefox browser.
This recipe provides a package for the Firefox web browser.
Two separate recipes are available: one for the latest stable version, and one for the latest ESR version.
recipes-browser/firefox-i10l: Language packs for Firefox. The default language is English, but installing any of these packages will make the new language available in the settings menu.
-
alsa: (detected automatically) Enable ALSA support to play audio. It will be enabled automatically when DISTRO_FEATURES contains "alsa". Note that Firefox's default audio backend is PulseAudio, not ALSA. Although it's not enabled in official build, we enable it by default to make easy to play audio without additional daemons. When PulseAudio is running, it will be used instead of using ALSA directly even if this config is specified.
-
wayland: (detected automatically) Enable wayland support. It will be enabled automatically when DISTRO_FEATURES contains "wayland".
-
gpu: (off by default) Enable GPU acceleration.
-
openmax: (off by default) Enable OpenMAX IL decoder to play H.264 video. This features is confirmed only on Renesas RZ/G1. Note: it is untested with version 113+.
-
webgl: (off by default) Firefox on Linux doesn't enable WebGL against most GPUs by default. This option adds a config file to enable it forcedly.
-
forbid-multiple-compositors: (off by default) This option allows to create only one GPU accelerated compositor, second and the following windows will use basic compositors. Multiple compositor may cause crash on platforms that doesn't support multiple EGL windows.
-
disable-sandboxed-libraries: (off by default) By default WASM libraries are sandboxed for security purposes, however that can introduce quite a big build-time overhead due to extra dependencies. Setting this disallows sandboxing these libraries, and removes the wasi-sdk dependency.
-
disable-gecko-profiler: (on by default, only v127+) Disable collecting profile statistics in different components of the browser. Reduces resource and size footprint (though not drastically).
-
rust-simd: (on by default) Enable explicit SIMD in Rust code, when supported by the CPU.
-
wayland-only: (off by default, only v120+) Don't build Firefox with X11 dependencies. This config should not be enabled if x11-only is enabled.
-
x11-only: (off by default, only v120+) Don't build Firefox with Wayland dependencies. This config should not be enable if wayland-only is enabled.
-
system-av1: (off by default) Use system av1. Currently untested.
-
system-nspr: (off by default and autodetected in some cases) Use NSPR from the operating system, instead of building it with Firefox. In case an ARM CPU is the target without cryptographic capabilities, this config is automatically enabled.
-
system-nss: (off by default and autodetected in some cases) Use NSS from the operating system, instead of building it with Firefox. In case an ARM CPU is the target without cryptographic capabilities, this config is automatically enabled.
-
system-ffi: (off by default) Use system libffi
-
system-icu: (off by default) Use system ICU.
-
system-zlib: (off by default) Use system libz.
-
system-pixman: (off by default) Use system pixman.
-
system-jpeg: (off by default) Use system libjpeg.
-
system-libevent: (off by default) Use system libevent.
-
system-libvpx: (off by default) Use system libvpx.
-
system-png: (off by default) Use system libpng (APNG support is required).
-
system-webp: (off by default) Use system libwebp.
While the source tarballs contains most of the compile dependencies, unfortunately some are missing, making it
impossible to build Firefox without network connection. Due to this the Rust crates are downloaded directly
(the list of downloaded crates and their version is taken from the third_party/rust
folder), and some are downloaded
from git directly (for the most part these were gathered from the top level Cargo.toml
). This section hopefully
documents where those magic commit hashes come from. (And will also be helpful for me, when I'm trying to figure
out where a specific dependency is coming from during updating to new versions).
In case a dependency is required by multiple sources, and they specify different versions, the latest version is taken into account only.
Note: the dependency column refers to the destsuffix
used in the recipes.
Firefox version | Dependency | Used commit | Source / Comment |
---|---|---|---|
128.9.0esr + 137.0 | any_all_workaround | 7fb1b7034c9f172aade21ee1c8554e8d8a48af80 | Required by top level Cargo.toml |
128.9.0esr + 137.0 | chardetng | 3484d3e3ebdc8931493aa5df4d7ee9360a90e76b | Required by top level Cargo.toml |
128.9.0esr + 137.0 | chardetng_c | ed8a4c6f900a90d4dbc1d64b856e61490a1c3570 | Required by top level Cargo.toml |
128.9.0esr + 137.0 | coremidi | fc68464b5445caf111e41f643a2e69ccce0b4f83 | Required by top level Cargo.toml |
128.9.0esr + 137.0 | cose | 43c22248d136c8b38fe42ea709d08da6355cf04b | Required by top level Cargo.toml |
128.9.0esr + 137.0 | midir | 85156e360a37d851734118104619f86bd18e94c6 | Required by top level Cargo.toml |
128.9.0esr + 137.0 | cubeb-pulse | 8678dcab1c287de79c4c184ccc2e065bc62b70e2 | Required by toolkit/library/rust/shared/Cargo.toml |
128.9.0esr + 137.0 | wpf-gpu-raster | 99979da091fd58fba8477e7fcdf5ec0727102916 | Required by toolkit/library/rust/shared/Cargo.toml |
128.9.0esr + 137.0 | unicode-bidi | ca612daf1c08c53abe07327cb3e6ef6e0a760f0c | Required by top level Cargo.toml |
128.9.0esr | jsparagus | 61f399c53a641ebd3077c1f39f054f6d396a633c | Required by js/src/frontend/smoosh/Cargo.toml |
128.9.0esr | gpu-descriptor | 7b71a4e47c81903ad75e2c53deb5ab1310f6ff4d | Required by top level Cargo.toml |
128.9.0esr | aa-stroke | d94278ed9c7020f50232689a26d1277eb0eb74d2 | Required by toolkit/library/rust/shared/Cargo.toml |
128.9.0esr | warp | 9d081461ae1167eb321585ce424f4fef6cf0092b | Required by top level Cargo.toml |
128.9.0esr | application-services | 7c275b9088557abcbc8f3c2834f9aaa9064ca5e4 | Required by top level Cargo.toml |
128.9.0esr | mio | 9a2ef335c366044ffe73b1c4acabe50a1daefe05 | Required by top level Cargo.toml |
128.9.0esr | mp4parse | a138e40ec1c603615873e524b5b22e11c0ec4820 | Required by toolkit/library/rust/shared/Cargo.toml |
128.9.0esr | cubeb-coreaudio | 8bce3b333a920999055397a397e59c2b81a93b9a | Required by toolkit/library/rust/shared/Cargo.toml |
128.9.0esr | audioipc | e1071472c55193032aa4c1403317844005f9d0fc | Required by toolkit/library/rust/shared/Cargo.toml |
128.9.0esr | mapped_hyph | c7651a0cffff41996ad13c44f689bd9cd2192c01 | Required by toolkit/library/rust/shared/Cargo.toml |
128.9.0esr | Required by netwerk/socket/neqo_glue/Cargo.toml - Not used by 128.9.0esr, uses vendored version. |
||
128.9.0esr | wgpu | c7458638d14921c7562e4197ddeefa17be413587 | Required by gfx/wgpu_bindings/Cargo.toml |
137.0 | application-services | 25934715ecc08fc922c80797c637dea64ee742d1 | Required by top level Cargo.toml |
137.0 | mp4parse | e64650a686e5c5732395cd059e17cfd3b1e5b63b | Required by toolkit/library/rust/shared/Cargo.toml |
137.0 | aa-stroke | a821fa621c2def48e90c82774b4c6563b5a8ea4a | Required by toolkit/library/rust/shared/Cargo.toml |
137.0 | cubeb-coreaudio | 2407441a2f67341a0e13b4ba6547555e387c671c | Required by toolkit/library/rust/shared/Cargo.toml |
137.0 | audioipc | e6f44a2bd1e57d11dfc737632a9e849077632330 | Required by toolkit/library/rust/shared/Cargo.toml |
137.0 | mapped_hyph | eff105f6ad7ec9b79816cfc1985a28e5340ad14b | Required by toolkit/library/rust/shared/Cargo.toml |
137.0 | neqo | f8946d5187271b3e63e8d0209343510bdeac1451 | Required by netwerk/socket/neqo_glue/Cargo.toml |
137.0 | wgpu | 93f64dc847a0e6788b17b292ae4d7d59361e3be0 | Required by gfx/wgpu_bindings/Cargo.toml |
137.0 | glutin | 03285da9c14ec56296c2400c781d2c32b80d745a | Required by gfx/wr/Cargo.toml |
137.0 | nss-gk-api | e48a946811ffd64abc78de3ee284957d8d1c0d63 | Required by top level Cargo.toml and third-party/rust/mls-rs-crypto-nss/Cargo.toml |
137.0 | mls-rs | b747d7efb85a776b97ad8afa8d1b32893fa5efa3 | Required by third_party/rust/mls-platform-api/Cargo.toml crate |
137.0 | mls-platform-api | 5d88241b9765cae3669aba21f0946bd3700f7db1 | Required by security/mls/mls_gk/Cargo.toml |
137.0 | objc | 4de89f5aa9851ceca4d40e7ac1e2759410c04324 | Required by top level Cargo.toml |
137.0 | osmesa-src | a9c57bae855c8a16c8397c04127f75ab14171c81 | Required by gfx/wr/wrench/Cargo.toml |