Apple Mach-O Linker Errors

Discussion in 'Mac Programming' started by isthisonetaken, Mar 15, 2011.

  1. isthisonetaken, Mar 15, 2011
    Last edited by a moderator: Jan 17, 2012

    isthisonetaken macrumors regular

    Joined:
    Jun 29, 2006
    #1
    Hey all,

    so I'm trying to use GCDAsyncSocket in a project and laid out my interface, hooked up my outlets and went to run it to make sure everything was ok (this is in Xcode 4, fyi). I get 16 Apple Mach-O Linker Errors all for GCDAsyncSocket:
    Code:
    Undefined symbols for architecture x86_64:
      "_SSLDisposeContext", referenced from:
          -[GCDAsyncSocket closeWithError:] in GCDAsyncSocket.o
      "_SSLRead", referenced from:
          -[GCDAsyncSocket doReadData] in GCDAsyncSocket.o
         (maybe you meant: _SSLReadFunction)
      "_SSLWrite", referenced from:
          -[GCDAsyncSocket doWriteData] in GCDAsyncSocket.o
         (maybe you meant: _SSLWriteFunction)
      "_SSLNewContext", referenced from:
          -[GCDAsyncSocket maybeStartTLS] in GCDAsyncSocket.o
      "_SSLSetIOFuncs", referenced from:
          -[GCDAsyncSocket maybeStartTLS] in GCDAsyncSocket.o
      "_SSLSetConnection", referenced from:
          -[GCDAsyncSocket maybeStartTLS] in GCDAsyncSocket.o
      "_SSLSetPeerDomainName", referenced from:
          -[GCDAsyncSocket maybeStartTLS] in GCDAsyncSocket.o
      "_SSLSetAllowsAnyRoot", referenced from:
          -[GCDAsyncSocket maybeStartTLS] in GCDAsyncSocket.o
      "_SSLSetAllowsExpiredRoots", referenced from:
          -[GCDAsyncSocket maybeStartTLS] in GCDAsyncSocket.o
      "_SSLSetEnableCertVerify", referenced from:
          -[GCDAsyncSocket maybeStartTLS] in GCDAsyncSocket.o
      "_SSLSetAllowsExpiredCerts", referenced from:
          -[GCDAsyncSocket maybeStartTLS] in GCDAsyncSocket.o
      "_SSLSetCertificate", referenced from:
          -[GCDAsyncSocket maybeStartTLS] in GCDAsyncSocket.o
      "_SSLSetProtocolVersionEnabled", referenced from:
          -[GCDAsyncSocket maybeStartTLS] in GCDAsyncSocket.o
      "_SSLSetEnabledCiphers", referenced from:
          -[GCDAsyncSocket maybeStartTLS] in GCDAsyncSocket.o
      "_SSLSetDiffieHellmanParams", referenced from:
          -[GCDAsyncSocket maybeStartTLS] in GCDAsyncSocket.o
      "_SSLHandshake", referenced from:
          -[GCDAsyncSocket continueSSLHandshake] in GCDAsyncSocket.o
    ld: symbol(s) not found for architecture x86_64
    clang: error: linker command failed with exit code 1 (use -v to see invocation)
    
    I have no idea what any of those means, and am hoping someone knows how to fix the error?

    Thanks,

    Dan
     
  2. jiminaus macrumors 65816

    jiminaus

    Joined:
    Dec 16, 2010
    Location:
    Sydney
  3. isthisonetaken thread starter macrumors regular

    Joined:
    Jun 29, 2006
    #3
    Thanks jiminaus, that indeed did fix the problem. What was it that tipped you off to that specific framework?

    Dan
     
  4. MacUser2525 macrumors 68000

    MacUser2525

    Joined:
    Mar 17, 2007
    Location:
    Canada
    #4
    I'll go with the SSL and TLS (secure sockets layer and transport layer security) errors in the output...
     
  5. jiminaus macrumors 65816

    jiminaus

    Joined:
    Dec 16, 2010
    Location:
    Sydney
    #5
    Yeap, except I thought it was going to need to be linked to libssl. But I looked at the source code to GCDAsyncSocket and saw it included Security/Security.h. That's what actually let me know which library or framework needed to be linked in.
     
  6. ompah, Mar 24, 2011
    Last edited by a moderator: Jan 17, 2012

    ompah macrumors newbie

    Joined:
    Sep 2, 2010
    #6
    Hi all :)

    Im having similar issues, (i think).
    Im stuck for a few days now,
    Using Xcode 4, upgrading my app from iOS 4.2 to 4.3
    Code:
    Undefined symbols for architecture armv7:
      "_xmlAddChild", referenced from:
          -[CXMLDocument(CXMLDocument_CreationExtensions) addChild:] in CXMLDocument_CreationExtensions.o
          -[CXMLElement(CXMLElement_CreationExtensions) addChild:] in CXMLElement_CreationExtensions.o
          -[CXMLElement(CXMLElement_CreationExtensions) setStringValue:] in CXMLElement_CreationExtensions.o
      "_xmlXPathNewContext", referenced from:
          -[CXMLNode(CXMLNode_NamespaceExtensions) nodesForXPath:namespaceMappings:error:] in CXMLNode_XPathExtensions.o
          -[CXMLNode nodesForXPath:error:] in CXMLNode.o
      "_xmlXPathFreeContext", referenced from:
          -[CXMLNode(CXMLNode_NamespaceExtensions) nodesForXPath:namespaceMappings:error:] in CXMLNode_XPathExtensions.o
          -[CXMLNode nodesForXPath:error:] in CXMLNode.o
      "_xmlCopyNode", referenced from:
          -[CXMLNode copyWithZone:] in CXMLNode.o
      "_xmlOutputBufferFlush", referenced from:
          -[CXMLNode XMLStringWithOptions:] in CXMLNode.o
      "_xmlXPathRegisterNs", referenced from:
          -[CXMLNode(CXMLNode_NamespaceExtensions) nodesForXPath:namespaceMappings:error:] in CXMLNode_XPathExtensions.o
      "_xmlFree", referenced from:
          -[CXMLDocument XMLDataWithOptions:] in CXMLDocument.o
          -[CXMLDocument description] in CXMLDocument.o
          -[CXMLNode stringValue] in CXMLNode.o
      "_xmlReadMemory", referenced from:
          -[CXMLDocument initWithData:encoding:options:error:] in CXMLDocument.o
      "_xmlNewNode", referenced from:
          +[CXMLNode(CXMLNode_CreationExtensions) elementWithName:stringValue:] in CXMLNode_CreationExtensions.o
          +[CXMLNode(CXMLNode_CreationExtensions) elementWithName:] in CXMLNode_CreationExtensions.o
          +[CXMLNode(CXMLNode_CreationExtensions) elementWithName:URI:] in CXMLNode_CreationExtensions.o
      "_xmlXPathFreeObject", referenced from:
          -[CXMLNode(CXMLNode_NamespaceExtensions) nodesForXPath:namespaceMappings:error:] in CXMLNode_XPathExtensions.o
          -[CXMLNode nodesForXPath:error:] in CXMLNode.o
      "_xmlAddPrevSibling", referenced from:
          -[CXMLDocument(CXMLDocument_CreationExtensions) insertChild:atIndex:] in CXMLDocument_CreationExtensions.o
      "_xmlDocDumpFormatMemory", referenced from:
          -[CXMLDocument description] in CXMLDocument.o
      "_xmlFreeDoc", referenced from:
          -[CXMLDocument dealloc] in CXMLDocument.o
      "_xmlNewText", referenced from:
          -[CXMLElement(CXMLElement_CreationExtensions) setStringValue:] in CXMLElement_CreationExtensions.o
      "_xmlFreeNode", referenced from:
          -[CXMLNode dealloc] in CXMLNode.o
      "_xmlDocSetRootElement", referenced from:
          +[CXMLNode(CXMLNode_CreationExtensions) documentWithRootElement:] in CXMLNode_CreationExtensions.o
      "_xmlParseDoc", referenced from:
          -[CXMLDocument initWithXMLString:options:error:] in CXMLDocument.o
      "_xmlNodeListGetString", referenced from:
          -[CXMLNode stringValue] in CXMLNode.o
      "_xmlNodeDumpOutput", referenced from:
          -[CXMLNode XMLStringWithOptions:] in CXMLNode.o
      "_xmlOutputBufferClose", referenced from:
          -[CXMLNode XMLStringWithOptions:] in CXMLNode.o
      "_xmlNewDoc", referenced from:
          +[CXMLNode(CXMLNode_CreationExtensions) document] in CXMLNode_CreationExtensions.o
          +[CXMLNode(CXMLNode_CreationExtensions) documentWithRootElement:] in CXMLNode_CreationExtensions.o
      "_xmlGetLastError", referenced from:
          -[CXMLDocument initWithXMLString:options:error:] in CXMLDocument.o
      "_xmlSetNs", referenced from:
          -[CXMLElement(CXMLElement_CreationExtensions) addNamespace:] in CXMLElement_CreationExtensions.o
      "_xmlNewPI", referenced from:
          +[CXMLNode(CXMLNode_CreationExtensions) processingInstructionWithName:stringValue:] in CXMLNode_CreationExtensions.o
      "_xmlDocDumpMemory", referenced from:
          -[CXMLDocument XMLDataWithOptions:] in CXMLDocument.o
      "_xmlXPathEvalExpression", referenced from:
          -[CXMLNode(CXMLNode_NamespaceExtensions) nodesForXPath:namespaceMappings:error:] in CXMLNode_XPathExtensions.o
          -[CXMLNode nodesForXPath:error:] in CXMLNode.o
      "_xmlDocGetRootElement", referenced from:
          -[CXMLDocument rootElement] in CXMLDocument.o
      "_xmlOutputBufferCreateIO", referenced from:
          -[CXMLNode XMLStringWithOptions:] in CXMLNode.o
      "_xmlNewNs", referenced from:
          +[CXMLNode(CXMLNode_CreationExtensions) namespaceWithName:stringValue:] in CXMLNode_CreationExtensions.o
          +[CXMLNode(CXMLNode_CreationExtensions) elementWithName:URI:] in CXMLNode_CreationExtensions.o
      "_xmlResetLastError", referenced from:
          -[CXMLDocument initWithXMLString:options:error:] in CXMLDocument.o
      "_xmlStrcmp", referenced from:
          -[CXMLElement attributeForName:] in CXMLElement.o
          -[CXMLElement elementsForName:] in CXMLElement.o
    ld: symbol(s) not found for architecture armv7
    collect2: ld returned 1 exit status
    
    If anyone could point me right direction I would be very happy!

    Thanks in advance!
    Daniel
     
  7. ompah macrumors newbie

    Joined:
    Sep 2, 2010
  8. rahul29tech, Dec 27, 2011
    Last edited by a moderator: Jan 17, 2012

    rahul29tech macrumors member

    Joined:
    Dec 22, 2011
    #8
    Code:
    Ld /Users/daccit_admin/Library/Developer/Xcode/DerivedData/QuartzFun_12-duaasdkdhhenpgamwilapowknilz/Build/Products/Debug-iphonesimulator/QuartzFun_12.app/QuartzFun_12 normal i386
        cd /Users/daccit_admin/Desktop/rahul_iphone_practise/QuartzFun_121
        setenv MACOSX_DEPLOYMENT_TARGET 10.6
        setenv PATH "/Developer/Platforms/iPhoneSimulator.platform/Developer/usr/bin:/Developer/usr/bin:/usr/bin:/bin:/usr/sbin:/sbin"
        /Developer/Platforms/iPhoneSimulator.platform/Developer/usr/bin/llvm-gcc-4.2 -arch i386 -isysroot /Developer/Platforms/iPhoneSimulator.platform/Developer/SDKs/iPhoneSimulator4.3.sdk -L/Users/daccit_admin/Library/Developer/Xcode/DerivedData/QuartzFun_12-duaasdkdhhenpgamwilapowknilz/Build/Products/Debug-iphonesimulator -F/Users/daccit_admin/Library/Developer/Xcode/DerivedData/QuartzFun_12-duaasdkdhhenpgamwilapowknilz/Build/Products/Debug-iphonesimulator -filelist /Users/daccit_admin/Library/Developer/Xcode/DerivedData/QuartzFun_12-duaasdkdhhenpgamwilapowknilz/Build/Intermediates/QuartzFun_12.build/Debug-iphonesimulator/QuartzFun_12.build/Objects-normal/i386/QuartzFun_12.LinkFileList -mmacosx-version-min=10.6 -Xlinker -objc_abi_version -Xlinker 2 -framework UIKit -framework Foundation -framework CoreGraphics -o /Users/daccit_admin/Library/Developer/Xcode/DerivedData/QuartzFun_12-duaasdkdhhenpgamwilapowknilz/Build/Products/Debug-iphonesimulator/QuartzFun_12.app/QuartzFun_12
    
    ld: duplicate symbol _OBJC_METACLASS_$_QuartzFunView in /Users/daccit_admin/Library/Developer/Xcode/DerivedData/QuartzFun_12-duaasdkdhhenpgamwilapowknilz/Build/Intermediates/QuartzFun_12.build/Debug-iphonesimulator/QuartzFun_12.build/Objects-normal/i386/QuartzFunView-7F31D4DF4C0CAD70.o and /Users/daccit_admin/Library/Developer/Xcode/DerivedData/QuartzFun_12-duaasdkdhhenpgamwilapowknilz/Build/Intermediates/QuartzFun_12.build/Debug-iphonesimulator/QuartzFun_12.build/Objects-normal/i386/QuartzFunView-70B37196F573EF4C.o for architecture i386
    collect2: ld returned 1 exit status
    Command /Developer/Platforms/iPhoneSimulator.platform/Developer/usr/bin/llvm-gcc-4.2 failed with exit code 1
    

    what to do plz tell me plzzzz...:( and if to add any framework ,so how to add framework plz tell me ...help me...
     
  9. rahul29tech macrumors member

    Joined:
    Dec 22, 2011
    #9
    hey problem solved....by default i added 2 same name method .....nw del it so prob is solved
     
  10. Mac_Max macrumors 6502

    Joined:
    Mar 8, 2004
    #10
    Looks like this is a necromancing self help thread. :D
     
  11. gracejo macrumors newbie

    Joined:
    Jan 9, 2012
    #11
    Linker error

    i also have a linker error. not sure what caused the error.

    Ld /Users/rc_loh/Library/Developer/Xcode/DerivedData/Fyp-gswtjfztcacmoobiahtquhcaunjh/Build/Products/Debug-iphonesimulator/Fyp.app/Fyp normal i386
    cd "/Users/rc_loh/Desktop/IOS LABS/Fyp"
    setenv MACOSX_DEPLOYMENT_TARGET 10.6
    setenv PATH "/Developer/Platforms/iPhoneSimulator.platform/Developer/usr/bin:/Developer/usr/bin:/usr/bin:/bin:/usr/sbin:/sbin"
    /Developer/Platforms/iPhoneSimulator.platform/Developer/usr/bin/llvm-gcc-4.2 -arch i386 -isysroot /Developer/Platforms/iPhoneSimulator.platform/Developer/SDKs/iPhoneSimulator4.3.sdk -L/Users/rc_loh/Library/Developer/Xcode/DerivedData/Fyp-gswtjfztcacmoobiahtquhcaunjh/Build/Products/Debug-iphonesimulator -F/Users/rc_loh/Library/Developer/Xcode/DerivedData/Fyp-gswtjfztcacmoobiahtquhcaunjh/Build/Products/Debug-iphonesimulator -filelist /Users/rc_loh/Library/Developer/Xcode/DerivedData/Fyp-gswtjfztcacmoobiahtquhcaunjh/Build/Intermediates/Fyp.build/Debug-iphonesimulator/Fyp.build/Objects-normal/i386/Fyp.LinkFileList -mmacosx-version-min=10.6 /Users/rc_loh/Desktop/IOS LABS/Fyp/iphonesimulator/libPhidget21.a -Xlinker -objc_abi_version -Xlinker 2 -framework ExternalAccessory -framework UIKit -framework Foundation -framework CoreGraphics -o /Users/rc_loh/Library/Developer/Xcode/DerivedData/Fyp-gswtjfztcacmoobiahtquhcaunjh/Build/Products/Debug-iphonesimulator/Fyp.app/Fyp

    i686-apple-darwin10-llvm-gcc-4.2: /Users/rc_loh/Desktop/IOS: No such file or directory
    i686-apple-darwin10-llvm-gcc-4.2: LABS/Fyp/iphonesimulator/libPhidget21.a: No such file or directory
    Command /Developer/Platforms/iPhoneSimulator.platform/Developer/usr/bin/llvm-gcc-4.2 failed with exit code 1



    anyone knows?
     
  12. jiminaus macrumors 65816

    jiminaus

    Joined:
    Dec 16, 2010
    Location:
    Sydney
    #12
    Take the space out of the name of the folder "IOS LABS". Change it IOSLABS, or IOS_LABS, or whatever, anything without a space.
     
  13. gracejo macrumors newbie

    Joined:
    Jan 9, 2012
    #13
    linker error

    i deleted the space. the linker error still exist. just shorten:

    Ld /Users/rc_loh/Library/Developer/Xcode/DerivedData/Fyp-hkolzxfaslngficfircgmxclgnhk/Build/Products/Debug-iphonesimulator/Fyp.app/Fyp normal i386
    cd /Users/rc_loh/Desktop/IOS_LABS/Fyp
    setenv MACOSX_DEPLOYMENT_TARGET 10.6
    setenv PATH "/Developer/Platforms/iPhoneSimulator.platform/Developer/usr/bin:/Developer/usr/bin:/usr/bin:/bin:/usr/sbin:/sbin"
    /Developer/Platforms/iPhoneSimulator.platform/Developer/usr/bin/llvm-gcc-4.2 -arch i386 -isysroot /Developer/Platforms/iPhoneSimulator.platform/Developer/SDKs/iPhoneSimulator4.3.sdk -L/Users/rc_loh/Library/Developer/Xcode/DerivedData/Fyp-hkolzxfaslngficfircgmxclgnhk/Build/Products/Debug-iphonesimulator -F/Users/rc_loh/Library/Developer/Xcode/DerivedData/Fyp-hkolzxfaslngficfircgmxclgnhk/Build/Products/Debug-iphonesimulator -filelist /Users/rc_loh/Library/Developer/Xcode/DerivedData/Fyp-hkolzxfaslngficfircgmxclgnhk/Build/Intermediates/Fyp.build/Debug-iphonesimulator/Fyp.build/Objects-normal/i386/Fyp.LinkFileList -mmacosx-version-min=10.6 /Users/rc_loh/Desktop/IOS_LABS/Fyp/iphonesimulator/libPhidget21.a -Xlinker -objc_abi_version -Xlinker 2 -framework ExternalAccessory -framework UIKit -framework Foundation -framework CoreGraphics -o /Users/rc_loh/Library/Developer/Xcode/DerivedData/Fyp-hkolzxfaslngficfircgmxclgnhk/Build/Products/Debug-iphonesimulator/Fyp.app/Fyp

    i686-apple-darwin10-llvm-gcc-4.2: /Users/rc_loh/Desktop/IOS_LABS/Fyp/iphonesimulator/libPhidget21.a: No such file or directory
    Command /Developer/Platforms/iPhoneSimulator.platform/Developer/usr/bin/llvm-gcc-4.2 failed with exit code 1
     
  14. Sayer macrumors 6502a

    Sayer

    Joined:
    Jan 4, 2002
    Location:
    Austin, TX
    #14
    Ignore the bulk of the text, and focus on the second to last line (the first line quoted above).

    What does it imply?
     
  15. gracejo macrumors newbie

    Joined:
    Jan 9, 2012
    #15
    linker error

    i followed exactly: adding $(SRCROOT) then the following file. i dunno why it is still not found.
     
  16. jiminaus macrumors 65816

    jiminaus

    Joined:
    Dec 16, 2010
    Location:
    Sydney
    #16
    Does this file actually exist? Can you find it in Finder?

    /Users/rc_loh/Desktop/IOS_LABS/Fyp/iphonesimulator/libPhidget21.a
     
  17. gracejo macrumors newbie

    Joined:
    Jan 9, 2012
    #17
    linker error

    yupps it can be found. i double and triple checked it.

    is it other cause or something?
     
  18. ripegooseberry macrumors newbie

    Joined:
    Feb 15, 2012
    #18
    I'm having teh same problem as ompah - please descibe your solution a bit more

    I am getting almost EXACTLY the same error! Could you please tell me exactly how you solved it? Was it by adding
    in Header Search Paths a line: /usr/include/libxml2
    it didn't work for me.

    Please please tell me what you have done to make this error go away [it's my third day trying to fix it]
     
  19. ompah macrumors newbie

    Joined:
    Sep 2, 2010
    #19
    Actually, when i added the path to the lib only in header it was not ok, i had to link it in the "Build Phrases -> Link Binary With Libraries" as well. Here I just added the libxml2 and removed any ref to the old one. Otherwise, i dont know :confused:
     
  20. skater618 macrumors newbie

    Joined:
    Aug 22, 2012
    #20
    linker error help

    I don't no what i need to do with this error i have not ever had it can anyone help me please.


    thanks, nick
     

    Attached Files:

  21. jared_kipe macrumors 68030

    jared_kipe

    Joined:
    Dec 8, 2003
    Location:
    Seattle
    #21
    You have a function 'speed' defined in multiple source files, looks like 'play' and 'easy'.
     
  22. skater618 macrumors newbie

    Joined:
    Aug 22, 2012
    #22
    thank you for the help jared_kipe

    thank you for pointing that out to me i had over looked that
     
  23. ArunKantSharma, Oct 4, 2012
    Last edited by a moderator: Oct 4, 2012

    ArunKantSharma macrumors newbie

    Joined:
    Oct 3, 2012
    #23
    Undefined symbols for architecture x86_64:

    i am new in mac and xcode .
    Please someone help me to solve the following problem.

    Code:
    Undefined symbols for architecture x86_64:
      "TiXmlString::assign(char const*, unsigned long)", referenced from:
          TiXmlString::operator=(char const*) in DataManager.o
      "TiXmlString::nullrep_", referenced from:
          TiXmlString::quit() in DataManager.o
          TiXmlString::quit() in XMLMessageObject.o
      "TiXmlElement::SetAttribute(char const*, char const*)", referenced from:
          SeComSFSDKDataManager::CSDKDataManager::createDefaultXmlFile(std::string) in DataManager.o
      "TiXmlElement::TiXmlElement(char const*)", referenced from:
          SeComSFSDKDataManager::CSDKDataManager::createDefaultXmlFile(std::string) in DataManager.o
      "TiXmlDocument::Parse(char const*, TiXmlParsingData*, TiXmlEncoding)", referenced from:
          SeComSFSDKDataManager::CSDKDataManager::findNode(TiXmlElement const*, std::string const*, std::list<std::string, std::allocator<std::string> >*) in DataManager.o
          CXMLMessageObject::parseMessage(char*) in XMLMessageObject.o
      "TiXmlDocument::LoadFile(TiXmlEncoding)", referenced from:
          SeComSFSDKDataManager::CSDKDataManager::read() in DataManager.o
      "TiXmlDocument::TiXmlDocument(char const*)", referenced from:
          SeComSFSDKDataManager::CSDKDataManager::findNode(TiXmlElement const*, std::string const*, std::list<std::string, std::allocator<std::string> >*) in DataManager.o
          SeComSFSDKDataManager::CSDKDataManager::read() in DataManager.o
          CXMLMessageObject::parseMessage(char*) in XMLMessageObject.o
      "TiXmlDocument::TiXmlDocument()", referenced from:
          SeComSFSDKDataManager::CSDKDataManager::createDefaultXmlFile(std::string) in DataManager.o
      "TiXmlDeclaration::TiXmlDeclaration(char const*, char const*, char const*)", referenced from:
          SeComSFSDKDataManager::CSDKDataManager::createDefaultXmlFile(std::string) in DataManager.o
      "TiXmlNode::LinkEndChild(TiXmlNode*)", referenced from:
          SeComSFSDKDataManager::CSDKDataManager::createDefaultXmlFile(std::string) in DataManager.o
      "TiXmlNode::Clear()", referenced from:
          SeComSFSDKDataManager::CSDKDataManager::read() in DataManager.o
          CXMLMessageObject::parseMessage(char*) in XMLMessageObject.o
      "TiXmlNode::TiXmlNode(TiXmlNode::NodeType)", referenced from:
          TiXmlText::TiXmlText(char const*) in DataManager.o
      "TiXmlNode::~TiXmlNode()", referenced from:
          TiXmlText::TiXmlText(char const*) in DataManager.o
          TiXmlDocument::~TiXmlDocument() in DataManager.o
          TiXmlDocument::~TiXmlDocument() in XMLMessageObject.o
      "TiXmlElement::GetText() const", referenced from:
          SeComSFSDKDataManager::CSDKDataManager::findNode(TiXmlElement const*, std::string const*, std::list<std::string, std::allocator<std::string> >*) in DataManager.o
          CXMLMessageObject::getTagValue(std::string, TiXmlElement*) in XMLMessageObject.o
      "TiXmlDocument::SaveFile(char const*) const", referenced from:
          SeComSFSDKDataManager::CSDKDataManager::createDefaultXmlFile(std::string) in DataManager.o
      "TiXmlNode::FirstChildElement(char const*) const", referenced from:
          TiXmlNode::FirstChildElement(char const*) in XMLMessageObject.o
      "TiXmlNode::FirstChildElement() const", referenced from:
          TiXmlNode::FirstChildElement() in DataManager.o
          TiXmlNode::FirstChildElement() in XMLMessageObject.o
      "TiXmlNode::NextSiblingElement() const", referenced from:
          TiXmlNode::NextSiblingElement() in DataManager.o
      "vtable for TiXmlDocument", referenced from:
          TiXmlDocument::~TiXmlDocument() in DataManager.o
          TiXmlDocument::~TiXmlDocument() in XMLMessageObject.o
      NOTE: a missing vtable usually means the first non-inline virtual member function has no definition.
      "vtable for TiXmlText", referenced from:
          TiXmlText::TiXmlText(char const*) in DataManager.o
      NOTE: a missing vtable usually means the first non-inline virtual member function has no definition.
    ld: symbol(s) not found for architecture x86_64
    clang: error: linker command failed with exit code 1 (use -v to see invocation)
     
  24. gnasher729 macrumors P6

    gnasher729

    Joined:
    Nov 25, 2005
    #24
    Look at the first error. You have a file named (probably) DataManager.cpp which is part of your target. There should be a file containing a function TiXmlString::assign, because that's what TiXmlString:: operator= is calling. What file is it in? Is that file part of your target?
     
  25. Senor Cuete, Oct 4, 2012
    Last edited: Oct 4, 2012

    Senor Cuete macrumors regular

    Joined:
    Nov 9, 2011
    #25
    I have a similar problem. One of my projects has stopped working:

    Undefined symbols for architecture x86_64:
    "_myFunctionName", referenced from:
    _callingfunctionName in my.cfilename.o

    The project compiles but doesn't link. I checked carefully and the .h file is #included in the .c file with the calling function. Also the called function is correctly prototyped in its .h file and defined in the .c file. This called file is used in a lot of my projects and works in all but this one. This code doesn't call any library functions except standard C functions so I don't know what framework would be missing. I have the Cocoa, Appkit, CoreData and foundation.foundation frameworks in my project.

    It appears that all of the functions that won't link call the same function. It only calls one library function: modf().

    The first function that won't link calls modf(). Shouldn't this be in the basic frameworks?
     

Share This Page