我正在使用Flutter构建应用程序。我正在尝试构建我的应用程序,它在Android上运行良好,并且可以在我的iPhone上构建调试版本。但是,在为IOS构建发行版本时,我不断收到错误消息:
c声:错误:没有这样的文件或目录:'CoreTelephony'
我已经搜索了我的项目,找不到关于CoreTelephony的任何提及。 我已经在项目的“构建阶段”中添加了CoreTelephony.Framework,但这似乎没有任何效果。 我发现了类似的问题,但是没有一个有效的答案。谁能建议我该怎么做才能消除此错误?
非常感谢,
这是堆栈跟踪:
Ld /Users/seanthomas/Library/Developer/Xcode/DerivedData/Runner-eyqpdbuzdprckidwlvebymycrkia/Build/Products/Release-iphoneos/Runner.app/Runner normal arm64
cd /Users/seanthomas/Desktop/reliving_flutter/ios
export IPHONEOS_DEPLOYMENT_TARGET=12.0
export PATH="/Applications/Xcode.app/Contents/Developer/Platforms/iPhoneOS.platform/Developer/usr/bin:/Applications/Xcode.app/Contents/Developer/usr/bin:/usr/local/bin:/usr/bin:/bin:/usr/sbin:/sbin"
/Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/bin/clang -Xlinker -rpath -Xlinker /usr/lib/swift -arch arm64 -isysroot /Applications/Xcode.app/Contents/Developer/Platforms/iPhoneOS.platform/Developer/SDKs/iPhoneOS12.4.sdk -L/Users/seanthomas/Library/Developer/Xcode/DerivedData/Runner-eyqpdbuzdprckidwlvebymycrkia/Build/Products/Release-iphoneos -L/Users/seanthomas/Desktop/reliving_flutter/ios/Flutter -F/Users/seanthomas/Library/Developer/Xcode/DerivedData/Runner-eyqpdbuzdprckidwlvebymycrkia/Build/Products/Release-iphoneos -F/Users/seanthomas/Library/Developer/Xcode/DerivedData/Runner-eyqpdbuzdprckidwlvebymycrkia/Build/Products/Release-iphoneos/FMDB -F/Users/seanthomas/Library/Developer/Xcode/DerivedData/Runner-eyqpdbuzdprckidwlvebymycrkia/Build/Products/Release-iphoneos/TOCropViewController -F/Users/seanthomas/Library/Developer/Xcode/DerivedData/Runner-eyqpdbuzdprckidwlvebymycrkia/Build/Products/Release-iphoneos/app_settings -F/Users/seanthomas/Library/Developer/Xcode/DerivedData/Runner-eyqpdbuzdprckidwlvebymycrkia/Build/Products/Release-iphoneos/audio_recorder -F/Users/seanthomas/Library/Developer/Xcode/DerivedData/Runner-eyqpdbuzdprckidwlvebymycrkia/Build/Products/Release-iphoneos/audioplayer -F/Users/seanthomas/Library/Developer/Xcode/DerivedData/Runner-eyqpdbuzdprckidwlvebymycrkia/Build/Products/Release-iphoneos/camera -F/Users/seanthomas/Library/Developer/Xcode/DerivedData/Runner-eyqpdbuzdprckidwlvebymycrkia/Build/Products/Release-iphoneos/flutter_statusbarcolor -F/Users/seanthomas/Library/Developer/Xcode/DerivedData/Runner-eyqpdbuzdprckidwlvebymycrkia/Build/Products/Release-iphoneos/geolocator -F/Users/seanthomas/Library/Developer/Xcode/DerivedData/Runner-eyqpdbuzdprckidwlvebymycrkia/Build/Products/Release-iphoneos/google_api_availability -F/Users/seanthomas/Library/Developer/Xcode/DerivedData/Runner-eyqpdbuzdprckidwlvebymycrkia/Build/Products/Release-iphoneos/image_cropper -F/Users/seanthomas/Library/Developer/Xcode/DerivedData/Runner-eyqpdbuzdprckidwlvebymycrkia/Build/Products/Release-iphoneos/image_picker -F/Users/seanthomas/Library/Developer/Xcode/DerivedData/Runner-eyqpdbuzdprckidwlvebymycrkia/Build/Products/Release-iphoneos/path_provider -F/Users/seanthomas/Library/Developer/Xcode/DerivedData/Runner-eyqpdbuzdprckidwlvebymycrkia/Build/Products/Release-iphoneos/permission_handler -F/Users/seanthomas/Library/Developer/Xcode/DerivedData/Runner-eyqpdbuzdprckidwlvebymycrkia/Build/Products/Release-iphoneos/shared_preferences -
F/Users/seanthomas/Library/Developer/Xcode/DerivedData/Runner-eyqpdbuzdprckidwlvebymycrkia/Build/Products/Release-iphoneos/sqflite -F/Users/seanthomas/Library/Developer/Xcode/DerivedData/Runner-eyqpdbuzdprckidwlvebymycrkia/Build/Products/Release-iphoneos/url_launcher -F/Users/seanthomas/Library/Developer/Xcode/DerivedData/Runner-eyqpdbuzdprckidwlvebymycrkia/Build/Products/Release-iphoneos/video_player -F/Users/seanthomas/Desktop/reliving_flutter/ios/Pods/../.symlinks/flutter/ios -F/Users/seanthomas/Desktop/reliving_flutter/ios/Flutter -filelist /Users/seanthomas/Library/Developer/Xcode/DerivedData/Runner-eyqpdbuzdprckidwlvebymycrkia/Build/Intermediates.noindex/Runner.build/Release-iphoneos/Runner.build/Objects-normal/arm64/Runner.LinkFileList -Xlinker -rpath -Xlinker @executable_path/Frameworks -Xlinker -rpath -Xlinker @loader_path/Frameworks -Xlinker -rpath -Xlinker @executable_path/Frameworks -miphoneos-version-min=12.0 -dead_strip -Xlinker -object_path_lto -Xlinker /Users/seanthomas/Library/Developer/Xcode/DerivedData/Runner-eyqpdbuzdprckidwlvebymycrkia/Build/Intermediates.noindex/Runner.build/Release-iphoneos/Runner.build/Objects-normal/arm64/Runner_lto.o -fobjc-arc -fobjc-link-runtime -L/Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/lib/swift/iphoneos -Xlinker -add_ast_path -Xlinker /Users/seanthomas/Library/Developer/Xcode/DerivedData/Runner-eyqpdbuzdprckidwlvebymycrkia/Build/Intermediates.noindex/Runner.build/Release-iphoneos/Runner.build/Objects-normal/arm64/Runner.swiftmodule -ObjC -lc++ -lsqlite3 -lz -framework Accelerate -framework CoreData -framework CoreGraphics -framework CoreImage -framework CoreLocation -force_load -framework CoreTelephony -framework CoreText -framework FMDB -framework Flutter -framework GLKit -framework GoogleMaps -framework GoogleMapsBase -framework GoogleMapsCore -framework ImageIO -framework OpenGLES -framework QuartzCore -framework SystemConfiguration -framework TOCropViewController -framework UIKit -framework audio_recorder2 -framework audioplayer -framework camera -framework geolocator -framework google_api_availability -framework google_maps_flutter -framework image_cropper -framework image_picker -framework path_provider -framework permission_handler -framework shared_preferences -framework sqflite -framework url_launcher -framework video_player -ObjC -lsqlite3 -framework FMDB -framework Flutter -framework TOCropViewController -framework app_settings -framework audio_recorder -framework audioplayer -framework camera -framework flutter_statusbarcolor -framework geolocator -framework google_api_availability -framework image_cropper -framework image_picker -framework path_provider -framework permission_handler -framework shared_preferences -framework sqflite -framework url_launcher -framework video_player -ObjC -lsqlite3 -framework FMDB -framework Flutter -framework TOCropViewController -framework audio_recorder2 -framework audioplayer -framework camera -framework geolocator -framework google_api_availability -framework image_cropper -framework image_picker -framework path_provider -framework permission_handler -framework shared_preferences -framework sqflite -framework url_launcher -framework video_player -force_load CoreFramework -framework CoreTelephony -framework Flutter -framework App -framework Pods_Runner -Xlinker -dependency_info -Xlinker /Users/seanthomas/Library/Developer/Xcode/DerivedData/Runner-eyqpdbuzdprckidwlvebymycrkia/Build/Intermediates.noindex/Runner.build/Release-iphoneos/Runner.build/Objects-normal/arm64/Runner_dependency_info.dat -o /Users/seanthomas/Library/Developer/Xcode/DerivedData/Runner-eyqpdbuzdprckidwlvebymycrkia/Build/Products/Release-iphoneos/Runner.app/Runner
clang: error: no such file or directory: 'CoreTelephony'