尝试运行应用时找不到Xcode文件 [英] Xcode File not found while trying to run app

查看:105
本文介绍了尝试运行应用时找不到Xcode文件的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我在Xcode中遇到此错误,然后尝试运行我的应用程序

I'm Getting this error in Xcode then I try to run my app

Ld /Users/danielsorensen/Library/Developer/Xcode/DerivedData/Keyboard-cimemloksqjdnxhkdziqxwhxgwcg/Build/Products/Debug-iphonesimulator/KeyboardTests.xctest/KeyboardTests normal x86_64
    cd "/Users/danielsorensen/Downloads/codecanyon-9105493-color-keyboard-universal/Color Custom Keyboard"
    export IPHONEOS_DEPLOYMENT_TARGET=8.0
    export PATH="/Applications/Xcode.app/Contents/Developer/Platforms/iPhoneSimulator.platform/Developer/usr/bin:/Applications/Xcode.app/Contents/Developer/usr/bin:/usr/bin:/bin:/usr/sbin:/sbin"
    /Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/bin/clang -arch x86_64 -bundle -isysroot /Applications/Xcode.app/Contents/Developer/Platforms/iPhoneSimulator.platform/Developer/SDKs/iPhoneSimulator8.0.sdk -L/Users/danielsorensen/Library/Developer/Xcode/DerivedData/Keyboard-cimemloksqjdnxhkdziqxwhxgwcg/Build/Products/Debug-iphonesimulator -F/Users/danielsorensen/Library/Developer/Xcode/DerivedData/Keyboard-cimemloksqjdnxhkdziqxwhxgwcg/Build/Products/Debug-iphonesimulator -F/Applications/Xcode.app/Contents/Developer/Platforms/iPhoneSimulator.platform/Developer/SDKs/iPhoneSimulator8.0.sdk/Developer/Library/Frameworks -F/Applications/Xcode.app/Contents/Developer/Platforms/iPhoneSimulator.platform/Developer/Library/Frameworks -F/Applications/Xcode.app/Contents/Developer/Platforms/iPhoneSimulator.platform/Developer/SDKs/iPhoneSimulator8.0.sdk/Developer/Library/Frameworks -filelist /Users/danielsorensen/Library/Developer/Xcode/DerivedData/Keyboard-cimemloksqjdnxhkdziqxwhxgwcg/Build/Intermediates/Keyboard.build/Debug-iphonesimulator/KeyboardTests.build/Objects-normal/x86_64/KeyboardTests.LinkFileList -Xlinker -rpath -Xlinker @executable_path/Frameworks -Xlinker -rpath -Xlinker @loader_path/Frameworks -bundle_loader /Users/danielsorensen/Library/Developer/Xcode/DerivedData/Keyboard-cimemloksqjdnxhkdziqxwhxgwcg/Build/Products/Debug-iphonesimulator/Color\ Custom\ Keyboard.app/Color\ Custom\ Keyboard -Xlinker -objc_abi_version -Xlinker 2 -framework XCTest -L/Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/lib/swift/iphonesimulator -Xlinker -add_ast_path -Xlinker /Users/danielsorensen/Library/Developer/Xcode/DerivedData/Keyboard-cimemloksqjdnxhkdziqxwhxgwcg/Build/Intermediates/Keyboard.build/Debug-iphonesimulator/KeyboardTests.build/Objects-normal/x86_64/KeyboardTests.swiftmodule -mios-simulator-version-min=8.0 -Xlinker -dependency_info -Xlinker /Users/danielsorensen/Library/Developer/Xcode/DerivedData/Keyboard-cimemloksqjdnxhkdziqxwhxgwcg/Build/Intermediates/Keyboard.build/Debug-iphonesimulator/KeyboardTests.build/Objects-normal/x86_64/KeyboardTests_dependency_info.dat -o /Users/danielsorensen/Library/Developer/Xcode/DerivedData/Keyboard-cimemloksqjdnxhkdziqxwhxgwcg/Build/Products/Debug-iphonesimulator/KeyboardTests.xctest/KeyboardTests

ld: file not found: /Users/danielsorensen/Library/Developer/Xcode/DerivedData/Keyboard-cimemloksqjdnxhkdziqxwhxgwcg/Build/Products/Debug-iphonesimulator/Color Custom Keyboard.app/Color Custom Keyboard
clang: error: linker command failed with exit code 1 (use -v to see invocation)

推荐答案

我遇到了相同的错误,并按照以下步骤解决了该问题:

I got the same error and I solved it by following these steps:

1)转到项目

2)在左侧栏中(在出现的屏幕中,单击测试"

2) On the left side bar (in the screen that appears click on Tests

3)转到构建设置标签,然后找到测试主机"

3) Go to the build settings tab and look for "test host"

4)现在,该字段中显示的路径可能是错误的,因此您只需要将其更新为适当的路径即可(在我的特殊情况下,我重命名了项目和某些文件夹,因此某些路径是错误的)

4) Now the path that appears in the field is probably wrong so you just need to update it to the appropriate one (In my particular case I renamed the project and some folders and so some paths were wrong)

如果仍然看到错误,则可能需要在构建设置"选项卡中修复一些其他路径.

If you still see the error then you might need to fix some other paths in the Build settings tabs.

这篇关于尝试运行应用时找不到Xcode文件的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