You need to enable JavaScript to run this app.
优惠活动
大模型
产品
解决方案
定价
更多

Flutter项目无法在Xcode Cloud构建,寻求解决方案

Xcode Cloud归档Flutter应用报错求助

本地可正常归档和构建Flutter应用,但使用Xcode Cloud默认工作流归档时,遇到以下四个错误:

  • could not find included file 'Pods/Target Support Files/Pods-Runner/Pods-Runner.release.xcconfig' in search paths
  • could not find included file 'Generated.xcconfig' in search paths
  • Unable to load contents of file list: '/Target Support Files/Pods-Runner/Pods-Runner-frameworks-Release-output-files.xcfilelist'
  • Unable to load contents of file list: '/Target Support Files/Pods-Runner/Pods-Runner-frameworks-Release-input-files.xcfilelist'

同时出现两个警告(不确定是否与错误关联):

  • Run script build phase '[CP] Embed Pods Frameworks' will be run during every build because it does not specify any outputs. To address this warning, either add output dependencies to the script phase, or configure it to run in every build by unchecking "Based on dependency analysis" in the script phase.
  • Unable to read contents of XCFileList '/Target Support Files/Pods-Runner/Pods-Runner-frameworks-Release-output-files.xcfilelist'

当前使用的post-clone脚本如下:

#!/bin/sh

# The default execution directory of this script is the ci_scripts directory.
cd $CI_WORKSPACE # change working directory to the root of your cloned repo.

# Install Flutter using git.
git clone https://github.com/flutter/flutter.git --depth 1 -b stable $HOME/flutter
export PATH="$PATH:$HOME/flutter/bin"

# Install Flutter artifacts for iOS (--ios), or macOS (--macos) platforms.
flutter precache --ios

# Install Flutter dependencies.
flutter pub get
flutter build ios

# Install CocoaPods using Homebrew.
HOMEBREW_NO_AUTO_UPDATE=1 # disable homebrew's automatic updates.
brew install cocoapods

# Install CocoaPods dependencies.
cd ios
pod install # run `pod install` in the `ios` directory.

exit 0

已尝试修改post-clone脚本和项目本身,但问题仍未解决,恳请提供解决方法,如需更多信息可随时补充。


内容的提问来源于stack exchange,提问作者Not_Ryan

相关产品推荐
方舟 Agent Plan

超全模态模型 × Harness 升级,最新支持 Deepseek-V4.1-Flash、GLM-5.3 系列、Doubao-Seedream-5.0-pro、Kimi-K3 (部分), 限时 9.9 元起

最近更新时间:2026.07.18 14:13:02