【问题标题】:AePub Reader Error in Xcode 4.6Xcode 4.6 中的 AePub 阅读器错误
【发布时间】:2023-03-04 14:30:02
【问题描述】:

我下载了一个名为 AePubReader 的开源 epub 阅读器,它工作正常。但是当我尝试在 xcode 4.6 中与我的应用程序集成时,由于 ARC 显示了很多错误。所以我选择了这些文件并设置了“-fno-objc -arc" 标志。但之后它会显示类似 #include <libxml/tree.h> not found![this is the error i got ][1]
的错误 $(SDK_DIR)"/usr/include/libxml2 我添加了这一行,然后问题就解决了,但之后它显示“43 错误”,例如“Apple Mach-O 链接器错误”,其中大部分与 xml 文件有关

我的错误信息

架构 i386 的未定义符号: “_htmlParseDoc”,引用自: -[CXHTMLDocument initWithXHTMLString:options:error:] in CXHTMLDocument.o

“_htmlReadMemory”,引用自: -[CXHTMLDocument initWithXHTMLData:encoding:options:error:] 在 CXHTMLDocument.o “_xmlAddChild”,引用自: -[CXMLDocument(CXMLDocument_CreationExtensions) addChild:] 在 CXMLDocument_CreationExtensions.o -[CXMLElement(CXMLElement_CreationExtensions) addChild:] 在 CXMLElement_CreationExtensions.o -[CXMLElement(CXMLElement_CreationExtensions) setStringValue:] 在 CXMLElement_CreationExtensions.o “_xmlAddPrevSibling”,引用自: -[CXMLDocument(CXMLDocument_CreationExtensions) insertChild:atIndex:] 在 CXMLDocument_CreationExtensions.o “_xmlCopyNode”,引用自: -[CXMLNode copyWithZone:] 在 CXMLNode.o 中

"_xmlDocDumpFormatMemory", referenced from:
  -[CXMLDocument description] in CXMLDocument.o

“_xmlDocDumpMemory”,引用自: -[CXMLDocument XMLDataWithOptions:] 在 CXMLDocument.o “_xmlDocGetRootElement”,引用自: -[CXMLDocument initWithData:encoding:options:error:] 在 CXMLDocument.o -CXMLDocument.o 中的[CXMLDocument rootElement] “_xmlDocSetRootElement”,引用自: +[CXMLNode(CXMLNode_CreationExtensions) documentWithRootElement:] 在 CXMLNode_CreationExtensions.o -[CXHTMLDocument initWithXHTMLString:options:error:] 在 CXHTMLDocument.o “_xmlFree”,引用自: -[CXMLDocument XMLDataWithOptions:] 在 CXMLDocument.o -CXMLDocument.o 中的[CXMLDocument 描述] “_xmlFreeDoc”,引用自: -CXMLDocument.o 中的[CXMLDocument dealloc] “_xmlFreeNode”,引用自: -CXMLNode.o 中的[CXMLNode dealloc] “_xmlGetCharEncodingName”,引用自: -[CXHTMLDocument initWithXHTMLString:options:error:] 在 CXHTMLDocument.o “_xmlGetLastError”,引用自: -[CXHTMLDocument initWithXHTMLString:options:error:] 在 CXHTMLDocument.o -[CXMLDocument initWithXMLString:options:error:] 在 CXMLDocument.o -[CXMLDocument initWithData:encoding:options:error:] in CXMLDocument.o

"_xmlNewDoc", referenced from:
  +[CXMLNode(CXMLNode_CreationExtensions) document] in CXMLNode_CreationExtensions.o
  +[CXMLNode(CXMLNode_CreationExtensions) documentWithRootElement:] in CXMLNode_CreationExtensions.o

