mirror of
https://github.com/revanced/Apktool.git
synced 2025-05-02 23:04:26 +02:00
Merge branch 'upstream'
This commit is contained in:
commit
43edf043ed
4
.github/workflows/build.yml
vendored
4
.github/workflows/build.yml
vendored
@ -88,6 +88,8 @@ jobs:
|
|||||||
- build-and-test-with-Java-8-and-later
|
- build-and-test-with-Java-8-and-later
|
||||||
steps:
|
steps:
|
||||||
- uses: actions/checkout@v3
|
- uses: actions/checkout@v3
|
||||||
|
with:
|
||||||
|
fetch-depth: 0
|
||||||
- uses: actions/setup-java@v3
|
- uses: actions/setup-java@v3
|
||||||
with:
|
with:
|
||||||
distribution: 'zulu'
|
distribution: 'zulu'
|
||||||
@ -100,4 +102,4 @@ jobs:
|
|||||||
uses: actions/upload-artifact@v3
|
uses: actions/upload-artifact@v3
|
||||||
with:
|
with:
|
||||||
name: apktool.jar
|
name: apktool.jar
|
||||||
path: brut.apktool/apktool-cli/build/libs/apktool-*-SNAPSHOT.jar
|
path: brut.apktool/apktool-cli/build/libs/apktool-v*
|
||||||
|
@ -69,6 +69,6 @@ tasks.register<ProGuardTask>("proguard") {
|
|||||||
dontwarn("javax.xml.xpath.**")
|
dontwarn("javax.xml.xpath.**")
|
||||||
dontnote("**")
|
dontnote("**")
|
||||||
|
|
||||||
val outPath = "build/libs/apktool-cli-$apktoolVersion.jar"
|
val outPath = "build/libs/apktool-$apktoolVersion.jar"
|
||||||
outjars(outPath)
|
outjars(outPath)
|
||||||
}
|
}
|
||||||
|
@ -77,7 +77,7 @@ public class Framework {
|
|||||||
crc.update(data);
|
crc.update(data);
|
||||||
entry = new ZipEntry("resources.arsc");
|
entry = new ZipEntry("resources.arsc");
|
||||||
entry.setSize(data.length);
|
entry.setSize(data.length);
|
||||||
entry.setMethod(ZipOutputStream.STORED);
|
entry.setMethod(ZipEntry.STORED);
|
||||||
entry.setCrc(crc.getValue());
|
entry.setCrc(crc.getValue());
|
||||||
out.putNextEntry(entry);
|
out.putNextEntry(entry);
|
||||||
out.write(data);
|
out.write(data);
|
||||||
|
@ -270,7 +270,9 @@ public class ARSCDecoder {
|
|||||||
|
|
||||||
mHeader.checkForUnreadHeader(mIn);
|
mHeader.checkForUnreadHeader(mIn);
|
||||||
|
|
||||||
if ((typeFlags & 0x01) != 0) {
|
// Be sure we don't poison mResTable by marking the application as sparse
|
||||||
|
// Only flag the ResTable as sparse if the main package is not loaded.
|
||||||
|
if ((typeFlags & 0x01) != 0 && !mResTable.isMainPkgLoaded()) {
|
||||||
mResTable.setSparseResources(true);
|
mResTable.setSparseResources(true);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -54,6 +54,7 @@ public class SparseFlagTest extends BaseTest {
|
|||||||
|
|
||||||
LOGGER.info("Decoding sparse.apk...");
|
LOGGER.info("Decoding sparse.apk...");
|
||||||
Config config = Config.getDefaultConfig();
|
Config config = Config.getDefaultConfig();
|
||||||
|
config.frameworkTag = "issue-3298";
|
||||||
|
|
||||||
ApkDecoder apkDecoder = new ApkDecoder(config, testApk);
|
ApkDecoder apkDecoder = new ApkDecoder(config, testApk);
|
||||||
ApkInfo apkInfo = apkDecoder.decode(sTestNewDir);
|
ApkInfo apkInfo = apkDecoder.decode(sTestNewDir);
|
||||||
@ -70,6 +71,7 @@ public class SparseFlagTest extends BaseTest {
|
|||||||
|
|
||||||
LOGGER.info("Decoding not-sparse.apk...");
|
LOGGER.info("Decoding not-sparse.apk...");
|
||||||
Config config = Config.getDefaultConfig();
|
Config config = Config.getDefaultConfig();
|
||||||
|
config.frameworkTag = "issue-3298";
|
||||||
|
|
||||||
ApkDecoder apkDecoder = new ApkDecoder(config, testApk);
|
ApkDecoder apkDecoder = new ApkDecoder(config, testApk);
|
||||||
ApkInfo apkInfo = apkDecoder.decode(sTestNewDir);
|
ApkInfo apkInfo = apkDecoder.decode(sTestNewDir);
|
||||||
|
Loading…
x
Reference in New Issue
Block a user