本文主要是介绍flutter webrtc 编译报错 Could not build the precompiled application for the device.,希望对大家解决编程问题提供一定的参考价值,需要的开发者们随着小编来一起学习吧!
flutter webrtc运行报错
Running Xcode build...
Xcode build done. 19.7s
Failed to build iOS app
Error output from Xcode build:
↳2022-03-31 15:36:50.750 xcodebuild[10731:312247] Requested but did not find extension point withidentifier Xcode.IDEKit.ExtensionSentinelHostApplications for extensionXcode.DebuggerFoundation.AppExtensionHosts.watchOS of plug-in com.apple.dt.IDEWatchSupportCore2022-03-31 15:36:50.751 xcodebuild[10731:312247] Requested but did not find extension point withidentifier Xcode.IDEKit.ExtensionPointIdentifierToBundleIdentifier for extensionXcode.DebuggerFoundation.AppExtensionToBundleIdentifierMap.watchOS of plug-incom.apple.dt.IDEWatchSupportCore** BUILD FAILED **Xcode's output:
↳Writing result bundle at path:/var/folders/55/9mlqm5pn4r570ldrcxqb0mx80000gn/T/flutter_tools.KcBTKD/flutter_ios_build_temp_dirICE83K/temporary_xcresult_bundle/usr/local/Caskroom/flutter/2.10.3/flutter/.pub-cache/hosted/pub.dartlang.org/flutter_webrtc-0.8.4/lib/src/native/rtc_data_channel_impl.dart:16:7: Error: The non-abstract class'RTCDataChannelNative' is missing implementations for these members:- RTCDataChannel.bufferedAmount- RTCDataChannel.idTry to either- provide an implementation,- inherit an implementation from a superclass or mixin,- mark the class as abstract, or- provide a 'noSuchMethod' implementation.class RTCDataChannelNative extends RTCDataChannel {^^^^^^^^^^^^^^^^^^^^/usr/local/Caskroom/flutter/2.10.3/flutter/.pub-cache/hosted/pub.dartlang.org/webrtc_interface-1.0.3/lib/src/rtc_data_channel.dart:79:11: Context: 'RTCDataChannel.bufferedAmount' is definedhere.int get bufferedAmount;^^^^^^^^^^^^^^/usr/local/Caskroom/flutter/2.10.3/flutter/.pub-cache/hosted/pub.dartlang.org/webrtc_interface-1.0.3/lib/src/rtc_data_channel.dart:74:11: Context: 'RTCDataChannel.id' is defined here.int? get id;^^/usr/local/Caskroom/flutter/2.10.3/flutter/.pub-cache/hosted/pub.dartlang.org/flutter_webrtc-0.8.4/lib/src/native/rtc_data_channel_impl.dart:36:15: Error: The return type of the method'RTCDataChannelNative.label' is 'String?', which does not match the return type, 'String', of theoverridden method, 'RTCDataChannel.label'.Change to a subtype of 'String'.String? get label => _label;^/usr/local/Caskroom/flutter/2.10.3/flutter/.pub-cache/hosted/pub.dartlang.org/webrtc_interface-1.0.3/lib/src/rtc_data_channel.dart:77:14: Context: This is the overridden method ('label').String? get label;^Failed to package /Users/***/Desktop/CQTOWTSDK_iOS/FlutterSDK/flutter-webrtc-demo.Command PhaseScriptExecution failed with a nonzero exit codenote: Using new build systemnote: Planningnote: Build preparation completenote: Building targets in dependency order/Users/***/Desktop/CQTOWTSDK_iOS/FlutterSDK/flutter-webrtc-demo/ios/Pods/Pods.xcodeproj: warning: The iOS deployment target 'IPHONEOS_DEPLOYMENT_TARGET' is set to 4.3, but the range ofsupported deployment target versions is 9.0 to 15.4.99. (in target 'Libyuv' from project 'Pods')Result bundle written to path:/var/folders/55/9mlqm5pn4r570ldrcxqb0mx80000gn/T/flutter_tools.KcBTKD/flutter_ios_build_temp_dirICE83K/temporary_xcresult_bundleCould not build the precompiled application for the device.Error launching application on Ming.
尝试了 清除缓存 重装 cocoapods , 重装flutter都不行最后
解决方案:找到flutter加载缓存加载的
/usr/local/Caskroom/flutter/2.10.3/flutter/.pub-cache/hosted/pub.dartlang.org/flutter_webrtc-0.8.4/lib/src/native/rtc_data_channel_impl.dart
文件 将
这几个的 get 给去掉
保存后再次 flutter run 就行了
这篇关于flutter webrtc 编译报错 Could not build the precompiled application for the device.的文章就介绍到这儿,希望我们推荐的文章对编程师们有所帮助!