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

smali not supporting Android N (oat ver. 079) #18

Closed
anestisb opened this issue Sep 3, 2016 · 5 comments
Closed

smali not supporting Android N (oat ver. 079) #18

anestisb opened this issue Sep 3, 2016 · 5 comments

Comments

@anestisb
Copy link
Owner

anestisb commented Sep 3, 2016

Bytecode de-optimization util is using baksmali / smali tools, which currently don't support Android N ART changes (JesusFreke/smali#378).

The second (although minor) problem is that old "boot.oat" is now split into multiple files prefixed with boot-XXX.oat and having their own ART image file. We'll probably have to deal with it manually, unless SmaliEx maintainers quickly pick up this and implement it.

Support for Android N is blocked until smali project (and then by extend SmaliEx which we actually use to simplify baksmali -> smali iterations) supports recent ART changes.

java -jar /aosp_b_prod/prepare_vendor_blobs/hostTools/Java/baksmali.jar -x -o $(pwd)/deopt -c "$(find boot64 -name "*.oat" -printf "%f\n" | while read -r file; do echo -ne "$file:"; done)" -d $(pwd)/boot64 atfwd.odex


Error occurred while loading boot class path files. Aborting.
java.lang.StringIndexOutOfBoundsException: String index out of range: 1599362287
        at java.lang.String.checkBounds(String.java:385)
        at java.lang.String.<init>(String.java:462)
        at org.jf.dexlib2.dexbacked.OatFile$1$1.next(OatFile.java:172)
        at org.jf.dexlib2.dexbacked.OatFile$1$1.next(OatFile.java:159)
        at org.jf.dexlib2.analysis.ClassPath.fromClassPath(ClassPath.java:191)
        at org.jf.baksmali.baksmali.disassembleDexFile(baksmali.java:67)
        at org.jf.baksmali.main.run(main.java:113)
        at org.jf.baksmali.main.main(main.java:322)
@anestisb
Copy link
Owner Author

anestisb commented Sep 3, 2016

cc @thestinger since it will affect CopperheadOS

@anestisb
Copy link
Owner Author

Adding JesusFreke/smali#418 for tracking reference

@nychitman1
Copy link

@anestisb JesusFreke/smali#378 -- JF updated to indicate support now works.

@anestisb
Copy link
Owner Author

anestisb commented Oct 4, 2016

Thanks for the update @nychitman1

anestisb added a commit that referenced this issue Oct 4, 2016
This effectively implements #18 & #20

So far it has been tested against N6p devices.

Signed-off-by: Anestis Bechtsoudis <anestis@census-labs.com>
@anestisb
Copy link
Owner Author

anestisb commented Oct 4, 2016

Support is still experimental. Users want to test can use the --smali flag from master script to enable it.

@anestisb anestisb closed this as completed Oct 4, 2016
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

2 participants