Apktool problem.

Search This thread

nightwalkerkg

Senior Member
Aug 20, 2012
699
607
28
Kragujevac
I am trying to do some mods to the prism apk. It's working fine with framework-res.apk but when i try to do apktool if com.htc.resources.apk i get this :


Code:
C:\Users\Ivke\Desktop\Apktool>apktool if com.htc.resources.apk
Exception in thread "main" brut.androlib.AndrolibException: Multiple resources:
spec=0x02050078 dimen/title_primary_xs, config=-mdpi
        at brut.androlib.res.data.ResConfig.addResource(ResConfig.java:63)
        at brut.androlib.res.data.ResConfig.addResource(ResConfig.java:56)
        at brut.androlib.res.decoder.ARSCDecoder.readEntry(ARSCDecoder.java:199)

        at brut.androlib.res.decoder.ARSCDecoder.readConfig(ARSCDecoder.java:168
)
        at brut.androlib.res.decoder.ARSCDecoder.readType(ARSCDecoder.java:134)
        at brut.androlib.res.decoder.ARSCDecoder.readPackage(ARSCDecoder.java:10
9)
        at brut.androlib.res.decoder.ARSCDecoder.readTable(ARSCDecoder.java:81)
        at brut.androlib.res.decoder.ARSCDecoder.decode(ARSCDecoder.java:49)
        at brut.androlib.res.decoder.ARSCDecoder.decode(ARSCDecoder.java:40)
        at brut.androlib.res.AndrolibResources.installFramework(AndrolibResource
s.java:686)
        at brut.androlib.Androlib.installFramework(Androlib.java:640)
        at brut.apktool.Main.cmdInstallFramework(Main.java:249)
        at brut.apktool.Main.main(Main.java:91)

@ckpv5 Can you tell me the version of your apktool ?
 

nightwalkerkg

