yashsingh1/xdaforums huggingface dataset:
[Android Software Development] lehmancurtis:
From the stock boot.img, will post a link asap. Dtb is combined with stock boot.img. No dt.img partition.

https://drive.google.com/file/d/1fPnVNAW2VLfTR3zInBNhgTDKa024qGyh/view?usp=drivesdk

---------- Post added at 04:07 PM ---------- Previous post was at 03:57 PM ----------

Model: MMC FN12MB (sd/mmc)
Disk /dev/block/mmcblk0: 7818MB
Sector size (logical/physical): 512B/512B
Partition Table: gpt

Number Start End Size File system Name Emmc-partition
1 17.4kB 542kB 524kB sbl1	mmcblk0p1
2 542kB 1066kB 524kB sbl1bak	mmcblk0p2
3 1066kB 4212kB 3146kB aboot	mmcblk0p3
4 4212kB 7357kB 3146kB abootbak	mmcblk0p4
5 7357kB 7882kB 524kB rpm	mmcblk0p5
6 7882kB 8406kB 524kB rpmbak	mmcblk0p6
7 8406kB 8930kB 524kB tz	mmcblk0p7
8 8930kB 9455kB 524kB tzbak	mmcblk0p8
9 9455kB 10.5MB 1049kB pad	mmcblk0p9
10 10.5MB 12.1MB 1573kB modemst1	mmcblk0p10
11 12.1MB 13.6MB 1573kB modemst2	mmcblk0p11
12 13.6MB 14.7MB 1049kB misc	mmcblk0p12
13 14.7MB 15.7MB 1049kB params	mmcblk0p13
14 15.7MB 36.7MB 21.0MB ext4 panic	mmcblk0p14
15 36.7MB 36.7MB 1024B fsc	mmcblk0p15
16 36.7MB 36.7MB 8192B ssd	mmcblk0p16
17 36.7MB 37.3MB 524kB keystore	mmcblk0p17
18 37.3MB 37.8MB 524kB config	mmcblk0p18
19 37.8MB 38.8MB 1049kB oem	mmcblk0p19
20 41.9MB 109MB 67.1MB fat16 modem	mmcblk0p20
21 109MB 110MB 1049kB devinfo	mmcblk0p21
22 110MB 110MB 32.8kB DDR	mmcblk0p22
23 110MB 112MB 1573kB fsg	mmcblk0p23
24 112MB 128MB 16.8MB boot	mmcblk0p24
25 128MB 128MB 16.4kB sec	mmcblk0p25
26 128MB 1954MB 1825MB ext4 system	mmcblk0p26
27 1954MB 1987MB 33.6MB ext4 persist	mmcblk0p27
28 1987MB 2256MB 268MB ext4 cache	mmcblk0p28
29 2256MB 2273MB 16.8MB recovery	mmcblk0p29
30 2273MB 7818MB 5546MB ext4 userdata	mmcblk0p30
[Android Software Development] tze_vitamin:
I have use this app on my Galaxy note 3,now I have Galaxy note 4,i have install the app,download the .img file for my phone,but when I finish download and put the file in sd card,application dont recognize that I already download file and I dont have options to choose file and flash recovery,I have only the option for downloading recovery again..

How to fix this?

I dont have Pc so I use this method,and on my last phone and phone before worked perfectly, but now on my note 4 I have problem..
[Android Software Development] Piospi:
Hello,

