isAndroidCppModule function

bool isAndroidCppModule(
  1. File specFile
)

Returns true ONLY when the spec declares android: NativeImpl.cpp (or AndroidNativeImpl.cpp). Unlike isNativeCppModule this does NOT match linux-only C++ modules.

Use this when deciding whether a module needs a Kotlin JniBridge.register() call: a module with android: NativeImpl.kotlin, linux: NativeImpl.cpp uses the JNI bridge on Android and should NOT be excluded from Kotlin linking.

Implementation

bool isAndroidCppModule(File specFile) =>
    PlatformTargetAnalyzer.fromSpec(specFile).supportsAndroid;