Project

General

Profile

Actions

Build Replicant 6.0

This page explains how to build Replicant 6.0 for supported devices.

Prerequisites

Before building, you must make sure that:

Warning

Do not build as root, always build as user.

See the build tips if you are facing issues.

Before building

  • On Debian stretch, building the toolchain will fail. See Replicant60BuildTips for how to workaround that and make the build succeed.

Building

All of the following build commands need to be run in the source tree root folder.

Building the toolchain

First, the toolchain needs to be built for replicant 6. To do that open a new shell and run the following command:

./vendor/replicant/build-toolchain

Building a Replicant image for a device

Once the toolchain has been built, you can then start building an image for a specific device.

Use the command corresponding to your device in this table to do that:

Device(s) Command
Galaxy S 2 (I9100) ./vendor/replicant/build.sh i9100
Galaxy S 3 (I9300) ./vendor/replicant/build.sh i9300
Galaxy S 3 4G (I9305) ./vendor/replicant/build.sh i9305
Galaxy Note (N7000) ./vendor/replicant/build.sh n7000
Galaxy Note 2 (N7100) ./vendor/replicant/build.sh n7100
Galaxy Nexus (I9250) ./vendor/replicant/build.sh maguro
Galaxy Tab 2 7.0 (P3100) ./vendor/replicant/build.sh espresso3g
Galaxy Tab 2 10.1 (P5100)
Galaxy Tab 2 7.0 Wi-Fi (P3110) ./vendor/replicant/build.sh espressowifi
Galaxy Tab 2 10.1 Wi-Fi (P5110)
Galaxy Note 8.0 (N5100) ./vendor/replicant/build.sh n5100
Galaxy Note 8.0 Wi-Fi (N5110) ./vendor/replicant/build.sh n5110

For instance to build for the Galaxy S3 (I9300) you need to type the following command:

./vendor/replicant/build.sh i9300

The first time you build an image it might ask you a few questions at various points during the build process as it needs then to build the images and generate the necessary signing keys near the end of the building process.

Output files

For the built host tools, the produced files are at: out/host/linux-x86/bin/

For the built target images, you can use the following table to find the directory that has the produced files:

Device(s) Output directory
Galaxy S 2 (I9100) out/dist/i9100/
Galaxy S 3 (I9300) out/dist/i9300/
Galaxy S 3 4G (I9305) out/dist/i9305/
Galaxy Note (N7000) out/dist/n7000/
Galaxy Note 2 (N7100) out/dist/n7100/
Galaxy Nexus (I9250) out/dist/maguro/
Galaxy Tab 2 7.0 (P3100) out/dist/espresso3g/
Galaxy Tab 2 10.1 (P5100)
Galaxy Tab 2 7.0 Wi-Fi (P3110) out/dist/espressowifi/
Galaxy Tab 2 10.1 Wi-Fi (P5110)
Galaxy Note 8.0 (N5100) out/dist/n5100/
Galaxy Note 8.0 Wi-Fi (N5110) out/dist/n5110/

For instance, for the Galaxy S 3 (I9300), the built target images are in out/dist/i9300/

The file names can change from version to version.

For Replicant 6.0 0004 RC2 the zip file name is replicant-6.0-0004-rc2-i9300.zip, whereas for replicant-6.0-dev branch or other previous releases the resulting zip file name will be replicant-6.0-i9300.zip.

A way to be sure of what file was just built is to use ls -l to show the time which represents the last time of modification:

For instance:

[...]out/dist/i9300$ ls -latr
total 1113288
[...]   6660096 Jan  1  2009 recovery-i9300.img
[...]      4096 Jul 22 00:50 ..
[...] 278175479 Aug 21 04:13 replicant-6.0-0004-rc2-i9300.zip
[...] 565995550 Sep  8 20:01 signed-target_files-i9300.zip
[...] 278261021 Sep  8 20:02 replicant-6.0-i9300.zip
[...]  10889357 Sep  8 20:02 signed-img-i9300.zip
[...]      4096 Sep  8 20:02 .

At the time of writing, it's the 9th September 2020, and I built images yesterday, so the resulting file is replicant-6.0-i9300.zip and not replicant-6.0-0004-rc2-i9300.zip.

Updated by Denis 'GNUtoo' Carikli over 3 years ago ยท 10 revisions

Also available in: PDF HTML TXT