yashsingh1/xdaforums huggingface dataset:
[Android Software Development] m0d:
UPDATE:

I made the change removing the brackets but still get the same error.

The kernel gets built|compiled during make recovery.

I think the issue lies with android_device_qcom_common not generating dtbToolCM, as it is not getting built into out/host/linux-x86/bin/ folder.

It is needed for the following, in custombootimg.mk:

DTBTOOL := $(HOST_OUT_EXECUTABLES)/dtbToolCM$(HOST_EXECUTABLE_SUFFIX)
$(INSTALLED_DTIMAGE_TARGET): $(DTBTOOL) $(TARGET_OUT_INTERMEDIATES)/KERNEL_OBJ/usr $(INSTALLED_KERNEL_TARGET)
$(call pretty,"Target DT image: $@")
$(hide) $(DTBTOOL) $(TARGET_DTB_EXTRA_FLAGS) -o $(INSTALLED_DTIMAGE_TARGET) -s $(BOARD_KERNEL_PAGESIZE) -p $(KERNEL_OUT)/scripts/dtc/ $(KERNEL_OUT)/arch/arm/boot/
@echo -e ${CL_CYN}"Made DT image: $@"${CL_RST}

$(INSTALLED_BOOTIMAGE_TARGET): $(PRODUCT_OUT)/kernel $(uncompressed_ramdisk) $(recovery_uncompressed_ramdisk) $(INSTALLED_RAMDISK_TARGET) $(INITSH) $(PRODUCT_OUT)/utilities/busybox $(PRODUCT_OUT)/utilities/extract_elf_ramdisk $(MKBOOTIMG) $(MINIGZIP) $(INTERNAL_BOOTIMAGE_FILES) $(INSTALLED_DTIMAGE_TARGET)
$(call pretty,"Target boot image: $@")

$(hide) rm -fr $(PRODUCT_OUT)/combinedroot
$(hide) mkdir -p $(PRODUCT_OUT)/combinedroot/sbin

[COLOR="SeaGreen"]$(hide) mv $(PRODUCT_OUT)/root/logo.rle $(PRODUCT_OUT)/combinedroot/logo.rle
$(hide) cp $(uncompressed_ramdisk) $(PRODUCT_OUT)/combinedroot/sbin/[/COLOR]
[COLOR="Red"]$(hide) cp $(recovery_uncompressed_ramdisk) $(PRODUCT_OUT)/combinedroot/sbin/[/COLOR]

The lines in green gets processed as there is /combinedroot/logo.rle and ramdisk in out directory.

But, in red the recovery ramdisk is not.

I even tried using omni's msm8974-common's custombootimg.mk

but stll get the same error.

Thank you both.

I am trying to build omnirom for z3 compact using cm12 device trees as omni does not have the needed repos.

Kernel source is available.

I am away from computer at the moment, so will provide more info later.

And,

Will try again without brackets - :fingers-crossed: still does not work

Trees used (and dependent trees):

android_device_sony_z3c

android_device_sony_shinano-common

android_kernel_sony_msm8974

android_device_qcom_common

android_device_sony_qcom-common

android_device_sony_msm8974-common

android_device_sony_common

android_device_qcom_sepolicy
[Android Software Development] gimmeitorilltell:
I have compiled twrp 2.8.3.0 for the quincyatt successfully but it NEVER wants to boot into the system. I can flash roms, restore nandroids and whatnot, but it still reboots right back into recovery. Anyone know what might be the cause of this? I had the same issue back when I first compile twrp 2.8.1.0 but somehow it got resolved. I'm not sure if it was something that I had done or not.
[Android Software Development] katinatez:
Try disabling CPUQuiet in kernel defconfig
[Android Software Development] gimmeitorilltell:
What will that do? I would give it a try but I don't see CPUQuiet in my defconfig.
[Android Software Development] Lanchon:
which bug tracker should be used? people are posting bugs on both:

https://github.com/omnirom/android_bootable_recovery/issues

https://github.com/TeamWin/Team-Win-Recovery-Project/issues

