###The development of B2G is discontinued
But an old working image still exists. Find out how to install it here:
If anything ever changes and B2G development starts again feel free to edit this wiki.
here lie the remains of a dead post
The current version of B2G is still a Beta Version and it only works partially on the Fairphone 2, so please only continue when you are completely aware of what you are doing
It is recommended to perform a backup of your current system e.g. using twrp
Before You start
Make shure you have performed a backup of all your partitions, if you don’t know how, here is a manual:
- If you are using a Linux Distribution, you should allow
adb
andfastboot
to access your device:
Add a file/etc/udev/rules.d/51-android.rules
with the following content (if not already done):
SUBSYSTEM==“usb”, ATTR{idVendor}==“18d1”, ATTR{idProduct}==“d00d”, MODE=“0600”, OWNER=“user”
and replace user
with your username. Then run sudo service udev reload
2. Turn off your device, connect it to your computer and hold down the Volume Down Button while pressing the Power button. If you can see the Fairphone logo you have accessed the fastboot mode.
3. Download the manual installation version of Fairphone Open Source OS and extract the .zip Archive.
4. Open a shell in the directory you placed your files in and run fastboot flash recovery recovery.img
This will flash the TWRP Recovery to your flash partition. Without a working recovery you may not be able to restore the functionality of your device after something went wrong
5. Reboot your device by typing in fastboot reboot
and shut it down again. Then start the TWRP recovery by holding down the Volume Up button while pressing the Power button.
6. If you have a MicroSD-card inserted you can perform a backup to the card, if not perform a backup to the internal memory, reboot and copy the TWRP directory of your internal memory to your computer.
If something went wrong during the installation process you can flash back the TWRP recovery in case it got overwritten, then you can write back the TWRP directory to your internal memory e.g. using by connecting to your phone while the recovery is loaded in case you didn’t backup to a MicroSD-card and finally restore your backup.
First of all there are 2 ways of how to get B2G working on the Fairphone 2. For both ways you either need Linux (64-Bit) or Mac OS X installed on your machine.
B2G-installer (recommended)
More information can be found here link:
Make sure you have the factory or the Fairphone Open Source version of the Fairphone OS installed on your device.
- Download a current version of Firefox Nightly (a beta version of Firefox): link
- Create a new profile for Firefox Nightly by running
./firefox -P
in the directory Nightly was placed and inactivate add-on signature:
Type inabout:config
and disablexpinstall.signatures.required
- Install ADB Helper link and b2g-installer link
- Connect your device and open
about:b2g-installer
and follow the steps shown. (Currently the b2g-installer does not find the nightly build of Juan. A download link can be found here: link) - Congratulations: Your device should now be flashed with a nightly build of B2G/Firefox OS.
Compile it on your own (currently not working with Ubuntu 16.04)
Make sure you have at least 4GB of RAM and 40GB of free disk space. Additional information can be found here, here and here.
- Install
adb
andfastboot
- For Ubuntu 14.04 install the following packages:
sudo apt-get install --no-install-recommends autoconf2.13 bison bzip2 ccache curl flex gawk gcc g++ g+±multilib git lib32ncurses5-dev lib32z1-dev libgconf2-dev zlib1g:amd64 zlib1g-dev:amd64 zlib1g:i386 zlib1g-dev:i386 libgl1-mesa-dev libx11-dev make zip lzop libxml2-utils openjdk-7-jdk nodejs unzip python
For Ubuntu 16.04 you have to switch back to version 3.81 of make, newer versions cause build errors. This can be done by adding the main repository of trusty
to your sources.list
, installing version 3.81 of make and running sudo apt-mark hold make
.
Afterwards you have to install the following packages:
sudo apt-get install --no-install-recommends autoconf2.13 bison bzip2 ccache curl flex gawk gcc g++ g+±multilib git lib32ncurses5-dev lib32z1-dev libgconf2-dev zlib1g:amd64 zlib1g-dev:amd64 zlib1g:i386 zlib1g-dev:i386 libgl1-mesa-dev libx11-dev zip lzop libxml2-utils openjdk-8-jdk nodejs unzip python
For Mac OS X you need do the following:
TODO (ask @novski )
3. Create a new folder and clone the git repository of B2G
git clone git://github.com/mozilla-b2g/B2G.git && cd B2G
configure and download the source code (this will take a lot of time but you only need to do it once):
./config.sh fairphone2
To improve the building speed you could activate ccache by running:
ccache -M 50G
Then start to build your system:
./build.sh
This will take 3-5 hours depending on your machine.
4.If no errors occurred, you can flash it to your device:
./flash.sh
Additional Information
As you may have noticed Mozilla announced that they will not continue to support B2G OS for smartphones, but the community of B2G OS is still active an continues the support of the OS.
Currently there aren’t many Apps available for B2G OS. If you miss an App think of creating one on your own and publishing it in the marketplace. Different to other mobile systems like Android B2G Apps are some kind of (local) website, written in html, css and JavaScript. So it is easier for Web developers to create an App.
More information about this can be found here.
Latest News:
PS: This is a wiki now. Please contribute and keep it up-to-date.