Settings: Read defaults from the bundled partition (#2852)#3394
Settings: Read defaults from the bundled partition (#2852)#3394abranson wants to merge 1 commit intomicrog:masterfrom
Conversation
|
Any reason to only allow How do those internal methods ( |
It was the suggestion here: #2852 (comment) to "first search on the same partition of the apk (whatever it is) and then fallback to system." and I thought that made a lot of sense. If we bundle then it should all be in the same partition. Falling back to system is only needed for backwards compat, but I think that's necessary.
There isn't any public docs that I found for those, but I couldn't use sourceDir precisely because it does not preserve the original installed location. These flags do get preserved: https://android.googlesource.com/platform/frameworks/base/+/refs/heads/main/services/core/java/com/android/server/pm/InstallPackageHelper.java#2101 |
|
@mar-v-in Also I suggest to change the path to |
Use `ApplicationInfo` partition flags to detect whether GmsCore was originally bundled on `product` or `system_ext`, and read `etc/<package>/microg.xml` or `etc/microg.xml` from that partition. Keep `/system/etc/microg.xml` as a shared defaults source.
|
Now it checks /$partition/etc/$packageName/settings.xml, then /$partition/etc/microg.xml, and finally /system/etc/microg.xml. I've seen anticipation of /$partition/etc/microg.xml so I thought it would be nice to leave that in. |
Use
ApplicationInfopartition flags to detect whether GmsCore was originally bundled onproductorsystem_ext, and readetc/microg.xmlfrom that partition. Keep/system/etc/microg.xmlas a shared defaults source underneath partition-specific overrides.