thanks!
[Android Software Development] EnerJon:
Hello Sir, can you show me an example of using "symlink=" flag?
[Android Software Development] yuweng:
Few fellow XDA friend told me they wait & wait but no response & i ask them did they miss out my post here . . . :cowboy: Just spoke to Master Shifu Dees_Troy yesterday, fyi, no worries, they are all very friendly DEVs even to a n00b like myself . . . :laugh:
[Android Software Development] katinatez:
I had trouble also with files disappearing. I only noticed after I unpacked recovery.img. I then ran across your post and decided to try this and recovery is good! Thanks alot
[Android Software Development] katinatez:
Any one know how to make recovery.img smaller with a pre-built kernel. Yes I know about kernel compression but cant use on this particular device. Any other tricks to compress image?
[Android Software Development] Android-Andi:
Compress the ramdisk using lzma or lzo? But must be supported from your kernel too.

Send from OnePlus One using Tapatalk
[Android Software Development] katinatez:
Thank You, but can't do that either have a pre-built kernel & dt.img extracted from device. Already tried tw_exclude_supersu = true but it only dropped from 9.0 mb to 8.8 mb previous twrp size is 8.3 mb
[Android Software Development] Android-Andi:
Exclude ttf and mtp :P , maybe exclude crypto also safes some space

Send from OnePlus One using Tapatalk
[Android Software Development] katinatez:
Thank you again, but I found the solution. Instead of building in android-5.0 repo I used android-4.0 repo instead and recovery.img came to 8.2 mb. Compiling again and adding SuperSu back into the build.
[Android Software Development] Android-Andi:
[MENTION=3814731]katinatez[/MENTION] yes, it's getting smaller on kitkat, though i have told you already on pm before [emoji14] twrp is getting to big on tab 2 too... same for some sony devices.

Send from OnePlus One using Tapatalk
[Android Software Development] katinatez:
Yes, credits are due your way. I do remember you saying that. So that was my final attempt and it worked. Thanks again.
[Android Software Development] Rohan purohit:
I have compiled twrp for my device xperia l ,, TWRP works fine with my BLISSPOP rom,, but when i flash a recovery image to FOTAKernel partition , partitions wont get mounted here,

http://i.imgur.com/1TsLA9A.jpg

DEVICE_RESOLUTION := 480x854

RECOVERY_GRAPHICS_USE_LINELENGTH := true

TW_HAS_NO_RECOVERY_PARTITION := true

TW_FLASH_FROM_STORAGE := true

TW_EXTERNAL_STORAGE_PATH := "/external_sd"

TW_EXTERNAL_STORAGE_MOUNT_POINT := "external_sd"

TW_DEFAULT_EXTERNAL_STORAGE := true

TW_INCLUDE_JB_CRYPTO := true

TW_CRYPTO_FS_TYPE := "ext4"

TW_CRYPTO_REAL_BLKDEV := "/dev/block/platform/msm_sdcc.1/by-name/userdata"

TW_CRYPTO_MNT_POINT := "/data"

TW_CRYPTO_FS_OPTIONS := "nosuid,nodev,barrier=1,noauto_da_alloc,discard"

TW_CRYPTO_FS_FLAGS := "0x00000406"

TW_CRYPTO_KEY_LOC := "footer"

TW_INCLUDE_FUSE_EXFAT := true

TW_BRIGHTNESS_PATH := /sys/class/leds/lcd-backlight/brightness

TW_MAX_BRIGHTNESS := 255

TW_NO_USB_STORAGE := true
[Android Software Development] katinatez:
Check your device native init.rc and make adjustment. How? Take stock recovery imgae and unpack then look at your init.rc. Does it match the init.rc found in bootable/recovery/etc/init.rc?
[Android Software Development] Android-Andi:
Set

TW_EXCLUDE_MTP := true

I.also think those flags aren't used:

TW_CRYPTO_FS_TYPE := "ext4"

TW_CRYPTO_REAL_BLKDEV := "/dev/block/platform/msm_sdcc.1/by-name/userdata"

TW_CRYPTO_MNT_POINT := "/data"

TW_CRYPTO_FS_OPTIONS := "nosuid,nodev,barrier=1,noauto_da_alloc,discard"

TW_CRYPTO_FS_FLAGS := "0x00000406"

TW_CRYPTO_KEY_LOC := "footer"

