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

建议对Google Play版本设置extractNativeLibs=false #4308

Closed
stevenlele opened this issue Feb 1, 2025 · 3 comments · May be fixed by #4342
Closed

建议对Google Play版本设置extractNativeLibs=false #4308

stevenlele opened this issue Feb 1, 2025 · 3 comments · May be fixed by #4342

Comments

@stevenlele
Copy link

stevenlele commented Feb 1, 2025

设置 extractNativeLibs=falseuseLegacyPackaging=false)可以减少安装后占用的空间。

Google Play 下载时会压缩,所以无需担心安装包变大。GitHub 上的版本不推荐设置。

目前 Google Play 版本分包下载的还是压缩过的 .so APK,系统仍然会解压出来。

https://developer.android.google.cn/guide/topics/manifest/application-element#extractNativeLibs

@2dust
Copy link
Owner

2dust commented Feb 2, 2025

感谢你的建议。
Google Play 目前是 Bundles 形式

@2dust 2dust closed this as not planned Won't fix, can't repro, duplicate, stale Feb 2, 2025
@stevenlele
Copy link
Author

Google Play 目前是 Bundles 形式

我已经提到了,目前 Google Play 版本分包(split APK)下载的还是压缩过的 .so APK(ABI split),系统仍然会解压出来。Bundles 应该也受到这个选项控制。

@stevenlele
Copy link
Author

附上 split_config.arm64_v8a.apk 里面的 AndroidManifest 供参考。可以看到目前 extractNativeLibs=true。

N: android=http://schemas.android.com/apk/res/android (line=0)
  E: manifest (line=0)
    A:android:versionCode(0x0101021b)=4000630
    A:android:splitTypes(0x0101064f)="base__abi" (Raw: "base__abi")
    A: package="com.v2ray.ang" (Raw: "com.v2ray.ang")
    A: split="config.arm64_v8a" (Raw: "config.arm64_v8a")
      E: application (line=0)
        A:android:hasCode(0x0101000c)=false
        A:android:extractNativeLibs(0x010104ea)=true <!-- 这里目前是 true -->
          E: meta-data (line=0)
            A:android:name(0x01010003)="com.android.vending.derived.apk.id" (Raw: "com.android.vending.derived.apk.id")
            A:android:value(0x01010024)=3

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

Successfully merging a pull request may close this issue.

2 participants