2013-09-16 28 views
1

我得到綁在Xcode在設備上運行的應用程序時,這個錯誤5不能Exec的「協同設計」(沒有這樣的文件或目錄)

這裏是完整的錯誤

CodeSign /Users/Nevo/Library/Developer/Xcode/DerivedData/RecipesBook-efcrcmgnkaitsqaxahtumfbdxtmb/Build/Products/Debug-iphoneos/RecipesBook.app 
    cd "/Users/Nevo/Desktop/RecipesBook for ios 7 and 6" 
    setenv CODESIGN_ALLOCATE "/Applications/Xcode 2.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/bin/codesign_allocate" 
    setenv PATH "/Applications/Xcode 2.app/Contents/Developer/Platforms/iPhoneOS.platform/Developer/usr/bin:/Applications/Xcode 2.app/Contents/Developer/usr/bin‭:‬‭/‬usr/bin‭:/‬bin‭:/‬usr/sbin‭:/‬sbin" 
    Using code signing identity "iPhone Distribution: Shay Shalev (QN94KCWC64)" and provisioning profile "ProfileRecipeBook" (52D189D8-2FFD-4939-A3C6-1CD1F8B645E0) 
    codesign --force --sign 4F0E5397A87B47EE07EC3288681661CBCBB4781C --resource-rules=/Users/Nevo/Library/Developer/Xcode/DerivedData/RecipesBook-efcrcmgnkaitsqaxahtumfbdxtmb/Build/Products/Debug-iphoneos/RecipesBook.app/ResourceRules.plist --entitlements /Users/Nevo/Library/Developer/Xcode/DerivedData/RecipesBook-efcrcmgnkaitsqaxahtumfbdxtmb/Build/Intermediates/RecipesBook.build/Debug-iphoneos/RecipesBook.build/RecipesBook.xcent /Users/Nevo/Library/Developer/Xcode/DerivedData/RecipesBook-efcrcmgnkaitsqaxahtumfbdxtmb/Build/Products/Debug-iphoneos/RecipesBook.app 

error: can't exec 'codesign' (No such file or directory) 
+0

我有這個相同的錯誤,你有沒有找到?看起來像一個路徑問題。 –

+0

複製更多信息http://stackoverflow.com/questions/18838378/xcode-5-error-cant-exec-codesign-no-such-file-or-directory –

+1

我看到你有一個空間在你的Xcode應用程序的名稱。有些腳本很難處理空格,所​​以我建議刪除它。我不知道這是不是真的導致了這個問題,但它值得一試。 – BergQuester

回答

0

解決我的問題,感謝您的幫助。問題出在我的路上。我通過/etc/launchd.conf設置了自己的路徑,並且我瘋狂地試圖通過〜/ .bashrc等來編輯我的路徑。確保/ usr/bin位於xcode啓動的路徑中。此頁面提醒我: http://overwatering.org/blog/2012/08/setting-path-osx-mountain-lion/

+1

你能解釋一下這個鏈接是如何爲你工作的嗎?我得到:setenv:命令沒有找到 –

+0

你不能在終端運行setenv,你需要確保你的路徑包含codesign。運行「哪個codeign」,然後確保你的$ PATH包括那個。 –

+0

這是我做了什麼,,代碼 /usr/bin/codesign Abdullahs-MacBook-Pro:〜abdullahumer $ cat $ PATH cat:/ usr/bin:/ bin:/ usr/sbin:/ sbin:/ usr/local/bin:沒有這個文件或目錄 Abdullahs-MacBook-Pro:〜abdullahumer $ PATH = $ PATH:/ usr/bin/codesign Abdullahs-MacBook-Pro:〜abdullahumer $ cat $ PATH cat:/ usr/bin:/ bin:/ usr/sbin:/ sbin:/ usr/local/bin:/ usr/bin/codesign:沒有這樣的文件或目錄 –

5

我從/usr/bin/ 到複製codesign/Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/u‌​sr/bin

,它爲我工作。

相關問題