安装新版本 XCode 15.0 后无法运行应用程序 XCode

2024-03-13

我已经安装了新版本的 Xcode 15.0。此后我无法运行我的 flutter 应用程序。它向我显示以下错误:

Error (Xcode): DT_TOOLCHAIN_DIR cannot be used to evaluate LIBRARY_SEARCH_PATHS, use TOOLCHAIN_DIR instead

我通过以下方式解决了这些问题:

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 = config.base_configuration_reference.real_path
      xcconfig = File.read(xcconfig_path)
      xcconfig_mod = xcconfig.gsub(/DT_TOOLCHAIN_DIR/, "TOOLCHAIN_DIR")
      File.open(xcconfig_path, "w") { |file| file << xcconfig_mod }
      end
  end
end
本文内容由网友自发贡献,版权归原作者所有,本站不承担相应法律责任。如您发现有涉嫌抄袭侵权的内容,请联系:hwhale#tublm.com(使用前将#替换为@)

安装新版本 XCode 15.0 后无法运行应用程序 XCode 的相关文章

随机推荐