And

TW_INCLUDE_JB_CRYPTO

TW_INCLUDE_L_CRYPTO

And

TW_INCLUDE_CRYPTO

Are the same at the end ;)

First 2 will define TW_INCLUDE_CRYPTO

For reference: https://github.com/omnirom/android_bootable_recovery/blob/android-5.0/Android.mk#L259-l268

Send from OnePlus One using Tapatalk
[Android Software Development] Rohan purohit:
Thanks but no solved it twrp.fstab wasn't pushed :)
[Android Software Development] desalesouche:
hi, if you speak about that device from your github, it seems that these 2 files are differents

https://github.com/rohanpurohit/android_device_sony_taoshan/blob/master/rootdir/root/fstab.qcom

https://github.com/rohanpurohit/android_device_sony_taoshan/blob/master/rootdir/root/twrp.fstab

make twrp.fstab look like fstab.qcom. besides there is some missing lines in twrp.fstab.

and here: https://github.com/rohanpurohit/android_device_sony_taoshan/blob/master/BoardConfig.mk#L135 change fstab.qcom for twrp.fstab

i would advice you to read op again.
[Android Software Development] f(x)THaxxorX:
FIXED
[Android Software Development] desalesouche:
compiling twrp with TARGET_CPU_VARIANT := scorpion

compiling twrp with TARGET_CPU_VARIANT := scorpion breaks the build with omni 5.0 sources.

here is the fix: https://github.com/TeamEOS/bionic/commit/b95d217a1c4b2bbff6fef6098e77e2c1a1c46b84
[Android Software Development] ne0zone75:
Could it be the same for 'TARGET_CPU_VARIANT := krait' because TWRP LP sources are not working for S4 mini...

Regards

Tapatalked from my D821
[Android Software Development] desalesouche:
sorry, i can't answer that. if cm sources are ok for you and krait use files from cm to fix omni sources
[Android Software Development] cleverior.ipul:
can anyone please help me how to enable "Partitions SD Card" menu ?
[Android Software Development] _that:
Read the OP, there's a flag to set (or not set) in BoardConfig.mk.
[Android Software Development] ne0zone75:
TWRP LP for S4 mini...

[MENTION=912474]Dees_Troy[/MENTION]

Good evening,

I do think that TWRP for S4 mini situation needs some clarification and that i need some assistance :

TWRP KK sources are buildable along with CyanogenMod KK sources (recovery is working BUT brightness control must be disabled...) <= no more updates to it...

TWRP LP sources are buildable along with CyanogenMod KK sources (recovery is working BUT it seems that brightness control must be disabled too...) <= one minor issue so far... trying to reboot to recovery from recovery does not work because device reboots straight to system...

TWRP LP sources are buildable along with CyanogenMod LP sources (i have no idea if it is working or not... i've never built the recovery that way yet...)

Now, it seems that it will be more and more difficult to build a working TWRP LP image regardless of the device with CM-12.0 ROM tree in the future (i am refering to OP), so is it possible to use CM-12.0 device + kernel trees for S4 mini with an omni 5.0 ROM tree in order to build the recovery (if it is the case, what vendor tree to use ?! TheMuppets ? AND if it is not the case what device + kernel + vendor trees for S4 mini to use with omni 5.0 ROM tree ?!) ? Like porting omnirom LP to S4 mini...

Thank you for your help,

Kindest regards
[Android Software Development] lj50036:
The only thing I know is that TWRP does not need the vendor tree to work....

That was the idea of an open-recovery which gave us TWRP..... :p

You can get way better help on TWRP irc ......

Thx Josh
[Android Software Development] Android-Andi:
But maybe the device tree need the vendor folder ;)

Without it could be, that it errors out without.

For official device trees

- CM:

https://github.com/TheMuppets

- Omni

https://github.com/DonkeyCoyote

- SlimRoms

https://github.com/TheLoonyBin

TWRP is getting bigger and bigger. I need to use lzma compressed recovery ramdisk to get it working on Galaxy Tab 2, same situation for other devices now.

Send from OnePlus One using Tapatalk
[Android Software Development] lj50036:
Most device tree get around this with something like this ....

