yashsingh1/xdaforums huggingface dataset:
[Android Software Development] zerolam:
Actually, I did not modify the syatemui.apk

I just decompile and recompile systemui.apk with framework-res.apk

If successful, I will try to remove the lock screen tint

https://xdaforums.com/android/general/guide-how-to-remove-lockscreen-t3819931

But, unsuccessful with non-modified systemui.apk.

I can't imagine this will success with modified systemui.apk

Could you tell me what steps are wrong?

Thank you so much
[Android Software Development] 1droidmod:
[MENTION=6642485]zerolam[/MENTION]

Check your messages
[Android Software Development] djdarkknight96:
This would be easier as an overlay just saying
[Android Software Development] zerolam:
sorry I don't understand, I am not good in english

sorry
[Android Software Development] zerolam:
is this possible to decompile and recompile "Systemui.apk" of AOSP ROM?

because I got BlackScreen after boot animation with rebuilded systemui.apk (without modication).
[Android Software Development] smallville7123:
any chance in releasing this for Android itself as a library as so it can be used in android applications, as directly importing the JAR appears to mess with Android Studio, producing false errors such as unresolved TypedValue.applyDimensions which go away after removing the apktool JAR file
[Android Software Development] sairam89:
Does anybody have a working solution for signing other than copying meta-inf and androidmanifest ? Because it's not working . Is there any way to bypass signature verification temporarily ,like when i am installing it should be disabled and enabled later ? I found no luck in finding a solution copying meta-inf ain't working anymore .

---------- Post added at 05:17 PM ---------- Previous post was at 04:48 PM ----------

I am thinking we should have a discussion group in telegram for apktool ,,,what do you guys think
[Android Software Development] djdarkknight96:
Sign with test keys or place on system/app it will ignore signature.
[Android Software Development] sairam89:
Actually sir i am trying to mod systemui and i have already tried signing with test key and also with platform key(since its a priv-app). Nothing works for me as of now in pie. I didn't have this problem in Oreo,,, i can just replace meta-inf and androidmanifest and then BOOOM it works. Can you confirm that apps like systemui works fine signing with test key or platform key ???? For the testing purpose i tried without any changing and i tried all possible combinations of signing or replacing . Nothing works for me :(:(:(:(:(:(
[Android Software Development] djdarkknight96:
Oh no not system apps. You were right
[Android Software Development] sairam89:
So there is no way signing system apps?>:confused:
[Android Software Development] djdarkknight96:
No reason to, just use original meta-info and manifest. At least was like that last I done it. You might wanna log the issues you are having.
[Android Software Development] sairam89:
System started to reboot immediately after placing apk(No changes) somehow i managed to get the logcat please check it once
[Android Software Development] Nima79:
hello there .. thanks for ur great great work .

i got error when de-compile this apk

i upload error .. would you plz help me ?? [MENTION=3924617]iBotPeaches[/MENTION]
[Android Software Development] djdarkknight96:
Here's your build issue

\Users\NISAAJ\Desktop\apktool\new\res\values\styles.xml:1412: error: Resource entry Theme.Black already has bag item android:dropDownListViewStyle.

W: C:\Users\NISAAJ\Desktop\apktool\new\res\values\styles.xml:1411: Originally defined here.

Like a 1411 and 1412 are duplicates
[Android Software Development] Nima79:
thank you so so much bro .. i fixed them.

but see another error :eek:
[Android Software Development] djdarkknight96:
Looks like you need Q framework installed to your pc

Use command

apktool if framework-res.apk

With Q fw in the folder

Then try building again
[Android Software Development] Nima79:
oh .. im in android p and not root . where can i get Q firmware ... searched but find nothing.
[Android Software Development] levone1:
https://github.com/dongfangxunlei/openjdk/wiki/How-to-play-with-apktool-on-android

The apk called 'OpenJDK Installer' is an app to connect here - https://github.com/dongfangxunlei/openjdk/releases, which is Android jre and jdk files, including an Apktool for Android.

Actually installing the whole thing on stock pie didn't work for me on Xperia XZ2 Compact, (the app somehow fails to be able to copy the jdk files), but I was able to get it done manually like this - https://xdaforums.com/showpost.php?p=79402786&postcount=1

