1require_relative './podfile_helpers.rb' 2require File.join(File.dirname(`node --print "require.resolve('react-native/package.json')"`), "scripts/react_native_pods") 3require File.join(File.dirname(`node --print "require.resolve('expo/package.json')"`), "scripts/autolinking") 4 5install! 'cocoapods', 6 :generate_multiple_pod_projects => true, 7 :incremental_installation => true 8platform :ios, '12.0' 9inhibit_all_warnings! 10 11# Disable expo-updates auto create manifest in podspec script_phase 12$expo_updates_create_manifest = false 13 14abstract_target 'Expo Go' do 15 # Expo Client dependencies 16 pod 'Amplitude' 17 pod 'CocoaLumberjack', '~> 3.5.3' 18 pod 'GoogleMaps', '~> 3.6' 19 pod 'Google-Maps-iOS-Utils', '~> 2.1.0' 20 pod 'JKBigInteger', :podspec => 'vendored/common/JKBigInteger.podspec.json' 21 pod 'MBProgressHUD', '~> 1.2.0' 22 23 # Expo modules 24 use_expo_modules!({ 25 exclude: [ 26 'expo-module-template', 27 'expo-in-app-purchases' 28 ], 29 # Modules for which to include Tests subspec 30 tests: [ 31 'expo-modules-core', 32 'expo-updates', 33 'expo-manifests', 34 'expo-json-utils', 35 'expo-structured-headers', 36 ], 37 flags: { 38 :inhibit_warnings => false 39 } 40 }) 41 42 # Expo modules that are not unimodules 43 pod 'EXRandom', path: '../packages/expo-random/ios' 44 45 # Install vendored pods. 46 use_pods! 'vendored/unversioned/**/*.podspec.json' 47 48 # Unversioned React Native 49 use_react_native! path: '../react-native-lab/react-native' 50 51 # Build React Native with RCT_DEV enabled and RCT_ENABLE_INSPECTOR and 52 # RCT_ENABLE_PACKAGER_CONNECTION disabled 53 post_install do |installer| 54 # Disabled as of CocoaPods 1.8.0.beta1 since pods_project seems to be nil 55 # installer.pods_project.main_group.tab_width = '2'; 56 # installer.pods_project.main_group.indent_width = '2'; 57 58 installer.target_installation_results.pod_target_installation_results 59 .each do |pod_name, target_installation_result| 60 61 # Run postinstalls actions for versioned dependencies. 62 # These actions are specified in `versioned-react-native/ABI*/postinstalls.rb` files. 63 run_versioned_postinstalls!(pod_name, target_installation_result) 64 65 target_installation_result.native_target.build_configurations.each do |config| 66 config.build_settings['IPHONEOS_DEPLOYMENT_TARGET'] = '12.0' 67 68 # Fix building failures on M1 69 config.build_settings['EXCLUDED_ARCHS[sdk=iphonesimulator*]'] = 'arm64' 70 end 71 72 if pod_name == 'Branch' 73 target_installation_result.native_target.build_configurations.each do |config| 74 config.build_settings['GCC_PREPROCESSOR_DEFINITIONS'] ||= ['$(inherited)'] 75 config.build_settings['GCC_PREPROCESSOR_DEFINITIONS'] << 'BRANCH_EXCLUDE_IDFA_CODE=1' 76 end 77 end 78 79 # Build React Native with RCT_DEV enabled and RCT_ENABLE_INSPECTOR and 80 # RCT_ENABLE_PACKAGER_CONNECTION disabled 81 next unless pod_name.start_with?('React') 82 target_installation_result.native_target.build_configurations.each do |config| 83 config.build_settings['GCC_PREPROCESSOR_DEFINITIONS'] ||= ['$(inherited)'] 84 config.build_settings['GCC_PREPROCESSOR_DEFINITIONS'] << 'RCT_DEV=1' 85 config.build_settings['GCC_PREPROCESSOR_DEFINITIONS'] << 'RCT_ENABLE_INSPECTOR=0' 86 config.build_settings['GCC_PREPROCESSOR_DEFINITIONS'] << 'ENABLE_PACKAGER_CONNECTION=0' 87 end 88 end 89 end 90 91 # Target for development, contains only unversioned code 92 target 'Expo Go (unversioned)' do 93 end 94 95 # Release target additionally includes versioned SDKs 96 target 'Expo Go (versioned)' do 97 # Evaluate all files matching `versioned-react-native/ABI*/dependencies.rb` glob pattern 98 # and install ReactABIXX_0_0 pods with all versioned unimodules. 99 use_versioned_abis! 100 end 101 102 # Test targets 103 target 'ExponentIntegrationTests' do 104 inherit! :search_paths 105 end 106 107 target 'Tests' do 108 inherit! :search_paths 109 110 pod 'Quick', :podspec => './Quick.podspec' 111 pod 'Nimble', :podspec => './Nimble.podspec' 112 end 113end 114