$(call inherit-product-if-exists, vendor/xxxx/xxxx/xxxx-vendor.mk)

The 'if-exists' will not kill the build if they are not present ....

In a perfect world that is how it should work.... :D

Thx Josh
[Android Software Development] _that:
Most of the bloat is probably from external dependencies. How small are the recovery partitions on those devices? On my TF700 (8 MB recovery) I've had to use LZMA for long time.
[Android Software Development] Android-Andi:
It makes sense to remove the if-exists imo to force builder to have vendor repos to compile.

We have a lot unofficial builders who forget to fetch the binaries needed for the device. The build will error out now if it was forgotten. Without the vendor blobs a rom won't boot.

https://github.com/SlimRoms/device_samsung_p3100/commit/0e06b9ce8eb627319f3ce52a602f28214d52cc2c

Send from OnePlus One using Tapatalk

---------- Post added at 11:55 AM ---------- Previous post was at 11:54 AM ----------

About 8MB too.

Send from OnePlus One using Tapatalk
[Android Software Development] rogersb11:
Looking for a little help here, I keep getting this error

zip error: Nothing to do! (/media/brett/Extra/Builds/system/target/product/t0lte/system/etc/recovery-resource.dat)

make: *** [/media/brett/Extra/Builds/system/target/product/t0lte/system/etc/recovery-resource.dat] Error 12

make: *** Waiting for unfinished jobs....

I was ALSO getting the recovery/root/res does not exist but manually adding an empty folder fixed that but that's just a workaround so I'd like to know how to fix that as well. I build my own rom and used to build philz all the time so not a noob, just slightly stumped as this is the first time I've messed with building TWRP. I'm building for t0lte BTW using that repo for resolution and smdk4412-common for the rest of course.

ALSO [MENTION=5153662]Android-Andi[/MENTION] I know you were using the ketut dual solution with philz like I was for KK and I know he's been busy and not interested lately LOL so I wondered if you had messed with it for L? I have a few times but it won't boot. After the sammy screen it just goes black and I can't pull a log. I would like to adapt it to L and start using TWRP for dual boot since philz is no longer supported. Any ideas? Thanks in advance guys
[Android Software Development] Android-Andi:
[MENTION=5554845]rogersb11[/MENTION] are you using RECOVERY_VARIANT=twrp ? Maybe try if it works. Make sure you have synced inside bootable/recovery-twrp

I always use omni source for twrp.

About dual boot:

No, no idea how to port this solution to twrp.

I haven't tried getting it work, make sure you set selinux to permissive in cmd line.

https://github.com/CyanogenMod/andr...mmit/c6db37b354a04c509f2920be7cf94fdcbeb67c9f

Send from OnePlus One using Tapatalk
[Android Software Development] rogersb11:
aah, no I did not have the variant set. I didn't see it set in the repos I was looking through to see what needed to be added. I just replaced the cm recovery folder with twrp. And yes I'm using Omni as well, I rebased it before starting to I knew that I had the latest. I will give it a go with the variant defined tho. And yep, already set permissive. I always run permissive so I don't get random se errors. Thanks for the quick reply, I'll try that now and see what happens. I actually have a recovery.img that it compiled during the rom build but it stalled out right after. I want it to just build default so figured I might as well fix it all now

Well threw this at me immediately now

make: *** No rule to make target `NOTICE-TARGET-STATIC_LIBRARIES-libminui', needed by `/media/brett/Extra/Builds/system/target/product/t0lte/root/sbin/healthd . Assuming I need to clean build again now but thought I would check beforehand

Edit again haha, MY FAULT, I missed that part about naming the folder recovery-twrp. Build running now, fingers crossed

---------- Post added at 06:10 PM ---------- Previous post was at 05:45 PM ----------

Ok so I get that same exact error about nothing to do! It happens immediately after the recovery.img is compiled
[Android Software Development] Android-Andi:
[MENTION=5554845]rogersb11[/MENTION] can you post/attach terminal output?

Time for "make clobber" ?

Send from OnePlus One using Tapatalk

Edit: trying to compile along with rom?

Or.do you run "make -iS recoveryimage" ?

Maybe this is causing problems?

BOARD_CUSTOM_GRAPHICS := ../../../device/samsung/smdk4412-common/recovery/graphics.c

