-
Notifications
You must be signed in to change notification settings - Fork 411
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Boost v1.67 Asio compile error for QNX700 #248
Comments
You'll get more attention from the Boost.ASIO maintainers if you post this on the ASIO subproject here: https://github.com/boostorg/asio or on the mailing list at boost-users@lists.boost.org. |
In my setup undefining _LIBCPP_HAS_NO_TEMPLATE_ALIASES helped! |
I meet the same problem when cross compile fast rtps for qnx!! |
@darbee I've checked vanilla LLVM headers and they follow the same logic, meaning that _LIBCPP_HAS_NO_TEMPLATE_ALIASES is defined for GCC compiler. I have no idea why that's the case. |
hi w0land @w0land , when I and -stdlib=libstdc++ flag when compling, It works. I learn that this flag will stop compiler from using llvm (qnx7/usr/include/c++/v1/). I do not know why LLVM has these problem |
I have the same problem with QNX SDP 7 (q++ 5.4.0) and Boost 1.69.0, 1.70.0 (currently available version). To be clear the following is not related to boost the errorThe error is a combination of code and compiler configuration (through compiler header files). For additional informations and instructions on how to solve this issue see here: boostorg/config#288 |
This is not a Boost.Config issue: Boost.Config already has:
Which would result in BOOST_NO_CXX11_ALLOCATOR being defined for this compiler. The issue is that Asio is not using Boost.Config and is not detecting this use case. |
Hi,
I am trying to build and use boost libraries for QNX700, but I cannot compile a test app for asio library.
Following is how I have ported the version 1.67.0:
Three files needs to be modified:
boost_1_67_0/boost/stacktrace/detail/location_from_symbol.hpp Line 31:
#if !defined(__QNX__) if (!::dladdr(addr, &dli_)) #else if (!::dladdr(const_cast<void*>(addr), &dli_)) #endif
boost_1_67_0/boost/stacktrace/detail/frame_unwind.ipp Line 87:
and how I have build it:
./b2 --layout=versioned --build-type=complete target-os=qnx toolset=qcc threadapi=pthread stage
The test App:
#include <boost/asio.hpp>
class timer
#include <string>
#include#include <boost/bind.hpp>
#include <boost/thread.hpp>{
public:timer(boost::asio::io_service &io):
m_timer(io),counter(0)
{timeout();
}private:
boost::asio::deadline_timer m_timer;unsigned int counter;
void timeout(){
std::cout<<boost::this_thread::get_id()<<":Timer:"<<counter++<<std::endl;m_timer.expires_from_now(boost::posix_time::seconds(1));
m_timer.async_wait(boost::bind(&timer::timeout,this));}
};int main( int argc, char* argv[] )
{boost::asio::io_service io_service;
timer t(io_service);io_service.run();
return 1;`}
and build the command:
`qcc src/main.cpp -o test.bin -I ../../boost_1_67 -L../../boost_1_67/stage/lib/ -lboost_system-qcc-mt-d-x64-1_67 -lboost_thread-qcc-mt-d-x64-1_67
and the error I get is:
Any help provided is highly appreciated.
Regards,
Afshin
The text was updated successfully, but these errors were encountered: