Skip to content

実効性の無くなったios.buildReactNativeFromSource設定を削除 - #6667

Merged
TinyKitten merged 1 commit into
devfrom
chore/drop-ios-build-rn-from-source
Aug 12, 2026
Merged

TinyKitten merged 1 commit into
devfrom
chore/drop-ios-build-rn-from-source

Conversation

@TinyKitten

@TinyKitten TinyKitten commented Aug 12, 2026 •

Copy link
Copy Markdown
Member

概要

iOS で実効性を失っている ios.buildReactNativeFromSource 設定を削除し、宣言と実際のビルド挙動の食い違いを解消します。挙動は変わりません(削除前後どちらも prebuilt バイナリを使用)。

Expo SDK 57 の iOS ビルド修正 (#6664) の調査中に、ios.buildReactNativeFromSource: true を宣言しているにもかかわらず prebuilt な React Core がダウンロードされていることに気付いたのが発端です。

変更の種類

  • バグ修正
  • 新機能
  • リファクタリング
  • ドキュメント
  • CI/CD
  • その他

変更内容

  • ios/Podfile.properties.json から "ios.buildReactNativeFromSource": "true" を削除
  • app.config.ts から expo-build-properties プラグイン項目を削除(このオプションのみを保持していたため)

expo-build-properties パッケージ自体は package.json に残しています。再ロックを伴う変更は避ける方針であり、設定専用プラグインなのでビルドへの影響もありません。

実効性が無い理由

React Native 0.86 の react_native_pods.rb(use_react_native! 内)が、環境変数を明示的に '0' にしない限り prebuilt を強制します。

# Use the React Native precompiled binaries by default.
# Users can still turn them off and build from source by setting the environment variable to 0.
ENV['RCT_USE_RN_DEP'] = ENV['RCT_USE_RN_DEP'] == '0' ? '0' : '1'
ENV['RCT_USE_PREBUILT_RNCORE'] = ENV['RCT_USE_PREBUILT_RNCORE'] == '0' ? '0' : '1'

一方 ios/Podfile は Expo SDK 54 期のテンプレートのままで、'1' を条件付きで代入することはあっても '0' を書きません。

ENV['RCT_USE_RN_DEP'] ||= '1' if podfile_properties['ios.buildReactNativeFromSource'] != 'true' && …

したがって true を指定しても環境変数は未設定のまま RN 側に渡り、'1'(prebuilt)へ上書きされます。React Native が既定をソースビルドから prebuilt へ反転させた際に、テンプレート側が追随していなかったことが原因です。

削除すると Podfile の条件が真になり環境変数へ '1' が明示的に入りますが、RN 側の評価結果は '1' のままで挙動は同一です。

元々の導入経緯と、現在は不要な理由

経緯 現況
#5471 で useHermesV1: true とセットで導入。useHermesV1: false は iOS でソースビルドを要求する(expo-build-properties の validation)ため必須だった #5503 で useHermesV1 自体が削除済みで、この結合は既に解消
#5494「EASビルド失敗対策」で再追加 現在の canary / production ビルドは GitHub Actions + xcodebuild archive で、EAS 固有の事情は該当しない
ソースビルドが必要なケースとして patch-package による react-native 本体へのパッチ patches/ に react-native 本体のパッチは無し(expo-speech / expo-task-manager などは Pod としてソースビルドされるため影響なし)

テスト

ローカル(Linux)で実行:

npm run lint       Checked 631 files. No fixes applied.
npm test           218 suites / 2304 tests 全て passed
npm run typecheck  エラーなし
npx expo-doctor    19/19 checks passed

CocoaPods / Xcode の検証は docs/ios-build-workflows.md の「Safe dry-run」手順に従い、本ブランチに対して Build iOS Canary を TestFlight アップロード無効で実行しました。

削除前(#6664 の検証ビルド)と同じく [ReactNativeCore] Using React Native Core and React Native Dependencies prebuilt がログに出ており、ビルド構成が変わっていないことを確認しています。

  • npm run lint が通ること
  • npm test が通ること
  • npm run typecheck が通ること

関連Issue

スクリーンショット(任意)

Summary by CodeRabbit

  • 変更
    • iOSアプリのビルド設定を整理しました。
    • React Nativeのソースからのビルドに関する個別設定を削除し、標準のビルド構成に戻しました。
    • アプリの機能や画面表示に変更はありません。

@TinyKitten TinyKitten self-assigned this Aug 12, 2026
@github-actions github-actions Bot added the ios label Aug 12, 2026
@coderabbitai

coderabbitai Bot commented Aug 12, 2026 •

Copy link
Copy Markdown
Contributor

Review Change Stack

No actionable comments were generated in the recent review. 🎉

ℹ️ Recent review info
⚙️ Run configuration

Configuration used: Organization UI

Review profile: CHILL

Plan: Pro

Run ID: 8a0812d3-042a-4226-8416-8b22862805f4

📥 Commits

Reviewing files that changed from the base of the PR and between 05f9c96 and 0694d1d.

📒 Files selected for processing (2)
  • app.config.ts
  • ios/Podfile.properties.json
💤 Files with no reviewable changes (2)
  • ios/Podfile.properties.json
  • app.config.ts

📝 Walkthrough

Walkthrough

expo-build-properties と buildReactNativeFromSource の設定を、アプリ設定および iOS Pod 設定から削除しました。

Changes

iOSビルド設定

Layer / File(s) Summary
React Nativeソースビルド設定の削除
app.config.ts, ios/Podfile.properties.json
expo-build-properties と buildReactNativeFromSource: true を削除しました。その他の iOS 設定は維持しました。

Estimated code review effort: 1 (Trivial) | ~2 minutes

Poem

うさぎが設定をひとつ消す
にんじん色のビルドが進む
Podfileもすっきり整い
React Nativeは軽やかに跳ねる
ぴょん、変更完了! 🐇

🚥 Pre-merge checks | ✅ 5
✅ Passed checks (5 passed)
Check name Status Explanation
Title check ✅ Passed タイトルは、実効性を失ったios.buildReactNativeFromSource設定の削除という主な変更を明確かつ簡潔に示しています。
Description check ✅ Passed 概要、変更内容、テスト結果、関連情報を具体的に記載し、テンプレートの主要な項目を満たしています。
Docstring Coverage ✅ Passed No functions found in the changed files to evaluate docstring coverage. Skipping docstring coverage check.
Linked Issues check ✅ Passed Check skipped because no linked issues were found for this pull request.
Out of Scope Changes check ✅ Passed Check skipped because no linked issues were found for this pull request.
✨ Finishing Touches
📝 Generate docstrings
  • Create stacked PR
  • Commit on current branch
🧪 Generate unit tests (beta)
  • Create PR with unit tests
  • Commit unit tests in branch chore/drop-ios-build-rn-from-source

Comment @coderabbitai help to get the list of available commands.

@TinyKitten
TinyKitten merged commit 1438fc9 into dev Aug 12, 2026
5 of 6 checks passed
@TinyKitten
TinyKitten deleted the chore/drop-ios-build-rn-from-source branch August 12, 2026 10:42
@TinyKitten TinyKitten mentioned this pull request Aug 18, 2026
6 of 9 tasks
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant