Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[BUG] Framework.jar cannot be recompiled normally. The latest apktool #2662

Closed
mandfx opened this issue Sep 19, 2021 · 4 comments · Fixed by #2941
Closed

[BUG] Framework.jar cannot be recompiled normally. The latest apktool #2662

mandfx opened this issue Sep 19, 2021 · 4 comments · Fixed by #2941
Milestone

Comments

@mandfx
Copy link

mandfx commented Sep 19, 2021

Information

  1. Apktool Version (apktool -version) - 2.6.0
  2. Operating System (Mac, Linux, Windows) - Windows10
  3. APK From? (Playstore, ROM, Other) - framework.jar

Stacktrace/Logcat

java -jar apktool_2.6.0.jar d framework-test.jar
I: Using Apktool 2.6.0 on framework-test.jar
I: Baksmaling classes.dex...
I: Baksmaling classes2.dex...
I: Baksmaling classes3.dex...
I: Baksmaling classes4.dex...
I: Copying assets and libs...
I: Copying unknown files...
I: Copying original files...

java -jar apktool_2.6.0.jar b framework-test.jar.out
I: Using Apktool 2.6.0
I: Checking whether sources has changed...
I: Smaling smali folder into classes.dex...
framework-test.jar.out\smali\android\Manifest$permission.smali[1750,27] Hidden API restrictions are only supported on api 29 and above.
framework-test.jar.out\smali\android\Manifest$permission.smali[1751,12] mismatched tree node: I_ORDERED_METHOD_ITEMS expecting I_FIELDS
Could not smali file: android/Manifest$permission.smali

java -jar apktool_2.6.0.jar b -api 29 framework-test.jar.out
I: Using Apktool 2.6.0
I: Checking whether sources has changed...
I: Smaling smali folder into classes.dex...
I: Checking whether sources has changed...
I: Smaling smali_classes2 folder into classes2.dex...
I: Checking whether sources has changed...
I: Smaling smali_classes3 folder into classes3.dex...
I: Checking whether sources has changed...
I: Smaling smali_classes4 folder into classes4.dex...
W: Could not find resources
I: Building apk file...
I: Copying unknown files/dir...
I: Built apk...

Steps to Reproduce

  1. apktool

Frameworks

MIUI12.5 /system/framework/framework.jar
framework-test.zip

Questions to ask before submission

  1. After compiling, you can't turn on the first screen of the card, including after cracking the signature. After adding - API 29, it can be compiled normally.
  2. adb logcat :09-19 12:25:43.787 7256 7256 W zygote64: Failed to open .dex from file '/system/framework/framework.jar': Failure to verify dex file '/system/framework/framework.jar': Non-zero padding e6 before section of type 61440 at offset 0x94634d
    09-19 12:25:43.799 7257 7257 W zygote : Failed to open .dex from file '/system/framework/framework.jar': Failure to verify dex file '/system/framework/framework.jar': Non-zero padding e6 before section of type 61440 at offset 0x94634d
@mandfx mandfx changed the title [BUG] [BUG] Framework.jar cannot be recompiled normally. The latest apktool Sep 21, 2021
@iBotPeaches
Copy link
Owner

Going to mark as 3rd party. We need this fix - JesusFreke/smali#816

@iBotPeaches iBotPeaches added this to the v2.6.1 milestone Nov 27, 2021
@thanhpv15
Copy link

Seem like JesusFreke has discontinued Smali project, this issue won't fix any more :(

@iBotPeaches
Copy link
Owner

Seem like JesusFreke has discontinued Smali project, this issue won't fix any more :(

Without a source, thats not the nicest thing to say.

@iBotPeaches
Copy link
Owner

I believe resolved with this: #2941

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging a pull request may close this issue.

3 participants