- 1 (one) copy of clang, preferably on the new side
- 1 (one) source tree containing mozilla-central
- 4 (four) GiB (that's 230, not 109) of memory
- Linux (these instructions not tested on OS X, so it may or may not work for you)
For the sake of example, I have clang installed to /usr/local; substitute as appropriate for your environment. Configure mozilla-central with the following mozconfig:
# -O4 tells clang to do LTO ac_add_options --disable-debug --enable-optimize='-O4' # Exclude this line, and your will use over 10x the amount of memory. ac_add_options --disable-debug-symbols # Build with clang export CC=/usr/local/bin/clang export CXX=/usr/local/bin/clang++ # These flags are necessary to get elfhack to compile export LDFLAGS='-Wl,-z,norelro -flto' # This flag is necessary to link properly export RANLIB='ar -s --plugin /usr/local/lib/LLVMgold.so'
You may season with other configure options as desired. Configure and let build for a few hours. Admire the build process as most individual files get compiled much quicker, but be displeased when link times explode. Enjoy!