Files
flipper/react-native/react-native-flipper/android/src
Caleb Clarke 3e95645f45 Fix release builds on Android, take 2 (#1329)
Summary:
Changelog: Fixed react-native-flipper causing Android release builds to fail

https://github.com/facebook/flipper/issues/1325 made progress but did not quite fix https://github.com/facebook/flipper/issues/1303. Android Release builds would still fail because `PackageList` depended on `FlipperPackage` and couldn't find it in release builds. There doesn't appear to be a clear way to set up a debug-only package with React Native's Android autolinking (see https://github.com/react-native-community/cli/issues/1211), so this change creates an empty `FlipperPackage` to satisfy that dependency, while still avoiding bundling the Flipper library into the release build.

(manual linking also works, but seems less-desirable for consumers of the library)

## Changelog

Add an empty `FlipperPackage` to the `release` folder to satisfy the reference put in `PackageList` by the autolinker for release builds.

Pull Request resolved: https://github.com/facebook/flipper/pull/1329

Test Plan:
Verified that release builds did fail without this change (using ReactNativeFlipperExample app)

Successfully built a React Native Android Release app from Android Studio using this library and verified that the APK still did not contain Flipper. Built debug and verified that Flipper still worked as before.

Reviewed By: passy

Differential Revision: D23292543

Pulled By: mweststrate

fbshipit-source-id: cb897a0e6dcdc04e29d676596447ca9dd68182c8
2020-08-24 14:46:11 -07:00
..