yashsingh1/xdaforums huggingface dataset:
[Android Software Development] NepoRood:
Dual boot, a VM is only going to use half of your limited resources. You'll also need to manipulate the Jack server, and use swap, that info can be found through searching this thread, or [MENTION=7065337]spookcity138[/MENTION] can tell you exactly what he does...
[Android Software Development] rajatgupta1998:
Hi all, i am using the minimal twrp manifest(lineage) for building twrp for my device.

The build stops at 97% with about 7 errors I don't know how to solve.

The errors: https://paste.ee/p/g8yuo

Device = athene (motorola moto g4 plus)

And I am using the official lineageos device tree and kernel tree. The vendors are from TheMuppets git for Motorola.

I am building on Ubuntu 16.04 LTS. If someone can look into this, I'd be grateful.
[Android Software Development] followmsi:
Had this problem already while building 3.1.0 in "stock" cm-14.1 sources.

Found these changes and used them for the "fix" .. for 3.1.0.

https://gerrit.omnirom.org/#/c/22769/

https://gerrit.omnirom.org/#/c/22768/

https://gerrit.omnirom.org/#/c/22770/

The AOSP 7.1.2 commit is changing the code again ..

https://github.com/omnirom/android_bootable_recovery/commit/84d61ce31c48d0da495617f64edb724eeb36d3bc

The "diff" to get it working is here.. at least for me.

https://github.com/followmsi/androi...mmit/56c125e15f7a598d44633636d2abab19fb9ae21f

I am not a coder .. hopefully this could be fixed better and merged into TWRP android-7.1 branch to make life simpler for all the LOS compilers ..

Cheers
[Android Software Development] followmsi:
My last post was related to your problem .. Did reply the wrong one ;)
[Android Software Development] Hikari no Tenshi:
Hello everyone.

Previously i was compiling TWRP for phones and now i need to compile it for tablet.

It's a device with landscape resolution 1920x1200. In build.prop it has property ro.sf.hwrotation=180.

In BoardConfig.mk i've set TW_THEME to landscape_hdpi, but in recovery theme is in portrait mode.

I don't know if there is any sysfs in kernel to control screen orientation, and i have no source for kernel.

I can rotate touchscreen, but can't rotate theme (i know that themes do not rotate).

Is there any way to use landscape theme insted of portrait?
[Android Software Development] _that:
TWRP uses the framebuffer's native orientation. If there isn't some way to rotate it in the kernel, then there is no way. Rotating using software would be slow, that's why it's not implemented.
[Android Software Development] kirito9:
I'm trying to compile TWRP with the kernel source branch 3.18.19 and I have a question about this command

make -C kernel/alcatel/4034 O=/home/kirito9/cm13/out/target/product/4034/obj/KERNEL_OBJ ARCH=arm CROSS_COMPILE="/home/kirito9/cm13/prebuilts/misc/linux-x86/ccache/ccache arm-eabi-" VARIANT_DEFCONFIG= SELINUX_DEFCONFIG= pixi4_4_8g1g_defconfig

The O=... would direct the zImage-dtb be built there right? If that's the case then I think this error

/home/kirito9/cm13/kernel/alcatel/4034/include/uapi/asm-generic/int-ll64.h:11:29: fatal error: asm/bitsperlong.h: No such file or directory

is the result of trying to build in a separate out directory.

Full log : https://hastebin.com/efovejenaz.pas

How would I go about fixing that?

Edit: Fixed by running make mrproper.
[Android Software Development] vampirefo:
Your source is dirty, you must clean it first.

/home/kirito9/cm13/kernel/alcatel/4034 is not clean, please run 'make mrproper'
[Android Software Development] kirito9:
Did that and it didn't help.

Edit: You were correct, tried to build separately and make mrproper fixed it. Thanks.
[Android Software Development] ZawZaw:
Hello...friends,

I have one question.

How many file size of omini full source?

This link...

https://github.com/omnirom/android

I want to know this repo's file size.

I don't have good internet connection.

Therefore, I want to ask you.

Please, help me.

•••
[Android Software Development] pix106:
Using the minimal TWRP manifest, I got less than 7GB of sources. Idk exactly about the full source now, but it's a TWRP thread, right ? :)
[Android Software Development] Guizão BR:
Guys, i trying to port TWRP for one device with mt6797m android 6.0 but the touchscreen is not working, someone know how fix that?
[Android Software Development] _that:
Start with this:

https://xdaforums.com/showpost.php?p=71400973&postcount=2884
[Android Software Development] vampirefo:
This is becoming a common problem, There are many work arounds, but to fix the problem you need kernel source, comment out the line of code calling to disable touch in recovery, build new kernel and use it.

I used the work arounds, until Blu finally released the kernel source for my device then I was able to permanently fix my touch problem.

Work arounds I used at one time or other.

1. USB mouse

2. fastboot boot recovery.img

3. flash twrp to boot partition

4. Built other recovery
[Android Software Development] ZawZaw:
Hi...friends,

I have one question. Please help me.

I want to know how to edit TWRP version or by Contributor name in source.

Example :

Team Win Recovery Project

3.0.0 by ZawZaw

Show on screenshot.

•••
[Android Software Development] _that:
You can set TW_DEVICE_VERSION in your environment or makefile, it will be appended to the main version number. The example in the screenshot is a bit extreme, the version number is not supposed to be that long. Of course you can also edit the theme XMLs.
[Android Software Development] ZawZaw:
Thank you very Much Sir. :D

•••
[Android Software Development] Royesking:
How can iI do, this??

I can't find any twrp recovery for my oppo joy 3??what can I do now??:(
[Android Software Development] shoey63:
Read, learn and build. Or else ask someone in your device forum to do it.
[Android Software Development] Kizoky:
Does anyone know how do I add an extra "button" in the Advanced tab?

I have seen many TWRP recoveries that have something like "patch" button which If you press it it will flash a .zip from a folder (for ex.: no-verity.zip)
[Android Software Development] _that:
The whole UI is defined by gui/theme/*/ui.xml and files included from there. The core is in gui/theme/common/portrait.xml (for phones).
[Android Software Development] qiurigao:
Hi my TWRP install zip fail:

https://gist.github.com/qiurigao/f1dbd862c044e7dfd5557aff9feb1d98

open "/dev/block/bootdevice/by-name/system" failed: Permission denied
[Android Software Development] ZawZaw:
Hi...friends,

How to fix this problem for Sony Xperia Z5 ( sumire ) Device tree.

Please, help me.

•••
[Android Software Development] vampirefo:
It's telling you exactly what's missing, you need to add the missing file, or remove it's calling.
[Android Software Development] ashyx:
HI Cap, just to cast your mind back to this issue. It seems I'm also having a similar issue with a Samsung kernel.

Samsung don't usually disable touch in recovery, so have tried the usual routes, making sure kernel and dtb are correct, kernel is built from source.

Any chance you could let me know the advice you gave to fix the touch issue?

Thanks.
[Android Software Development] vampirefo:
Use [MENTION=4878287]_that[/MENTION] post to check and see if touch is enabled via recovery. My device isn't Samsung, but on my device I can easily flash recovery.img to boot partition boot and check if touch is working or not.

I fixed my touch problem once Blu released my kernels source code. In my touch screen source Blu added a line of code that disabled touch in recovery, commenting that line out prevented that line from working so touch wouldn't be disabled in recovery.
[Android Software Development] ashyx:
Where' did you find this line of code?
[Android Software Development] vampirefo:
Ours will be different mine is in.

drivers/input/touchscreen/mediatek/GT5668_X6068/gt1x_tpd.c

Change this

//#ifdef CONFIG_MTK_BOOT
if (RECOVERY_BOOT == get_boot_mode()) // important
return -1;
//#endif

to this

//#ifdef CONFIG_MTK_BOOT
// if (RECOVERY_BOOT == get_boot_mode()) // important
// return -1;
//#endif
[Android Software Development] Ibuprophen:
Maybe one of you fine experts can help me out :)

I've submitted 2 issues a month ago +/- in Github regarding the TWRP v3.1.0-0 for the d2vzw as follows.

https://github.com/TeamWin/android_device_samsung_d2vzw/issues/1

https://github.com/TeamWin/android_device_samsung_d2vzw/issues/2

Though, i can work around them without a problem but, it's kinda irritating... LOL!

Any thoughts?

***Please Note: As always, I welcome any member to help with further valuable information/clarification for any of my posts.

Sent via Communicator [D2VZW] from the Bridge of the U.S.S. Enterprise...
[Android Software Development] Captain_Throwback:
Already posted in this thread...
[Android Software Development] Ibuprophen:
I just didn't put the two together with what i was experiencing.

I'll have to check into the this and see what I can do..

Thank You!

***Please Note: As always, I welcome any member to help with further valuable information/clarification for any of my posts.

Sent via Communicator [D2VZW] from the Bridge of the U.S.S. Enterprise...
[Android Software Development] Prabudh:
To TWRP Developer Team,

Sir will u pls build a custom recovery for YU YUreka S(YU5200) n provide official support.I will try to provide u device details(build prop) but can't provide recovery.img file as there is no link or source to get it.
[Android Software Development] ashyx:
Smashing that did the trick.

I must be going blind though. I usually try my best to fix these things myself before posting. Before asking I grep'd the touchscreen drivers for 'recovery' but nothing stood out.

After what you said I grep'd 'bootmode' and found the offending lines.

Appreciate the assistance.
[Android Software Development] aburezk:
Hello

I'm trying to compile twrp for p10 lite I created this device tree

https://github.com/aburezk/huawei/tree/master/generic_a15

and when I try to compile it, it gives me this error

https://pastebin.com/XEaPxuPu

there is no directory for that, how can I fix that?

I'm using minimal Omni source 7.1

https://github.com/minimal-manifest-twrp/platform_manifest_twrp_omni/tree/twrp-7.1
[Android Software Development] vampirefo:
You need to sync cause goldfish directory exists in every source.
[Android Software Development] aburezk:
I'm not using full source even when I sync it doesnt create that folder
[Android Software Development] vampirefo:
I don't use full source either, I use the mini source to build TWRP.
[Android Software Development] aburezk:
Can you link the source?
[Android Software Development] vampirefo:
https://github.com/minimal-manifest-twrp/platform_manifest_twrp_omni/tree/twrp-7.1

We are using same source, yours just isn't downloading correctly.
[Android Software Development] aburezk:
Edit: Downloaded
[Android Software Development] vampirefo:
If sync didn't work, then delete everything and start over, you could cherry pick the directory from full source, but I wouldn't trust your source most likely more stuff is missing from your source, starting over would be best option.
[Android Software Development] martyfender:
Is this the source you used when you built for the Nextbook Ares 8A?

Also I would need to modify the boot.img in android kitchen and change the line in fstab, and device fstab: "forceencrypt", to"encryptable"? I unpacked the boot.img from the ares 8 to get this info. Where did you set selinux to permissive?

I don't know of a way to get the boot.img off of the Ares 8A without root though. Is there a way, or do I need twrp first to make a backup?

I am new to all of this, of course. I just need to figure out if I have enough space on my windows disk to either duel boot or setup a virtual machine. Can I use a smaller, minimal build, like lubuntu or other, or do you recommend something else?

Thanks again for your help.

Thanks
[Android Software Development] vampirefo:
No Intel needs to be built off of 5, not 6 or 7 or Lineage 12, not 13 or 14 plus a lot of modifications are required to source. Straight source can't​ build useable Intel recovery.
[Android Software Development] martyfender:
5 for the android 6.0.1 on the Ares 8A?

See my edited post above.

The modifications you mentioned are probably beyond my skill level at this Time.

Would you even consider releasing your build and modified boot to the community?

My original Ares 8 is running great with your ported 5.1.1. I have tuned it with lspeed, kernel Auditor to improve it. Even the wifi issues are better. Performance and battery life are great.

Thank You so much for your contributions
[Android Software Development] vampirefo:
My Intel stuff in on my son's laptop he is in college. Intel's are complicated and source takes time to modify so I keep it away from my other sources.

I have no access to his laptop and no desire to bother him for such stuff.

The Ares 8A I rooted and built TWRP for belongs to my son, he needed it rooted to use some app at his school.

His laptop has the source, device tree, TWRP and boot.img plus backups on it, For all Intel's that I have rooted, or built recovery for.

It's cheaper to let him use my laptop then to buy him one of his own.
[Android Software Development] martyfender:
I understand, I have three sons, two of which have graduated from college and the youngest who is now attending. It is a busy time. Best of luck to him.

Thanks

---------- Post added at 12:49 AM ---------- Previous post was at 12:22 AM ----------

Yes, it is cheaper. I've performed repairs and maintenance on my son's Mac and Windows systems over the years, as well as contributing to the purchase. I would have done the same if I had systems to spare. Sorry for getting OT.
[Android Software Development] martyfender:
[MENTION=2472806]vampirefo[/MENTION] I was able to use adb pull /system to pull my system from the ares 8A. Is there a way to do this for stock recovery and boot.img without root? Also, the saved system is in the form of directories and files. Would it have to be made into a system.img to restore it? If so, how would I do that? With image kitchen? Would file permissions be restored correctly?

I had tried adb pull before of the system and it failed with a memory error. I had used minimal adb.

This time I used your recommended system wide solution, I guess that is the reason it worked this time.

If you do ever get the twrp for the 8A, you are welcome to post it on my Ares 8A root thread

Thanks, so much
[Android Software Development] aburezk:
I've successfully compiled twrp for my p10 lite, but ADB and MTP are not working, how can I fix it?
[Android Software Development] NepoRood:
Add to "system.prop" in your device tree

persist.sys.usb.config=mtp,adb

If that doesn't work, there are other methods...
[Android Software Development] KHARKOVSKIY30:
Spruce someone knows, give a link where you can order to collect third-party recovery from source.
[Android Software Development] aburezk:
Not Working
[Android Software Development] NepoRood:
Link device, branch, vendor, kernel, etc...
[Android Software Development] aburezk:
https://github.com/aburezk/huawei/tree/master/generic_a15
[Android Software Development] Ibuprophen:
[MENTION=912474]Dees_Troy[/MENTION], are there plans for updating the OP at some point or is the information (though, a bit outdated) just going to remain the same?

I'm not in any hurry... I was just wondering about it?

Thanks a bunch :)

***Please Note: As always, I welcome any member to help with further valuable information/clarification for any of my posts.

Sent via Communicator [D2VZW] from the Bridge of the U.S.S. Enterprise...
[Android Software Development] Ashley david:
After porting TWRP now my device is not showing storage how to fix thank you
[Android Software Development] _that:
Read this fully, then ask again:

http://www.catb.org/esr/faqs/smart-questions.html
[Android Software Development] NepoRood:
Add to "device.mk"

PRODUCT_DEFAULT_PROPERTY_OVERRIDES += \
persist.sys.usb.config=mtp

Be sure to clean or clobber after making changes to your tree...
[Android Software Development] aburezk:
works but no serial number
[Android Software Development] celoxocis:
i have a question related to encryption and "BOARD_USERDATAIMAGE_PARTITION_SIZE" but can't find any information about it.

i understand that the proper size here should be userdata partition in blocks (in my case mmcblk0p56 * 1024) hence:

25030639 * 1024 mmcblk0p56

which makes the actualy size in bytes

25631374336

but should i subtract 16384 bytes in regard for device encryption? or not?

which would be

(25030639 * 1024) - 16384

or is that step only required for building rom's and not TWRP?

Does it affect the userdata backup/restore in any way?

my TWRP fstab already includes the following:

/data auto /dev/block/bootdevice/by-name/userdata flags=encryptable=footer;length=-16384
[Android Software Development] _that:
I'm pretty sure that the only thing this setting does is create an (always empty?) image of a userdata partition when building a ROM that you can flash to your device afterwards. I don't know why anyone would want to do that.

It doesn't have any effect on TWRP, which gets the partition sizes from your device at runtime.

[/QUOTE]
[Android Software Development] celoxocis:
[/QUOTE]

Thanks for clearing that up _that

If it doesn't affect TWRP at all, then I will leave it at the actual size for reference.

It got me confused. I've seen a few TWRP device repo's where the 16384 was subtracted but to me that would only make sense, like you said, when building the ROM and using that empty userdata.img. Which the custom ROMs don't use at all.
[Android Software Development] ashyx:
Thanks for clearing that up _that

If it doesn't affect TWRP at all, then I will leave it at the actual size for reference.

It got me confused. I've seen a few TWRP device repo's where the 16384 was subtracted but to me that would only make sense, like you said, when building the ROM and using that empty userdata.img. Which the custom ROMs don't use at all.[/QUOTE]

I dont even specify partition sizes in the TWRP config at all.

Never had a problem.
[Android Software Development] Captain_Throwback:
It's probably a good idea to at least include the Recovery partition size, to ensure the created image will actually fit ;).
[Android Software Development] vampirefo:
Recovery is a must, I add them all, just for myself. I believe this practice was carried over from CWM recovery.
[Android Software Development] ashyx:
I always know it's going to fit when I've compiled it. ;)

Maybe for some devices it's worth including the recovery size, but for Samsung it doesn't really matter as ODIN simply rejects it if it's oversize.

Honestly I stopped including partition sizes a long time ago and I've compiled TWRP for countless devices and not yet had an issue.
[Android Software Development] pix106:
It's a security : building stops and fails if built recovery img is bigger than the real partition size.

IMHO, the sooner the exception happens, the better :)
[Android Software Development] ashyx:
Not really.

I'd rather it built so I can see the actual finished size otherwise if it is too big I wouldn't know how much smaller it needs to be.
[Android Software Development] _that:
This is exactly what you get when you specify the partition size and you build an oversized image.
[Android Software Development] ashyx:
I build it, I check the size, if it's oversize I remove what I need to. I then modify the configuration accordingly.

It's irrelevant how it's done it's not going to flash either way.
[Android Software Development] _that:
One day you will probably appreciate the convenience and accuracy of automated tests.
[Android Software Development] ashyx:
Maybe. It's what works for me.
[Android Software Development] vampirefo:
What ever works is good, I prefer to present the size but it's not required.
[Android Software Development] _that:
It is required for proper official support. Or do you think that Dees_Troy or bigbiff will manually check all the 200+ images for each release if one of them is oversized?
[Android Software Development] vampirefo:
Everyone has their own opinion, my guess would be there are more recoveries not officially supported then there are officially supported.

Officially supported may have certain rules to follow unsupported doesn't.

I have never used an officially supported recovery, cause I build my own.

To each their own, build your own or use one built by someone else, if built by someone else you follow their rules, if you build it yourself you don't.
[Android Software Development] nima0003:
Hi, could you help me build twrp from source? Thank you!
[Android Software Development] ScottDB:
If I am going to compile only TWRP (not Omni ROM), do I need to download the kernel source code for my device?
[Android Software Development] Andrzej_Andrzej:
Battery indicator in TWRP recovery

Hi,

How to add battery level indicator to TWRP recovery for my phone xperia xa f3111ss ? I want to have it in upper bar in order to know that charging battery is going ok.

In some recoveries I observe that they have it and in some they don't. Xperia uses something called Qnovo to control battery.
[Android Software Development] vampirefo:
No you don't need kernel source.
[Android Software Development] kessaras:
Can't you decompile a recovery that has it and check the XML files ?

It's in the template . When you will find it in the template you will know what to do.
[Android Software Development] vampirefo:
You need to set your battery path flag in TWRP.

---------- Post added at 04:46 AM ---------- Previous post was at 04:45 AM ----------

This thread is all about building TWRP from source.
[Android Software Development] nima0003:
I was running into a couple of errors but it's sorted now
[Android Software Development] Andrzej_Andrzej:
Hi,

what do you mean by template ?

---------- Post added at 12:01 PM ---------- Previous post was at 11:59 AM ----------

Hi, how can I do it I mean: "You need to set your battery path flag in TWRP." ?
[Android Software Development] kessaras:
we both told you the same thing but with other words.

if you don't even know about the template , or how to set a simple flag then what do you want ?

a teacher ?

google and find it :p
[Android Software Development] Andrzej_Andrzej:
Thank you that was very kind and helpful.
[Android Software Development] vampirefo:
TW_CUSTOM_BATTERY_PATH := /sys/class/power_supply/battery/batt_attr_text
[Android Software Development] Andrzej_Andrzej:
Hi, Thank you very much indeed Sir vampirefo,

Sometime we newbies need a little hint from guys like you and we can continue on our learning journey.:)

Should I put it in twrp.fstab file or Boardconfig.mk (just forgot).

I know how to unpack and modify than repack recovery.img. (Carliv Kitchen) so this "template" mentioned above I assume is a*.xml file that I would be able to find after unpacking recovery.img ?
[Android Software Development] pix106:
this is not a mount definition to be used when tablet boots, but a build flag when your computer builds, so it goes to a mk file.
[Android Software Development] vampirefo:
You apply to BoardConfig.mk

One of mine is like this .

TW_CUSTOM_BATTERY_PATH := /sys/class/power_supply/battery

you have to find your own path, most likely it's different than mine.
[Android Software Development] Andrzej_Andrzej:
I will do, thanks again.:)
[Android Software Development] diosdetiempo:
how would i start building one for the sony xperia xa1?
[Android Software Development] ScottDB:
I am trying to build TWRP 3.1.0 for hammerhead (on an Ubuntu 16.04 setup). I know it already exists, but I want to update twrp-hammerhead to 3.1.1, but I need to be able to build 3.1.0 first. I think I have all the needed source downloaded, but maybe not.

When I entered "make -j3 recoveryimage", make ran for 42 seconds, and ended with these lines:

Starting build with ninja

ninja: Entering directory `.'

ninja: no work to do.

I'm at a loss as to what's missing, or even why 'ninja' has no work to do. Can someone be so kind as to help me with this?

Thanks in advance...