Skip to content

Commit

Permalink
[RN][iOS] Improve Swift support for 3rd party libs (#42075)
Browse files Browse the repository at this point in the history
  • Loading branch information
cipolleschi authored Feb 16, 2024
1 parent c3fda24 commit 6939021
Show file tree
Hide file tree
Showing 4 changed files with 14 additions and 4 deletions.
3 changes: 2 additions & 1 deletion packages/react-native/ReactCommon/React-Fabric.podspec
Original file line number Diff line number Diff line change
Expand Up @@ -33,7 +33,8 @@ Pod::Spec.new do |s|
s.source = source
s.source_files = "dummyFile.cpp"
s.pod_target_xcconfig = { "USE_HEADERMAP" => "YES",
"CLANG_CXX_LANGUAGE_STANDARD" => "c++17" }
"CLANG_CXX_LANGUAGE_STANDARD" => "c++17",
"DEFINES_MODULE" => "YES" }

if ENV['USE_FRAMEWORKS']
s.header_mappings_dir = './'
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -27,7 +27,10 @@ Pod::Spec.new do |s|
s.source = source
s.source_files = "**/*.{cpp,h}"
s.header_dir = "react/debug"
s.pod_target_xcconfig = { "CLANG_CXX_LANGUAGE_STANDARD" => "c++17" }
s.pod_target_xcconfig = {
"CLANG_CXX_LANGUAGE_STANDARD" => "c++17",
"DEFINES_MODULE" => "YES"
}

if ENV['USE_FRAMEWORKS']
s.module_name = "React_debug"
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -49,7 +49,11 @@ Pod::Spec.new do |s|
header_search_paths = header_search_paths + ["\"$(PODS_TARGET_SRCROOT)/platform/ios\""]
end

s.pod_target_xcconfig = { "USE_HEADERMAP" => "NO", "HEADER_SEARCH_PATHS" => header_search_paths.join(" ") }
s.pod_target_xcconfig = {
"USE_HEADERMAP" => "NO",
"HEADER_SEARCH_PATHS" => header_search_paths.join(" "),
"DEFINES_MODULE" => "YES"
}

s.dependency "glog"
s.dependency "RCT-Folly/Fabric", folly_version
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -44,7 +44,9 @@ Pod::Spec.new do |s|
s.exclude_files = "tests"
s.pod_target_xcconfig = {
"CLANG_CXX_LANGUAGE_STANDARD" => "c++17",
"HEADER_SEARCH_PATHS" => header_search_paths.join(' ')}
"HEADER_SEARCH_PATHS" => header_search_paths.join(' '),
"DEFINES_MODULE" => "YES"
}

if ENV['USE_FRAMEWORKS']
s.module_name = "React_utils"
Expand Down

0 comments on commit 6939021

Please sign in to comment.