This page contains old build instructions for Replicant 9. The source code is kept to do regression testing. Active development has moved into Replicant 10.
$ repo init -u https://git.replicant.us/contrib/replicant-next/manifest.git -b replicant-9-dev $ repo sync
Alternatively a shallow copy of the source tree can be fetched in order to save on disk space:
$ repo init -u https://git.replicant.us/replicant-next/manifest.git -b replicant-9-dev --depth=1 $ repo sync -c
To `unshallow` a specific module:
$ cd path/to/module $ git fetch --unshallow <remote>
sudo apt-get install bc bison build-essential bsdmainutils ccache curl flex g++-multilib gcc-multilib gettext git gnupg gperf imagemagick lib32ncurses5-dev lib32readline-dev lib32z1-dev liblz4-tool libncurses5-dev libsdl1.2-dev libssl-dev libwxgtk3.0-dev libxml2 libxml2-utils lzop python-mako pngcrush rsync schedtool squashfs-tools xsltproc zip zlib1g-dev sudo apt-get install gcc-5-arm-linux-gnueabi
Follow the i9300 manifest instructions:
$ subject='/C=US/ST=California/L=Mountain View/O=Android/OU=Android/CN=Android/emailAddress=android@android.com' $ mkdir .android-certs $ for x in releasekey platform shared media testkey; do \ ./development/tools/make_key .android-certs/$x "$subject"; \ done $ parallel_tasks=$(echo "$(grep 'processor' /proc/cpuinfo | wc -l ) + 1" | bc) $ source build/envsetup.sh $ lunch lineage_i9305-eng $ make -j${parallel_tasks} bacon
The images can then be flashed with heimdall. They are then in:
out/target/product/i9305/obj/PACKAGING/target_files_intermediates/lineage_i9305-target_files-eng.replicant/IMAGES/
$ rm -rf .repo/manifests/ # This enables me to force push and rebase the manifest repository as well $ repo init -u https://git.replicant.us/replicant-next/manifest.git -b replicant-9-dev $ repo sync --force-sync
$ repo sync --force-sync
$ sudo heimdall flash --BOOT out/target/product/i9305/obj/PACKAGING/target_files_intermediates/lineage_i9305-target_files-eng.replicant/IMAGES/boot.img --USERDATA out/target/product/i9305/obj/PACKAGING/target_files_intermediates/lineage_i9305-target_files-eng.replicant/IMAGES/userdata.img --SYSTEM out/target/product/i9305/obj/PACKAGING/target_files_intermediates/lineage_i9305-target_files-eng.replicant/IMAGES/system.img
As the device IDs are the ones given by the Linux kernel, they are not in the adb udev rules, so for now it requires to run adb as root:
$ sudo adb shell * daemon not running; starting now at tcp:5037 * daemon started successfully i9305:/ # $ sudo adb kill-server $ adb shell * daemon not running; starting now at tcp:5037 * daemon started successfully error: no devices/emulators found
$ adb kill-server $ sudo adb shell * daemon not running; starting now at tcp:5037 * daemon started successfully i9305:/ #
At some point during boot, the device goes into suspend, so you will need to press some buttons like the power or volume button to make the boot continue until the graphical interface.
You can also follow the boot progress with adb:
adb logcat adb logcat -b main
Note that the device can go into suspend at any time, so adb might be interrupted. That looks like that:
First you get a shell
$ sudo adb shell i9305:/ #
Then the connection is interrupted:
$ adb shell i9305:/ # [randomdev@fullyfreelaptop ]$
The effect with adb logcat is similar.
To use SwifShader you need a kernel that supports UDIV/SDIV emulation, you can checkout the branch GNUtoo/udiv-emulation for kernel/replicant/linux. After doing that that run the following commands to use SwiftShader:
$ adb remount $ adb shell i9305:/ # rm vendor/lib/egl/libGLES_mesa.so # or move it somewhere safe meanwhile you test SwiftShader i9305:/ # nano system/build.prop # set ro.hardware.hwcomposer=ranchu and ro.hardware.gralloc=default $ adb reboot
First get the source code:
$ repo init -u git://git.putti.eu/aosp/manifest_i9305.git -b android-9.0.0
sudo apt-get install git-core gnupg flex bison gperf build-essential zip curl zlib1g-dev gcc-multilib g++-multilib libc6-dev-i386 lib32ncurses5-dev x11proto-core-dev libx11-dev lib32z-dev libgl1-mesa-dev libxml2-utils xsltproc unzip bc python-mako gcc-5-arm-linux-gnueabi
Once this is done, see the device/putti/i9305/README.md for the build instructions.