Senior Member
Aug 20, 2012
699
607
28
Kragujevac
Use latest version of apktool (https://code.google.com/p/android-apktool/) and latest aapt.

xpirt

I have this problem with the latest version v2.0.0b7.
I downloaded the version 1.5.2 and now i get this,looks like it will do it but with errors :

Code:
C:\Users\Ivke\Desktop\apktool2>apktool d Prism.apk prism
I: Baksmaling...
I: Loading resource table...
I: Loaded.
I: Decoding AndroidManifest.xml with resources...
I: Loading resource table from file: C:\Users\Ivke\apktool\framework\1.apk
I: Loaded.
I: Regular manifest package...
I: Decoding file-resources...
I: Loading resource table from file: C:\Users\Ivke\apktool\framework\2.apk
W: Config flags size > 36. Exceeding bytes: 0x2000000.
W: Invalid config flags detected: dimen-mdpi-ERR0
W: Config flags size > 36. Exceeding bytes: 0x4000000.
W: Invalid config flags detected: dimen-mdpi-ERR1
W: Config flags size > 36. Exceeding bytes: 0x5000000.
W: Invalid config flags detected: dimen-mdpi-ERR2
W: Config flags size > 36. Exceeding bytes: 0x6000000.
W: Invalid config flags detected: dimen-mdpi-ERR3
W: Config flags size > 36. Exceeding bytes: 0x2000000.
W: Invalid config flags detected: dimen-hdpi-ERR4
W: Config flags size > 36. Exceeding bytes: 0x4000000.
W: Invalid config flags detected: dimen-hdpi-ERR5
W: Config flags size > 36. Exceeding bytes: 0x5000000.
W: Invalid config flags detected: dimen-hdpi-ERR6
W: Config flags size > 36. Exceeding bytes: 0x6000000.
W: Invalid config flags detected: dimen-hdpi-ERR7
W: Config flags size > 36. Exceeding bytes: 0x2000000.
W: Invalid config flags detected: dimen-ja-mdpi-ERR8
W: Config flags size > 36. Exceeding bytes: 0x4000000.
W: Invalid config flags detected: dimen-ja-mdpi-ERR9
W: Config flags size > 36. Exceeding bytes: 0x5000000.
W: Invalid config flags detected: dimen-ja-mdpi-ERR10
W: Config flags size > 36. Exceeding bytes: 0x6000000.
W: Invalid config flags detected: dimen-ja-mdpi-ERR11
W: Config flags size > 36. Exceeding bytes: 0x2000000.
W: Invalid config flags detected: dimen-ja-hdpi-ERR12
W: Config flags size > 36. Exceeding bytes: 0x4000000.
W: Invalid config flags detected: dimen-ja-hdpi-ERR13
W: Config flags size > 36. Exceeding bytes: 0x5000000.
W: Invalid config flags detected: dimen-ja-hdpi-ERR14
W: Config flags size > 36. Exceeding bytes: 0x6000000.
W: Invalid config flags detected: dimen-ja-hdpi-ERR15
W: Config flags size > 36. Exceeding bytes: 0x2000000.
W: Invalid config flags detected: dimen-ko-mdpi-ERR16
W: Config flags size > 36. Exceeding bytes: 0x4000000.
W: Invalid config flags detected: dimen-ko-mdpi-ERR17
W: Config flags size > 36. Exceeding bytes: 0x5000000.
W: Invalid config flags detected: dimen-ko-mdpi-ERR18
W: Config flags size > 36. Exceeding bytes: 0x6000000.
W: Invalid config flags detected: dimen-ko-mdpi-ERR19
W: Config flags size > 36. Exceeding bytes: 0x2000000.
W: Invalid config flags detected: dimen-ko-hdpi-ERR20
W: Config flags size > 36. Exceeding bytes: 0x4000000.
W: Invalid config flags detected: dimen-ko-hdpi-ERR21
W: Config flags size > 36. Exceeding bytes: 0x5000000.
W: Invalid config flags detected: dimen-ko-hdpi-ERR22
W: Config flags size > 36. Exceeding bytes: 0x6000000.
W: Invalid config flags detected: dimen-ko-hdpi-ERR23
W: Config flags size > 36. Exceeding bytes: 0x2000000.
W: Invalid config flags detected: dimen-zh-rCN-mdpi-ERR24
W: Config flags size > 36. Exceeding bytes: 0x4000000.
W: Invalid config flags detected: dimen-zh-rCN-mdpi-ERR25
W: Config flags size > 36. Exceeding bytes: 0x5000000.
W: Invalid config flags detected: dimen-zh-rCN-mdpi-ERR26
W: Config flags size > 36. Exceeding bytes: 0x6000000.
W: Invalid config flags detected: dimen-zh-rCN-mdpi-ERR27
W: Config flags size > 36. Exceeding bytes: 0x2000000.
W: Invalid config flags detected: dimen-zh-rCN-hdpi-ERR28
W: Config flags size > 36. Exceeding bytes: 0x4000000.
W: Invalid config flags detected: dimen-zh-rCN-hdpi-ERR29
W: Config flags size > 36. Exceeding bytes: 0x5000000.
W: Invalid config flags detected: dimen-zh-rCN-hdpi-ERR30
W: Config flags size > 36. Exceeding bytes: 0x6000000.
W: Invalid config flags detected: dimen-zh-rCN-hdpi-ERR31
W: Config flags size > 36. Exceeding bytes: 0x2000000.
W: Invalid config flags detected: dimen-zh-rTW-mdpi-ERR32
W: Config flags size > 36. Exceeding bytes: 0x4000000.
W: Invalid config flags detected: dimen-zh-rTW-mdpi-ERR33
W: Config flags size > 36. Exceeding bytes: 0x5000000.
W: Invalid config flags detected: dimen-zh-rTW-mdpi-ERR34
W: Config flags size > 36. Exceeding bytes: 0x6000000.
W: Invalid config flags detected: dimen-zh-rTW-mdpi-ERR35
W: Config flags size > 36. Exceeding bytes: 0x2000000.
W: Invalid config flags detected: dimen-zh-rTW-hdpi-ERR36
W: Config flags size > 36. Exceeding bytes: 0x4000000.
W: Invalid config flags detected: dimen-zh-rTW-hdpi-ERR37
W: Config flags size > 36. Exceeding bytes: 0x5000000.
W: Invalid config flags detected: dimen-zh-rTW-hdpi-ERR38
W: Config flags size > 36. Exceeding bytes: 0x6000000.
W: Invalid config flags detected: dimen-zh-rTW-hdpi-ERR39
W: Config flags size > 36. Exceeding bytes: 0x2000000.
W: Invalid config flags detected: integer-mdpi-ERR40
W: Config flags size > 36. Exceeding bytes: 0x4000000.
W: Invalid config flags detected: integer-mdpi-ERR41
W: Config flags size > 36. Exceeding bytes: 0x5000000.
W: Invalid config flags detected: integer-mdpi-ERR42
W: Config flags size > 36. Exceeding bytes: 0x6000000.
W: Invalid config flags detected: integer-mdpi-ERR43
W: Config flags size > 36. Exceeding bytes: 0x2000000.
W: Invalid config flags detected: integer-hdpi-ERR44
W: Config flags size > 36. Exceeding bytes: 0x4000000.
W: Invalid config flags detected: integer-hdpi-ERR45
W: Config flags size > 36. Exceeding bytes: 0x5000000.
W: Invalid config flags detected: integer-hdpi-ERR46
W: Config flags size > 36. Exceeding bytes: 0x6000000.
W: Invalid config flags detected: integer-hdpi-ERR47
I: Loaded.
I: Decoding values */* XMLs...
I: Done.
I: Copying assets and libs...
 

nightwalkerkg

Senior Member
Aug 20, 2012
699
607
28
Kragujevac
--keep-broken-res: http://xdaforums.com/showthread.php?t=2229230 to decompile.
Now it's installed successfully btw.

xpirt

I can't seem to run this variable in windows. Hmmm. :confused:
I managed to install it but with this error :
Code:
C:\Users\Ivke\Desktop\apktool2>apktool if com.htc.resources.apk
W: Config flags size > 36. Exceeding bytes: 0x2000000.
W: Invalid config flags detected: dimen-mdpi-ERR0
W: Config flags size > 36. Exceeding bytes: 0x4000000.
W: Invalid config flags detected: dimen-mdpi-ERR1
W: Config flags size > 36. Exceeding bytes: 0x5000000.
W: Invalid config flags detected: dimen-mdpi-ERR2
W: Config flags size > 36. Exceeding bytes: 0x6000000.
W: Invalid config flags detected: dimen-mdpi-ERR3
W: Config flags size > 36. Exceeding bytes: 0x2000000.
W: Invalid config flags detected: dimen-hdpi-ERR4
W: Config flags size > 36. Exceeding bytes: 0x4000000.
W: Invalid config flags detected: dimen-hdpi-ERR5
W: Config flags size > 36. Exceeding bytes: 0x5000000.
W: Invalid config flags detected: dimen-hdpi-ERR6
W: Config flags size > 36. Exceeding bytes: 0x6000000.
W: Invalid config flags detected: dimen-hdpi-ERR7
W: Config flags size > 36. Exceeding bytes: 0x2000000.
W: Invalid config flags detected: dimen-ja-mdpi-ERR8
W: Config flags size > 36. Exceeding bytes: 0x4000000.
W: Invalid config flags detected: dimen-ja-mdpi-ERR9
W: Config flags size > 36. Exceeding bytes: 0x5000000.
W: Invalid config flags detected: dimen-ja-mdpi-ERR10
W: Config flags size > 36. Exceeding bytes: 0x6000000.
W: Invalid config flags detected: dimen-ja-mdpi-ERR11
W: Config flags size > 36. Exceeding bytes: 0x2000000.
W: Invalid config flags detected: dimen-ja-hdpi-ERR12
W: Config flags size > 36. Exceeding bytes: 0x4000000.
W: Invalid config flags detected: dimen-ja-hdpi-ERR13
W: Config flags size > 36. Exceeding bytes: 0x5000000.
W: Invalid config flags detected: dimen-ja-hdpi-ERR14
W: Config flags size > 36. Exceeding bytes: 0x6000000.
W: Invalid config flags detected: dimen-ja-hdpi-ERR15
W: Config flags size > 36. Exceeding bytes: 0x2000000.
W: Invalid config flags detected: dimen-ko-mdpi-ERR16
W: Config flags size > 36. Exceeding bytes: 0x4000000.
W: Invalid config flags detected: dimen-ko-mdpi-ERR17
W: Config flags size > 36. Exceeding bytes: 0x5000000.
W: Invalid config flags detected: dimen-ko-mdpi-ERR18
W: Config flags size > 36. Exceeding bytes: 0x6000000.
W: Invalid config flags detected: dimen-ko-mdpi-ERR19
W: Config flags size > 36. Exceeding bytes: 0x2000000.
W: Invalid config flags detected: dimen-ko-hdpi-ERR20
W: Config flags size > 36. Exceeding bytes: 0x4000000.
W: Invalid config flags detected: dimen-ko-hdpi-ERR21
W: Config flags size > 36. Exceeding bytes: 0x5000000.
W: Invalid config flags detected: dimen-ko-hdpi-ERR22
W: Config flags size > 36. Exceeding bytes: 0x6000000.
W: Invalid config flags detected: dimen-ko-hdpi-ERR23
W: Config flags size > 36. Exceeding bytes: 0x2000000.
W: Invalid config flags detected: dimen-zh-rCN-mdpi-ERR24
W: Config flags size > 36. Exceeding bytes: 0x4000000.
W: Invalid config flags detected: dimen-zh-rCN-mdpi-ERR25
W: Config flags size > 36. Exceeding bytes: 0x5000000.
W: Invalid config flags detected: dimen-zh-rCN-mdpi-ERR26
W: Config flags size > 36. Exceeding bytes: 0x6000000.
W: Invalid config flags detected: dimen-zh-rCN-mdpi-ERR27
W: Config flags size > 36. Exceeding bytes: 0x2000000.
W: Invalid config flags detected: dimen-zh-rCN-hdpi-ERR28
W: Config flags size > 36. Exceeding bytes: 0x4000000.
W: Invalid config flags detected: dimen-zh-rCN-hdpi-ERR29
W: Config flags size > 36. Exceeding bytes: 0x5000000.
W: Invalid config flags detected: dimen-zh-rCN-hdpi-ERR30
W: Config flags size > 36. Exceeding bytes: 0x6000000.
W: Invalid config flags detected: dimen-zh-rCN-hdpi-ERR31
W: Config flags size > 36. Exceeding bytes: 0x2000000.
W: Invalid config flags detected: dimen-zh-rTW-mdpi-ERR32
W: Config flags size > 36. Exceeding bytes: 0x4000000.
W: Invalid config flags detected: dimen-zh-rTW-mdpi-ERR33
W: Config flags size > 36. Exceeding bytes: 0x5000000.
W: Invalid config flags detected: dimen-zh-rTW-mdpi-ERR34
W: Config flags size > 36. Exceeding bytes: 0x6000000.
W: Invalid config flags detected: dimen-zh-rTW-mdpi-ERR35
W: Config flags size > 36. Exceeding bytes: 0x2000000.
W: Invalid config flags detected: dimen-zh-rTW-hdpi-ERR36
W: Config flags size > 36. Exceeding bytes: 0x4000000.
W: Invalid config flags detected: dimen-zh-rTW-hdpi-ERR37
W: Config flags size > 36. Exceeding bytes: 0x5000000.
W: Invalid config flags detected: dimen-zh-rTW-hdpi-ERR38
W: Config flags size > 36. Exceeding bytes: 0x6000000.
W: Invalid config flags detected: dimen-zh-rTW-hdpi-ERR39
W: Config flags size > 36. Exceeding bytes: 0x2000000.
W: Invalid config flags detected: integer-mdpi-ERR40
W: Config flags size > 36. Exceeding bytes: 0x4000000.
W: Invalid config flags detected: integer-mdpi-ERR41
W: Config flags size > 36. Exceeding bytes: 0x5000000.
W: Invalid config flags detected: integer-mdpi-ERR42
W: Config flags size > 36. Exceeding bytes: 0x6000000.
W: Invalid config flags detected: integer-mdpi-ERR43
W: Config flags size > 36. Exceeding bytes: 0x2000000.
W: Invalid config flags detected: integer-hdpi-ERR44
W: Config flags size > 36. Exceeding bytes: 0x4000000.
W: Invalid config flags detected: integer-hdpi-ERR45
W: Config flags size > 36. Exceeding bytes: 0x5000000.
W: Invalid config flags detected: integer-hdpi-ERR46
W: Config flags size > 36. Exceeding bytes: 0x6000000.
W: Invalid config flags detected: integer-hdpi-ERR47
I: Framework installed to: C:\Users\Ivke\apktool\framework\2.apk
 

ckpv5

Inactive Recognized Contributor
Feb 11, 2008
14,354
18,301
Kuala Lumpur
It's 1.5.2 and I think this the latest version as I don't see any new version been released except beta

Check your Enviroment Variables and you have below set in System Variables PATH

C:\Program Files\Java\jre7\bin;

Anyway, mine is Windows 8.1 64bit with java 7 update 51(64-bit)

---------- Post added at 11:53 PM ---------- Previous post was at 11:49 PM ----------

I managed to install it but with this error :

Don't worry about the error as what you're trying to mod is the prism.apk not com.htc.resources.apk
 
Last edited:
  • Like
Reactions: nightwalkerkg

xpirt

Recognized Developer / Inactive RC
Feb 19, 2013
5,070
21,225
Oh if you're going to mod Prism.apk then the framework it's installed you can go ahead.

xpirt
 
  • Like
Reactions: nightwalkerkg

nightwalkerkg

Senior Member
Aug 20, 2012
699
607
28
Kragujevac
Ok then,thanks a lot guys.
One more question i am trying to get the dock bar opaque on the blinkfeed but transparent on other screen pages. Can you just guide me where are the settings for the dock ? xD I am lost with all these files. xD
 

ckpv5

Inactive Recognized Contributor
Feb 11, 2008
14,354
18,301
Kuala Lumpur
Is this Dock, you are referring to the NavBar ?
If it is the stock Prism.apk, you don't need to decommpile it. Just take out home_nav_bg.jpg from res/drawable-hdpi and change its transparency to your liking and drag it back to the Prism.apk. You'll have Dock transparent/any transparency that you choose but the dock on blinkfeed page still opaque.
 
  • Like
Reactions: nightwalkerkg

nightwalkerkg

Senior Member
Aug 20, 2012
699
607
28
Kragujevac
Now that is something i can do easy. :D Thanks a lot. :D
I will try to follow the tutorial for porting 4.2 statusbar tiles to 4.1. If i have some questions i will post them here.
 

nightwalkerkg

Senior Member
Aug 20, 2012
699
607
28
Kragujevac
Is this Dock, you are referring to the NavBar ?
If it is the stock Prism.apk, you don't need to decommpile it. Just take out home_nav_bg.jpg from res/drawable-hdpi and change its transparency to your liking and drag it back to the Prism.apk. You'll have Dock transparent/any transparency that you choose but the dock on blinkfeed page still opaque.

I did it,but when i push the Prism.apk to system and reboot i get fc.
 

ckpv5

Inactive Recognized Contributor
Feb 11, 2008
14,354
18,301
Kuala Lumpur
Is the home_nav_bg.jpg properly done ? Is the permission is set correctly when pushed to system ?

Here is mine .. after I made the home_nav_bg.jpg transparent and pushed back the Prism.apk to system/app



Here is my apk if you want to compare with yours.

Time to bed now ... enjoy your new adventure in modding ;)
 

Attachments

  • Prism.apk
    1.1 MB · Views: 15
  • Like
Reactions: nightwalkerkg

nightwalkerkg

Senior Member
Aug 20, 2012
699
607
28
Kragujevac
Is the home_nav_bg.jpg properly done ? Is the permission is set correctly when pushed to system ?

Here is mine .. after I made the home_nav_bg.jpg transparent and pushed back the Prism.apk to system/app



Here is my apk if you want to compare with yours.

Time to bed now ... enjoy your new adventure in modding ;)

Permission,yeah. Forgot that. xD
Ok,i will do it tomorrow.

It's great,i was just going with the 1px divider. :D
Thanks man.
 

shyvam

Senior Member
Dec 31, 2014
229
115
DELHI
--keep-broken-res: http://xdaforums.com/showthread.php?t=2229230 to decompile.
Now it's installed successfully btw.

xpirt

hey sir i followed --keep broken res--- guide and typed [ java -jar apktool.jar d --keep-broken-res com.htc.resources.apk com.htc.resources-decoded ] and i deleted erro folders and after that i tried to compile com.htc.resources.apk but i got errors and i wasn"t able to compile framework (com.htc.resources.apk) i ask to u because u made lots of cool mods for (htc desire x ) so i thought u know about this prob please help

MY APKTOOL VERSION=1..5.2
ROM=SENSE 4.1
DEVICE=HTC DESIRE X DUAL SIM
 
Last edited:

Top Liked Posts

  • There are no posts matching your filters.
  • 1
    It's 1.5.2 and I think this the latest version as I don't see any new version been released except beta

    Check your Enviroment Variables and you have below set in System Variables PATH

    C:\Program Files\Java\jre7\bin;

    Anyway, mine is Windows 8.1 64bit with java 7 update 51(64-bit)

    ---------- Post added at 11:53 PM ---------- Previous post was at 11:49 PM ----------

    I managed to install it but with this error :

    Don't worry about the error as what you're trying to mod is the prism.apk not com.htc.resources.apk
    1
    Oh if you're going to mod Prism.apk then the framework it's installed you can go ahead.

    xpirt
    1
    Is this Dock, you are referring to the NavBar ?
    If it is the stock Prism.apk, you don't need to decommpile it. Just take out home_nav_bg.jpg from res/drawable-hdpi and change its transparency to your liking and drag it back to the Prism.apk. You'll have Dock transparent/any transparency that you choose but the dock on blinkfeed page still opaque.
    1
    Is the home_nav_bg.jpg properly done ? Is the permission is set correctly when pushed to system ?

    Here is mine .. after I made the home_nav_bg.jpg transparent and pushed back the Prism.apk to system/app



    Here is my apk if you want to compare with yours.

    Time to bed now ... enjoy your new adventure in modding ;)