I am trying to install a newer TWRP (https://xdaforums.com/sho....php?t=3557606) for Carbon Mod custom rom. I tried:

- install .img with TWRP in TWRP

- flashify

- official app TWRP from google play

- fastboot commands with "platform-tools"

Everywhere I get a message that everything went fine but in TWRP I still have the old version - 3.0.0.2 :/

I am asking for help because I have been fighting this from two days :/

I have Xperia Z3C with unlocked bootloader, stock prerooted firmware .291 + EliteKernel v3.
[Android Software Development] _that:
Do you guys even read the thread title before posting a reply? This thread is about compiling your own TWRP image from source code. Please ask about installing or using TWRP in your device forum. Thank you for not posting further non-development questions in a development thread.
[Android Software Development] pk1979:
ช่วยด้วยฉันติดตั้งไม่ได้

mod edit - transmission added

I can not install it.

Forum rules
[Android Software Development] _that:
Since a moderator helped with rule 4, may I add:

It's becoming preposterous.
[Android Software Development] :
hello. i have ported TWRP to Moto Z3 Play, it's an a/b device with snapdragon 636 and recovery integrated in boot.

the problem is that "make recoveryimage" generates recovery.img which won't boot with "fastboot boot recovery.img", it hangs on motorola logo without any response to adb, no TWRP, no android.

if i fastboot flash boot_a recovery.img it's the same but i can boot into TWRP if i select Recovery in fastboot mode menu and TWRP works as expected.

i remember that on sony pioneer i had to fastboot boot recovery.img and it started TWRP directly, afterwards i had to flash twrp installer zip.

my device if there is anyone interested to look into it - https://drive.google.com/open?id=1ftNHXS84AHVEd7u3fQ0Mq0YQ62Qr32jv

stock boot.img - https://drive.google.com/open?id=1oddVMFw3JgEn17aSMehdiCOAY8FkDiRM

my question is, how do i get the recovery.img to fastboot boot directly into TWRP and how do i make twrp installer zip?

thank you.
[Android Software Development] inguna:
Can anyone build TWRP for Honor 7C (LND-L29)? I will pay for your work
[Android Software Development] Augustoandro:
Send me the recovery.img on this thread:

https://xdaforums.com/android/general/unofficial-twrps-devices-source-code-t3833338
[Android Software Development] lehmancurtis:
I've been able to compile twrp, and boot images, but when I flash the recovery.img it boots to bootloader instead of recovery. Which partitions are supposed to be listed in recovery.fstab?
[Android Software Development] bassbounce:
While compile I get some kernel related errors, is it possible to fix it?
[Android Software Development] Magendanz:
I'm trying to migrate my TWRP project for an Android TV device, a box based on Amlogic reference hardware (p212) that previously shipped with Nougat and now comes with Oreo. Tweaking the project for the new Oreo OEM firmware was pretty straight forward, using the new prebuilt recovery kernel, fstab and init.rc files, and it seems to run fine...

for about 30 seconds

. After that, the device spontaneously reboots to a boot loop, just cycling on a blank screen and the boot logo....never again to return to TWRP or boot to system.

Any ideas what might be causing this?
[Android Software Development] pix106:
What do you see in logcat ?
[Android Software Development] Magendanz:
The device doesn't support adb and I haven't set up a logcatd service to dump it to a file. If I did that in my init.rc, it could still be pretty challenging to retrieve the file, considering that I haven't figured a way to break out of the subsequent bootloop. Perhaps I could just send it to the SD card. Are there any tricks you might suggest? (This device isn't rooted yet.)
[Android Software Development] pix106:
what do you mean ?

Did you build TWRP using "eng" variant ? adb should be started at boot using "eng"
[Android Software Development] _that:
Maybe.
[Android Software Development] bassbounce:
Finally, it works.

Only vibration does not work, does someone know where i can fix that?
[Android Software Development] M.A.P:
Hello everyone, someone help me. My device is already having a twrp which I made when our phone was on nougat and now it is updated to oreo. When I'm trying to use android-8.1 android_bootable_Recovery repo not the omni source repo it is compiling aosp recovery. Seriously? As I know omni source now comes with aosp recovery but I tried deleting and cloning the twrp but still aosp recovery is compiling. The same is happening in both Lineageos 15.1 and omni 8.1 source. Someone help.