Edit:

Are you using https://gerrit.omnirom.org/11468 ?

It's causing problems on make bacon (slight modified from ketuts commit, but only made optional)
[Android Software Development] rogersb11:
Trying to compile it WITH the Rom. It works if I only want to build the recovery but the ketut lzma commit, which IS the one I was using since I was using it for kk is what was giving me the "zip error, nothing to do!" I actually didn't have those, I deleted them before I added twrp to the boardconfig since they are obsolete I thought I should just get rid of them. Basically I just get that zip error and an error telling me that in the out directory under product/t0lte/recovery/root/res' not found and it's not there. I can add it myself empty but I still get the zip error. If I was just trying to compile it for myself then I would be fine but I'm trying to just replace the cm recovery in my rom source since you can't really use it at all, at least you couldn't the last time I tried it

Edit: I meant that i removed the custom graphics and recovery file that are in the device repo as normally. I basically just mocked omni smdk common and then used their i9300 for t0lte but all that was is the resolution
[Android Software Development] Android-Andi:
[MENTION=5554845]rogersb11[/MENTION] check my comment on the commit, you need a custom mkbootimg.mk instead this commit to compile along the rom. Lzma is needed in my case to get it working, twrpsize getting to big.

About the other error:

There has been a commit to prevent deleting the res folder in build. Make sure using a existing twrp resolution.

https://github.com/SlimRoms/android_build/commit/31dbeac14ac75e56cc38f98b41d49fc28ab79620

https://github.com/SlimRoms/android_build/commit/87e9bdc07a896779478a0b8f1e520bef5e5a961d

Send from OnePlus One using Tapatalk
[Android Software Development] rogersb11:
Oh man, you're awesome. Thank you very much. I have a rom build running for a different device right now but as soon add it finishes I will make these changes and give it another go. Thank you for being extremely helpful. When I saw you were the last one to comment in here before I posted I was thrilled because I remember how awesome and helpful you were in philz and helping out in ketut threads
[Android Software Development] yakub234go:
hi [MENTION=535343]all[/MENTION]

there are no images in res folder after i compile it

is it normal or i am missing something

i have defined

DEVICE_RESOLUTION := 320x480

TARGET_RECOVERY_PIXEL_FORMAT := "RGBA_8888"
[Android Software Development] Android-Andi:
Read some posts above yours, lol.

Make sure your resolution exist and check if you have included this commit https://github.com/SlimRoms/android_build/commit/87e9bdc07a896779478a0b8f1e520bef5e5a961d

Send from OnePlus One using Tapatalk
[Android Software Development] yakub234go:
Thanx i will do that

