代码之家  ›  专栏  ›  技术社区  ›  Christopher Reid

XCode 9.2-iOS-存档生产应用程序在代码设计时失败,出现未知错误

  •  0
  • Christopher Reid  · 技术社区  · 8 年前

    就在几周前,我对存档和上传我的应用程序没有问题。现在我突然变得 /usr/bin/codesign failed with exit code 1 最令人不安的是,这就是原因:

    unknown error -1=ffffffffffffffff
    

    我见过的大多数有这个问题的人都有更有用的错误信息。也许苹果的系统发生了一些变化,因为我这边什么都没变,我所有的证书在明年之前都是好的。如有任何见解,将不胜感激。

    以下是完整的错误输出:

    CodeSign /Users/USERNAME/Library/Developer/Xcode/DerivedData/THE_APP-gmiiqepwfsfeorbketgcgewghlil/Build/Intermediates.noindex/ArchiveIntermediates/THE_APP/InstallationBuildProductsLocation/Applications/THE_APP.app
        cd /Users/USERNAME/ots/ios
        export CODESIGN_ALLOCATE=/Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/bin/codesign_allocate
        export PATH="/Applications/Xcode.app/Contents/Developer/Platforms/iPhoneOS.platform/Developer/usr/bin:/Applications/Xcode.app/Contents/Developer/usr/bin:/usr/local/bin:/usr/bin:/bin:/usr/sbin:/sbin"
    
    Signing Identity:     "iPhone Developer: ___________ (_________)"
    Provisioning Profile: "iOS Team Provisioning Profile: ______________"
                          (______________________)
    
        /usr/bin/codesign --force --sign XXXXXXXXXXXXXXXXXXXXXX--entitlements /Users/USERNAME/Library/Developer/Xcode/DerivedData/THE_APP-gmiiqepwfsfeorbketgcgewghlil/Build/Intermediates.noindex/ArchiveIntermediates/THE_APP/IntermediateBuildFilesPath/THE_APP.build/Release-iphoneos/THE_APP.build/THE_APP.app.xcent --timestamp=none /Users/USERNAME/Library/Developer/Xcode/DerivedData/THE_APP-gmiiqepwfsfeorbketgcgewghlil/Build/Intermediates.noindex/ArchiveIntermediates/THE_APP/InstallationBuildProductsLocation/Applications/THE_APP.app
    
    
    
    /Users/USERNAME/Library/Developer/Xcode/DerivedData/THE_APP-gmiiqepwfsfeorbketgcgewghlil/Build/Intermediates.noindex/ArchiveIntermediates/THE_APP/InstallationBuildProductsLocation/Applications/THE_APP.app: unknown error -1=ffffffffffffffff
    Command /usr/bin/codesign failed with exit code 1
    
    1 回复  |  直到 8 年前
        1
  •  0
  •   Christopher Reid    8 年前

    上周我更改了笔记本电脑的登录密码,这似乎就是codesign失败的原因。似乎xcode存储了我的旧密码,并试图将其与codesign一起使用,但最终失败了。

    我所做的是锁定所有钥匙链(登录打开)并更改密码。然后我关闭并重新打开xcode,这次它请求了我的钥匙链密码(以前没有),然后我就可以成功地存档我的应用程序了。