onnxruntime/js/react_native/e2e/ios/Podfile
Changming Sun 3328eb3bb3
Update min iOS version to 15.1 to align with React Native 0.76 (#23292)
Update min iOS version to 15.1 to align with React Native 0.76. We need
to update React Native .
See
https://github.com/react-native-community/discussions-and-proposals/discussions/812
for background.

Similar to PR  #20773
2025-01-08 16:02:45 -08:00

39 lines
1.3 KiB
Ruby

require_relative '../node_modules/react-native/scripts/react_native_pods'
require_relative '../node_modules/@react-native-community/cli-platform-ios/native_modules'
platform :ios, '15.1'
pre_install do |installer|
# Custom pre-install script or commands
puts "Running pre-install script..."
# Recommended fix for https://github.com/facebook/react-native/issues/32483
# from https://github.com/facebook/react-native/issues/32483#issuecomment-966784501
system("sed -i '' 's/typedef uint8_t clockid_t;//' \"./Pods/RCT-Folly/folly/portability/Time.h\"")
end
target 'OnnxruntimeModuleExample' do
config = use_native_modules!
use_react_native!(:path => config["reactNativePath"])
use_frameworks!
ort_c_local_pod_path = ENV['ORT_C_LOCAL_POD_PATH']
if ort_c_local_pod_path != nil
print 'Using onnxruntime-c pod at ', ort_c_local_pod_path, "\n"
pod 'onnxruntime-c', :path => ort_c_local_pod_path
end
pod 'onnxruntime-react-native', :path => '../node_modules/onnxruntime-react-native'
inherit! :search_paths
end
post_install do |installer|
installer.generated_projects.each do |project|
project.targets.each do |target|
target.build_configurations.each do |config|
config.build_settings['IPHONEOS_DEPLOYMENT_TARGET'] = '15.1'
end
end
end
end