# R8 keep rules for the release build (POLISH-PLAN W3-9, # REQ-RELEASE-PACKAGING): only the seams the minifier cannot see — JNI name # lookups and native-method registration. Everything else (Compose, Room's # generated impls, compiled kotlinx-serialization serializers) is reached # through ordinary references R8 tracks itself. # JNI half of the device link: native methods must keep their names and # signatures or System.loadLibrary registration fails at runtime. -keepclasseswithmembers class com.sptmobile.link.LinkNative { native ; } # rustls-platform-verifier: the Rust side of the .so looks these classes up # BY NAME through JNI (the relay-TLS trust-store bridge); its AAR ships no # consumer rules, so renaming/stripping them kills TLS at first dial. -keep class org.rustls.platformverifier.** { *; } # Room: the runtime instantiates the generated database impl by reflection # from the @Database class name (Room.databaseBuilder). Room's own consumer # rules cover the runtime; pin our database class so its generated _Impl # sibling keeps a resolvable name. -keep class com.sptmobile.voice.VoiceDb { *; } -keep class * extends androidx.room.RoomDatabase { (); }