A people asks me about how to build Firefox/riscv64. Since all patches to build it are merged, so the instruction is updated from previous. The following instruction is on Ubuntu 22.10 on riscv64gc
- Clone firefox code from mozilla official repository
hg clone https://hg.mozilla.org/mozilla-central
(Mercurial)git clone https://github.com/mozilla/gecko-dev
(git).
- Change current directory to cloned directory
cd mozilla-central
(if using mercurial)cd gecko-dev
(if using git)
- Create
mozconfig
file in current dicrectory. File content is the followingmk_add_options MOZ_OBJDIR=@TOPSRCDIR@/objdir mk_add_options AUTOCLOBBER=1 ac_add_options --enable-application=browser ac_add_options --disable-debug ac_add_options --enable-optimize ac_add_options --disable-tests ac_add_options --without-wasm-sandboxed-libraries
- Install rust. See rustup.rs
- Install clang and nodejs
sudo apt install clang nodejs
- Run
./mach bootstrap
and select "2. Firefox for Desktop" - Run
./mach configure
- Run
./mach build
. It spends 8-9 hours.
Enjoy!
0 件のコメント:
コメントを投稿