mirror of
https://github.com/revanced/Apktool.git
synced 2025-01-06 10:05:54 +01:00
parent
aee0792e00
commit
a561a95542
@ -70,7 +70,7 @@ public class Androlib {
|
||||
public void decodeSourcesRaw(ExtFile apkFile, File outDir, String filename)
|
||||
throws AndrolibException {
|
||||
try {
|
||||
LOGGER.info("Copying raw classes.dex file...");
|
||||
LOGGER.info("Copying raw " + filename + " file...");
|
||||
apkFile.getDirectory().copyToDir(outDir, filename);
|
||||
} catch (DirectoryException ex) {
|
||||
throw new AndrolibException(ex);
|
||||
@ -301,6 +301,7 @@ public class Androlib {
|
||||
public void buildNonDefaultSources(ExtFile appDir)
|
||||
throws AndrolibException {
|
||||
try {
|
||||
// loop through any smali_ directories for multi-dex apks
|
||||
Map<String, Directory> dirs = appDir.getDirectory().getDirs();
|
||||
for (Map.Entry<String, Directory> directory : dirs.entrySet()) {
|
||||
String name = directory.getKey();
|
||||
@ -314,6 +315,18 @@ public class Androlib {
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
// loop through any classes#.dex files for multi-dex apks
|
||||
File[] dexFiles = appDir.listFiles();
|
||||
if (dexFiles != null) {
|
||||
for (File dex : dexFiles) {
|
||||
|
||||
// skip classes.dex because we have handled it in buildSources()
|
||||
if (dex.getName().endsWith(".dex") && ! dex.getName().equalsIgnoreCase("classes.dex")) {
|
||||
buildSourcesRaw(appDir, dex.getName());
|
||||
}
|
||||
}
|
||||
}
|
||||
} catch(DirectoryException ex) {
|
||||
throw new AndrolibException(ex);
|
||||
}
|
||||
|
Loading…
Reference in New Issue
Block a user