gpt4 book ai didi

react-native - Xcode 12 部署警告 'IPHONEOS_DEPLOYMENT_TARGET'

转载 作者:行者123 更新时间:2023-12-02 02:33:24 25 4
gpt4 key购买 nike

我安装了react-native-maps并开始收到以下警告:

warning: The iOS Simulator deployment target'IPHONEOS_DEPLOYMENT_TARGET' is set to 8.0, but the range of supporteddeployment target versions is 9.0 to 14.1.99. (in target 'Flipper'from project 'Pods') warning: The iOS Simulator deployment target'IPHONEOS_DEPLOYMENT_TARGET' is set to 7.0, but the range of supporteddeployment target versions is 9.0 to 14.1.99. (in target'Google-Maps-iOS-Utils' from project 'Pods') warning: The iOSSimulator deployment target 'IPHONEOS_DEPLOYMENT_TARGET' is set to8.0, but the range of supported deployment target versions is 9.0 to 14.1.99. (in target 'react-native-google-maps' from project 'Pods')

我看到了一些在线建议,如下所示:

post_install do |installer|
installer.pods_project.targets.each do |target|
target.build_configurations.each do |config|
config.build_settings['DEBUG_INFORMATION_FORMAT'] = 'dwarf'
config.build_settings.delete 'IPHONEOS_DEPLOYMENT_TARGET'
config.build_settings['ONLY_ACTIVE_ARCH'] = 'YES'
end
end
end

但是,我的 podfile 如下所示(这是我安装 React-native 时的样子)

require_relative '../node_modules/react-native/scripts/react_native_pods'
require_relative '../node_modules/@react-native-community/cli-platform-ios/native_modules'

platform :ios, '10.0'

target 'allocentric' do
config = use_native_modules!

use_react_native!(:path => config["reactNativePath"])
# React Native Maps dependencies
rn_maps_path = '../node_modules/react-native-maps'
pod 'react-native-google-maps', :path => rn_maps_path
pod 'GoogleMaps'
pod 'Google-Maps-iOS-Utils'
pod 'RNVectorIcons', :path => '../node_modules/react-native-vector-icons'
target 'allocentricTests' do
inherit! :complete
# Pods for testing
end

# Enables Flipper.
#
# Note that if you have use_frameworks! enabled, Flipper will not work and
# you should disable these next few lines.
use_flipper!
post_install do |installer|
flipper_post_install(installer)
end
end

target 'allocentric-tvOS' do
# Pods for allocentric-tvOS

target 'allocentric-tvOSTests' do
inherit! :search_paths
# Pods for testing
end
end

我似乎无法运行“post_install”存在之前在线发布的解决方案,我已经尝试删除第一个 post_install 或将上述解决方案放入该 post_install 但都不起作用。

最佳答案

尝试在 pod 文件中添加此内容

post_install do |pi|
pi.pods_project.targets.each do |t|
t.build_configurations.each do |config|
config.build_settings['IPHONEOS_DEPLOYMENT_TARGET'] = '9.0'
end
end
end

引用号:Range-of-supported

关于react-native - Xcode 12 部署警告 'IPHONEOS_DEPLOYMENT_TARGET',我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/64707834/

25 4 0
Copyright 2021 - 2024 cfsdn All Rights Reserved 蜀ICP备2022000587号
广告合作:1813099741@qq.com 6ren.com