“_xmlNewNode”,引用自: +[CXMLNode(CXMLNode_CreationExtensions) elementWithName:] 在 CXMLNode_CreationExtensions.o +[CXMLNode(CXMLNode_CreationExtensions) elementWithName:URI:] 在 CXMLNode_CreationExtensions.o +[CXMLNode(CXMLNode_CreationExtensions) elementWithName:stringValue:] in CXMLNode_CreationExtensions.o “_xmlNewNs”,引用自: +[CXMLNode(CXMLNode_CreationExtensions) elementWithName:URI:] 在 CXMLNode_CreationExtensions.o “_xmlNewPI”,引用自: +[CXMLNode(CXMLNode_CreationExtensions) processingInstructionWithName:stringValue:] 在 CXMLNode_CreationExtensions.o “_xmlNewText”,引用自: -[CXMLElement(CXMLElement_CreationExtensions) setStringValue:] 在 CXMLElement_CreationExtensions.o “_xmlNodeDumpOutput”,引用自: -[CXMLNode XMLStringWithOptions:] 在 CXMLNode.o “_xmlNodeSetContent”,引用自: -[CXMLNode(CXMLNode_CreationExtensions) setStringValue:] 在 CXMLNode_CreationExtensions.o “_xmlOutputBufferClose”,引用自: -[CXMLNode XMLStringWithOptions:] 在 CXMLNode.o “_xmlOutputBufferCreateIO”,引用自: -[CXMLNode XMLStringWithOptions:] 在 CXMLNode.o “_xmlOutputBufferFlush”,引用自: -[CXMLNode XMLStringWithOptions:] 在 CXMLNode.o “_xmlParseDoc”,引用自: -[CXMLDocument initWithXMLString:options:error:] 在 CXMLDocument.o “_xmlReadMemory”,引用自: -[CXMLDocument initWithData:encoding:options:error:] 在 CXMLDocument.o “_xmlResetLastError”,引用自: -[CXHTMLDocument initWithXHTMLString:options:error:] 在 CXHTMLDocument.o -[CXMLDocument initWithXMLString:options:error:] 在 CXMLDocument.o -[CXMLDocument initWithData:encoding:options:error:] 在 CXMLDocument.o “_xmlSetNs”,引用自: -[CXMLElement(CXMLElement_CreationExtensions) addNamespace:] 在 CXMLElement_CreationExtensions.o “_xmlStrcmp”,引用自: -[CXMLElement elementsForName:] 在 CXMLElement.o -[CXMLElement elementsForLocalName:URI:] 在 CXMLElement.o -[CXMLElement attributeForName:] 在 CXMLElement.o -[CXMLElement attributeForLocalName:URI:] 在 CXMLElement.o -[CXMLElement namespaceForPrefix:] 在 CXMLElement.o -[CXMLElement resolvePrefixForNamespaceURI:] 在 CXMLElement.o “_xmlXPathEvalExpression”,引用自: -[CXHTMLDocument initWithXHTMLString:options:error:] 在 CXHTMLDocument.o -[CXMLNode(CXMLNode_NamespaceExtensions) nodesForXPath:namespaceMappings:error:] 在 CXMLNode_XPathExtensions.o -[CXMLNode nodesForXPath:error:] 在 CXMLNode.o “_xmlXPathFreeContext”,引用自: -[CXHTMLDocument initWithXHTMLString:options:error:] 在 CXHTMLDocument.o -[CXMLNode(CXMLNode_NamespaceExtensions) nodesForXPath:namespaceMappings:error:] 在 CXMLNode_XPathExtensions.o -[CXMLNode nodesForXPath:error:] 在 CXMLNode.o “_xmlXPathFreeObject”,引用自: -[CXHTMLDocument initWithXHTMLString:options:error:] 在 CXHTMLDocument.o -[CXMLNode(CXMLNode_NamespaceExtensions) nodesForXPath:namespaceMappings:error:] 在 CXMLNode_XPathExtensions.o -[CXMLNode nodesForXPath:error:] 在 CXMLNode.o “_xmlXPathNewContext”,引用自: -[CXHTMLDocument initWithXHTMLString:options:error:] 在 CXHTMLDocument.o -[CXMLNode(CXMLNode_NamespaceExtensions) nodesForXPath:namespaceMappings:error:] 在 CXMLNode_XPathExtensions.o -[CXMLNode nodesForXPath:error:] 在 CXMLNode.o “_xmlXPathRegisterNs”,引用自: -[CXMLNode(CXMLNode_NamespaceExtensions) nodesForXPath:namespaceMappings:error:] 在 CXMLNode_XPathExtensions.o ld:未找到体系结构 i386 的符号 clang:错误:链接器命令失败,退出代码为 1(使用 -v 查看调用)

“_htmlParseDoc”,引用自:

  -[CXHTMLDocument initWithXHTMLString:options:error:] in CXHTMLDocument.o

