Merge "Add keep rules for SysUI plugin annotations" am: 1df98adda8
Original change: https://android-review.googlesource.com/c/platform/frameworks/base/+/2619797 Change-Id: Ic620f8bb76745ae5c47d6294ccabff6ee53fce94 Signed-off-by: Automerger Merge Worker <android-build-automerger-merge-worker@system.gserviceaccount.com>
This commit is contained in:
@@ -25,6 +25,9 @@ java_library {
|
|||||||
sdk_version: "current",
|
sdk_version: "current",
|
||||||
name: "PluginCoreLib",
|
name: "PluginCoreLib",
|
||||||
srcs: ["src/**/*.java"],
|
srcs: ["src/**/*.java"],
|
||||||
|
optimize: {
|
||||||
|
proguard_flags_files: ["proguard.flags"],
|
||||||
|
},
|
||||||
|
|
||||||
// Enforce that the library is built against java 8 so that there are
|
// Enforce that the library is built against java 8 so that there are
|
||||||
// no compatibility issues with launcher
|
// no compatibility issues with launcher
|
||||||
|
|||||||
11
packages/SystemUI/plugin_core/proguard.flags
Normal file
11
packages/SystemUI/plugin_core/proguard.flags
Normal file
@@ -0,0 +1,11 @@
|
|||||||
|
# R8's full mode is a bit more aggressive in stripping annotations, but the
|
||||||
|
# SystemUI plugin architecture requires these annotations at runtime. The
|
||||||
|
# following rules are the minimal set necessary to ensure compatibility.
|
||||||
|
# For more details, see:
|
||||||
|
# https://r8.googlesource.com/r8/+/refs/heads/master/compatibility-faq.md#r8-full-mode
|
||||||
|
-keepattributes RuntimeVisible*Annotation*,AnnotationDefault
|
||||||
|
|
||||||
|
-keep interface com.android.systemui.plugins.annotations.** {
|
||||||
|
*;
|
||||||
|
}
|
||||||
|
-keep,allowshrinking,allowoptimization,allowobfuscation,allowaccessmodification @com.android.systemui.plugins.annotations.** class *
|
||||||
Reference in New Issue
Block a user