0

我们最近将 xcode 升级到了 4.3。我正在进行测试,我需要复制目标文件并集成 FoneMonkey 文件并执行目标。我对原始目标进行了以下更改以使其成功执行:

updated framework serch paths

"$(DEVELOPER_FRAMEWORKS_DIR)"
"$(SRCROOT)/../../Developer/Library/Frameworks"
"$(SRCROOT)"

updated Library search paths

"$(DEVELOPER_FRAMEWORKS_DIR)"
"$(SRCROOT)/../../Developer/Library/Frameworks"
"$(SRCROOT)"
"/users/ezprintsqa/FoneMonkey/lib"

executed below command 
sudo xcode-select -switch /Applications/Xcode.app/Contents/Developer

现在构建成功执行。但是添加了 Fonemonkey 文件的重复目标给出了以下错误:

Ld "/Users/ezprintsqa/Library/Developer/Xcode/DerivedData/SnapCards-dtjqrhfvqueyhrbbgjgydberyqdm/Build/Products/Debug-iphonesimulator/SnapCards copy.app/SnapCards copy" normal i386
    cd /Users/ezprintsqa/Documents/snapcards
    setenv MACOSX_DEPLOYMENT_TARGET 10.6
    setenv 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 i386 -isysroot /Applications/Xcode.app/Contents/Developer/Platforms/iPhoneSimulator.platform/Developer/SDKs/iPhoneSimulator5.1.sdk -L/Users/ezprintsqa/Library/Developer/Xcode/DerivedData/SnapCards-dtjqrhfvqueyhrbbgjgydberyqdm/Build/Products/Debug-iphonesimulator -L/Applications/Xcode.app/Contents/Developer/Library/Frameworks -L/Applications/Xcode.app/Contents/Developer/Library/Frameworks/CPlusTest.framework -L/Applications/Xcode.app/Contents/Developer/Library/Frameworks/DTPerformanceSession.framework -L/Applications/Xcode.app/Contents/Developer/Library/Frameworks/InterfaceBuilderKit.framework -L/
.
.

ld: warning: directory not found for option '-L/Users/ezprintsqa/Documents/snapcards/../../Developer/Library/Frameworks'
ld: warning: directory not found for option '-F/Users/ezprintsqa/Documents/snapcards/../../Developer/Library/Frameworks'
Undefined symbols for architecture i386:
  "_SCNetworkReachabilitySetCallback", referenced from:
      -[Reachability startNotifier] in Reachability.o
  "_SCNetworkReachabilityScheduleWithRunLoop", referenced from:
      -[Reachability startNotifier] in Reachability.o
  "_SCNetworkReachabilityUnscheduleFromRunLoop", referenced from:
      -[Reachability stopNotifier] in Reachability.o
  "_SCNetworkReachabilityCreateWithName", referenced from:
      +[Reachability reachabilityWithHostName:] in Reachability.o
  "_SCNetworkReachabilityCreateWithAddress", referenced from:
      +[Reachability reachabilityWithAddress:] in Reachability.o
  "_SCNetworkReachabilityGetFlags", referenced from:
      -[Reachability currentReachabilityStatus] in Reachability.o
      -[Reachability isReachable] in Reachability.o
      -[Reachability isConnectionRequired] in Reachability.o
      -[Reachability isConnectionOnDemand] in Reachability.o
      -[Reachability isInterventionRequired] in Reachability.o
      -[Reachability isReachableViaWWAN] in Reachability.o
      -[Reachability isReachableViaWiFi] in Reachability.o
      ...
  "_OBJC_CLASS_$_SenTestSuite", referenced from:
      objc-class-ref in libFoneMonkeyOCUnit.5.5b.a(FoneMonkey+OCUnit.o)
  "_OBJC_CLASS_$_SenTestObserver", referenced from:
      objc-class-ref in libFoneMonkeyOCUnit.5.5b.a(FoneMonkey+OCUnit.o)
  "_OBJC_CLASS_$_SenTestLog", referenced from:
      objc-class-ref in libFoneMonkeyOCUnit.5.5b.a(FoneMonkey+OCUnit.o)
ld: symbol(s) not found for architecture i386
clang: error: linker command failed with exit code 1 (use -v to see invocation)

有人可以帮我解决以下问题:

  1. 升级到 4.3 后,该文件夹/Users/ezprintsqa/Library/Developer/现在不可用,但这里正在配置此路径(我该如何更改)?
  2. _objc_class 问题。

提前致谢。

4

1 回答 1

0

通过SenTesting.framework从 Xcode 中删除,问题得到了解决。

于 2012-06-08T07:51:22.220 回答