Got twrp to compile. I think this is a new change. in android 7 source even with breakfast it sued to work but now it is working only with lunch that too eng.
[Android Software Development] Serpico_One:
Your device tree is cloned from https://github.com/TeamWin/android_device_samsung_star2lte?

I'm not sure, but the error point to '/EXECUTABLES/dtbhtoolExynos_intermediates/'.

Only reference to dtbhtool in star2lte device tree is in mkbootimg.mk that include device/qcom/common/dtbtool/Android.mk. Have you this directory in place (from omni.dependencies you need also the kernel, from what i understood those are the only 'external' references you need for compiling twrp)?

Have a good day!
[Android Software Development] ianmacd:
Yes.

I don't have device/qcom/common/dtbtool/Android.mk. I'm not sure where that should have been pulled in from. I do have the kernel in place, however.

I tried downloading the device trees for a few other Samsung devices, and the compilation of those fails in the same place each time:

including ./hardware/intel/bootstub/Android.mk ...
including ./hardware/libhardware/Android.mk ...
including ./hardware/qcom/keymaster/Android.mk ...
including ./hardware/samsung/Android.mk ...
hardware/samsung/AdvancedDisplay/Android.mk:34: frameworks/base/packages/SettingsLib/common.mk: No such file or directory

Any idea where that's supposed to be pulled from?
[Android Software Development] Serpico_One:
I made a search in teamwin repos. I would try to clone https://github.com/TeamWin/android_device_qcom_common.git in device/qcom/common
[Android Software Development] ianmacd:
No, that doesn't fix it. I guess I'm going to have to start again from scratch.

I've been following the instructions in the OP, which say to use https://github.com/minimal-manifest-twrp, but "there may be some situations where you will need more repos in your tree than this manifest provides". It's not clear, however, what those situations are; or which other repos might be needed in such cases. I would have thought that the 21 Gb I downloaded via that manifest would have been enough to build TWRP in just about any circumstances, but evidently not.

Are there clearer instructions available anywhere else? I'm familiar with git, less so with repo, but the tools aren't the problem. It's just a matter of understanding the build environment of TWRP. I am familiar with it only as an end-user, and have no familiarity at all with Omni. I would have expected building an existing device tree to be a reasonably straightforward affair, but out of about 8 that I downloaded, only one of them compiled through to the end and produced a boot.img.
[Android Software Development] Serpico_One:
Building Android is not an easy or plain task, as you are experiencing. It takes me weeks to get the first recovery working and is taking me months trying to compile rom for different and unsupported devices.

You can find many great tutorials but no one is 'complete'. I think that this is due to the complexity and the ever updating system. Many of us did not have much time to resolve his own problems and errors, helping others (or write pages of instructions) is even harder.

Said that, compiling twrp for an officially supported device on omni sources should be a relatively easy task.

If you synced omni sources with a command like:

repo init -u https://github.com/omnirom/android.git -b android-8.1

You should clone every other repository with same branch.

In your case you have to clone (for example):

git clone https://github.com/TeamWin/android_device_samsung_star2lte.git -b android-8.1

And so on for every extra repo needed (twrp-recovery in bootable/; kernel sources in kernel/samsung/; and qualcomm common tree to device/qcom/). All repos needed should be on TeamWin github repos (note that those are probably 'reduced' trees ready only for recovery build).

You can also check makefiles in device/samsung/star2lte to see if every 'include' statement point to existing folders.

Good developing day...
[Android Software Development] ianmacd:
Thank you very much for this tip. This was definitely a major part of the problem. Even at 40 Gb, the manifest mentioned in the OP doesn't provide enough of an environment to build TWRP for any modern device. At least, that's my experience with the half dozen that I have tried. I need the full Omni source: 60 Gb.

And still it doesn't build all the way, although I do now get 99% (10289/10292) of the way there. The 2 Samsung devices I tried (star2lte and starlte) failed on producing the ramdisk, because adbd hadn't been built. I haven't figured out why yet.

