Using Visual Studio 7.1 trying to compile a project using TinyXML, and getting link errors:
Linking...
wEntity.obj : error LNK2019: unresolved external symbol "public: class TiXmlElement * __thiscall TiXmlNode::NextSiblingElement(char const *)const " (?NextSiblingElement@TiXmlNode@@QBEPAVTiXmlElement@@PBD@Z) referenced in function "public: void __thiscall wEntity::initEntity(class Ogre::SceneManager *,class TiXmlElement *)" (?initEntity@wEntity@@QAEXPAVSceneManager@Ogre@@PAVTiXmlElement@@@Z)
wEntity.obj : error LNK2019: unresolved external symbol "public: class TiXmlElement * __thiscall TiXmlNode::FirstChildElement(char const *)const " (?FirstChildElement@TiXmlNode@@QBEPAVTiXmlElement@@PBD@Z) referenced in function "public: void __thiscall wEntity::initEntity(class Ogre::SceneManager *,class TiXmlElement *)" (?initEntity@wEntity@@QAEXPAVSceneManager@Ogre@@PAVTiXmlElement@@@Z)
WRWorld.obj : error LNK2019: unresolved external symbol "public: void __thiscall wStatic::addStatic(class std::basic_string<char,struct std::char_traits<char>,class std::allocator<char> >,class std::basic_string<char,struct std::char_traits<char>,class std::allocator<char> >)" (?addStatic@wStatic@@QAEXV?$basic_string@DU?$char_traits@D@std@@V?$allocator@D@2@@std@@0@Z) referenced in function "public: void __thiscall WRWorld::addStatic(class std::basic_string<char,struct std::char_traits<char>,class std::allocator<char> >,class std::basic_string<char,struct std::char_traits<char>,class std::allocator<char> >)" (?addStatic@WRWorld@@QAEXV?$basic_string@DU?$char_traits@D@std@@V?$allocator@D@2@@std@@0@Z)
WRWorld.obj : error LNK2019: unresolved external symbol "public: void __thiscall wStatic::addStatic(class std::basic_string<char,struct std::char_traits<char>,class std::allocator<char> >,class std::basic_string<char,struct std::char_traits<char>,class std::allocator<char> >,class Ogre::Vector3)" (?addStatic@wStatic@@QAEXV?$basic_string@DU?$char_traits@D@std@@V?$allocator@D@2@@std@@0VVector3@Ogre@@@Z) referenced in function "public: void __thiscall WRWorld::addStatic(class std::basic_string<char,struct std::char_traits<char>,class std::allocator<char> >,class std::basic_string<char,struct std::char_traits<char>,class std::allocator<char> >,class Ogre::Vector3)" (?addStatic@WRWorld@@QAEXV?$basic_string@DU?$char_traits@D@std@@V?$allocator@D@2@@std@@0VVector3@Ogre@@@Z)
WRWorld.obj : error LNK2019: unresolved external symbol "public: void __thiscall wStatic::addStatic(class TiXmlElement *)" (?addStatic@wStatic@@QAEXPAVTiXmlElement@@@Z) referenced in function "public: void __thiscall WRWorld::addStatic(class TiXmlElement *)" (?addStatic@WRWorld@@QAEXPAVTiXmlElement@@@Z)
C:\whiteRock\WallSocket\Bin\Debug\WhiteRockDebug.exe : fatal error LNK1120: 5 unresolved externals
I am not using the .lib file, I just added the .h and .cpp files to my project and there in the same directory as all the rest of my stuff. Is there something else I'm not checking for?
If you would like to refer to this comment somewhere else in this project, copy and paste the following link:
Using Visual Studio 7.1 trying to compile a project using TinyXML, and getting link errors:
Linking...
wEntity.obj : error LNK2019: unresolved external symbol "public: class TiXmlElement * __thiscall TiXmlNode::NextSiblingElement(char const *)const " (?NextSiblingElement@TiXmlNode@@QBEPAVTiXmlElement@@PBD@Z) referenced in function "public: void __thiscall wEntity::initEntity(class Ogre::SceneManager *,class TiXmlElement *)" (?initEntity@wEntity@@QAEXPAVSceneManager@Ogre@@PAVTiXmlElement@@@Z)
wEntity.obj : error LNK2019: unresolved external symbol "public: class TiXmlElement * __thiscall TiXmlNode::FirstChildElement(char const *)const " (?FirstChildElement@TiXmlNode@@QBEPAVTiXmlElement@@PBD@Z) referenced in function "public: void __thiscall wEntity::initEntity(class Ogre::SceneManager *,class TiXmlElement *)" (?initEntity@wEntity@@QAEXPAVSceneManager@Ogre@@PAVTiXmlElement@@@Z)
WRWorld.obj : error LNK2019: unresolved external symbol "public: void __thiscall wStatic::addStatic(class std::basic_string<char,struct std::char_traits<char>,class std::allocator<char> >,class std::basic_string<char,struct std::char_traits<char>,class std::allocator<char> >)" (?addStatic@wStatic@@QAEXV?$basic_string@DU?$char_traits@D@std@@V?$allocator@D@2@@std@@0@Z) referenced in function "public: void __thiscall WRWorld::addStatic(class std::basic_string<char,struct std::char_traits<char>,class std::allocator<char> >,class std::basic_string<char,struct std::char_traits<char>,class std::allocator<char> >)" (?addStatic@WRWorld@@QAEXV?$basic_string@DU?$char_traits@D@std@@V?$allocator@D@2@@std@@0@Z)
WRWorld.obj : error LNK2019: unresolved external symbol "public: void __thiscall wStatic::addStatic(class std::basic_string<char,struct std::char_traits<char>,class std::allocator<char> >,class std::basic_string<char,struct std::char_traits<char>,class std::allocator<char> >,class Ogre::Vector3)" (?addStatic@wStatic@@QAEXV?$basic_string@DU?$char_traits@D@std@@V?$allocator@D@2@@std@@0VVector3@Ogre@@@Z) referenced in function "public: void __thiscall WRWorld::addStatic(class std::basic_string<char,struct std::char_traits<char>,class std::allocator<char> >,class std::basic_string<char,struct std::char_traits<char>,class std::allocator<char> >,class Ogre::Vector3)" (?addStatic@WRWorld@@QAEXV?$basic_string@DU?$char_traits@D@std@@V?$allocator@D@2@@std@@0VVector3@Ogre@@@Z)
WRWorld.obj : error LNK2019: unresolved external symbol "public: void __thiscall wStatic::addStatic(class TiXmlElement *)" (?addStatic@wStatic@@QAEXPAVTiXmlElement@@@Z) referenced in function "public: void __thiscall WRWorld::addStatic(class TiXmlElement *)" (?addStatic@WRWorld@@QAEXPAVTiXmlElement@@@Z)
C:\whiteRock\WallSocket\Bin\Debug\WhiteRockDebug.exe : fatal error LNK1120: 5 unresolved externals
I am not using the .lib file, I just added the .h and .cpp files to my project and there in the same directory as all the rest of my stuff. Is there something else I'm not checking for?
On the "is it plugged in" front: Are you sure you got the tinyxml.cpp file? It looks like it may be missing?
I have certainly compiled TinyXML on VC6, .NET, and 2005 without problem, but it's hard to know what could be going wrong on your system.
sorry,
lee