“_htmlReadMemory”,引用自:

  -[CXHTMLDocument initWithXHTMLData:encoding:options:error:] in CXHTMLDocument.o

“_xmlAddChild”,引用自:

  -[CXMLDocument(CXMLDocument_CreationExtensions) addChild:] in CXMLDocument_CreationExtensions.o


  -[CXMLElement(CXMLElement_CreationExtensions) addChild:] in CXMLElement_CreationExtensions.o


  -[CXMLElement(CXMLElement_CreationExtensions) setStringValue:] in CXMLElement_CreationExtensions.o

“_xmlAddPrevSibling”,引用自:

  -[CXMLDocument(CXMLDocument_CreationExtensions) insertChild:atIndex:] in CXMLDocument_CreationExtensions.o

“_xmlCopyNode”,引用自:

  -[CXMLNode copyWithZone:] in CXMLNode.o

“_xmlDocDumpFormatMemory”,引用自:

  -[CXMLDocument description] in CXMLDocument.o

“_xmlDocDumpMemory”,引用自:

  -[CXMLDocument XMLDataWithOptions:] in CXMLDocument.o

“_xmlDocGetRootElement”,引用自:

  -[CXMLDocument initWithData:encoding:options:error:] in CXMLDocument.o


  -[CXMLDocument rootElement] in CXMLDocument.o

“_xmlDocSetRootElement”,引用自:

  +[CXMLNode(CXMLNode_CreationExtensions) documentWithRootElement:] in CXMLNode_CreationExtensions.o


  -[CXHTMLDocument initWithXHTMLString:options:error:] in CXHTMLDocument.o

“_xmlFree”,引用自:

  -[CXMLDocument XMLDataWithOptions:] in CXMLDocument.o


  -[CXMLDocument description] in CXMLDocument.o

“_xmlFreeDoc”,引用自:

  -[CXMLDocument dealloc] in CXMLDocument.o

“_xmlFreeNode”,引用自:

  -[CXMLNode dealloc] in CXMLNode.o

“_xmlGetCharEncodingName”,引用自:

  -[CXHTMLDocument initWithXHTMLString:options:error:] in CXHTMLDocument.o

“_xmlGetLastError”,引用自:

  -[CXHTMLDocument initWithXHTMLString:options:error:] in CXHTMLDocument.o


  -[CXMLDocument initWithXMLString:options:error:] in CXMLDocument.o


  -[CXMLDocument initWithData:encoding:options:error:] in CXMLDocument.o

“_xmlNewDoc”,引用自:

  +[CXMLNode(CXMLNode_CreationExtensions) document] in CXMLNode_CreationExtensions.o


  +[CXMLNode(CXMLNode_CreationExtensions) documentWithRootElement:] in CXMLNode_CreationExtensions.o

“_xmlNewNode”,引用自:

  +[CXMLNode(CXMLNode_CreationExtensions) elementWithName:] in CXMLNode_CreationExtensions.o


  +[CXMLNode(CXMLNode_CreationExtensions) elementWithName:URI:] in CXMLNode_CreationExtensions.o


  +[CXMLNode(CXMLNode_CreationExtensions) elementWithName:stringValue:] in CXMLNode_CreationExtensions.o

“_xmlNewNs”,引用自:

  +[CXMLNode(CXMLNode_CreationExtensions) elementWithName:URI:] in CXMLNode_CreationExtensions.o

“_xmlNewPI”,引用自:

  +[CXMLNode(CXMLNode_CreationExtensions) processingInstructionWithName:stringValue:] in CXMLNode_CreationExtensions.o

“_xmlNewText”,引用自:

  -[CXMLElement(CXMLElement_CreationExtensions) setStringValue:] in CXMLElement_CreationExtensions.o

“_xmlNodeDumpOutput”,引用自:

  -[CXMLNode XMLStringWithOptions:] in CXMLNode.o

“_xmlNodeSetContent”,引用自:

  -[CXMLNode(CXMLNode_CreationExtensions) setStringValue:] in CXMLNode_CreationExtensions.o

“_xmlOutputBufferClose”,引用自:

  -[CXMLNode XMLStringWithOptions:] in CXMLNode.o

“_xmlOutputBufferCreateIO”,引用自:

  -[CXMLNode XMLStringWithOptions:] in CXMLNode.o

