文章目录
出现场景
更新了一些三方库,升级了Xcode
, 编译IOS
出现以下错误。
Failed to build iOS app
Could not build the precompiled application for the device.
Error (Xcode): DT_TOOLCHAIN_DIR cannot be used to evaluate LIBRARY_SEARCH_PATHS, use TOOLCHAIN_DIR instead
出现场景
这是Cocoapos
老版本的一个bug,主要是在更新了Xcode15之后编译ios产生的问题。有两种解决方法。更新Cocoapods
版本或者修改Podfile
文件配置.
解决方案
修改Podfile
post_install do |installer|
installer.pods_project.targets.each do |target|
flutter_additional_ios_build_settings(target)
# 新增以下内容
target.build_configurations.each do |config|
xcconfig_path = conf