undefined reference to `tinyxml2::XMLDocument::LoadFile(char const*)'
Hello, I am running the xmltest.cpp on visual studio code 2022. I got the error listed below. The compiler is g++ version 7.5.0. I tried to install older version on the device(Ubuntu 20.04). However Ubuntu 20.04 doesn't support older versions. I am wondering how could be solved?
/tinyxml2-master/xmltest.cpp:67: undefined reference to tinyxml2::XMLDocument::ErrorIDToName(tinyxml2::XMLError)' /tinyxml2-master/xmltest.cpp:67: undefined reference to tinyxml2::XMLDocument::ErrorIDToName(tinyxml2::XMLError)'
/tinyxml2-master/xmltest.cpp:117: undefined reference to tinyxml2::XMLDocument::XMLDocument(bool, tinyxml2::Whitespace)' /tinyxml2-master/xmltest.cpp:118: undefined reference to tinyxml2::XMLDocument::LoadFile(char const*)'
Thanks