从源react-native-fcm构建时编译失败

时间:2017-03-06 21:08:22

标签: android react-native google-cloud-messaging

我已经尝试过在github问题上找到的所有替代方案。这看起来是版本不兼容问题

FIRMessagingModule.java:36: error: FIRMessagingModule is not abstract and does not override abstract method onActivityResult(int,int,Intent) in ActivityEventListener public class FIRMessagingModule extends ReactContextBaseJavaModule implements LifecycleEventListener, ActivityEventListener { ^ AwesomeProject\node_modules\react-native-fcm\android\src\main\java\com\evollu\react\fcm\FIRMessagingModule.java:274: error: method does not override or implement a method from a supertype @Override ^ AwesomeProject\node_modules\react-native-fcm\android\src\main\java\com\evollu\react\fcm\FIRMessagingModule.java:278: error: method does not override or implement a method from a supertype @Override ^ 3 errors :react-native-fcm:compileReleaseJavaWithJavac FAILED

React native version: 1000.0.0(从源码构建)
操作系统: Windows 10

1 个答案:

答案 0 :(得分:0)

您可以尝试替换:

( - )compile' com.facebook.react:react-native:+'

(+)编译项目(':ReactAndroid')

在node_modules / react-native-fcm / android / build.gradle