Skip to content

Conversation

@kraenhansen
Copy link
Collaborator

@kraenhansen kraenhansen commented Sep 13, 2025

As an alternative to #207 want the test app to enable RCT_USE_RN_DEP (since we can and this is faster) and assert that RCT_USE_PREBUILT_RNCORE is never enabled (since we cannot support this as the prebuild of React Native Core use a JSI header which we have to patch - resulting in runtime crashes when enabled with our patched Hermes).

@kraenhansen kraenhansen self-assigned this Sep 13, 2025
@kraenhansen kraenhansen added the Apple 🍎 Anything related to the Apple platform (iOS, macOS, Cocoapods, Xcode, XCFrameworks, etc.) label Sep 13, 2025
@kraenhansen kraenhansen force-pushed the kh/precompiled-ios-builds branch from 6b64353 to 86ff582 Compare September 13, 2025 18:47
@kraenhansen kraenhansen marked this pull request as draft September 14, 2025 11:42
@kraenhansen
Copy link
Collaborator Author

kraenhansen commented Sep 14, 2025

Converted this into draft: I don't think we'll actually want to merge and add this matrix. We'll likely just pick one configuration (most likely RCT_USE_PREBUILT_RNCORE=1) and run the tests with that.

@kraenhansen kraenhansen changed the title Add matrix with prebuilds for RN core deps enabled Enable RCT_USE_RN_DEP in test app and assert RCT_USE_PREBUILT_RNCORE != 0 Sep 14, 2025
@kraenhansen kraenhansen changed the title Enable RCT_USE_RN_DEP in test app and assert RCT_USE_PREBUILT_RNCORE != 0 Enable RCT_USE_RN_DEP in test app and assert RCT_USE_PREBUILT_RNCORE != 1 Sep 14, 2025
@kraenhansen
Copy link
Collaborator Author

I updated the description to reflect my change in intent with this PR.

Comment on lines -49 to -64
s.dependency "React-Core"
# Don't install the dependencies when we run `pod install` in the old architecture.
if ENV['RCT_NEW_ARCH_ENABLED'] == '1' then
# TODO: Re-visit these dependencies and flags and remove them if not needed.
s.compiler_flags = folly_compiler_flags + " -DRCT_NEW_ARCH_ENABLED=1"
s.pod_target_xcconfig = {
"HEADER_SEARCH_PATHS" => "\"$(PODS_ROOT)/boost\"",
"OTHER_CPLUSPLUSFLAGS" => "-DFOLLY_NO_CONFIG -DFOLLY_MOBILE=1 -DFOLLY_USE_LIBCPP=1",
"CLANG_CXX_LANGUAGE_STANDARD" => "c++17"
}
s.dependency "React-Codegen"
s.dependency "RCT-Folly"
s.dependency "RCTRequired"
s.dependency "RCTTypeSafety"
s.dependency "ReactCommon/turbomodule/core"
end
Copy link
Collaborator Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Drive-by deleting this as we don't support old versions of React Native anyway.

Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

What's the output when users try on an unsupported version?

Copy link
Collaborator Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

An error is raised:

This version of React Native is too old for React Native Node-API

@kraenhansen kraenhansen marked this pull request as ready for review September 14, 2025 19:47
@kraenhansen kraenhansen merged commit b53f84a into main Sep 16, 2025
6 checks passed
@kraenhansen kraenhansen deleted the kh/precompiled-ios-builds branch September 16, 2025 16:35
@kraenhansen
Copy link
Collaborator Author

Please review in retrospect 🙏

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

Labels

Apple 🍎 Anything related to the Apple platform (iOS, macOS, Cocoapods, Xcode, XCFrameworks, etc.)

Projects

None yet

Development

Successfully merging this pull request may close these issues.

4 participants