Xcode 4 上的权限被拒绝

声明:本页面是StackOverFlow热门问题的中英对照翻译,遵循CC BY-SA 4.0协议,如果您需要使用它,必须同样遵循CC BY-SA许可,注明原文地址和作者信息,同时你必须将它归于原作者(不是我):StackOverFlow 原文地址: http://stackoverflow.com/questions/8109468/
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

提示:将鼠标放在中文语句上可以显示对应的英文。显示中英文
时间:2020-09-14 22:24:26  来源:igfitidea点击:

Permission Denied on Xcode 4

iphonexcodexcode4permissionsdenied

提问by nickj890

I'm getting error message about permission denied, when I build any app on Xcode 4:

当我在 Xcode 4 上构建任何应用程序时,我收到有关权限被拒绝的错误消息:

error: unable to create '/Users/mike/Library/Developer/Xcode/DerivedData/JewBack-ejcsrvhiqaxnzmdheqdhshjvwjng/Build/Products' (Permission denied)

错误:无法创建“/Users/mike/Library/Developer/Xcode/DerivedData/JewBack-ejcsrvhiqaxnzmdheqdhshjvwjng/Build/Products”(权限被拒绝)

There's other error message, too:

还有其他错误消息:

Check dependencies ProcessInfoPlistFile /Users/mike/Library/Developer/Xcode/DerivedData/JewBack-ejcsrvhiqaxnzmdheqdhshjvwjng/Build/Products/Debug-iphonesimulator/JewBack.app/Info.plist JewBack-Info.plist cd /Users/mike/Downloads/JewBack setenv PATH "/Developer/Platforms/iPhoneSimulator.platform/Developer/usr/bin:/Developer/usr/bin:/usr/bin:/bin:/usr/sbin:/sbin" builtin-infoPlistUtility JewBack-Info.plist -genpkginfo /Users/mike/Library/Developer/Xcode/DerivedData/JewBack-ejcsrvhiqaxnzmdheqdhshjvwjng/Build/Products/Debug-iphonesimulator/JewBack.app/PkgInfo -expandbuildsettings -format binary -platform iphonesimulator -o /Users/mike/Library/Developer/Xcode/DerivedData/JewBack-ejcsrvhiqaxnzmdheqdhshjvwjng/Build/Products/Debug-iphonesimulator/JewBack.app/Info.plist error: couldn't create directory /Users/mike/Library/Developer/Xcode/DerivedData/JewBack-ejcsrvhiqaxnzmdheqdhshjvwjng/Build/Products/Debug-iphonesimulator/JewBack.app: Permission deniederror: couldn't create directory /Users/mike/Library/Developer/Xcode/DerivedData/JewBack-ejcsrvhiqaxnzmdheqdhshjvwjng/Build/Products/Debug-iphonesimulator/JewBack.app: Permission deniederror: The file “Info.plist” doesn't exist.

检查依赖关系 ProcessInfoPlistFile /Users/mike/Library/Developer/Xcode/DerivedData/JewBack-ejcsrvhiqaxnzmdheqdhshjvwjng/Build/Products/Debug-iphonesimulator/JewBack.app/Info.plist JewBack-Info.plist cd /Users/mike/Downloads/J路径“/Developer/Platforms/iPhoneSimulator.platform/Developer/usr/bin:/Developer/usr/bin:/usr/bin:/bin:/usr/sbin:/sbin” builtin-infoPlistUtility JewBack-Info.plist -genpkginfo /Users/mike/Library/Developer/Xcode/DerivedData/JewBack-ejcsrvhiqaxnzmdheqdhshjvwjng/Build/Products/Debug-iphonesimulator/JewBack.app/PkgInfo -expandbuildsettings -format binary -platform iphonesimulator -o /Users/mike/Library/Developer /DerivedData/JewBack-ejcsrvhiqaxnzmdheqdhshjvwjng/Build/Products/Debug-iphonesimulator/JewBack.app/Info.plist 错误:不能't 创建目录 /Users/mike/Library/Developer/Xcode/DerivedData/JewBack-ejcsrvhiqaxnzmdheqdhshjvwjng/Build/Products/Debug-iphonesimulator/JewBack.app: Permission deniederror: 无法创建目录 /Users/mike/Library/Developer/Xcode /DerivedData/JewBack-ejcsrvhiqaxnzmdheqdhshjvwjng/Build/Products/Debug-iphonesimulator/JewBack.app:权限被拒绝错误:文件“Info.plist”不存在。

回答by DShah

Ok. It seems you may be restricted to create Build Folder in your system. Try out the procedure below which creates a Build Folder in project folder itself.

好的。似乎您可能被限制在您的系统中创建构建文件夹。试试下面的过程,在项目文件夹本身中创建一个构建文件夹。

In Xcdemenu bar go to: Preferences> LocationsTab. In Locationschange Derived Datato Relativeand set any name in the text box. I have used "Build". This folder will be created in your project folder for built binaries.

Xcde菜单栏中转到:首选项> 位置选项卡。在Locations中将Derived Data更改为Relative并在文本框中设置任何名称。我用过“构建”。此文件夹将在您的项目文件夹中为构建的二进制文件创建。

回答by TMD

please check your Xcode version and upgrade your Xcode. early I was using Xcode 6.1 and I got error message with that Xcode version after then I upgrade Xcode Version 6.2. now It is working perfectly. when you upgrade your OS X version You should upgrade Xcode version.

请检查您的 Xcode 版本并升级您的 Xcode。早期我使用 Xcode 6.1,然后我升级 Xcode 版本 6.2 后,我收到了该 Xcode 版本的错误消息。现在它运行良好。当您升级 OS X 版本时,您应该升级 Xcode 版本。