0
我正在嘗試使用apktool修改一個Android應用程序。ubuntu上的反編譯和重新編譯apk文件
我已經下載了apktool,現在我有3個文件apktool,AAPT和apktool.jar
我想我使用這些命令編譯修改的Gallery_3D.apk
背景然後重新編譯
./apktool if Gallery 3D.apk
./apktool d Gallery 3D.apk gallery
它工作正常的上述2的步驟,但在使用命令
./apktool b gallery Gallery 3D New.apk
0重新編譯
但是我在最後一步得到這個錯誤。
I: Checking whether sources has changed...
I: Smaling...
I: Checking whether resources has changed...
I: Building resources...
Exception in thread "main" brut.androlib.AndrolibException: brut.common.BrutException: could not exec command: [aapt, p, -F, /tmp/APKTOOL4811911322257021960.tmp, -I, /home/seat2/apktool/framework/1.apk, -S, /home/seat2/Desktop/apktool/gallery/res, -M, /home/seat2/Desktop/apktool/gallery/AndroidManifest.xml]
at brut.androlib.res.AndrolibResources.aaptPackage(AndrolibResources.java:193)
at brut.androlib.Androlib.buildResourcesFull(Androlib.java:301)
at brut.androlib.Androlib.buildResources(Androlib.java:248)
at brut.androlib.Androlib.build(Androlib.java:171)
at brut.androlib.Androlib.build(Androlib.java:154)
at brut.apktool.Main.cmdBuild(Main.java:182)
at brut.apktool.Main.main(Main.java:67)
Caused by: brut.common.BrutException: could not exec command: [aapt, p, -F, /tmp/APKTOOL4811911322257021960.tmp, -I, /home/seat2/apktool/framework/1.apk, -S, /home/seat2/Desktop/apktool/gallery/res, -M, /home/seat2/Desktop/apktool/gallery/AndroidManifest.xml]
at brut.util.OS.exec(OS.java:87)
at brut.androlib.res.AndrolibResources.aaptPackage(AndrolibResources.java:191)
... 6 more
Caused by: java.io.IOException: Cannot run program "aapt": java.io.IOException: error=2, No such file or directory
at java.lang.ProcessBuilder.start(ProcessBuilder.java:475)
at java.lang.Runtime.exec(Runtime.java:610)
at java.lang.Runtime.exec(Runtime.java:483)
at brut.util.OS.exec(OS.java:78)
... 7 more
Caused by: java.io.IOException: java.io.IOException: error=2, No such file or directory
at java.lang.UNIXProcess.<init>(UNIXProcess.java:164)
at java.lang.ProcessImpl.start(ProcessImpl.java:81)
at java.lang.ProcessBuilder.start(ProcessBuilder.java:468)
... 10 more
在我看來,你需要'aapt'在你的'PATH' – 2013-03-29 06:29:03
如果您正在使用舊的Andriod-SDK,你應該更新它。另外檢查,aapt工具的路徑已添加到您的環境路徑中。 –
謝謝你有一個路徑問題。我成功構建了應用程序,但在安裝INSTALL_PARSE_FAILED_NO_CERTIFICATES時如何得到此錯誤 –