IdentifiantMot de passe
Loading...
Mot de passe oublié ?Je m'inscris ! (gratuit)
Navigation

Inscrivez-vous gratuitement
pour pouvoir participer, suivre les réponses en temps réel, voter pour les messages, poser vos propres questions et recevoir la newsletter

Boost C++ Discussion :

Probleme a compiler du code incluant asio


Sujet :

Boost C++

  1. #1
    Nouveau membre du Club
    Homme Profil pro
    Inscrit en
    Avril 2005
    Messages
    61
    Détails du profil
    Informations personnelles :
    Sexe : Homme
    Localisation : Canada

    Informations forums :
    Inscription : Avril 2005
    Messages : 61
    Points : 27
    Points
    27
    Par défaut Probleme a compiler du code incluant asio
    Bonjour, j'essai d'utiliser asio, pour commencer j'ai voulu essayé de compiler l'exemple du tutoriel asio que voici http://gwenael-dunand.developpez.com...st/asio/#LVI-B j'ai essayé de compiler le client de l'exemple avec le download des source en bas de la page, mais sa me renvois des erreurs...


    Code : Sélectionner tout - Visualiser dans une fenêtre à part
    1
    2
    3
    4
    5
    6
    7
    8
    9
    10
    11
    12
    13
    14
    15
    16
    17
    18
    19
    20
    21
    22
    23
    24
    25
    26
    27
    28
    29
    30
    31
    32
    33
    34
    35
    36
    37
    38
    39
    40
    41
    42
    43
    44
    45
    46
    47
    48
    49
    50
    51
    52
    53
    54
    55
    56
    57
    58
    59
    60
    61
    62
    63
    64
    65
    66
    67
    68
    69
    70
    71
    72
    73
    74
    75
    76
    77
    78
    obj/Debug/chat complet/chat client/chat client/chat_client.o||In function `__static_initialization_and_destruction_0':|
    /usr/include/boost/system/error_code.hpp|208|undefined reference to `boost::system::get_system_category()'|
    /usr/include/boost/system/error_code.hpp|209|undefined reference to `boost::system::get_generic_category()'|
    /usr/include/boost/system/error_code.hpp|214|undefined reference to `boost::system::get_generic_category()'|
    /usr/include/boost/system/error_code.hpp|215|undefined reference to `boost::system::get_generic_category()'|
    /usr/include/boost/system/error_code.hpp|216|undefined reference to `boost::system::get_system_category()'|
    obj/Debug/chat complet/chat client/chat client/chat_client.o||In function `error_code':|
    /usr/include/boost/system/error_code.hpp|315|undefined reference to `boost::system::get_system_category()'|
    obj/Debug/chat complet/chat client/chat client/chat_client.o||In function `boost::asio::error::get_system_category()':|
    /usr/include/boost/asio/error.hpp|218|undefined reference to `boost::system::get_system_category()'|
    obj/Debug/chat complet/chat client/chat client/chat_client.o||In function `~posix_thread':|
    /usr/include/boost/asio/detail/posix_thread.hpp|69|undefined reference to `pthread_detach'|
    obj/Debug/chat complet/chat client/chat client/chat_client.o||In function `boost::asio::detail::posix_thread::join()':|
    /usr/include/boost/asio/detail/posix_thread.hpp|77|undefined reference to `pthread_join'|
    obj/Debug/chat complet/chat client/chat client/chat_client.o||In function `text_iarchive':|
    /usr/include/boost/archive/text_iarchive.hpp|129|undefined reference to `boost::archive::text_iarchive_impl<boost::archive::text_iarchive>::text_iarchive_impl(std::basic_istream<char, std::char_traits<char> >&, unsigned int)'|
    /usr/include/boost/archive/text_iarchive.hpp|129|undefined reference to `boost::archive::detail::shared_ptr_helper::shared_ptr_helper()'|
    obj/Debug/chat complet/chat client/chat client/chat_client.o||In function `~text_iarchive':|
    /usr/include/boost/archive/text_iarchive.hpp|131|undefined reference to `boost::archive::detail::shared_ptr_helper::~shared_ptr_helper()'|
    obj/Debug/chat complet/chat client/chat client/chat_client.o||In function `text_oarchive':|
    /usr/include/boost/archive/text_oarchive.hpp|92|undefined reference to `boost::archive::text_oarchive_impl<boost::archive::text_oarchive>::text_oarchive_impl(std::basic_ostream<char, std::char_traits<char> >&, unsigned int)'|
    obj/Debug/chat complet/chat client/chat client/chat_client.o||In function `~text_iarchive_impl':|
    /usr/include/boost/archive/text_iarchive.hpp|80|undefined reference to `boost::archive::basic_text_iprimitive<std::basic_istream<char, std::char_traits<char> > >::~basic_text_iprimitive()'|
    /usr/include/boost/archive/text_iarchive.hpp|80|undefined reference to `boost::archive::basic_text_iprimitive<std::basic_istream<char, std::char_traits<char> > >::~basic_text_iprimitive()'|
    obj/Debug/chat complet/chat client/chat client/chat_client.o||In function `~text_oarchive_impl':|
    /usr/include/boost/archive/text_oarchive.hpp|77|undefined reference to `boost::archive::basic_text_oprimitive<std::basic_ostream<char, std::char_traits<char> > >::~basic_text_oprimitive()'|
    /usr/include/boost/archive/text_oarchive.hpp|77|undefined reference to `boost::archive::basic_text_oprimitive<std::basic_ostream<char, std::char_traits<char> > >::~basic_text_oprimitive()'|
    obj/Debug/chat complet/chat client/chat client/chat_client.o||In function `~common_iarchive':|
    /usr/include/boost/archive/detail/common_iarchive.hpp|43|undefined reference to `boost::archive::detail::basic_iarchive::~basic_iarchive()'|
    obj/Debug/chat complet/chat client/chat client/chat_client.o||In function `~common_oarchive':|
    /usr/include/boost/archive/detail/common_oarchive.hpp|38|undefined reference to `boost::archive::detail::basic_oarchive::~basic_oarchive()'|
    obj/Debug/chat complet/chat client/chat client/chat_client.o||In function `posix_tss_ptr':|
    /usr/include/boost/asio/detail/posix_tss_ptr.hpp|47|undefined reference to `pthread_key_create'|
    obj/Debug/chat complet/chat client/chat client/chat_client.o||In function `~posix_tss_ptr':|
    /usr/include/boost/asio/detail/posix_tss_ptr.hpp|61|undefined reference to `pthread_key_delete'|
    obj/Debug/chat complet/chat client/chat client/chat_client.o||In function `void boost::archive::detail::save_non_pointer_type<boost::archive::text_oarchive>::save_standard::invoke<chat_message>(boost::archive::text_oarchive&, chat_message const&)':|
    /usr/include/boost/archive/detail/oserializer.hpp|253|undefined reference to `boost::archive::detail::basic_oarchive::save_object(void const*, boost::archive::detail::basic_oserializer const&)'|
    obj/Debug/chat complet/chat client/chat client/chat_client.o||In function `void boost::archive::detail::load_non_pointer_type<boost::archive::text_iarchive>::load_standard::invoke<chat_message>(boost::archive::text_iarchive&, chat_message const&)':|
    /usr/include/boost/archive/detail/iserializer.hpp|381|undefined reference to `boost::archive::detail::basic_iarchive::load_object(void*, boost::archive::detail::basic_iserializer const&)'|
    obj/Debug/chat complet/chat client/chat client/chat_client.o||In function `oserializer':|
    /usr/include/boost/archive/detail/oserializer.hpp|112|undefined reference to `boost::archive::detail::basic_oserializer::basic_oserializer(boost::serialization::extended_type_info const&)'|
    obj/Debug/chat complet/chat client/chat client/chat_client.o||In function `~oserializer':|
    /usr/include/boost/archive/detail/oserializer.hpp|133|undefined reference to `boost::archive::detail::basic_oserializer::~basic_oserializer()'|
    obj/Debug/chat complet/chat client/chat client/chat_client.o||In function `iserializer':|
    /usr/include/boost/archive/detail/iserializer.hpp|133|undefined reference to `boost::archive::detail::basic_iserializer::basic_iserializer(boost::serialization::extended_type_info const&)'|
    obj/Debug/chat complet/chat client/chat client/chat_client.o||In function `~iserializer':|
    /usr/include/boost/archive/detail/iserializer.hpp|158|undefined reference to `boost::archive::detail::basic_iserializer::~basic_iserializer()'|
    obj/Debug/chat complet/chat client/chat client/chat_client.o||In function `extended_type_info_typeid':|
    /usr/include/boost/serialization/extended_type_info_typeid.hpp|86|undefined reference to `boost::serialization::typeid_system::extended_type_info_typeid_0::extended_type_info_typeid_0(char const*)'|
    /usr/include/boost/serialization/extended_type_info_typeid.hpp|88|undefined reference to `boost::serialization::typeid_system::extended_type_info_typeid_0::type_register(std::type_info const&)'|
    /usr/include/boost/serialization/extended_type_info_typeid.hpp|89|undefined reference to `boost::serialization::extended_type_info::key_register() const'|
    /usr/include/boost/serialization/extended_type_info_typeid.hpp|86|undefined reference to `boost::serialization::typeid_system::extended_type_info_typeid_0::~extended_type_info_typeid_0()'|
    obj/Debug/chat complet/chat client/chat client/chat_client.o||In function `~extended_type_info_typeid':|
    /usr/include/boost/serialization/extended_type_info_typeid.hpp|92|undefined reference to `boost::serialization::extended_type_info::key_unregister() const'|
    /usr/include/boost/serialization/extended_type_info_typeid.hpp|93|undefined reference to `boost::serialization::typeid_system::extended_type_info_typeid_0::type_unregister()'|
    /usr/include/boost/serialization/extended_type_info_typeid.hpp|94|undefined reference to `boost::serialization::typeid_system::extended_type_info_typeid_0::~extended_type_info_typeid_0()'|
    /usr/include/boost/serialization/extended_type_info_typeid.hpp|94|undefined reference to `boost::serialization::typeid_system::extended_type_info_typeid_0::~extended_type_info_typeid_0()'|
    ]+0x10)||undefined reference to `boost::serialization::typeid_system::extended_type_info_typeid_0::is_less_than(boost::serialization::extended_type_info const&) const'|
    ]+0x18)||undefined reference to `boost::serialization::typeid_system::extended_type_info_typeid_0::is_equal(boost::serialization::extended_type_info const&) const'|
    ]+0x10)||undefined reference to `boost::serialization::typeid_system::extended_type_info_typeid_0::is_less_than(boost::serialization::extended_type_info const&) const'|
    ]+0x18)||undefined reference to `boost::serialization::typeid_system::extended_type_info_typeid_0::is_equal(boost::serialization::extended_type_info const&) const'|
    ]+0x18)||undefined reference to `typeinfo for boost::serialization::typeid_system::extended_type_info_typeid_0'|
    ]+0x10)||undefined reference to `typeinfo for boost::archive::detail::basic_iserializer'|
    ]+0x10)||undefined reference to `typeinfo for boost::archive::detail::basic_oserializer'|
    ]+0x18)||undefined reference to `typeinfo for boost::archive::detail::basic_oarchive'|
    ]+0x18)||undefined reference to `typeinfo for boost::archive::detail::basic_iarchive'|
    obj/Debug/chat complet/chat client/chat client/chat_client.o||In function `boost::archive::detail::iserializer<boost::archive::text_iarchive, chat_message>::load_object_data(boost::archive::detail::basic_iarchive&, void*, unsigned int) const':|
    /usr/include/boost/archive/detail/iserializer.hpp|173|undefined reference to `boost::archive::archive_exception::archive_exception(boost::archive::archive_exception::exception_code, char const*, char const*)'|
    /usr/include/boost/archive/detail/iserializer.hpp|173|undefined reference to `boost::archive::archive_exception::~archive_exception()'|
    /usr/include/boost/archive/detail/iserializer.hpp|173|undefined reference to `boost::archive::archive_exception::~archive_exception()'|
    obj/Debug/chat complet/chat client/chat client/chat_client.o||In function `archive_exception':|
    /usr/include/boost/archive/archive_exception.hpp|45|undefined reference to `vtable for boost::archive::archive_exception'|
    /usr/include/boost/archive/archive_exception.hpp|45|undefined reference to `vtable for boost::archive::archive_exception'|
    obj/Debug/chat complet/chat client/chat client/chat_client.o||In function `void boost::serialization::throw_exception<boost::archive::archive_exception>(boost::archive::archive_exception const&)':|
    /usr/include/boost/serialization/throw_exception.hpp|36|undefined reference to `boost::archive::archive_exception::~archive_exception()'|
    ||More errors follow but not being shown.|
    ||Edit the max errors limit in compiler options...|
    ||=== Build finished: 50 errors, 0 warnings ===|
    Pourtant, j'ai les librarie system d'installé aussi : \

  2. #2
    Membre expérimenté

    Profil pro
    Inscrit en
    Juin 2006
    Messages
    1 294
    Détails du profil
    Informations personnelles :
    Localisation : Royaume-Uni

    Informations forums :
    Inscription : Juin 2006
    Messages : 1 294
    Points : 1 543
    Points
    1 543
    Par défaut
    Salut,

    Il faut que tu lies avec Boost.System donc par exemple ajouter un -lboost_system-gcc-mt-gd-1.46 qui dépend de la version que tu utilises.

    MAT.

  3. #3
    Nouveau membre du Club
    Homme Profil pro
    Inscrit en
    Avril 2005
    Messages
    61
    Détails du profil
    Informations personnelles :
    Sexe : Homme
    Localisation : Canada

    Informations forums :
    Inscription : Avril 2005
    Messages : 61
    Points : 27
    Points
    27
    Par défaut
    J'ai fait quelques essais, mais je ne trouve pas comment faire avec Code::Block.. (en passan je suis avec la version 1.42)

Discussions similaires

  1. [SDL 1.2] Probleme de compilation sous code blocks
    Par c3rise019 dans le forum SDL
    Réponses: 13
    Dernier message: 28/04/2014, 18h43
  2. Réponses: 16
    Dernier message: 20/02/2009, 14h03
  3. problems en compilant un code!
    Par t.n.b.g dans le forum Langage
    Réponses: 16
    Dernier message: 06/03/2008, 20h37
  4. Réponses: 3
    Dernier message: 29/08/2006, 16h47
  5. Probleme en compilant le code avec C2.EXE ?!?!?
    Par angelevil dans le forum VB 6 et antérieur
    Réponses: 4
    Dernier message: 17/11/2005, 16h13

Partager

Partager
  • Envoyer la discussion sur Viadeo
  • Envoyer la discussion sur Twitter
  • Envoyer la discussion sur Google
  • Envoyer la discussion sur Facebook
  • Envoyer la discussion sur Digg
  • Envoyer la discussion sur Delicious
  • Envoyer la discussion sur MySpace
  • Envoyer la discussion sur Yahoo