美文网首页
Multiple commands produce '/xxx/

Multiple commands produce '/xxx/

作者: 悟饭哪 | 来源:发表于2021-05-09 15:53 被阅读0次

新建 iOS 项目时,一般会把 info.plist 文件从根目录中移到 SupportingFiles 目录中,这时编译项目时会报错

Multiple commands produce '/Users/david/Library/Developer/Xcode/DerivedData/xxxx-drkfpinemltwfnfqvyvovrozfaci/Build/Products/Debug-iphonesimulator/xxx.app/Info.plist':
1) Target 'xxxx' (project 'xxxx') has copy command from '/Users/david/david/myprojects/xxx/xxx/xxxx/SupportingFiles/Info.plist' to '/Users/david/Library/Developer/Xcode/DerivedData/xxxxx-drkfpinemltwfnfqvyvovrozfaci/Build/Products/Debug-iphonesimulator/xxxx.app/Info.plist'
2) Target 'xxxxx' (project 'xxxx') has process command with output '/Users/david/Library/Developer/Xcode/DerivedData/xxxx-drkfpinemltwfnfqvyvovrozfaci/Build/Products/Debug-iphonesimulator/xxxxx.app/Info.plist'
原因:

info.plist 的路径变了,编译器找不到了。

解决办法:

项目名 -> Build Settings -> 搜索 info.plist,找到 Packaging 下的Info.plist File,把路径改为正确的就行了,比如我的就是在原有路径中添加上 SupportingFiles 就可以了。
如图:

Have fun.

相关文章

网友评论

      本文标题:Multiple commands produce '/xxx/

      本文链接:https://www.haomeiwen.com/subject/gjeidltx.html