将ObjectiveFlickr添加到项目中

时间:2013-03-27 07:12:26

标签: xcode xcode4 armv7 armv6 objectiveflickr

我正在尝试将ObjectiveFlickr框架添加到我的项目中。

我尝试按照这些说明操作:

Add ObjectiveFlickr.xcodeproj to your Mac project (from Xcode menu Project > Add to Project...)
On your app target, open the info window (using Get Info on the target), then in the General tab, add ObjectiveFlickr (library) to Direct Dependencies
Also, in the same window, add CFNetwork.framework to Linked Libraries
Drag libObjecitveFlickr.a to the target's Linked Binary With Libraries group
Open the Info window of your target again. Set Configuration to All Configurations, then in the Header Search Paths property, add these two paths, separately (<OF root> is where you checked out ObjectiveFlickr):

<OF root>/Source
<OF root>/LFWebAPIKit   

Use #import "ObjectiveFlickr.h" in your project

但是,似乎这些指令是为旧版本的XCode编写的(我使用的是4.6)。 我试图将这些指令“翻译”到更新版本的XCode,但无论我做什么,libObjectiveFlickr.a都保持红色,我收到以下错误:

Undefined symbols for architecture armv7:
  "_SCNetworkReachabilityUnscheduleFromRunLoop", referenced from:
      -[LFSiteReachability stopChecking] in libObjectiveFlickr.a(LFSiteReachability.o)
  "_SCNetworkReachabilitySetCallback", referenced from:
      -[LFSiteReachability startChecking] in libObjectiveFlickr.a(LFSiteReachability.o)
  "_SCNetworkReachabilityCreateWithAddress", referenced from:
      -[LFSiteReachability networkConnectivityExists] in libObjectiveFlickr.a(LFSiteReachability.o)
      -[LFSiteReachability startChecking] in libObjectiveFlickr.a(LFSiteReachability.o)
  "_SCNetworkReachabilityScheduleWithRunLoop", referenced from:
      -[LFSiteReachability startChecking] in libObjectiveFlickr.a(LFSiteReachability.o)
  "_SCNetworkReachabilityGetFlags", referenced from:
      -[LFSiteReachability networkConnectivityExists] in libObjectiveFlickr.a(LFSiteReachability.o)
      -[LFSiteReachability startChecking] in libObjectiveFlickr.a(LFSiteReachability.o)
ld: symbol(s) not found for architecture armv7
clang: error: linker command failed with exit code 1 (use -v to see invocation)

1 个答案:

答案 0 :(得分:1)

您还需要将目标与SystemConfiguration.framework相关联。您可以按照与CFNetwork.framework链接相同的方式执行此操作。