1

I have a flutter module and integrated in the existing iOS app (add to app). Everything was working but when I try to Archive it produces an error in webview_flutter module:

bitcode bundle could not be generated because '/Users/flutter-module/.ios/Flutter/engine/Flutter.framework/Flutter' was built without full bitcode. All frameworks and dylibs for bitcode must be generated from Xcode Archive or Install build file '/Users/flutter-module/.ios/Flutter/engine/Flutter.framework/Flutter' for architecture armv7

I checked the build setting and the Bitcode enabled is set to "Yes" for obvious reasons, what might be the reason for this error? Does it have something to do with the webview_flutter module?

EDIT

macOS: 10.15.3 (Catalina)

Xcode version: 11.0 (11A420a)

Flutter version: Channel stable, 1.20.2

Let's_Create
  • 2,963
  • 3
  • 14
  • 33
  • What version of Flutter are you using? As of 1.9.6, Flutter should have bitcode included. – Coder-256 Aug 20 '20 at 17:19
  • @Coder-256 I am using 1.20.2, Do you think it is an issue with the package (webview_flutter), because this error occurs within that package. – Let's_Create Aug 20 '20 at 18:35
  • I'm not sure yet, but I'm leaning towards no. What Xcode and macOS version are you using? Could you add all the version info into your question? – Coder-256 Aug 21 '20 at 00:36
  • Can you check that "Enable Bitcode" is enabled, and everything under "Architectures" is set to the default (not bold) on *all* your targets? – Coder-256 Aug 21 '20 at 00:45
  • I have updated the question with versions, and Bit code is enabled and the "Architectures" are all set to defaults. let me know if you need any further data – Let's_Create Aug 21 '20 at 07:18
  • What version of Xcode 11 specifically? Sorry for all these questions – Coder-256 Aug 21 '20 at 19:04
  • No problem at all updated the question. Also @Coder-256 I see an open issue for this in the flutter repo https://github.com/flutter/flutter/issues/48092. Though it is not specific to this package. – Let's_Create Aug 22 '20 at 09:00
  • Ok, I guess the answer is that this is a known bug and nothing wrong with your code. However one thing I would try is upgrading Xcode to the latest version (currently 11.6). – Coder-256 Aug 22 '20 at 23:50

1 Answers1

1

To archive an iOS app with Flutter module:

  1. Run flutter build ios in your flutter module directory to create a release build.
  2. Return to Xcode, then clean build folder (optional) and perform archive.

This part is not well-documented in Add-to-app section. For more detail, see create a build archive in official document.

speshiou
  • 313
  • 2
  • 9