LINUX.ORG.RU
решено ФорумTalks

ppp over xmpp не компилируется :(


0

0

по мотивам.
http://www.linux.org.ru/view-message.jsp?msgid=2445958

как это чудо собрать?
при оригинальном исходнике выдает

$ g++ pppoj.cpp
pppoj.cpp: In function ‘int main(int, char**)’:
pppoj.cpp:94: error: ‘strcmp’ was not declared in this scope
pppoj.cpp:108: error: ‘system’ was not declared in this scope
pppoj.cpp:126: error: ‘memset’ was not declared in this scope

после добавления

14a15,16
> #include <string.h>
> #include <stdlib.h>

начинает выдавать

$ g++ pppoj.cpp
/tmp/ccwHnHOE.o: In function `Bot::recv()':
pppoj.1.cpp:(.text._ZN3Bot4recvEv[Bot::recv()]+0x18): undefined reference to `gloox::ClientBase::recv(int)'
/tmp/ccwHnHOE.o: In function `Bot::handleMessage(gloox::Stanza*, gloox::MessageSession*)':
pppoj.1.cpp:(.text._ZN3Bot13handleMessageEPN5gloox6StanzaEPNS0_14MessageSession E[Bot::handleMessage(gloox::Stanza*, gloox::MessageSession*)]+0x147): undefined reference to `gloox::Base64::decode64(std::basic_string<char, std::char_traits<char>, std::allocator<char> > const&)'
/tmp/ccwHnHOE.o: In function `gloox::JID::JID(std::basic_string<char, std::char_traits<char>, std::allocator<char> > const&)':
pppoj.1.cpp:(.text._ZN5gloox3JIDC1ERKSs[gloox::JID::JID(std::basic_string<char, std::char_traits<char>, std::allocator<char> > const&)]+0x67): undefined reference to `gloox::JID::setJID(std::basic_string<char, std::char_traits<char>, std::allocator<char> > const&)'
/tmp/ccwHnHOE.o: In function `Bot::Bot(int, char const*, char const*, char const*)':
pppoj.1.cpp:(.text._ZN3BotC1EiPKcS1_S1_[Bot::Bot(int, char const*, char const*, char const*)]+0x15a): undefined reference to `gloox::Client::Client(gloox::JID const&, std::basic_string<char, std::char_traits<char>, std::allocator<char> > const&, int)'
pppoj.1.cpp:(.text._ZN3BotC1EiPKcS1_S1_[Bot::Bot(int, char const*, char const*, char const*)]+0x1da): undefined reference to `gloox::ClientBase::registerMessageHandler(gloox::MessageHandler*)'
pppoj.1.cpp:(.text._ZN3BotC1EiPKcS1_S1_[Bot::Bot(int, char const*, char const*, char const*)]+0x248): undefined reference to `gloox::Client::setPresence(gloox::Presence, int, std::basic_string<char, std::char_traits<char>, std::allocator<char> > const&)'
pppoj.1.cpp:(.text._ZN3BotC1EiPKcS1_S1_[Bot::Bot(int, char const*, char const*, char const*)]+0x2a1): undefined reference to `gloox::ClientBase::connect(bool)'
pppoj.1.cpp:(.text._ZN3BotC1EiPKcS1_S1_[Bot::Bot(int, char const*, char const*, char const*)]+0x2d8): undefined reference to `gloox::ClientBase::recv(int)'
/tmp/ccwHnHOE.o: In function `Bot::send(void const*, int)':
pppoj.1.cpp:(.text._ZN3Bot4sendEPKvi[Bot::send(void const*, int)]+0x4c): undefined reference to `gloox::Base64::encode64(std::basic_string<char, std::char_traits<char>, std::allocator<char> > const&)'
pppoj.1.cpp:(.text._ZN3Bot4sendEPKvi[Bot::send(void const*, int)]+0x12c): undefined reference to `gloox::Stanza::createMessageStanza(gloox::JID const&, std::basic_string<char, std::char_traits<char>, std::allocator<char> > const&, gloox::StanzaSubType, std::basic_string<char, std::char_traits<char>, std::allocator<char> > const&, std::basic_string<char, std::char_traits<char>, std::allocator<char> > const&, std::basic_string<char, std::char_traits<char>, std::allocator<char> > const&)'
collect2: ld returned 1 exit status

как бы это побороть?
дистриб - debian Lenny
версия g++ - 4.3.2-2
версия libgloox - 0.9.9.5-1

★★★★★

10 апреля 2009 г.

Интересно, вообще, проект этот развивается?

Я вот пописываю немного, есть желание добавить многопоточность. Может есть смысл объединить усилия над этой вещью.

KRom
()
Вы не можете добавлять комментарии в эту тему. Тема перемещена в архив.