ios 错误:模块文件的最小部署目标是 ios8.3 v8.3
声明:本页面是StackOverFlow热门问题的中英对照翻译,遵循CC BY-SA 4.0协议,如果您需要使用它,必须同样遵循CC BY-SA许可,注明原文地址和作者信息,同时你必须将它归于原作者(不是我):StackOverFlow
原文地址: http://stackoverflow.com/questions/29307117/
Warning: these are provided under cc-by-sa 4.0 license. You are free to use/share it, But you must attribute it to the original authors (not me):
StackOverFlow
error: module file's minimum deployment target is ios8.3 v8.3
提问by Vatsal Manot
All attempts to import a dynamic framework in an Xcode playground yield the following error:
在 Xcode playground 中导入动态框架的所有尝试都会产生以下错误:
error: module file's minimum deployment target is ios8.3 v8.3
回答by alreadytaken
You might have created a target after updating Xcode, which made 8.3 the iOS Deployment Targetin Build Settings for that target.
您可能在更新 Xcode 后创建了一个目标,这使 8.3 成为该目标的构建设置中的iOS 部署目标。
I fixed this by:
我通过以下方式解决了这个问题:
- Setting the iOS Deployment Targetto 8.0 (Which is the same as the rest of the project)
- 将iOS 部署目标设置为 8.0(与项目的其余部分相同)
Note iOS version mismatch in this screenshot (one is 10.0, other is 9.3)
- Doing a clean (Command+Shift+k) and build
- 进行清理(Command+Shift+k)并构建
If a clean+build doesn't fix it, switching the device/simulator that you are deploying to from the scheme menu and building again should help.
如果 clean+build 没有修复它,从方案菜单切换您要部署到的设备/模拟器并再次构建应该会有所帮助。
回答by Vick Swift
This error might also crop up if you're unit testing. So in addition to what @Tony and @Allreadyhome has suggested, do the following:
如果您在进行单元测试,也可能会出现此错误。因此,除了@Tony 和@Allreadyhome 所建议的之外,请执行以下操作:
- With your test target selected, go to 'Build Settings'
- Search for 'iOS Deployment target' at the top search bar.
- Change the value for the iOS Deployment Target accordingly, (in the context of this question, you will change the deployment target to 8.0)
- 选择测试目标后,转到“构建设置”
- 在顶部搜索栏中搜索“iOS 部署目标”。
- 相应地更改 iOS 部署目标的值,(在此问题的上下文中,您将部署目标更改为 8.0)
And you should be good.
你应该很好。
回答by Allreadyhome
As mentioned by Tony you have to
正如托尼所说,你必须
1. Set the iOS Deployment Target to 8.0
1.设置iOS部署目标为8.0
If using Pods the further step you may need to do:
如果使用 Pods,您可能需要执行以下步骤:
2. Go into the Pods dependancies and change the deployment targets to 8.0 also.
2. 进入 Pods 依赖项并将部署目标也更改为 8.0。
In my case, I had to change the deployment target on each of my pods to 8.0 as they were all on 8.3.
就我而言,我必须将每个 pod 上的部署目标更改为 8.0,因为它们都在 8.3 上。
回答by Khuong
In your Pod File, just delete the comment at this line:
在您的 Pod 文件中,只需删除此行的注释:
platform :ios, '8.0'
It work for me.
它对我有用。
回答by Nianliang
I've encountered error:
我遇到了错误:
Module file's minimum deployment target is ios9.2 v9.2
After I changed the iOS deployment target to 8.0 for my PROJECT. The project is created by Xcode 7.2, with 'Include Unit Tests' and 'Include UI Tests' checked.
在我将项目的 iOS 部署目标更改为 8.0 之后。该项目由 Xcode 7.2创建,并选中“包含单元测试”和“包含 UI 测试”。
Because of the XCUIApplication() requires iOS 9.0+, to fix the error, just change the deployment target of UI Teststo 9.0 or above, and leaves 8.0 for other targets.
因为XCUIApplication()需要iOS 9.0+,修复这个错误,只需将UI Tests的部署目标改为9.0或以上,其他目标保留8.0。
回答by priya
1) Goto, Target -> General -> deployment Info
1) 转到,目标 -> 常规 -> 部署信息
2) set the deployment Target as the one being prompted in the error message(8.3 in your case).
2)将部署目标设置为错误消息中提示的目标(在您的情况下为8.3)。
3) product -> clean
3) 产品 -> 清洁
4) product -> Build
4) 产品 -> 构建
回答by anoo_radha
I had the same issue when i downloaded a framework tutorial with ios 12 & my sdk has to have ios 11.4. I set the iOS Deployment Target to the version I needed(11.4) and updated the Pods dependancies also. But missed a few. So, then I did a search with the version that i wanted to change (that is 12.0). It just lists everything that has the version number (target, project, podspec, pods). Changing everyone of those (to 11.4 in my case), solved it.
当我下载带有 ios 12 的框架教程时遇到了同样的问题,我的 sdk 必须有 ios 11.4。我将 iOS 部署目标设置为我需要的版本 (11.4) 并更新了 Pods 依赖项。但是漏了几个。所以,然后我搜索了我想要更改的版本(即 12.0)。它只列出所有具有版本号的内容(目标、项目、podspec、pods)。改变所有这些(在我的情况下为 11.4),解决了它。
回答by anoo_radha
I had this problem when the minimum deployment target of a select few dependencies was set to a more recent iOS version than main targets minimum deployment target.
I had this problem when the minimum deployment target of a select few dependencies was set to a more recent iOS version than main targets minimum deployment target.