我的应用程序使用boost :: asio进行网络通信。 问题是,当我启动应用程序时,我得到:
$('input[name='+i+'].errorField.apply-form-multi-select').css("color", "red");
在解码之后,这转化为:
undefined symbol: _ZNKSt9type_infoeqERKS_
经过大量挖掘,要知道代码中的实际被引用的位置,我将std::type_info::operator==(std::type_info const&) const
添加到我的编译器标志中,导致编译时错误:
-Wl,--no-undefined
有关如何在错误中找到函数定义的任何建议吗?
编辑:
In function `boost::asio::ip::resolver_service<boost::asio::ip::tcp>& boost::asio::detail::service_registry::use_service<boost::asio::ip::resolver_service<boost::asio::ip::tcp> >()':
NetworkService.cpp:(.text._ZN5boost4asio6detail16service_registry11use_serviceINS0_2ip16resolver_serviceINS4_3tcpEEEEERT_v[boost::asio::ip::resolver_service<boost::asio::ip::tcp>& boost::asio::detail::service_registry::use_service<boost::asio::ip::resolver_service<boost::asio::ip::tcp> >()]+0x83): undefined reference to `std::type_info::operator==(std::type_info const&) const'
test.cpp是:
Boost version: 1.55
g++ (GCC) 4.1.2
g++ test.cpp -L$BIN/ -lcommunicationlayer -I/home/tmp/Boost1.55/boost_1_55_0
/bin/libcommunicationlayer.so: undefined reference to `std::type_info::operator==(std::type_info const&) const'
collect2: ld returned 1 exit status