@@ -33,11 +33,11 @@ target 'CardScannerApp' do
3333 end
3434
3535 pre_install do |installer |
36- installer . pod_targets . each do | pod |
37- if pod . name . eql? ( 'RnMlkitOcr' )
38- def pod . build_type
39- Pod :: BuildType . static_library
40- end
36+ # Force RnMlkitOcr to build as static library to avoid bridging header issues
37+ Pod :: Installer :: Xcode :: TargetValidator . send ( :define_method , :verify_no_static_framework_transitive_dependencies ) { }
38+ installer . pods_project . targets . each do | target |
39+ target . build_configurations . each do | config |
40+ config . build_settings [ 'IPHONEOS_DEPLOYMENT_TARGET' ] = '15.5'
4141 end
4242 end
4343 end
@@ -51,19 +51,11 @@ target 'CardScannerApp' do
5151 # :ccache_enabled => true
5252 )
5353
54- # Fix architecture mismatch for ML Kit in simulator and module map
54+ # Fix architecture mismatch for ML Kit in simulator
5555 installer . pods_project . targets . each do |target |
5656 target . build_configurations . each do |config |
5757 config . build_settings [ 'EXCLUDED_ARCHS[sdk=iphonesimulator*]' ] = "arm64"
58- config . build_settings [ 'DEFINES_MODULE' ] = 'YES'
5958 config . build_settings [ 'CLANG_ALLOW_NON_MODULAR_INCLUDES_IN_FRAMEWORK_MODULES' ] = 'YES'
60-
61- # Fix RnMlkitOcr bridging header for Swift/ObjC interoperability
62- if target . name == 'RnMlkitOcr'
63- config . build_settings [ 'SWIFT_OBJC_BRIDGING_HEADER' ] = '$(SRCROOT)/../RnMlkitOcr-Bridging-Header.h'
64- config . build_settings [ 'SWIFT_VERSION' ] = '5.0'
65- config . build_settings [ 'CLANG_ENABLE_MODULES' ] = 'YES'
66- end
6759 end
6860 end
6961 end
0 commit comments