BTW - I know this is not exactly the library solution you were asking about, but just thought maybe it would address your issue another way...
[Android Software Development] DragonFire1024:
I have a question regarding Apktool X, the Android application. The application installs twice. I can't find a mention of this anywhere, but I'm not concerned. Rather intrigued. Does this application clone itself when you install it? I notice one of the two installations is present in the apps data/data folder. Any information, little or not would be appreciated. I have an interest in trying this on another application if this is the case.
[Android Software Development] levone1:
It's not connected to the development of this thread. Androblack simply used official Apktool and modified it and made an installer to use it on Android. I think why it installs twice is because you have to install the installer to give it the proper permissions to install the needed files, (similar to OpenJDK Installer I posted about above). ApktoolX won't be able to do much of what it does without you selecting 'root' and 'install openjdk' options in settings, for example...
[Android Software Development] DragonFire1024:
Right that I know. I was more hoping it was a way for it to actually execute everything without interference or something to that effect. In other words I was hoping it was taking advantage of data/data much in the way termux uses it or how it can install things in that area.
[Android Software Development] levone1:
you can use apktool via command line, just like on a computer, if you want, for full control of options, etc. Just cd to a folder that has the jre files, and apktool jar, and commands should work. I can give more detail if you want. What I've done in the past is install OpenJDK, or ApktoolX, then copied all of the files from /data/data/...., and made a directory in /data/local, or wherever, and use command line, or executable scripts...
[Android Software Development] DragonFire1024:
For now that helps. Thanks for the quick reply.
[Android Software Development] denkazzzget:
Anyone knows how to resolve this?

https://xdaforums.com/showpost.php?p=79764132&postcount=1321
[Android Software Development] Thebear j koss:
Only move whatever you changed from recompiled apk into original apk. Then flash the original apk with the changed files moved into it. Use 7zip or winrar to open apks to view contents, if you changed colors.xml for example, drag resources.arc from new apk into original overwriting the original.

Sent from my PH-1 using Thebear Blue XDA Labs
[Android Software Development] jps1x2:
Thanks for your work.

Donation sent!

Regards
[Android Software Development] Lanchon:
how is this possible? apktool bundles patched binaries of AAPT and AAPT2, and they are i386 and x86-64 only. there is no support for armv7 or arm64 archs. have you tried rebuilding an app on a real android device?
[Android Software Development] levone1:
I use it all the time, since a year ago, when [MENTION=8704781]pqy330[/MENTION] first posted about it in Apktool on Android thread, and I've used AoktoolX by Androblack for probably 2 years before that. I never have a rom that I personally haven't modified, and I almost never use a computer, (except for porting, etc, where you need adb to debug bootloops). For example - https://xdaforums.com/x-compact/themes/ui-mods-existenz-8-t3940511 - was all done on the phone, using OpenJDK/Amaze.
[Android Software Development] Lanchon:
mystery solved: dongfangxunlei talks about the "apktool.jar" but he is referring to his own fork of it, which includes AAPT(2) builds for android on several archs. it is here: https://github.com/dongfangxunlei/Apktool

thanks!
[Android Software Development] levone1:
Right... BTW - thanks for your work. Long-time MicroG user, and until recently, (since NanaoDroid / Magisk), I couldn't live without Haystack / Needle / Tingle...
[Android Software Development] Lanchon:
welcome!

BTW you continue to use haystack. although it seems not clear for users, nanodroid patcher is haystack+dexpatcher bundled to run in recovery.

thanks!
[Android Software Development] TheZakDroid:
When trying to recompile the /system/framework/framework-res.apk, I get this output:

C:\Users\theza>apktool b framework-res -c
I: Using Apktool 2.4.0
W: Could not find sources
I: Checking whether resources has changed...
I: Building resources...
brut.androlib.AndrolibException: brut.common.BrutException: could not exec: [ Long list of possibly all of the files in the apk ]

I'm using Windows and I have the latest version of Apktool (2.4.0) and (if it helps) I've got JDK 8.0 installed and set to path. I also decompiled the apk using the command:

apktool d framework-res.apk

...and everything went fine.

Am I typing the command wrong? If so which parameters should I use to decompile and recompile the APK?