I tried building dream2lte just for the hell of it, but it failed early on, due to a library redefinition. I fixed that, but then the build failed on missing libraries that I didn't actually need. ALLOW_MISSING_DEPENDENCIES=true got me past that obstacle and all the way to 99% of the build again, but then it failed post-kernel build on a cp command that was missing the -r flag. I gave up at that point, because I'm not actually interested in dream2lte or any of the other device trees I've tried. I just wanted to witness a normal build, so that when I tried porting TWRP to a new device, I'd be able to distinguish the typical warnings and errors from any that I was introducing with my new device tree.

No doubt my general unfamiliarity with building for Android is a complicating factor here, but the process of building TWRP seems unnecessarily error-prone to me.

Anyway, I'll muddle on with this for a while longer. If I can get another modern Samsung device to build properly, building for the new Tab S4 (gts4lwifi) shouldn't actually be that hard. I already have a kernel source tree for the device that I've patched until it builds, so once I have an existing TWRP device tree that will build, I can use that as a template for this new device.

UPDATE: I finally got adbd to build, so my build went all the way through to producing a recovery.img this time. I guess I'll start work on a device tree for gts4lwifi now.
[Android Software Development] Serpico_One:
Glad to read that your build successfully completed. You are absolutely right, android building is absurdly error-prone and logs are criptic, to say the least. The 'look but not touch' open source software, we must deal with it (here a gif would be good).

Cheers to every xdaer's out there.
[Android Software Development] LameMonster82:
Hello, I'm not quite sure how do I built TWRP for my treble device. Do I still need a device tree? So far I've created one but I'm still new to this and when I compiled it with the minimal TWRP source the boot image won't boot to anything other than the bootloader. How do I debug my boot image and what do I need to build TWRP for a treble device?
[Android Software Development] MasterJack1697:
Guys i have a problem with my twrp port for the bq aquaris x2, basically it doesn't boot. After the fastboot boot command the phone remains stucked at the android one logo, i think it's a kernel panic but I don't know how to take the last_kmsg since the last_kmsg is overwritten by the os kernel during the android boot..

If someone can check, here is my source: https://github.com/mj1687/twrp_device_bq_zangya
[Android Software Development] bassbounce:
So i have a a/b device compiled twrp works great but after reboot it dont stay there it get replaced by stock recovery.

I look at other devices that are using a/b the all use a twrp-installer.zip after the use fastboot boot twrp.img.

How do i make a twrp-installler.zip? since a/b devices don't have a recovery partition, that also explains when i install twrp to both a and b partitions the phone straight into twrp and not to system.

So we need to take out the stock recovery out of the boot.img and replace it with twrp?

We talking here about The Xiaomi A2 with android one, i dont understand why it isn't possible to use twrp as a recovery while the system keep working like non a/b devices.

the command Fastboot boot twrp.img doesn't work, it just boot and a red error page device is not secure not allowed to boot or something in that order.
[Android Software Development] MartinX3:
I also need to know, how to make a flashable zip for the A/B device Xperia XZ2.

The XA2 maintianer (A/B device) did not answer me weeks ago.

And how to successfully log errors, if you stuck in the splash screen and a reworked compile guide for A/B devices would be nice, too.
[Android Software Development] ouzqan:
i have little problem. I port twrp 3.2.1 for z5 to z5 premium but loading bar pixel problem and Cpu temperature problem. How fix it?
[Android Software Development] Travisholt92:
Proper configuration
[Android Software Development] ouzqan:
Thanks man. I will try.
[Android Software Development] bassbounce:
I compiled serval taep's, but it gives a short freeze like 5 seconds everytime if u boot into twrp.

Is this a know issue?
[Android Software Development] ashyx:
This is NOT a request thread for TWRP.
[Android Software Development] HiddenSystem:
Oh ok. Sorry. I just now using forum
[Android Software Development] milukramteke81:
please help me to make twrp recovery for my mi tv host model no mdz-18-da. Thank you.
[Android Software Development] ashyx:
Here you go:

