Xcode 4.5和iOS 6链接错误与Tapuku图书馆

Xcode 4.5和iOS 6链接错误与Tapuku图书馆

问题描述:

当我的项目编译为在iOS设备上运行时,我只收到此错误。有没有人遇到类似这样的问题?我正试图在设备上运行我的项目。我几乎到处都在看,无法找到解决方案。任何帮助,将不胜感激。Xcode 4.5和iOS 6链接错误与Tapuku图书馆

Ld /Users/dapage/Library/Developer/Xcode/DerivedData/McKendree_University-clkfusicbtxoumeeuoisuduipobw/Build/Products/Debug-iphoneos/McKendree.app/McKendree normal armv7 
    cd /Users/dapage/Developer/workspace/McKendree 
    setenv IPHONEOS_DEPLOYMENT_TARGET 4.0 
    setenv PATH "/Applications/Xcode.app/Contents/Developer/Platforms/iPhoneOS.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 armv7 -isysroot /Applications/Xcode.app/Contents/Developer/Platforms/iPhoneOS.platform/Developer/SDKs/iPhoneOS6.0.sdk -L/Users/dapage/Library/Developer/Xcode/DerivedData/McKendree_University-clkfusicbtxoumeeuoisuduipobw/Build/Products/Debug-iphoneos -L/Users/dapage/Developer/workspace/McKendree -L/Users/dapage/Developer/workspace/McKendree/Libraries -L/Users/dapage/Developer/workspace/McKendree/Libraries/OAuthConsumer -L/Users/dapage/Developer/workspace/McKendree/Libraries/TestFlight -L/Users/dapage/Developer/workspace/McKendree/../../../Downloads/TestFlightSDK1 -F/Users/dapage/Library/Developer/Xcode/DerivedData/McKendree_University-clkfusicbtxoumeeuoisuduipobw/Build/Products/Debug-iphoneos -filelist "/Users/dapage/Library/Developer/Xcode/DerivedData/McKendree_University-clkfusicbtxoumeeuoisuduipobw/Build/Intermediates/McKendree University.build/Debug-iphoneos/McKendree.build/Objects-normal/armv7/McKendree.LinkFileList" -dead_strip -ObjC -fobjc-link-runtime -miphoneos-version-min=4.0 /Users/dapage/Library/Developer/Xcode/DerivedData/McKendree_University-clkfusicbtxoumeeuoisuduipobw/Build/Products/Debug-iphoneos/libThree20UI.a /Users/dapage/Library/Developer/Xcode/DerivedData/McKendree_University-clkfusicbtxoumeeuoisuduipobw/Build/Products/Debug-iphoneos/libThree20UICommon.a /Users/dapage/Library/Developer/Xcode/DerivedData/McKendree_University-clkfusicbtxoumeeuoisuduipobw/Build/Products/Debug-iphoneos/libThree20UINavigator.a /Users/dapage/Library/Developer/Xcode/DerivedData/McKendree_University-clkfusicbtxoumeeuoisuduipobw/Build/Products/Debug-iphoneos/libextThree20XML.a /Users/dapage/Library/Developer/Xcode/DerivedData/McKendree_University-clkfusicbtxoumeeuoisuduipobw/Build/Products/Debug-iphoneos/libThree20.a /Users/dapage/Library/Developer/Xcode/DerivedData/McKendree_University-clkfusicbtxoumeeuoisuduipobw/Build/Products/Debug-iphoneos/libThree20Core.a /Users/dapage/Library/Developer/Xcode/DerivedData/McKendree_University-clkfusicbtxoumeeuoisuduipobw/Build/Products/Debug-iphoneos/libThree20Network.a /Users/dapage/Library/Developer/Xcode/DerivedData/McKendree_University-clkfusicbtxoumeeuoisuduipobw/Build/Products/Debug-iphoneos/libThree20Style.a /Users/dapage/Library/Developer/Xcode/DerivedData/McKendree_University-clkfusicbtxoumeeuoisuduipobw/Build/Products/Debug-iphoneos/libTapkuLibrary.a -framework AddressBook -framework AddressBookUI -framework AudioToolbox -lz -framework QuartzCore -framework Foundation -framework UIKit -framework CoreGraphics -framework MapKit -framework MessageUI -framework MediaPlayer -framework AVFoundation -framework SystemConfiguration -framework CoreLocation -lxml2 -lsqlite3.0 -framework CFNetwork -framework Security -lOAuth -lTestFlight -o /Users/dapage/Library/Developer/Xcode/DerivedData/McKendree_University-clkfusicbtxoumeeuoisuduipobw/Build/Products/Debug-iphoneos/McKendree.app/McKendree\ 

的错误是:

clang: error: no such file or directory: '/Users/dapage/Library/Developer/Xcode/DerivedData/McKendree_University-clkfusicbtxoumeeuoisuduipobw/Build/Products/Debug-iphoneos/libTapkuLibrary.a' 
+0

看来链接程序无法在目标库搜索路径所指定的位置找到相关库的二进制文件。图书馆是否位于错误表达的路径? – FluffulousChimp

+0

我被困在同一点,任何人有任何解决方案? –

确保二进制库是项目的根目录下,并且添加它作为参考。您可以通过在Project Navigator(Cmd-1)中选择项目来完成此操作,然后选择Build Phases。在与库链接二进制文件下,​​您应该有对二进制文件的引用。您可能还想将库二进制文件添加到项目中,该项目可能会自动将其作为链接二进制文件。您还可以在“生成设置”下编辑“库搜索路径”,并添加具有此二进制文件的文件夹。

"$(SRCROOT)/lib" 

如果你在那个文件夹中有二进制文件,它可能会发现它更容易。您还需要引用此库的标题,请查看设置标题搜索路径并将头文件添加到您的项目中。

如果可以的话,我更愿意将来自第三方库的代码添加为静态库并将它们添加为依赖项。您可以首先将其作为一个单独的项目来完成,并让它自行成功构建。然后,您可以将该项目文件拖放到Xcode中的其他项目中,并将其设置为依赖项。您需要了解方案如何管理构建项目的依赖关系以设置子项目。您可能会发现这种方法比链接到预编译的库更容易,该库可能不包括Apple发布的设备所需的体系结构。如果你有源代码作为依赖关系,你将能够构建必要的二进制版本。