notishell / android-apktool

Automatically exported from code.google.com/p/android-apktool
0 stars 0 forks source link

Cannot recompile unchanged ChatON.apk #644

Closed GoogleCodeExporter closed 9 years ago

GoogleCodeExporter commented 9 years ago
What steps will reproduce the problem?
1. Download ChatON from the Google Play store
2. apktool d com.sec.chaton-1.apk
3. apktool b -a ~/android-sdk-macosx/build-tools/19.1.0/aapt com.sec.chaton-1

What is the expected output? What do you see instead?

mbpr15:Downloads awt$ 
~/android-sdk-macosx/apktool-install-macosx-r05-ibot/apktool b -a 
~/android-sdk-macosx/build-tools/19.1.0/aapt com.sec.chaton-1
I: Checking whether sources has changed...
I: Smaling...
I: Checking whether resources has changed...
I: Building resources...
invalid resource directory name: 
/Users/awt/Downloads/com.sec.chaton-1/res/xml-mcc460-mnc-1
Exception in thread "main" brut.androlib.AndrolibException: 
brut.androlib.AndrolibException: brut.common.BrutException: could not exec 
command: [/Users/awt/android-sdk-macosx/build-tools/19.1.0/aapt, p, 
--min-sdk-version, 8, --target-sdk-version, 17, -F, 
/var/folders/2v/25lsm4bx0kgcs2_36dd0m9h00000gn/T/APKTOOL6740723894514903996.tmp,
 -0, arsc, -I, /Users/awt/Library/apktool/framework/1.apk, -S, 
/Users/awt/Downloads/com.sec.chaton-1/res, -M, 
/Users/awt/Downloads/com.sec.chaton-1/AndroidManifest.xml]
    at brut.androlib.Androlib.buildResourcesFull(Androlib.java:358)
    at brut.androlib.Androlib.buildResources(Androlib.java:283)
    at brut.androlib.Androlib.build(Androlib.java:206)
    at brut.androlib.Androlib.build(Androlib.java:176)
    at brut.apktool.Main.cmdBuild(Main.java:228)
    at brut.apktool.Main.main(Main.java:79)
Caused by: brut.androlib.AndrolibException: brut.common.BrutException: could 
not exec command: [/Users/awt/android-sdk-macosx/build-tools/19.1.0/aapt, p, 
--min-sdk-version, 8, --target-sdk-version, 17, -F, 
/var/folders/2v/25lsm4bx0kgcs2_36dd0m9h00000gn/T/APKTOOL6740723894514903996.tmp,
 -0, arsc, -I, /Users/awt/Library/apktool/framework/1.apk, -S, 
/Users/awt/Downloads/com.sec.chaton-1/res, -M, 
/Users/awt/Downloads/com.sec.chaton-1/AndroidManifest.xml]
    at brut.androlib.res.AndrolibResources.aaptPackage(AndrolibResources.java:357)
    at brut.androlib.Androlib.buildResourcesFull(Androlib.java:336)
    ... 5 more
Caused by: brut.common.BrutException: could not exec command: 
[/Users/awt/android-sdk-macosx/build-tools/19.1.0/aapt, p, --min-sdk-version, 
8, --target-sdk-version, 17, -F, 
/var/folders/2v/25lsm4bx0kgcs2_36dd0m9h00000gn/T/APKTOOL6740723894514903996.tmp,
 -0, arsc, -I, /Users/awt/Library/apktool/framework/1.apk, -S, 
/Users/awt/Downloads/com.sec.chaton-1/res, -M, 
/Users/awt/Downloads/com.sec.chaton-1/AndroidManifest.xml]
    at brut.util.OS.exec(OS.java:89)
    at brut.androlib.res.AndrolibResources.aaptPackage(AndrolibResources.java:355)
    ... 6 more

What version of the product are you using? On what operating system?
apk v1.5.2 for Mac OSX Mavericks 10.9 with smali v1.4.1 and baksmali v1.4.1
aapt version 19.1.0 directly from Google

Please provide any additional information below.

Original issue reported on code.google.com by torgis....@gmail.com on 11 Jun 2014 at 2:27

GoogleCodeExporter commented 9 years ago
Looks like as far as I can tell, the specific error is:

invalid resource directory name: 
/Users/awt/Downloads/com.sec.chaton-1/res/xml-mcc460-mnc-1

I saw that others have fixed this by recompiling with the latest version of 
aapt, however I am using 19.1.0 build tools (aapt v0.2) and still have a 
problem.

Original comment by torgis....@gmail.com on 11 Jun 2014 at 2:29

GoogleCodeExporter commented 9 years ago
ibotpeaches@raganok:~/Downloads/Apktool/Bug644$ apktool d com.sec.chaton.apk 
I: Using Apktool 2.0.0-584d1c-SNAPSHOT on com.sec.chaton.apk
I: Loading resource table...
W: Skipping "android" package group
I: Loading resource table...
W: Skipping "android" package group
I: Decoding AndroidManifest.xml with resources...
I: Loading resource table from file: /home/ibotpeaches/apktool/framework/1.apk
I: Regular manifest package...
I: Decoding file-resources...
I: Decoding values */* XMLs...
I: Baksmaling...
I: Copying assets and libs...
I: Copying unknown files...
I: Copying original files...
ibotpeaches@raganok:~/Downloads/Apktool/Bug644$ apktool b com.sec.chaton
I: Using Apktool 2.0.0-584d1c-SNAPSHOT on com.sec.chaton
I: Checking whether sources has changed...
I: Smaling...
I: Checking whether resources has changed...
I: Building resources...
I: Copying libs...
I: Building apk file...
I: Copying unknown files/dir...
ibotpeaches@raganok:~/Downloads/Apktool/Bug644$ 

Could not duplicate.

Original comment by connor.tumbleson on 11 Jun 2014 at 9:17

GoogleCodeExporter commented 9 years ago
This is indeed fixed in 2.0 Beta 9, it is the MCC/MNC asset tag issue

Original comment by torgis....@gmail.com on 12 Jun 2014 at 10:31

GoogleCodeExporter commented 9 years ago
Gfu

Original comment by p3.ng...@gmail.com on 20 Oct 2014 at 6:27