https://xdaforums.com/showpost.php?p=32965365&postcount=1
[Android Software Development] MartinX3:
In my opinion, the guide should be reworked by a team containing a TWRP professional with A/B know how and a person which never made a TWRP from the ground.

It is not very helpful for me who is having knowhow in Linux, android and the Plattformtools and beeing a hard working IT professional with IT Hobbys in my free time.

The only real useful "guide" was using the device source files from another smartphone with the same Snapdragon chipset like mine.
[Android Software Development] milukramteke81:
can you make twrp recovery for my mi tv bar model mdz-18-da? because i don't have any knowledge about it. if yes then make it and contact me. thank you.
[Android Software Development] Travisholt92:
You need to learn to read and learn to search for any questions you may have. Twrp is one of the easiest open source projects to tackle. If you can't handle taking the 2 hours to learn to compile it, you don't need it. Using the sources from similar devices + the prebuilt stock kernel image is extremely easy as long as you build twrp off of the version of android your device is already running. Want to learn how? Read the OP!

Just saying, my first project was building twrp from scratch using this exact guide. Its not hard if you're willing to use a search bar to find the answers to your questions which have been answered hundreds of times already.
[Android Software Development] MartinX3:
How is the TWRP Android 9.0 support?

Buggy? Ready?
[Android Software Development] milukramteke81:
Yes I want to learn. Please give the link of OP. THANKS
[Android Software Development] Travisholt92:
OP is original post. Aka PAGE ONE of THIS THREAD.....
[Android Software Development] Ibuprophen:
It's great that your providing assistance [MENTION=4711784]Travisholt92[/MENTION] but, OP = The First Post (aka Original Post #1) of a thread.

Here's a helpful OP Specific URL for this thread...

https://xdaforums.com/showthread.php?p=32965365

Thanks a bunch! :)

~~~~~~~~~~~~~~~

UNLESS asked to do so, PLEASE don't PM me regarding support. Sent using The ClaRetoX Forum App on my SM-G900V device.
[Android Software Development] Travisholt92:
Nice "correction" there
[Android Software Development] MortC137:
Huawei DRA-LX2

Hi Developers, I have spent a few days searching for n twrp for my model phone. Is there a trwp for Huawei Y5 Prime 2018? would the Huawei Y5 2017 image work on the 2018 model and if the answer is no on both questions, would you be able to assist me with porting one for my specific model please?
[Android Software Development] MartinX3:
Dear Developers,

do you know why i am not getting a twres folder in the ramdisk?

device tree

https://github.com/MartinX3/android_device_sony_akari

twrp minimal sources

https://github.com/minimal-manifest-twrp/platform_manifest_twrp_omni/tree/twrp-8.1

Edit:

Found the solution.

I made a "userdebug" build.

Only an "eng" build will integrate TWRP.
[Android Software Development] Invisan:
Alright. I would like to learn this but im quite unsure what i need especially regarding the BoardConfig.mk File.

My Device is a Xiaomi Black Shark with A/B Boot File.

I do have Android 8.1.0 currently running on it. There is no root till now and no TWRP till now.

The Shark has a Snapdragon 845 Processor.

So which device would you suggest as similar device?

I doubt it is enough to just download the Omnirom Github from here https://github.com/omnirom/android_bootable_recovery

Which files exactly do i need?

Kind Regards,

Invi
[Android Software Development] MartinX3:
Xz2

Xz2c

Xz2p

Oneplus6

Galaxy s9 with snapdragon

Keep a look in Wikipedia
[Android Software Development] mickrussom:
Any tips for building TWRP for a Pixel 3 XL?
[Android Software Development] superchilpil:
[MENTION=912474]Dees_Troy[/MENTION] is probably going to just tell you to wait until he builds it. There's a lot new with this device, and without previous experience you could possibly brick your device.

