xcode 构建失败:错误:生成目录文件存在
声明:本页面是StackOverFlow热门问题的中英对照翻译,遵循CC BY-SA 4.0协议,如果您需要使用它,必须同样遵循CC BY-SA许可,注明原文地址和作者信息,同时你必须将它归于原作者(不是我):StackOverFlow
原文地址: http://stackoverflow.com/questions/27085003/
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
Build Failed: error: make directory File exists
提问by Backstage Apps
I have an app in the app store and have built and released several updates without issue. I am working on a major update, but having a significant error that I have been Googling for over a week now.
我在应用程序商店中有一个应用程序,并且已经构建并发布了几个没有问题的更新。我正在进行重大更新,但有一个重大错误,我已经使用谷歌搜索了一个多星期。
I can build the app for the simulator, but when I try to build for iOS device (such as with my iPhone 6 plugged in) or Archive (so that I can distribute via TestFlight), I get the same error every time. Full error posted below.
我可以为模拟器构建应用程序,但是当我尝试为 iOS 设备(例如插入我的 iPhone 6)或存档(以便我可以通过 TestFlight 分发)构建应用程序时,我每次都会遇到相同的错误。下面发布了完整的错误。
Things I have tried:
我尝试过的事情:
- Cleaning the Project
- Restarting xCode
- Restarting my Mac - Deleting the Derived Data folder
- Updating xCode
- Deleting and Reinstalling xCode
- 清理项目
- 重新启动 xCode
- 重新启动我的 Mac - 删除派生数据文件夹
- 更新 xCode
- 删除和重新安装 xCode
The actual error received is:
收到的实际错误是:
CpResource Libraries/AppIRater/en.lproj /Users/terrencewilliams/Library/Developer/Xcode/DerivedData/SMBox-gbfftxbyzlmadeazsrisoquokaxr/Build/Intermediates/ArchiveIntermediates/SMBox/InstallationBuildProductsLocation/Applications/SMBox.app/en.lproj cd "/Users/terrencewilliams/Desktop/APP/SMBox/APP Builds - v.2.0/SMBox2 4" export PATH="/Applications/Xcode.app/Contents/Developer/Platforms/iPhoneOS.platform/Developer/usr/bin:/Applications/Xcode.app/Contents/Developer/usr/bin:/usr/bin:/bin:/usr/sbin:/sbin" builtin-copy -exclude .DS_Store -exclude CVS -exclude .svn -exclude .git -exclude .hg -strip-debug-symbols -strip-tool /Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/bin/strip -resolve-src-symlinks /Users/terrencewilliams/Desktop/APP/SMBox/APP\ Builds\ -\ v.2.0/SMBox2\ 4/Libraries/AppIRater/en.lproj /Users/terrencewilliams/Library/Developer/Xcode/DerivedData/SMBox-gbfftxbyzlmadeazsrisoquokaxr/Build/Intermediates/ArchiveIntermediates/SMBox/InstallationBuildProductsLocation/Applications/SMBox.app
error: make directory /Users/terrencewilliams/Library/Developer/Xcode/DerivedData/SMBox-gbfftxbyzlmadeazsrisoquokaxr/Build/Intermediates/ArchiveIntermediates/SMBox/InstallationBuildProductsLocation/Applications/SMBox.app/en.lproj: File exists
CpResource Libraries/AppIRater/en.lproj /Users/terrencewilliams/Library/Developer/Xcode/DerivedData/SMBox-gbfftxbyzlmadeazsrisoquokaxr/Build/Intermediates/ArchiveIntermediates/SMBox/InstallationBuildProductsLocation/Applications/SMBox.app/en.l /Desktop/APP/SMBox/APP Builds - v.2.0/SMBox2 4" export PATH="/Applications/Xcode.app/Contents/Developer/Platforms/iPhoneOS.platform/Developer/usr/bin:/Applications/Xcode.app /Contents/Developer/usr/bin:/usr/bin:/bin:/usr/sbin:/sbin" builtin-copy -exclude .DS_Store -exclude CVS -exclude .svn -exclude .git -exclude .hg -strip- debug-symbols -strip-tool /Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/bin/strip -resolve-src-symlinks /Users/terrencewilliams/Desktop/APP/SMBox/APP\ Builds\ -\ v.2。0/SMBox2\ 4/Libraries/AppIRater/en.lproj /Users/terrencewilliams/Library/Developer/Xcode/DerivedData/SMBox-gbfftxbyzlmadeazsrisoquokaxr/Build/Intermediates/ArchiveIntermediates/SMBox/InstallationBuildProductsBoxLocation/Applications/SMBox
错误:制作目录/Users/terrencewilliams/Library/Developer/Xcode/DerivedData/SMBox-gbfftxbyzlmadeazsrisoquokaxr/Build/Intermediates/ArchiveIntermediates/SMBox/InstallationBuildProductsLocation/Applications/SMBox.app/en.lproj:文件存在
I really need to get this update rolling, but can't seem to actually build it. Can anyone advise if there might be some underlying cause that I don't see relating to the derived data folder?
我真的需要让这个更新滚动,但似乎无法真正构建它。任何人都可以建议是否可能存在一些我没有看到与派生数据文件夹相关的潜在原因?
回答by vikas chandra
I solved this problem by removing duplicate bundle from my project which I have added from other source. Look for duplicate copy of en.lproj and remove it this might solve ur problem.
我通过从我从其他来源添加的项目中删除重复的包来解决这个问题。查找 en.lproj 的重复副本并将其删除,这可能会解决您的问题。
回答by JAL
My issue was due to a merge conflict I had the same dynamic framework in "Embedded Binaries" listed twice. Removing the duplicate framework allowed me to build successfully.
我的问题是由于合并冲突我在“嵌入式二进制文件”中列出了相同的动态框架两次。删除重复的框架使我能够成功构建。
回答by Jeremy Huddleston Sequoia
This path exists as a file (whereas itthe build is trying to create a directory): /Users/terrencewilliams/Library/Developer/Xcode/DerivedData/SMBox-gbfftxbyzlmadeazsrisoquokaxr/Build/Intermediates/ArchiveIntermediates/SMBox/InstallationBuildProductsLocation/Applications/SMBox.app/en.lproj
此路径作为文件存在(而它正在尝试创建一个目录):/Users/terrencewilliams/Library/Developer/Xcode/DerivedData/SMBox-gbfftxbyzlmadeazsrisoquokaxr/Build/Intermediates/ArchiveIntermediates/SMBox/InstallationBuildProductsLocation/Applications/SMBox.app。 /en.lproj
I suggest you just delete /Users/terrencewilliams/Library/Developer/Xcode/DerivedData and rebuild.
我建议你删除 /Users/terrencewilliams/Library/Developer/Xcode/DerivedData 并重建。
Yes, I realize you said you deleted the DerivedData folder already. Did you really delete thatone? If so, what is creating the en.lproj? You might want to just search through the build log for it.
是的,我知道你说你已经删除了 DerivedData 文件夹。你真的删了那个吗?如果是这样,什么是创建 en.lproj?您可能只想在构建日志中搜索它。