Skip to content

Add experimental React Native iOS example for Linux - #411

Draft
sbosell wants to merge 2 commits into
xtool-org:mainfrom
Andean-Bridge:codex/react-native-linux-example
Draft

sbosell wants to merge 2 commits into
xtool-org:mainfrom
Andean-Bridge:codex/react-native-linux-example

Conversation

@sbosell

@sbosell sbosell commented Oct 29, 2026 •

Copy link
Copy Markdown

What does this PR do?

Contributes an experimental React Native iOS example for Linux as a bounded feasibility result for #364.

The example resolves React Native 0.77.3's native source graph using CocoaPods, compiles Objective-C/C++/Objective-C++ and assembly locally with Linux Clang, archives/links with LLVM tools against an externally supplied Apple SDK, and uses xtool install for provisioning, signing and USB installation. The screen runs React 18.3.1 with system JavaScriptCore and the legacy bridge/Paper renderer; its Pressable updates a React state counter.

Includes portable tool/SDK configuration, npm/Ruby/Pod lockfiles, two guarded dependency compatibility patches, setup/build instructions, a validation record, and six SDK-free regression checks with a dedicated CI job. No Apple SDK, signing material, compiled app, dependency cache, or raw device logs are included.

This is a separate example adapter, not integration into xtool dev build. Scope remains experimental: Hermes, the New Architecture, Expo modules, arbitrary pods/build phases/resources, Swift pods, simulator builds and Fast Refresh remain future work. This PR relates to #364 and does not close the broader request.

How was it tested?

  • Original standalone prototype: compiled all 684 native files on Omarchy x86_64 using Linux Clang/LLD 23.1.3 and iPhoneOS 27.1 SDK; xtool 1.24.0 signed and installed it on iPhone16,2 / iOS 27.0.1. The human tester confirmed rendering and counter interaction; independent device logs recorded component startup and counter values 1, 2 and 3.
  • Packaged fork example: a fresh dependency install and clean native build passed bash scripts/build.sh (all 684 files, archives and Mach-O arm64 link). Required React Native/JSC symbols were independently verified again.
  • The packaged example retains the exact device-tested ios/Main.mm and index.js sources. After a human deletion, device app browsing confirmed absence; xtool then freshly signed/installed this packaged binary and browsing confirmed presence. The human tester confirmed the screen/counter again, corroborated by a fresh log capture recording component startup and counter values 1–4. The input executable hash matched the clean packaged build. Results are recorded in Examples/ReactNativeLinux/VALIDATION.md.
  • python3 -m unittest discover -s tests -v: six passing checks for toolchain/SDK validation, build settings, cache invalidation, compilation failure handling, safe/idempotent dependency patches, and unsupported xcrun queries.
  • Shell and Ruby syntax checks and workflow YAML parsing passed. Metro successfully bundled the actual JSX screen.
  • Required make lint was attempted: the downloaded SwiftLint 0.65.1 binary cannot start on this Omarchy host because libxml2.so.2 is unavailable. No Swift source changes are included. Core Swift build/tests, macOS and WSL testing were not run locally.

Known device limitations are recorded explicitly: Home Screen launch works, automatic xtool launch returned a debugserver error, screenshot capture lacked the required developer disk image, and RN emitted a non-fatal startup warning. No automated device UI test is claimed.

AI tool usage

  • 0 - No AI was used to write code
  • 1 - I was assisted by AI. I reviewed the finished result.
  • 2 - I set the AI going and left it to it; nobody has read the result - no review, or AI review only

The app was exercised by a human on the phone; source review so far has been AI-only. Opening as a draft in accordance with the repository's PR template.

@coderabbitai

coderabbitai Bot commented Oct 29, 2026

Copy link
Copy Markdown

Important

Draft PR not reviewed

Draft PRs are not automatically reviewed by default.

  • Trigger a manual review

To automatically review draft PRs, update your CodeRabbit configuration:

reviews:
  auto_review:
    drafts: true
  • Autofix · Keep fixing CodeRabbit findings and required CI, and resolving merge conflicts

Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out.

❤️ Share

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

This branch has not been deployed

No deployments
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant