プログラミングスクール最大70%OFF! ←クリックして見に行く

【Flutter】iOSシミュレータービルド時に「Command CompileSwift failed with a nonzero exit code」

【Flutter】iOSシミュレータービルド時に「Command CompileSwift failed with a nonzero exit code」

エラー解消方法の備忘録_φ(・_・ )

発生したエラー

Command CompileSwift failed with a nonzero exit code
Uncategorized (Xcode): Command CompileSwift failed with a nonzero exit code
Swift Compiler Error (Xcode): Cannot call value of non-function type ‘String?’
/Users/xxx/.pub-cache/hosted/pub.dev/flutter_inappwebview-5.7.2+3/ios/Classes/MyCookieManager.swift:259:43

Could not build the application for the simulator.
Error launching application on iPhone 8.

翻訳

未分類(Xcode)です: コマンド CompileSwift が 0 以外の終了コードで失敗しました。

Swiftコンパイラーエラー(Xcode): 非関数型 ‘String?’ の値を呼び出すことができません。
/Users/xxx/.pub-cache/hosted/pub.dev/flutter_inappwebview-5.7.2+3/ios/Classes/MyCookieManager.swift:259:43

シミュレーター用のアプリケーションをビルドできませんでした。
iPhone 8でアプリケーションを起動する際にエラーが発生しました。

原因

Xcodeのversionが14以降じゃないことが原因で怒られていました。

解決手順

Xcodeのversionを上げる。

Xcodeの最新バージョンのインストールや、
バージョンを指定してのインストール手順は以下の記事を参照
Xcodeバージョンを指定してインストールする方法

参考サイト

Version5.5.0+1 build fail on Xcode 13. #1369
https://github.com/pichillilorenzo/flutter_inappwebview/issues/1369
iOS – MyCookieManager.swift – Cannot call value of non-function type ‘String? #1376
https://github.com/pichillilorenzo/flutter_inappwebview/issues/1376

Flutterカテゴリの最新記事