Skip to content

Instantly share code, notes, and snippets.

@sooorajjj
Last active March 3, 2020 12:33
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save sooorajjj/14fe01733d454e01ad2049a232a74b38 to your computer and use it in GitHub Desktop.
Save sooorajjj/14fe01733d454e01ad2049a232a74b38 to your computer and use it in GitHub Desktop.
Fairphone 3 build and flash TWRP
mkdir twrp
cd twrp
repo init --depth=1 -u git://github.com/minimal-manifest-twrp/platform_manifest_twrp_omni.git -b twrp-9.0
mkdir .repo/local_manifests/
tee .repo/local_manifests/FP3.xml << EOF
<?xml version="1.0" encoding="UTF-8"?>
<manifest>
<project name="chaosmaster/android_device_fairphone_fp3" path="device/fairphone/FP3" remote="github" revision="android-9.0" />
<project name="chaosmaster/android_kernel_fairphone_sdm632" path="kernel/fairphone/sdm632" remote="github" revision="twrp-9.0" />
</manifest>
EOF
repo sync
# fix all python2 scripts
mkdir ./bin
ln -s `which python2` ./bin/python
ln -s `which python2-config` ./bin/python-config
export PATH=./bin:$PATH
bash # envsetup.sh only supports bash
. build/envsetup.sh
export ALLOW_MISSING_DEPENDENCIES=true
export DTC_EXT=$PWD/prebuilts/misc/linux-x86/dtc/dtc
# will tell device not found, but still succeeds
lunch omni_fp3-eng
mka recoveryimage
fastboot boot out/target/product/FP3/recovery.img
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment