我有一个离子项目,它使用了一个电容器。我项目的环境信息显示如下:
Ionic:
ionic (Ionic CLI) : 4.1.1 (/usr/local/lib/node_modules/ionic)
Ionic Framework: ionic-angular 3.9.2
@ionic/app-scripts : 3.1.11
Capacitor:
capacitor (Capacitor CLI) : 1.1.0
@capacitor/core : 1.1.0
Cordova:
cordova (Cordova CLI) : 7.0.0
Cordova Platforms : none
Cordova Plugins : no whitelisted plugins (0 plugins total)
System:
Android SDK Tools : 26.1.1 (/Users/iosbuild/Library/Android/sdk)
NodeJS : v9.4.0 (/usr/local/bin/node)
npm : 6.4.1
OS : macOS High Sierra
Xcode : Xcode 9.4.1 Build version 9F2000
╭─────────────────────────────────────╮
│ │
│ Update available 4.1.1 → 5.2.3 │
│ Run npm i -g ionic to update │
│ │
╰─────────────────────────────────────╯
要构建和部署项目,该项目使用Fastlane。该应用程序是自动代码签名的。
Fastlane的健身房看起来像:
gym(
scheme: IOS_SCHEME,
workspace: IOS_WORKSPACE,
export_method: EXPORT_METHOD[releaseType],
export_xcargs: '-allowProvisioningUpdates',
export_options: {
'signingStyle': 'automatic',
'compileBitcode': false
}
)
突然,几个月后,构建开始失败,错误代码为65。 这是构建失败消息:
[33m▸[0m [39;1mProcessing[0m Info.plist
[33m▸[0m [39;1mGenerating 'App.app.dSYM'[0m
[33m▸[0m [39;1mRunning script[0m '[CP] Embed Pods Frameworks'
** ARCHIVE FAILED **
The following build commands failed:
PhaseScriptExecution [CP]\ Embed\ Pods\ Frameworks /Users/iosbuild/Library/Developer/Xcode/DerivedData/App-fdavtmgcrorkxicfvghtsxxtwfeo/Build/Intermediates.noindex/ArchiveIntermediates/App/IntermediateBuildFilesPath/App.build/Release-iphoneos/App.build/Script-9592DBEFFC6D2A0C8D5DEB22.sh
(1 failure)
[09:28:20]: [31mExit status: 65[0m
+---------------+-------------------------+
| [32m[33mBuild environment[0m |
+---------------+-------------------------+
| xcode_path | /Applications/Xcode.app |
| gym_version | 2.105.2 |
| export_method | enterprise |
| SDK | iPhoneOS11.4.SDK |
+---------------+-------------------------+
[09:28:20]: ▸ [35mtotal size is 10252820 speedup is 1.00[0m
[09:28:20]: ▸ [35mCode Signing /Users/iosbuild/Library/Developer/Xcode/DerivedData/App-fdavtmgcrorkxicfvghtsxxtwfeo/Build/Intermediates.noindex/ArchiveIntermediates/App/InstallationBuildProductsLocation/Applications//App.app/Frameworks/Capacitor.framework with Identity iPhone Developer: XXXX XXXX (XXXXXXXXX)[0m
[09:28:20]: ▸ [35m/usr/bin/codesign --force --sign <[Some alphanumeric text]> --preserve-metadata=identifier,entitlements '/Users/iosbuild/Library/Developer/Xcode/DerivedData/App-fdavtmgcrorkxicfvghtsxxtwfeo/Build/Intermediates.noindex/ArchiveIntermediates/App/InstallationBuildProductsLocation/Applications//App.app/Frameworks/Capacitor.framework'[0m
[09:28:20]: ▸ [35m/Users/iosbuild/Library/Developer/Xcode/DerivedData/App-fdavtmgcrorkxicfvghtsxxtwfeo/Build/Intermediates.noindex/ArchiveIntermediates/App/InstallationBuildProductsLocation/Applications//App.app/Frameworks/Capacitor.framework: errSecInternalComponent[0m
[09:28:20]: ▸ [35mCommand /bin/sh failed with exit code 1[0m
经过大量谷歌搜索,已经尝试了许多解决方案,但是失败..! 已经尝试了以下解决方案:
pod install
使用Fastlane。Podfile如下所示:
platform :ios, '11.0'
use_frameworks!
# workaround to avoid Xcode 10 caching of Pods that requires
# Product -> Clean Build Folder after new Cordova plugins installed
# Requires CocoaPods 1.6 or newer
install! 'cocoapods', :disable_input_output_paths => true
def capacitor_pods
# Automatic Capacitor Pod dependencies, do not delete
pod 'Capacitor', :path => '../../node_modules/@capacitor/ios'
pod 'CapacitorCordova', :path => '../../node_modules/@capacitor/ios'
pod 'CordovaPluginsStatic', :path => '../capacitor-cordova-ios-plugins'
# Do not delete
end
target 'App' do
capacitor_pods
# Add your Pods here
end
Mac-mini的Cocoapods版本为1.7.4
这里的第一个问题是,是否需要将Xcode版本更新为10?
第二个问题,fastlane版本重要吗?当前使用的快速通道版本为:2.105.2
如何解决此存档失败问题?所需的证书均已正确安装。从几天开始尝试,但仍然停留在这里。
任何帮助将不胜感激!
答案 0 :(得分:0)
电容器需要Xcode 10或更高版本,因为最新版本使用Swift 4.2,而Xcode 9上没有此功能