我打算将instaPDF和Avairy合并到我的应用程序中。我可以使用Xcode 4.6很好地下载和编译instaPDF。

我遇到的问题是,作为合并Aviary的一部分,我必须将“其他链接程序标志”设置为“ -ObjC -all_load”。一旦设置好这些错误。如果删除其他链接器标记,一切正常。当然,鸟舍不会启动,它会崩溃。

所以两个问题

1)其他链接器标记有什么意义?将其设置为-ObjC -all_load是什么意思

2)有没有一种方法可以设置其他链接器标志并使instaPDF感到满意,或者这意味着没有Aviary和InstaPDF可以共存?

这是错误。

Undefined symbols for architecture armv7:
  "_CVPixelBufferGetPixelFormatType", referenced from:
      -[CvVideoCamera captureOutput:didOutputSampleBuffer:fromConnection:] in opencv2(cap_ios_video_camera.o)
  "_CVPixelBufferGetWidthOfPlane", referenced from:
      -[CvVideoCamera captureOutput:didOutputSampleBuffer:fromConnection:] in opencv2(cap_ios_video_camera.o)
  "_CVPixelBufferGetHeightOfPlane", referenced from:
      -[CvVideoCamera captureOutput:didOutputSampleBuffer:fromConnection:] in opencv2(cap_ios_video_camera.o)
  "_CVPixelBufferLockBaseAddress", referenced from:
      -[CaptureDelegate updateImage] in opencv2(cap_avfoundation.o)
      -[CvVideoCamera captureOutput:didOutputSampleBuffer:fromConnection:] in opencv2(cap_ios_video_camera.o)
  "_CVPixelBufferGetBaseAddressOfPlane", referenced from:
      -[CvVideoCamera captureOutput:didOutputSampleBuffer:fromConnection:] in opencv2(cap_ios_video_camera.o)
  "_CVPixelBufferGetBaseAddress", referenced from:
      -[CaptureDelegate updateImage] in opencv2(cap_avfoundation.o)
      -[CvVideoCamera captureOutput:didOutputSampleBuffer:fromConnection:] in opencv2(cap_ios_video_camera.o)
  "_CVPixelBufferGetWidth", referenced from:
      -[CaptureDelegate updateImage] in opencv2(cap_avfoundation.o)
      -[CvVideoCamera captureOutput:didOutputSampleBuffer:fromConnection:] in opencv2(cap_ios_video_camera.o)
  "_CVPixelBufferGetBytesPerRow", referenced from:
      -[CaptureDelegate updateImage] in opencv2(cap_avfoundation.o)
      -[CvVideoCamera captureOutput:didOutputSampleBuffer:fromConnection:] in opencv2(cap_ios_video_camera.o)
  "_CVPixelBufferGetBytesPerRowOfPlane", referenced from:
      -[CvVideoCamera captureOutput:didOutputSampleBuffer:fromConnection:] in opencv2(cap_ios_video_camera.o)
  "_CVBufferRetain", referenced from:
      -[CaptureDelegate captureOutput:didOutputSampleBuffer:fromConnection:] in opencv2(cap_avfoundation.o)
      -[CaptureDelegate updateImage] in opencv2(cap_avfoundation.o)
  "_kCVPixelBufferPixelFormatTypeKey", referenced from:
      -[CvVideoCamera createVideoDataOutput] in opencv2(cap_ios_video_camera.o)
      -[CvVideoCamera createVideoFileOutput] in opencv2(cap_ios_video_camera.o)
  "_CVPixelBufferGetHeight", referenced from:
      -[CaptureDelegate updateImage] in opencv2(cap_avfoundation.o)
      -[CvVideoCamera captureOutput:didOutputSampleBuffer:fromConnection:] in opencv2(cap_ios_video_camera.o)
  "_CVPixelBufferUnlockBaseAddress", referenced from:
      -[CaptureDelegate updateImage] in opencv2(cap_avfoundation.o)
      -[CvVideoCamera captureOutput:didOutputSampleBuffer:fromConnection:] in opencv2(cap_ios_video_camera.o)
  "_CVBufferRelease", referenced from:
      -[CaptureDelegate captureOutput:didOutputSampleBuffer:fromConnection:] in opencv2(cap_avfoundation.o)
      -[CaptureDelegate updateImage] in opencv2(cap_avfoundation.o)
ld: symbol(s) not found for architecture armv7
clang: error: linker command failed with exit code 1 (use -v to see invocation)

最佳答案

您需要链接CoreVideo框架来解析所有这些符号。

这是一个简单的把戏。查看未定义的符号之一。复制符号(减去下划线),然后将其输入Xcode组织者中参考文档的搜索字段中。选择匹配的参考。滚动到参考页面的顶部。页面顶部的标题中应有一个Framework条目。

10-07 20:23