我正在使用react-native-maps,並試圖使用Google Maps for iOS,並且我遵循https://github.com/airbnb/react-native-maps/issues/693的上述說明來執行此操作,因此我從pod安裝中收到錯誤:運行pod安裝後無法找到目標文件
無法找到一個名爲AirMapsExplorer
這裏的目標是podfile我有
# You Podfile should look similar to this file. React Native currently does not support use_frameworks!
source 'https://github.com/CocoaPods/Specs.git'
platform :ios, '8.0'
# Change 'AirMapsExplorer' to match the target in your Xcode project.
target 'AirMapsExplorer' do
pod 'Yoga', :path => '../../node_modules/react-native/ReactCommon/yoga/Yoga.podspec'
pod 'React', path: '../../node_modules/react-native', :subspecs => [
'Core',
'RCTActionSheet',
'RCTAnimation',
'RCTGeolocation',
'RCTImage',
'RCTLinkingIOS',
'RCTNetwork',
'RCTSettings',
'RCTText',
'RCTVibration',
'RCTWebSocket',
'BatchedBridge'
]
pod 'GoogleMaps' # <~~ remove this line if you do not want to support GoogleMaps on iOS
pod 'react-native-maps', path: '../../'
pod 'react-native-google-maps', path: '../../' # <~~ if you need GoogleMaps support on iOS
end
post_install do |installer|
installer.pods_project.targets.each do |target|
if target.name == "react-native-google-maps"
target.build_configurations.each do |config|
config.build_settings['CLANG_ENABLE_MODULES'] = 'No'
end
end
end
end
我再重新啓動我的設備(2次了)刪除莢文件夾和podfile,按照說明操作,得到同樣的錯誤。我甚至嘗試做乾淨的生成和乾淨的文件夾仍然無濟於事。
任何人都有這個錯誤或遇到一種方法來解決,如果你碰到這個。我不會經常使用xcode,因爲我正在使用React Native進行構建,並且儘量不使用xcode,除非我絕對需要iOS。
如果還有其他事情要我顯示,我將幫助調試此問題。謝謝
你以前用過cocoapods嗎? –