Ship R8 consumer keep rules in the Android AAR for the UniFFI/JNA FFI surface.
Deliverable
- Package
consumer-rules.pro into the AAR as proguard.txt.
- Keep
com.sun.jna.Structure$FieldOrder.
- Keep annotated
org.lightningdevkit.ldknode struct classes, fields, and constructors.
- Keep
com.sun.jna.* JNI names used by libjnidispatch.
- Keep classes that extend
com.sun.jna.*, including com.sun.jna.ptr ByReference types.
- Keep JNA
Structure fields and constructors in org.lightningdevkit.ldknode.
- Keep JNA
Callback methods in org.lightningdevkit.ldknode.
- Keep
UniffiLib native method names in org.lightningdevkit.ldknode.
- Keep
IntegrityCheckingUniffiLib native method names when that class exists.
- Fail
bundleReleaseAar when those consumer keep rules are missing or empty.
Acceptance
- The release AAR contains a non-empty
proguard.txt with those keep rules.
- A minified Bitkit build loads
org.lightningdevkit.ldknode without an app keep for that package.
Ship R8 consumer keep rules in the Android AAR for the UniFFI/JNA FFI surface.
Deliverable
consumer-rules.prointo the AAR asproguard.txt.com.sun.jna.Structure$FieldOrder.org.lightningdevkit.ldknodestruct classes, fields, and constructors.com.sun.jna.*JNI names used bylibjnidispatch.com.sun.jna.*, includingcom.sun.jna.ptrByReference types.Structurefields and constructors inorg.lightningdevkit.ldknode.Callbackmethods inorg.lightningdevkit.ldknode.UniffiLibnative method names inorg.lightningdevkit.ldknode.IntegrityCheckingUniffiLibnative method names when that class exists.bundleReleaseAarwhen those consumer keep rules are missing or empty.Acceptance
proguard.txtwith those keep rules.org.lightningdevkit.ldknodewithout an app keep for that package.