Skip to content

Commit

Permalink
feat: update podspec (#776)
Browse files Browse the repository at this point in the history
  • Loading branch information
vonovak authored Jun 27, 2023
1 parent fe9c2c6 commit bd9f363
Show file tree
Hide file tree
Showing 2 changed files with 375 additions and 25 deletions.
21 changes: 2 additions & 19 deletions RNDateTimePicker.podspec
Original file line number Diff line number Diff line change
@@ -1,7 +1,5 @@
require 'json'

fabric_enabled = ENV['RCT_NEW_ARCH_ENABLED'] == '1'

package = JSON.parse(File.read(File.join(__dir__, 'package.json')))

Pod::Spec.new do |s|
Expand All @@ -17,23 +15,8 @@ Pod::Spec.new do |s|
s.source_files = "ios/**/*.{h,m,mm,cpp}"
s.requires_arc = true

if fabric_enabled
folly_compiler_flags = '-DFOLLY_NO_CONFIG -DFOLLY_MOBILE=1 -DFOLLY_USE_LIBCPP=1 -Wno-comma -Wno-shorten-64-to-32'

s.compiler_flags = folly_compiler_flags + " -DRCT_NEW_ARCH_ENABLED=1"
s.pod_target_xcconfig = {
'HEADER_SEARCH_PATHS' => '"$(PODS_ROOT)/boost" "$(PODS_ROOT)/boost-for-react-native" "$(PODS_ROOT)/RCT-Folly"',
"CLANG_CXX_LANGUAGE_STANDARD" => "c++17"
}

s.dependency "React"
s.dependency "React-RCTFabric"
s.dependency "React-Codegen"
s.dependency "RCT-Folly"
s.dependency "RCTRequired"
s.dependency "RCTTypeSafety"
s.dependency "ReactCommon/turbomodule/core"

if ENV['RCT_NEW_ARCH_ENABLED'] == '1'
install_modules_dependencies(s)
else
s.exclude_files = "ios/fabric"

Expand Down
Loading

0 comments on commit bd9f363

Please sign in to comment.