安卓 运行不起来

object1984 14天前 57

You are applying Flutter's app_plugin_loader Gradle plugin imperatively using the apply script method, which is deprecated and will be removed in a future release. Migrate to applying Gradle plugins with the declarative plugins block: https://flutter.dev/to/flutter-gradle-plugin-apply

You are applying Flutter's main Gradle plugin imperatively using the apply script method, which is deprecated and will be removed in a future release. Migrate to applying Gradle plugins with the declarative plugins block: https://flutter.dev/to/flutter-gradle-plugin-apply

../../../.pub-cache/git/fluttertpc_flutter_local_notifications-b2056b29243e05c4c0774360933929a4836da9a3/flutter_local_notifications/lib/src/flutter_local_notifications_plugin.dart:45:56: Error: Member not found: 'ohos'. } else if (defaultTargetPlatform == TargetPlatform.ohos) { ^^^^ ../../../.pub-cache/git/fluttertpc_flutter_local_notifications-b2056b29243e05c4c0774360933929a4836da9a3/flutter_local_notifications/lib/src/flutter_local_notifications_plugin.dart:93:57: Error: Member not found: 'ohos'. } else if ((defaultTargetPlatform == TargetPlatform.ohos) && ^^^^ ../../../.pub-cache/git/fluttertpc_flutter_local_notifications-b2056b29243e05c4c0774360933929a4836da9a3/flutter_local_notifications/lib/src/flutter_local_notifications_plugin.dart:157:56: Error: Member not found: 'ohos'. } else if (defaultTargetPlatform == TargetPlatform.ohos) { ^^^^ ../../../.pub-cache/git/fluttertpc_flutter_local_notifications-b2056b29243e05c4c0774360933929a4836da9a3/flutter_local_notifications/lib/src/flutter_local_notifications_plugin.dart:249:56: Error: Member not found: 'ohos'. } else if (defaultTargetPlatform == TargetPlatform.ohos) { ^^^^ ../../../.pub-cache/git/fluttertpc_flutter_local_notifications-b2056b29243e05c4c0774360933929a4836da9a3/flutter_local_notifications/lib/src/flutter_local_notifications_plugin.dart:278:56: Error: Member not found: 'ohos'. } else if (defaultTargetPlatform == TargetPlatform.ohos) { ^^^^ ../../../.pub-cache/git/fluttertpc_flutter_local_notifications-b2056b29243e05c4c0774360933929a4836da9a3/flutter_local_notifications/lib/src/flutter_local_notifications_plugin.dart:322:56: Error: Member not found: 'ohos'. } else if (defaultTargetPlatform == TargetPlatform.ohos) { ^^^^ ../../../.pub-cache/git/fluttertpc_flutter_local_notifications-b2056b29243e05c4c0774360933929a4836da9a3/flutter_local_notifications/lib/src/flutter_local_notifications_plugin.dart:407:56: Error: Member not found: 'ohos'. } else if (defaultTargetPlatform == TargetPlatform.ohos) { ^^^^ ../../../.pub-cache/git/fluttertpc_flutter_local_notifications-b2056b29243e05c4c0774360933929a4836da9a3/flutter_local_notifications/lib/src/flutter_local_notifications_plugin.dart:482:56: Error: Member not found: 'ohos'. } else if (defaultTargetPlatform == TargetPlatform.ohos) { ^^^^ ../../../.pub-cache/git/fluttertpc_flutter_local_notifications-b2056b29243e05c4c0774360933929a4836da9a3/flutter_local_notifications/lib/src/flutter_local_notifications_plugin.dart:546:56: Error: Member not found: 'ohos'. } else if (defaultTargetPlatform == TargetPlatform.ohos) { ^^^^ ../../../.pub-cache/git/fluttertpc_mobile_scanner-ada6c1488c4a74ecd5f76a6e6ed1884c23b4bde1/lib/src/mobile_scanner_controller.dart:269:49: Error: Member not found: 'ohos'. if (defaultTargetPlatform == TargetPlatform.ohos) { ^^^^ ../../../.pub-cache/git/fluttertpc_mobile_scanner-ada6c1488c4a74ecd5f76a6e6ed1884c23b4bde1/lib/src/method_channel/mobile_scanner_method_channel.dart:69:49: Error: Member not found: 'ohos'. defaultTargetPlatform == TargetPlatform.ohos) { ^^^^ Target kernel_snapshot_program failed: Exception

FAILURE: Build failed with an exception.

Flutter 版本 3.27.2 clean 过也不行

最新回复 (1)
  • x86 14天前
    引用 2
    你看下readme,为了同时支持安卓,苹果,鸿蒙,要求用鸿蒙版的flutter
返回