Xcode 8无法归档“Command / usr / bin / codesign失败,退出代码为1”。

编程入门 行业动态 更新时间:2024-10-17 02:46:06
本文介绍了Xcode 8无法归档“Command / usr / bin / codesign失败,退出代码为1”。的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧! 问题描述

我在macOS Sierra上的Xcode 8上遇到了严重的问题。 当我尝试构建我的应用时,我遇到以下问题。

I've got a serious problem on Xcode 8 on macOS Sierra. when I try to build my app, I get the following issue.

CodeSign /Users/me/Library/Developer/Xcode/DerivedData/MyApp-gnoiiwnelmxzdidnijaswisrwdqe/Build/Products/Debug-iphonesimulator/MyApp.app cd /Users/me/Desktop/MyAppFolder1/MyAppFolder2/MyAppxcode export CODESIGN_ALLOCATE=/Users/me/Downloads/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/bin/codesign_allocate export PATH="/Users/me/Downloads/Xcode.app/Contents/Developer/Platforms/iPhoneSimulator.platform/Developer/usr/bin:/Users/me/Downloads/Xcode.app/Contents/Developer/usr/bin:/usr/local/bin:/usr/bin:/bin:/usr/sbin:/sbin" Signing Identity: "-" /usr/bin/codesign --force --sign - --timestamp=none /Users/me/Library/Developer/Xcode/DerivedData/MyApp-gnoiiwnelmxzdidnijaswisrwdqe/Build/Products/Debug-iphonesimulator/MyApp.app /Users/me/Library/Developer/Xcode/DerivedData/MyApp-gnoiiwnelmxzdidnijaswisrwdqe/Build/Products/Debug-iphonesimulator/MyApp.app: resource fork, Finder information, or similar detritus not allowed Command /usr/bin/codesign failed with exit code 1

然后我确实 forums.developer.apple/thread / 48905 在终端中如下并且有效。但是一旦我清理,问题就会回来。

then I did forums.developer.apple/thread/48905 in the terminal as the following and it worked. but once I clean, the issue comes back.

cd /Users/me/Library/Developer/Xcode/DerivedData/MyApp-gnoiiwnelmxzdidnijaswisrwdqe/Build/Products/Debug-iphonesimulator/MyApp ls -al@ * xattr -c *

此解决方案不适用于存档,但存在以下问题。是有它的任何解决方案?

and this solution doesn't work for archive with the following issue. is there any solution for it?

CodeSign /Users/me/Library/Developer/Xcode/DerivedData/MyApp-gnoiiwnelmxzdidnijaswisrwdqe/Build/Intermediates/ArchiveIntermediates/MyApp/InstallationBuildProductsLocation/Applications/MyApp.app cd /Users/me/Desktop/MyAppFolder1/MyAppFolder2/MyAppxcode export CODESIGN_ALLOCATE=/Users/me/Downloads/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/bin/codesign_allocate export PATH="/Users/me/Downloads/Xcode.app/Contents/Developer/Platforms/iPhoneOS.platform/Developer/usr/bin:/Users/me/Downloads/Xcode.app/Contents/Developer/usr/bin:/usr/local/bin:/usr/bin:/bin:/usr/sbin:/sbin" Signing Identity: "iPhone Developer: My Name (**********)" Provisioning Profile: "iOS Team Provisioning Profile: com.**********.*********" (********-****-****-****-************) /usr/bin/codesign --force --sign **************************************** --entitlements /Users/me/Library/Developer/Xcode/DerivedData/MyApp-gnoiiwnelmxzdidnijaswisrwdqe/Build/Intermediates/ArchiveIntermediates/MyApp/IntermediateBuildFilesPath/MyApp.build/Release-iphoneos/MyApp.build/MyApp.app.xcent --timestamp=none /Users/me/Library/Developer/Xcode/DerivedData/MyApp-gnoiiwnelmxzdidnijaswisrwdqe/Build/Intermediates/ArchiveIntermediates/MyApp/InstallationBuildProductsLocation/Applications/MyApp.app /Users/me/Library/Developer/Xcode/DerivedData/MyApp-gnoiiwnelmxzdidnijaswisrwdqe/Build/Intermediates/ArchiveIntermediates/MyApp/InstallationBuildProductsLocation/Applications/MyApp.app: resource fork, Finder information, or similar detritus not allowed Command /usr/bin/codesign failed with exit code 1

推荐答案

我在Apple论坛找到了这个解决方案

I found this solution in the Apple forum

cd ~/Library/Developer/Xcode/DerivedData xattr -rc .

xattr -rc ~/Library/Developer/Xcode/DerivedData

更多推荐

Xcode 8无法归档“Command / usr / bin / codesign失败,退出代码为1”。

本文发布于:2023-11-26 13:40:30,感谢您对本站的认可!
本文链接:https://www.elefans.com/category/jswz/34/1634037.html
版权声明:本站内容均来自互联网,仅供演示用,请勿用于商业和其他非法用途。如果侵犯了您的权益请与我们联系,我们将在24小时内删除。
本文标签:代码   Command   Xcode   usr   codesign

发布评论

评论列表 (有 0 条评论)
草根站长

>www.elefans.com

编程频道|电子爱好者 - 技术资讯及电子产品介绍!