Open ghost opened 6 years ago
I have installed sudo apt-get install libxml2-dev but I don't know why do I get these error message when I want to make the libaiml AIML interpreter:
sudo apt-get install libxml2-dev
make
libaiml
make all-recursive make[1]: Entering directory '/home/m/libaiml' Making all in src make[2]: Entering directory '/home/m/libaiml/src' make[2]: Nothing to be done for 'all'. make[2]: Leaving directory '/home/m/libaiml/src' Making all in test_app make[2]: Entering directory '/home/m/libaiml/test_app' Making all in aiml make[3]: Entering directory '/home/m/libaiml/test_app/aiml' make[3]: Nothing to be done for 'all'. make[3]: Leaving directory '/home/m/libaiml/test_app/aiml' make[3]: Entering directory '/home/m/libaiml/test_app' /bin/bash ../libtool --tag=CXX --mode=link g++ -Wall -Werror -ansi -pedantic `xml2-config --cflags` -g -O2 -o test_app `xml2-config --libs` main.o ../src/libaiml.a -lstd_utils g++ -Wall -Werror -ansi -pedantic -I/usr/include/libxml2 -g -O2 -o test_app main.o -lxml2 ../src/libaiml.a -lstd_utils ../src/libaiml.a(user_manager.o): In function `aiml::cUserManager::cUserManager(aiml::cCore&)': /home/m/libaiml/src/user_manager.cpp:32: undefined reference to `xmlNewParserCtxt' ../src/libaiml.a(user_manager.o): In function `aiml::cUserManager::~cUserManager()': /home/m/libaiml/src/user_manager.cpp:36: undefined reference to `xmlFreeParserCtxt' ../src/libaiml.a(user_manager.o): In function `aiml::cUserManager::save(std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char> > const&)': /home/m/libaiml/src/user_manager.cpp:101: undefined reference to `xmlNewTextWriterFilename' /home/m/libaiml/src/user_manager.cpp:104: undefined reference to `xmlTextWriterSetIndent' /home/m/libaiml/src/user_manager.cpp:105: undefined reference to `xmlTextWriterSetIndentString' /home/m/libaiml/src/user_manager.cpp:108: undefined reference to `xmlTextWriterStartDocument' /home/m/libaiml/src/user_manager.cpp:109: undefined reference to `xmlTextWriterStartElement' /home/m/libaiml/src/user_manager.cpp:113: undefined reference to `xmlTextWriterStartElement' /home/m/libaiml/src/user_manager.cpp:114: undefined reference to `xmlTextWriterWriteAttribute' /home/m/libaiml/src/user_manager.cpp:118: undefined reference to `xmlTextWriterStartElement' /home/m/libaiml/src/user_manager.cpp:119: undefined reference to `xmlTextWriterWriteAttribute' /home/m/libaiml/src/user_manager.cpp:120: undefined reference to `xmlTextWriterWriteCDATA' /home/m/libaiml/src/user_manager.cpp:121: undefined reference to `xmlTextWriterEndElement' /home/m/libaiml/src/user_manager.cpp:123: undefined reference to `xmlTextWriterEndElement' /home/m/libaiml/src/user_manager.cpp:126: undefined reference to `xmlTextWriterEndElement' /home/m/libaiml/src/user_manager.cpp:127: undefined reference to `xmlTextWriterEndDocument' /home/m/libaiml/src/user_manager.cpp:138: undefined reference to `xmlFreeTextWriter' ../src/libaiml.a(user_manager.o): In function `aiml::cUserManager::load(std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char> > const&)': /home/m/libaiml/src/user_manager.cpp:51: undefined reference to `xmlCtxtReadFile' /home/m/libaiml/src/user_manager.cpp:55: undefined reference to `xmlDocGetRootElement' /home/m/libaiml/src/user_manager.cpp:93: undefined reference to `xmlFreeDoc' ../src/libaiml.a(config_parser.o): In function `aiml::cConfigParser::cConfigParser(aiml::cCore&)': /home/m/libaiml/src/config_parser.cpp:38: undefined reference to `xmlNewParserCtxt' ../src/libaiml.a(config_parser.o): In function `aiml::cConfigParser::~cConfigParser()': /home/m/libaiml/src/config_parser.cpp:42: undefined reference to `xmlFreeParserCtxt' ../src/libaiml.a(config_parser.o): In function `aiml::cConfigParser::load(std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char> > const&, bool)': /home/m/libaiml/src/config_parser.cpp:51: undefined reference to `xmlCtxtReadFile' /home/m/libaiml/src/config_parser.cpp:55: undefined reference to `xmlDocGetRootElement' /home/m/libaiml/src/config_parser.cpp:78: undefined reference to `xmlFreeDoc' ../src/libaiml.a(aiml_parser.o): In function `aiml::AIMLparser::onError()': /home/m/libaiml/src/aiml_parser.cpp:120: undefined reference to `xmlCtxtGetLastError' /home/m/libaiml/src/aiml_parser.cpp:120: undefined reference to `xmlCtxtGetLastError' /home/m/libaiml/src/aiml_parser.cpp:124: undefined reference to `xmlStopParser' ../src/libaiml.a(aiml_parser.o): In function `aiml::AIMLparser::onFatalError()': /home/m/libaiml/src/aiml_parser.cpp:130: undefined reference to `xmlCtxtGetLastError' /home/m/libaiml/src/aiml_parser.cpp:130: undefined reference to `xmlCtxtGetLastError' /home/m/libaiml/src/aiml_parser.cpp:134: undefined reference to `xmlStopParser' ../src/libaiml.a(aiml_parser.o): In function `aiml::AIMLparser::startElement(std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char> > const&, std::__cxx11::list<std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char> >, std::allocator<std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char> > > > const&)': /home/m/libaiml/src/aiml_parser.cpp:211: undefined reference to `xmlStopParser' /home/m/libaiml/src/aiml_parser.cpp:296: undefined reference to `xmlStopParser' /home/m/libaiml/src/aiml_parser.cpp:337: undefined reference to `xmlStopParser' ../src/libaiml.a(aiml_parser.o): In function `aiml::AIMLparser::parse(std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char> > const&, bool, bool)': /home/m/libaiml/src/aiml_parser.cpp:88: undefined reference to `xmlCreateFileParserCtxt' /home/m/libaiml/src/aiml_parser.cpp:94: undefined reference to `xmlParseDocument' /home/m/libaiml/src/aiml_parser.cpp:102: undefined reference to `xmlFreeDoc' /home/m/libaiml/src/aiml_parser.cpp:103: undefined reference to `xmlFreeParserCtxt' collect2: error: ld returned 1 exit status Makefile:225: recipe for target 'test_app' failed make[3]: *** [test_app] Error 1 make[3]: Leaving directory '/home/m/libaiml/test_app' Makefile:274: recipe for target 'all-recursive' failed make[2]: *** [all-recursive] Error 1 make[2]: Leaving directory '/home/m/libaiml/test_app' Makefile:250: recipe for target 'all-recursive' failed make[1]: *** [all-recursive] Error 1 make[1]: Leaving directory '/home/m/libaiml' Makefile:179: recipe for target 'all' failed make: *** [all] Error 2
I have installed
sudo apt-get install libxml2-dev
but I don't know why do I get these error message when I want tomake
thelibaiml
AIML interpreter: