Monday, August 11, 2014

What went wrong with Firefox OS compiling (and how I fixed them all)

Firefox OS 2.1 pre is running on my Nexus 4 at the moment. How does that sound? I'm very pleased myself. Happy I would say. Read on and I tell you what went wrong and how I fixed them all.

Wilson Page is a Firefox OS developer at Mozilla. He has compiled Firefox OS for Nexus 4. His instructions seemed pretty straight forward. Not too many steps. So I decided to try it myself.

My Ubuntu Linux was NOT up-to-date. Apps and libraries which are needed when compiling Firefox OS were missing. So I read through these instructions from Mozilla Developer site and installed required software. For me this part of the compiling was the most challenging. So if you face problems have some more coffee and chewing gum. Don't give up. Try to make sure all necessary software is installed.

After the survival of the software installation needed I started to type in commands. The next command copies Boot2Gecko-files from server to a local directory:

git clone https://github.com/mozilla-b2g/B2G.git

Then I moved to directory B2G:

cd B2G

The next part took long time. Before the actual compilation some configuration is needed. In my case for Nexus 4:

./config.sh nexus-4

Building also took long time. Once again I was desperate. All kind of messages were showing up on screen. I wasn't sure if I was going to succeed:

./build.sh

No errors showed up after building (which *did* many times before when compilation process failed!). As a *root* I gave the next command and saved a prayer:

./flash.sh

Nexus 4 booted and after a while Firefox OS 2.1 pre was up and runnning.

I hate compiling. Nothing works. Errors here and there. Maybe compiling a whole operating system is just too much for me. Too technical. That's why I'm so pleased I finally succeeded with Firefox OS 2.1. Tried many times! Couldn't be happier!

My Nexus 4 running Firefox OS 2.1 pre

Icons really are big enough!