I looked into it myself but it's beyond my ability and without help I'd be wasting my time trying to compile something that most likely wouldn't work
[Android Software Development] borg79:
I am a newbie in TWRP and wish to learn to build custom TWRP for any device. I follow the steps in the guide and have the twrp recovery image build successfully. The device tree is (e.g twrp emulator, leeco x2 ) from TeamWin github and twrp source is from omnirom (android 9.0) .

My question is :

Is it possible to test out the twrp image in android-emulator first before flashing to the mobile phone ?

I follow the guide , build the twrp image and test it using the following command

emulator -avd xxx -ramdisk out/target/product/xxx/ramdisk-recovery.img .....

However, I cannot get the twrp screen layout in the android-emulator (as shown in the guide), what I get is only a normal AOSP screen layout.

Can anyone shed some light on this ?

---------- Post added at 03:30 AM ---------- Previous post was at 03:30 AM ----------
[Android Software Development] Rawwrius01:
I have a question.

Is it possible to upgrade a recovery which is build with 6.0 source.

If yes is it easy and how :D would be nice if someone can help me :D

Gesendet von meinem ONEPLUS A3003 mit Tapatalk
[Android Software Development] pix106:
Just change the branch for android_bootable_recovery project in your local manifest (remove project, then add the project using a newer branch)
[Android Software Development] Rawwrius01:
Didn't I have to use kernel source or something ? I found a device tree by the builder of the official twr.img but he is using Android 6 source so now Android 8 is out and I've got display issues which makes the recovery not usable.

Gesendet von meinem ONEPLUS A3003 mit Tapatalk
[Android Software Development] ashyx:
You don't need to change branches. Twrp compiled under MM branch will compile and boot fine on Oreo.

Your kernel is more likely the problem. Recompile the Oreo kernel from source and use it to compile or repack twrp.
[Android Software Development] pix106:
I thought you were already building twrp for your device and wanted to update twrp.

I build twrp 3.2.3 from Android 9 branch (Android_bootable_recovery) using omnirom 5.1 source for my Android 5 device, with stock prebuilt kernel (which is usualy enough for twrp)
[Android Software Development] Rawwrius01:
Can I use the stock Oreo kernel to repack the recovery ? Because the source isn't out for Oreo right now. I have already extract the boot.img from the firmware.

I haven't compiled it. Just watched the maintainers repo. He is using twrp 6 source and Android 6 kernel source.

Gesendet von meinem ONEPLUS A3003 mit Tapatalk
[Android Software Development] ashyx:
You should be able to use the stock zImage and dtb and just repack it with the current build of TWRP.
[Android Software Development] Rawwrius01:
That's what I was thinking of and doing! But then I thought, before I break something I better not flash it.

Will it work with older versions than Oreo?

Gesendet von meinem ONEPLUS A3003 mit Tapatalk
[Android Software Development] ashyx:
Probably not if you use the Oreo kernel.
[Android Software Development] mdmiko80:
Unable to mount /system and /cache

I'd like to change recovery in my custom rom. It's a LegacyXperia LineageOS 14.1 on Xperia Pro.

I successfull build this rom, kernel and TWRP. But I can't get work mount for /system and /cache (/data f2fs it's ok on sdcard).

They are mtd/yaffs2. My twrp.fstab is very simple:

/system yaffs2 /dev/block/mtd/by-name/system

/cache yaffs2 /dev/block/mtd/by-name/cache

/data f2fs /dev/block/mmcblk01

if I do -> Advanced -> Terminal -> mount /dev/block/mtd/by-name/system yaffs2 /system the partition is mounted correctly...

Anyone with similar problem on building? Source branch is 7.1 v 3.1.1-0
[Android Software Development] Rortiz2:
Hello [MENTION=912474]Dees_Troy[/MENTION] I have compiled a recovery for the energy phone colors device and I would like to give it official support.

Where could I send you all the information that is needed?

Device tree, recovery.img, etc.