Skip to content

Commit 17fe4b5

Browse files
committed
fix(react-native): add defines_modules for rctappdelegate
1 parent 440e163 commit 17fe4b5

File tree

2 files changed

+14
-1
lines changed

2 files changed

+14
-1
lines changed

example/package.json

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -6,7 +6,8 @@
66
"android": "react-native run-android",
77
"ios": "react-native run-ios",
88
"start": "react-native start",
9-
"pods": "pod-install --quiet"
9+
"pods": "pod-install --quiet",
10+
"postinstall": "npx patch-package"
1011
},
1112
"dependencies": {
1213
"react": "18.2.0",
Lines changed: 12 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,12 @@
1+
diff --git a/node_modules/react-native/Libraries/AppDelegate/React-RCTAppDelegate.podspec b/node_modules/react-native/Libraries/AppDelegate/React-RCTAppDelegate.podspec
2+
index fff8711..61e0e5a 100644
3+
--- a/node_modules/react-native/Libraries/AppDelegate/React-RCTAppDelegate.podspec
4+
+++ b/node_modules/react-native/Libraries/AppDelegate/React-RCTAppDelegate.podspec
5+
@@ -54,6 +54,7 @@ Pod::Spec.new do |s|
6+
# This guard prevent to install the dependencies when we run `pod install` in the old architecture.
7+
s.compiler_flags = other_cflags
8+
s.pod_target_xcconfig = {
9+
+ "DEFINES_MODULE" => "YES",
10+
"HEADER_SEARCH_PATHS" => header_search_paths,
11+
"OTHER_CPLUSPLUSFLAGS" => other_cflags,
12+
"CLANG_CXX_LANGUAGE_STANDARD" => "c++17"

0 commit comments

Comments
 (0)