$(hide) rm -rf $(TARGET_RECOVERY_ROOT_OUT)/res/*

i dont have this line

I am compiling with cm11 source
[Android Software Development] _that:
They should be in /twres now.
[Android Software Development] yakub234go:
i dont have that folder anywhere

https://github.com/dhinesh77/android_bootable_recovery/tree/android-4.4-ubifs

https://github.com/TeamWin/Team-Win-Recovery-Project/tree/android-5.0

I am using these sources with cm11 sources
[Android Software Development] Android-Andi:
cd bootable
git clone https://github.com/omnirom/android_bootable_recovery.git recovery-twrp
cd ..
export RECOVERY_VARIANT=twrp
. build/envsetup.sh && lunch && mka -j3 recoveryimage

Send from OnePlus One using Tapatalk
[Android Software Development] yakub234go:
ok i am cloning now will build & report

build/core/base_rules.mk:134: *** bootable/recovery: MODULE.TARGET.EXECUTABLES.recovery already defined by bootable/recovery-twrp. Stop.
[Android Software Development] Android-Andi:
Possible resolution:

https://github.com/omnirom/android_bootable_recovery/tree/android-5.0/gui/devices

Send from OnePlus One using Tapatalk
[Android Software Development] yakub234go:
[MENTION=5153662]Android-Andi[/MENTION]

i am getting error after cloning & building Read my above post

i realised that i want to built it for supporting ubis so i cannot use the source u linked

& one more think i cannot get shell or logcat from the compiled recovery

is it because of the res image missing ?
[Android Software Development] Android-Andi:
Do you now have twrp source twice inside bootable/ ?

Send from OnePlus One using Tapatalk
[Android Software Development] yakub234go:
i used urs and deleted mine recovery-twrp

so now i have two folder recovery & recovery-twrp
[Android Software Development] theBstep:
newbie

hello guys I'm planning to make a Twrp recovery for my phone Cherry Mobile Titan 2.0

what's the first thing I should do?
[Android Software Development] rogersb11:
If you don't already have a build environment setup you will need you start there. If it's only too build twrp you would be wise to pull omni since you won't have to adapt anything for fixes other than the device configs. Should be easy with omni. I use a ROM that has stuff from all over and I still have issues Eben tho I an able to be the recovery itself
[Android Software Development] theBstep:
so basically what softwares do I need mate?

my phone is Jellybean 4.1.2 and it's similar to CM10 but TWRP doesn't support my device and I'm planning to be the first to make
[Android Software Development] rogersb11:
You need to setup a build environment, you will need one to compile anyway. Setting it to will give you ant software you'll need. Then you'll need to download the source, I'd do it overnight if I were you
[Android Software Development] yakub234go:
Hi [MENTION=535343]all[/MENTION] again

i have successfully compiled twrp recovery from source with ubifs support for my device & i can do backup with it & all other features but i am not able to restore those backup whenever i try to restore the backup the the system gets formatted but the recovery can't write or make directory inside system or data folders with "mkdir(): Permission denied" error & even with root shell a can't make folders inside /system or /data when they r mounted & i don't have any clue why this is happening cause i am building from source for the first time so am new to it

Please if anyone can help me with this

my device is mt6571 with ubifs system

here is the twrp log of the error http://pastebin.com/nbh0rJbi

Thanx in advance
[Android Software Development] lj50036:
What is the output of this command ?

adb shell getenforce

Thx Josh
[Android Software Development] yakub234go:
/sbin/sh: getenforcing: not found

the command is "getenforce"

and i get "Enforcing"

Thanx [MENTION=5123642]lj50036[/MENTION]

i changed it to permissive using "setenforce 0" & now i can restore my backup

but this is temporary solution how can i add selinux to permissive while building recovery from source
[Android Software Development] lj50036:
As long as you are building the kernel from source ....

Set this flag in BoardConfig.mk

androidboot.selinux=permissive

Here is an e.g.

GITHUB

Thx Josh
[Android Software Development] yakub234go:
[MENTION=5123642]lj50036[/MENTION] i am using prebuilt kernel how can i force permission there
[Android Software Development] Android-Andi:
Add inside init.rc

setenforce 0

Add it here: https://github.com/omnirom/android_bootable_recovery/blob/android-5.0/etc/init.rc#L10

Send from OnePlus One using Tapatalk
[Android Software Development] lj50036:
Yep that will do it .... :good:

Thx Josh
[Android Software Development] yakub234go:
[MENTION=5123642]lj50036[/MENTION] [MENTION=5153662]Android-Andi[/MENTION] now i have problems with installing apps

"unknown error code during application install -110"
[Android Software Development] aguaz:
Does anyone have a list of projects which are safe to remove from the Omni tree in order to be still able to build twrp?
[Android Software Development] _that:
Try the manifest linked in the OP.
[Android Software Development] yakub234go:
hi [MENTION=371528]Everybody[/MENTION] again

now i am not able to wipe dalvik cache

here is the log View attachment DALVIKTWRP.log
[Android Software Development] sir mordred:
Can i build twrp on CM sources?

i dont know but maybe some android_build/config changes should be reverted?

Thanx

EDIT: i mean only changing recovery folder(putting twrp into cm tree) is enough? Or is there another changes should be done?
[Android Software Development] katinatez:
Correct on both; you have to revert this in android/build https://github.com/katinatez/android_build/commit/c453b60684e2f6150c08ca29f3d405a3e323192d

And add this to your local manifest

<remove-project name="android_bootable_recovery" />
<project name="katinatez/android_bootable_recovery/" path="bootable/recovery" remote="github" revision="android-5.0" />
[Android Software Development] schwabe93:
an anyone help me with that error?:

Thanks