Bitcode とは?
iOS9から導入された技術で LLVM の中間言語のことを指します。以前まではコンパイルが完了しているものを Apple に提出していましたが、Bitcode を用いることで Apple 側で最適化してコンパイルを行えるようになります。
Bitcode を用いたくない場合
基本的にアプリで Bitcode を有効にする場合は、依存しているライブラリなども全て Bitcode に対応している必要があります。そのため、Carthage などでコンパイル済みのバイナリを使用するような時にライブラリの Bitcode が有効になっていない場合はアプリを配信するときなどにプロジェクトの Bitcode を無効にする必要があります。
Xcode から配信する場合
Rebuild from Bitcode
のチェックボックスを外せば無効にできます。
Fastlane から配信する場合
export_options
に compileBitcode
の項目を追加することで Bitcode でのコンパイルを制御できるようになります。
lane :adhoc do
match(type: "adhoc", app_identifier: "hoge.com", force_for_new_devices: true, readonly: true)
gym(
workspace: WORKSPACE,
scheme: SCHEME,
configuration: "Staging",
export_method: "ad-hoc",
export_options: { compileBitcode: false }
)
firebase_app_distribution(
app: "hogehoge",
testers: "hogehoge@hoge.com",
release_notes: "Lots of amazing new features to test out!",
firebase_cli_path: "./node_modules/.bin/firebase"
)
end
参考