“_xmlOutputBufferFlush”,引用自:

  -[CXMLNode XMLStringWithOptions:] in CXMLNode.o

“_xmlParseDoc”,引用自:

  -[CXMLDocument initWithXMLString:options:error:] in CXMLDocument.o

“_xmlReadMemory”,引用自:

  -[CXMLDocument initWithData:encoding:options:error:] in CXMLDocument.o

“_xmlResetLastError”,引用自:

  -[CXHTMLDocument initWithXHTMLString:options:error:] in CXHTMLDocument.o


  -[CXMLDocument initWithXMLString:options:error:] in CXMLDocument.o


  -[CXMLDocument initWithData:encoding:options:error:] in CXMLDocument.o

“_xmlSetNs”,引用自:

  -[CXMLElement(CXMLElement_CreationExtensions) addNamespace:] in CXMLElement_CreationExtensions.o

“_xmlStrcmp”,引用自:

  -[CXMLElement elementsForName:] in CXMLElement.o


  -[CXMLElement elementsForLocalName:URI:] in CXMLElement.o


  -[CXMLElement attributeForName:] in CXMLElement.o


  -[CXMLElement attributeForLocalName:URI:] in CXMLElement.o


  -[CXMLElement namespaceForPrefix:] in CXMLElement.o


  -[CXMLElement resolvePrefixForNamespaceURI:] in CXMLElement.o

“_xmlXPathEvalExpression”,引用自:

  -[CXHTMLDocument initWithXHTMLString:options:error:] in CXHTMLDocument.o


  -[CXMLNode(CXMLNode_NamespaceExtensions) nodesForXPath:namespaceMappings:error:] in CXMLNode_XPathExtensions.o


  -[CXMLNode nodesForXPath:error:] in CXMLNode.o

“_xmlXPathFreeContext”,引用自:

  -[CXHTMLDocument initWithXHTMLString:options:error:] in CXHTMLDocument.o


  -[CXMLNode(CXMLNode_NamespaceExtensions) nodesForXPath:namespaceMappings:error:] in CXMLNode_XPathExtensions.o


  -[CXMLNode nodesForXPath:error:] in CXMLNode.o

“_xmlXPathFreeObject”,引用自:

  -[CXHTMLDocument initWithXHTMLString:options:error:] in CXHTMLDocument.o


  -[CXMLNode(CXMLNode_NamespaceExtensions) nodesForXPath:namespaceMappings:error:] in CXMLNode_XPathExtensions.o


  -[CXMLNode nodesForXPath:error:] in CXMLNode.o

“_xmlXPathNewContext”,引用自:

  -[CXHTMLDocument initWithXHTMLString:options:error:] in CXHTMLDocument.o


  -[CXMLNode(CXMLNode_NamespaceExtensions) nodesForXPath:namespaceMappings:error:] in CXMLNode_XPathExtensions.o


  -[CXMLNode nodesForXPath:error:] in CXMLNode.o

“_xmlXPathRegisterNs”,引用自:

  -[CXMLNode(CXMLNode_NamespaceExtensions) nodesForXPath:namespaceMappings:error:] in CXMLNode_XPathExtensions.o

ld:未找到体系结构 i386 的符号

clang:错误:链接器命令失败,退出代码为 1(使用 -v 查看调用)

【问题讨论】:

标签: ios6 epub xcode4.6 libxml2


【解决方案1】:

您必须将“libz.dylib”和“libxml2.dylib”添加到目标“Build Phases”中的“Link Binary With Libraries”项中。

【讨论】:

  • ok..我添加了现在显示 35 个错误,之前是 43 个错误
  • 你必须显示错误信息,我猜不出来。也许您必须添加“libxml2.dylib”?
  • 好的,我会评论 url 地址检查这个lh5.googleusercontent.com/-GbL2Bg58MgY/UUwe7BtLc3I/AAAAAAAAAMQ/…
  • 请将错误消息作为文本添加到您的问题中。您是否尝试添加“libxml2.dylib”?
  • 你添加了“libxml2.dylib”吗??
猜你喜欢
  • 1970-01-01
  • 1970-01-01
  • 1970-01-01
  • 2013-02-06
  • 2015-02-24
  • 2013-03-02
  • 2013-08-20
  • 2013-01-13
  • 1970-01-01
相关资源
最近更新 更多