My situation and environment is as below:

XCode 16.2,macOS Sequoia 15.2, flutter 3.7.12 Swift 5, mini os iOS 12.0

 

I used the commands of “flutter clean” and “flutter pub get” and cd to ios folder and run “pod install”.

I opened Xcode to archive ipa file appear a problem as below:

 

Disabling previews because SWIFT_VERSION is set and SWIFT_OPTIMIZATION_LEVEL=-O, expected -Onone

 

Solution: In the file of Runner/Flutter/Release.xcconfig in Xcode, add the code as below:

 

ENABLE_PREVIEWS = NO

 

And then Clean Build Folder and archive again. The problem will be solved.

文章標籤
全站熱搜
創作者介紹
創作者 Akira Chen 的頭像
Akira Chen

akira32 編程之家 pixnet

Akira Chen 發表在 痞客邦 留言(0) 人氣(37)