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] Can't recompile YouTube 1.6.21 #3553

Open
mrkrabs206 opened this issue Mar 28, 2024 · 4 comments
Open

[BUG] Can't recompile YouTube 1.6.21 #3553

mrkrabs206 opened this issue Mar 28, 2024 · 4 comments

Comments

@mrkrabs206
Copy link

mrkrabs206 commented Mar 28, 2024

Information

  1. Apktool Version (apktool -version) - 2.9.3
  2. Operating System (Mac, Linux, Windows) - Windows 10 (Version 22H2, OS Build 19045.42039)
  3. APK From? (Playstore, ROM, Other) - APKMirror.com
  4. Java Version (java --version) - 21.0.2

Stacktrace/Logcat

C:\Users\Z\Downloads>java -jar C:\Users\Z\Downloads\apktool_2.9.3.jar d C:\Users\Z\Downloads\1.6.21youtube.apk
I: Using Apktool 2.9.3 on 1.6.21youtube.apk
I: Loading resource table...
W: Skipping package group: android
I: Decoding file-resources...
I: Loading resource table from file: C:\Users\Z\AppData\Local\apktool\framework\1.apk
I: Decoding values */* XMLs...
I: Decoding AndroidManifest.xml with resources...
I: Regular manifest package...
I: Baksmaling classes.dex...
I: Copying assets and libs...
I: Copying unknown files...
I: Copying original files...

C:\Users\Z\Downloads\1.6.21youtube>java -jar C:\Users\Z\Downloads\apktool_2.9.3.jar b C:\Users\Z\Downloads\1.6.21youtube
I: Using Apktool 2.9.3
I: Checking whether sources has changed...
I: Smaling smali folder into classes.dex...
I: Checking whether resources has changed...
I: Building resources...
W: C:\Users\Z\Downloads\1.6.21youtube\res\values\attrs.xml:9: error: invalid value for type 'attr'. Expected a reference.
W: C:\Users\Z\Downloads\1.6.21youtube\res\values\attrs.xml:10: error: invalid value for type 'attr'. Expected a reference.
W: C:\Users\Z\Downloads\1.6.21youtube\res\values\attrs.xml:11: error: invalid value for type 'attr'. Expected a reference.
W: C:\Users\Z\Downloads\1.6.21youtube\res\values\attrs.xml:12: error: invalid value for type 'attr'. Expected a reference.
W: C:\Users\Z\Downloads\1.6.21youtube\res\values\attrs.xml:13: error: invalid value for type 'attr'. Expected a reference.
W: C:\Users\Z\Downloads\1.6.21youtube\res\values\attrs.xml:14: error: invalid value for type 'attr'. Expected a reference.
W: C:\Users\Z\Downloads\1.6.21youtube\res\values\attrs.xml:15: error: invalid value for type 'attr'. Expected a reference.
W: C:\Users\Z\Downloads\1.6.21youtube\res\values\attrs.xml: error: file failed to compile.
brut.androlib.exceptions.AndrolibException: brut.common.BrutException: could not exec (exit code = 1): [C:\Users\Z\AppData\Local\Temp\brut_util_Jar_31748610698093171515207734452244682453.tmp, compile, --dir, C:\Users\Z\Downloads\1.6.21youtube\res, --legacy, -o, C:\Users\Z\Downloads\1.6.21youtube\build\resources.zip]

Steps to Reproduce

  1. java -jar C:\Users\Z\Downloads\apktool_2.9.3.jar d C:\Users\Z\Downloads\1.6.21youtube.apk
  2. java -jar C:\Users\Z\Downloads\apktool_2.9.3.jar b C:\Users\Z\Downloads\1.6.21youtube

APK

https://www.apkmirror.com/apk/google-inc/youtube/youtube-1-6-21-release/

Questions to ask before submission

  1. Have you tried apktool d, apktool b without changing anything? Yes
  2. Are you using the latest apktool version? Yes

Image(s) containing the log

ap1f
ap2f

@iBotPeaches
Copy link
Owner

Yeah this is going to be interesting to solve. aapt2 is clearly squashing the reference into a literal value and including it at build time to cut space/time.

When Apktool disassembles - it only sees the plaintext literal, but the type was expecting a reference.

@gohoski
Copy link

gohoski commented Jul 10, 2024

any updates? have the same issue

@mrkrabs206
Copy link
Author

any updates? have the same issue

No it was 4months ago

@sevilS
Copy link

sevilS commented Oct 4, 2024

Any update on this?, can we help on how to fix this?

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

No branches or pull requests

4 participants