Re: [Boost-bugs] [Boost C++ Libraries] #5964: Linkage fails with cross-compiled boost.thread

Subject: Re: [Boost-bugs] [Boost C++ Libraries] #5964: Linkage fails with cross-compiled boost.thread
From: Boost C++ Libraries (noreply_at_[hidden])
Date: 2011-10-18 07:50:31


#5964: Linkage fails with cross-compiled boost.thread
--------------------------------------+-------------------------------------
  Reporter: anonymous | Owner: anthonyw
      Type: Bugs | Status: new
 Milestone: To Be Determined | Component: thread
   Version: Boost Development Trunk | Severity: Problem
Resolution: | Keywords:
--------------------------------------+-------------------------------------

Comment (by vleschuk@…):

 I reviewed the boost headers and found out that the second problem (with
 multiple definition of thread_data_base is caused because during build of
 boost itself posix threads are used, but when compiling headers for the
 application threadapi is being detected by compiler and OS defines. So it
 was trying to use Win32 threads. This can be solved by using
 BOOST_THREAD_POSIX define

 The following command works fine:

 x86_64-w64-mingw32-g++ -DBOOST_THREAD_POSIX -DBOOST_THREAD_USE_LIB
 -I/path/to/pthreads/headers -I/path/to/boost/headers -o test.exe
 test_boost.cpp -L/path/to/boost/lib -lboost_thread-mgw-mt-s-1_48
 -lpthreadGC2 -static-libgcc -static-libstdc++

 So I think this ticket should be closed as "not a bug".

-- 
Ticket URL: <https://svn.boost.org/trac/boost/ticket/5964#comment:3>
Boost C++ Libraries <http://www.boost.org/>
Boost provides free peer-reviewed portable C++ source libraries.

This archive was generated by hypermail 2.1.7 : 2017-02-16 18:50:07 UTC