Please let me know
[Android Software Development] gloeyisk:
If you're trying to compile/decompile Oreo/Pie APKs then yes, happened to me once either I'm use all the necessary tools to the latest update. Else you need to check whether your APK is odexed or not. Then if yes, you need to do another tasks (it's called deodexing the APK).
[Android Software Development] Thebear j koss:
Need full log

Sent from my PH-1 using Thebear Blue XDA Labs
[Android Software Development] Ticklefish:
Hello! Welcome to the wonderful (and sometimes painfully confusing) world of Android modding!

It's difficult to know exactly what's caused this issue without knowing a bit more information about your full decompile/recompile process but I suspect this is being caused by an issue with your framework file. Apktool is saying that it can't find resource identifiers for some of the parts of your APK.

Make sure you've installed the latest framework file available before you decompile your APK. I don't know where you're getting your APK from but, if you've taken it from your phone, you'll find the framework file in there as well.

Best of luck!

(Oh, and I've put "CODE" tags around your error log in my quote. It's a little thing but it makes the post that much easier to read. :))
[Android Software Development] gaplan:
Thank you for quick answer.

i was download apk file this adress;

YouTube 14.28.55 (x86) (nodpi) (Android 4.4+)

apkmirror.com/wp-content/themes/APKMirror/download.php?id=747387

and the same errors.

how can I debug and build it correctly?
[Android Software Development] TheZakDroid:
How do I check if it's odexed and how would I deodex it?

Would I also have to odex it again?
[Android Software Development] Thebear j koss:
Need to install framework files into apktool before modding apk. Probably need at least the latest pie fw res apk

Sent from my PH-1 using Thebear Blue XDA Labs

---------- Post added at 04:57 AM ---------- Previous post was at 04:53 AM ----------

If you are going to theme or mod you should be on a deodex rom. Are there any .odex files within the directory of the apk? And no, once an app is deodexed it doesn't need to be odexed once again. But if you don't know what you are doing, you can mess things up pretty good so always keep a good backup just in case.

Sent from my PH-1 using Thebear Blue XDA Labs
[Android Software Development] gaplan:
Hello again,

framework-res.apk installed.

pie framework ?

where or how can i find it ?

Thank you for time.
[Android Software Development] Thebear j koss:
Here, you can try my framework from my Essential, extract it from the zip. https://drive.google.com/file/d/11czJHSPbcLBMt1WkM0ajNspiKrr1edAd/view?usp=sharing

Sent from my PH-1 using Thebear Blue XDA Labs
[Android Software Development] gaplan:
Thank you for all.

i have last 2 problem line.

W: /Users/osa/Downloads/toollar/yitip/AndroidManifest.xml:26: error: No resource identifier found for attribute 'requestLegacyExternalStorage' in package 'android'

W:

W: /Users/osa/Downloads/toollar/yitip/AndroidManifest.xml:159: error: No resource identifier found for attribute 'foregroundServiceType' in package 'android'

W:

brut.androlib.AndrolibException: brut.common.BrutException: could not exec (exit code = 1): [/var/folders/ft/fk_6yv092fg1pjvwsdvv7tq00000gn/T/brut_util_Jar_8320603045500234351.tmp,
[Android Software Development] Ticklefish:
Curiously, there doesn't seem to be any decent guides on the internet about odexed and deodexed roms. There are a few short ones but nothing that goes into the right sort of depth while still being noob-friendly and up-to-date.

I found this from 2010, which gives you an idea: https://www.addictivetips.com/mobile/what-is-odex-and-deodex-in-android-complete-guide/. (This has been neatly plagiarised here: https://xdaforums.com/showthread.php?t=2200349 and here: https://xdaforums.com/showthread.php?t=2336411)

There's a good post on stackexchange here: https://android.stackexchange.com/questions/6925/what-is-the-difference-between-odexed-and-deodexed-roms

And also quite a useful guide here: https://www.wugfresh.com/deodexing-explained-how-to/

Those last two are from 2011 which is a very long time ago considering how often Google change how odexing actually works, but they should give you an idea of what it's all about.

If you want to deodex your rom, you need to do some research, find a good and up-to-date deodexing tool (cough..cough..TOAD..cough) and make sure you take a full backup before you start processing anything.

It's very easy to get it wrong and soft-brick your phone so you need to know how to fix that.

---------- Post added at 10:49 AM ---------- Previous post was at 10:31 AM ----------

I've done a bit of research into this and it looks like "requestLegacyExternalStorage" and "foregroundServiceType" are manifest attributes added to API 29.

Or, to put it another way, these are new to Android Q.

Which would mean that we'd need a "framework-res.apk" from Android Q to be able to decompile and recompile the APK properly..
[Android Software Development] tpuserhp:
I want to make changes to an app which has splitted apks using apktook 2.4.0. There is an updated android-framework.jar for the issplitrequired keyword issue. But after I update apktook.jar with the updated android-framework.jar, apktool.jar is corrupted. Can this be done? I believe I need to decompile, make changes, recompile, sign and install the apks using SAI app. Would this be possible? Please let me know the steps if you have done this before. Thanks.
[Android Software Development] Ticklefish:
I don't know why you're getting a corrupted apktool.jar so I can't help there. But I did a little Googling and "isSplitRequired" is something that's been introduced for API 29 - Android Q.

So it's worth trying to decompile these files after you've installed a framework-res.apk from a recent Q build. That might let you decompile the APK's without any trouble.
[Android Software Development] gloeyisk:
What is SAI app?
[Android Software Development] Ticklefish:
According to the first result when I Google "Sai app" (https://lmgtfy.com/?q=sai+app), it's something that installs split apps.
[Android Software Development] Ibuprophen:
Just to add to what [MENTION=4315551]Ticklefish[/MENTION] had posted...

Apktool isn't equipped/adapted to deal with ".apks" files (aka Split App Bundles).

The only tool (that I'm aware of) to work with these Bundle Apps is the following.

Official Google Bundletool (A tool to manipulate Android App Bundles known as .apks) - Github

Just to add (or an FYI)... If you change the file extension from ".apks" to ".zip", you'll find that the .apks files contain multiple apk files. This is done by design.

Please refer to the above link for more information as my knowledge of working with them is currently limited to the basic understanding and not developmental.

I hope I had explained this to you okay via text... :eek:

I wish you the best of luck! :)

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

Unless asked to do so, PLEASE don't PM me regarding support. Sent using The ClaRetoX Forum App on my Apple Macintosh.
[Android Software Development] Jonny:
it does help if you upload the apk files you want to be checked
[Android Software Development] reosm:
browser.apk decompile just submit the form at least version 2.9.14
[Android Software Development] iBotPeaches:
I ignore you at MIUIAndroid. I ignore you everywhere. Let me make this clear.

You make no sense. Forgive me if its our language barrier, but I don't understand. I build MIUI ROMs everyday using this apktool and never received an error.

Start posting APKs, and stack-traces, and logs. Stop these 1 line responses that make absolutely no sense.

@ Everyone else.

peaches@turf:~/build/wip/rom_wip_aries/apks/test$ apktool b -o MiuiSystemUI.apk MiuiSystemUI
I: Checking whether sources has changed...
I: Checking whether resources has changed...
I: Building apk file...
I: Building resources into original apk file...
[Android Software Development] cowsquad:
I don't have any problems with apktool at all. I am happy with your tool. Thank you for your hard work, just ignore those peeps lol.

tapatalked² cowsquadGnex®
[Android Software Development] reosm:
I just think the lines are missing values ​​too, so I wanted to check out?

---------- Post added at 09:43 PM ---------- Previous post was at 09:39 PM ----------

I9100 Rom decompile settings.apk values ​​/ string.xml values-en/string.xml 150 kb 133 kb?
[Android Software Development] iBotPeaches:
values will be the largest. It has everything, even some strings that aren't translatable. Those strings are just @string/android/something that point to another value.

So those aren't included in any values-xx translation, which can explain the difference. If its major, its probably since you haven't re-signed the APK.
[Android Software Development] reosm:
hat's the problem the error message does not match the lines already
[Android Software Development] evol4g:
http://paste.ubuntu.com/1214003/

i'm not quite sure what i can do about this error, but i do need to fix it :\
[Android Software Development] CosmicDan:
I'm sorry if this is another noob issue question iBotPeaches, but I get the following error recompiling Phone on latest MIUI:

base_miui\app\Phone\res\values-uk\strings.xml:166: error: Multiple substitutions specified in non-positional format; did you mean to add the formatted="false" attribute?

I am def. using the latest aapt and apktool, but am on Windows. Would this be solved rebuilding under Linux with the newer aapt (i.e. an aapt bug)?

EDIT: For now I just deleted the Ukranian translation and it recompiled fine. The APK is from 2.9.14 language pack for Nexus S (crespo file). I remember I could fix it once by adding some % or $ somewhere in the string but I can't remember what exactly.
[Android Software Development] iBotPeaches:
I'm not good at 9patch image decoding at all. The error means though that its not a 9patch image, so it converted it back to PNG. The error could be wrong, but I'm not going to go mess around with de-swilzing image classes, unless your positive those were 9patch images.
[Android Software Development] iBotPeaches:
bah. I just duplicated that. So it seems it compiles fine with the current stance on the XML, but decompiling it again causes it to break. So maybe I'll add the attribute adder to automatically add formatted="false".

I'll add this into the roadmap for v1.5.1.
[Android Software Development] evol4g:
they should have been 9patch images.. I got it from a custom TW ROM.. but if they were edited correctly by the dev of the ROM it should have been a 9patch image still
[Android Software Development] Skizzy034:
I've come across a bunch of themed apks with those errors for 9.png's. I did a little searching and found how to correctly theme the 9.png's (rather just change the color in photoshop because I'm still learning) and then recompile so that when decompiled you won't get those error's. It's not the way they are being decompiled but the way they were changed by the person before you and recompiled.

There are two steps I used:

Decompile an apk such as from CM10 and there will be no errors. Say if you wanna change the color of the 9.png from blue to red as I did, you open it up in photoshop and you will see those black boundary lines that tell Android where to extend the image to. Just make sure you don't change anything over those lines. Only what's inside of them. When you recompile they will be correctly made.

I also used 9png Ultimate Decompiler. I you just want to compile a couple 9.pngs without compiling the whole apk then this tool works great.

I'm sorry if I'm way of base with this post but it looked like this is what the last two posts before were about. I'm just starting to get the hang of compiling/decompiling apks and editing png's and xml's. I made my first theme in the AT&T One X forum.
[Android Software Development] g3ckospy:
sorry for being a noob, i was wondering where i could find the installer of the latest apktool?

EDIT: have found the workaround, thanks...
[Android Software Development] ingbrzy:
RTFM OP

~Tapatalk~
[Android Software Development] vinodkbishnoi:
I have tried that. But no avail. And yes this is a system app. so how to sign it using original rom platform key.
[Android Software Development] robm1911:
Easy peasy
[Android Software Development] iBotPeaches:
Developer News!

All the projects (brut.apktool.smali, brut.j.common, brut.j.util, brut.j.dir, and brut.apktool). Have been merged into one project here: https://github.com/iBotPeaches/Apktool/.

The good news. Maven is gone! No more build errors due to my lack of knowledge of maven. Thanks to JesusFreke for the tip on gradle. Simply follow the build instructions here: https://github.com/iBotPeaches/Apktool/wiki/Build-Instructions

To help work on future Apktool releases. I will have lots of documentation ready and new features for Apktool v1.5.1.
[Android Software Development] cowsquad:
Do we use the aapt from SDK or your modified aapt man with this new build of apktool?

Edited

Never mind lol

tapatalked² from cowsquadGnex®
[Android Software Development] Ghost_in_love:
Mod edit: Please read the OP before posting.
[Android Software Development] Ticklefish:
Huh..I didn't know that. I hadn't heard of split apps until I saw the earlier post this morning and I have to admit I'd just assumed that they came as different ".APK" files. I didn't realise they were all contained inside one parent ".APKS" file.

In theory, you could extract the APK you want to modify from the APKS file. Then decompile-modify-recompile it as usual before inserting it back into the APKS file. But there's no guarantee that would work. Knowing Google it would have to have the same compression rate or something..

I think if you're going to do this, [MENTION=5333182]tpuserhp[/MENTION], you'll need to do a bit of experimenting. Let us know how you get on!
[Android Software Development] Ibuprophen:
I know what you mean... LOL!

It was only recently (the past few months) I was bumping into them and was thrown off about it.

It's just an alternative for Google Play Store for developers to be able to provide smaller sized apps to individuals based upon DPI and Architecture.

Some apps can get really huge that becomes discouraging to individuals who doesn't want/can't use such large sized apps. So the developers can break up the app into these apks bundles that provides the individual with a smaller and single apk on the Play Store based upon the Device the Play Store sees from each individual.

This is only a brief explanation and I hope I had explained this okay via text.... :eek:

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

Unless asked to do so, PLEASE don't PM me regarding support. Sent using The ClaRetoX Forum App on my Apple Macintosh.