This is the mail archive of the
cygwin
mailing list for the Cygwin project.
Re: difficulty with c++ boost::thread (1.53.0) on Cygwin 1.7.20(0.266/5/3)
- From: Lewis S <lewis dot cygwin at gmail dot com>
- To: cygwin at cygwin dot com
- Date: Sun, 30 Jun 2013 16:06:19 -0700
- Subject: Re: difficulty with c++ boost::thread (1.53.0) on Cygwin 1.7.20(0.266/5/3)
- References: <fee89236a34f4d82ab3607bf14531e88 at star-mountain dot com> <51CFC91B dot 7080104 at gmail dot com> <CAOgZ4k_hpuwcaGv2=+OpjyDguDn3GdSLC__M2HdSHw7ODcbECQ at mail dot gmail dot com> <51D06E54 dot 80901 at gmail dot com>
Thanks for the information about nm
We're both using the same g++ -- and presumably the same boost & cygwin.
I'm still at the same error.
... unless there are other suggestions, I guess I'll re-install cygwin
and hope for the best.
With gratitude,
Lewis
On Sun, Jun 30, 2013 at 10:43 AM, marco atzeri <marco.atzeri@gmail.com> wrote:
> Il 6/30/2013 6:31 PM, Lewis S ha scritto:
>
>> Thanks Marco!
>>
>> I now get complaints about start_thread_noexcept:
>>
>> $ g++ -D THREADED multithread.cpp -l boost_system-mt -l boost_thread-mt
>
>
> it works on my system, with
>
> $ g++ --version
> g++ (GCC) 4.5.3
>
>
>
>>
>> /tmp/ccfP6V1v.o:multithread.cpp:(.text$_ZN5boost6thread12start_threadEv[boost::thread::start_thread()]+0xe):
>> undefined reference to `boost::thread::start_thread_noexcept()'
>> collect2: ld returned 1 exit status
>>
>> Can you (or anyone) tell me how to go from the "undefined reference"
>> error to the name of the library to be loaded?
>
>
> $ nm /usr/lib/libboost_thread-mt.dll.a |grep start_thread
> 00000000 I __imp___ZN5boost6thread12start_threadEv
> 00000000 T __ZN5boost6thread12start_threadEv
> 00000000 I __imp___ZN5boost6thread12start_threadERKNS_17thread_attributesE
> 00000000 T __ZN5boost6thread12start_threadERKNS_17thread_attributesE
>
>
>> Do the -l argument themselves require an order? If so, how do I learn
>> the required ordering (w/o trial&error)
>
>
> -l requires an order if one library depends on a following one.
> For your case both ways work
>
> g++ -D THREADED multithread.cpp -l boost_thread-mt -l boost_system-mt
>
> as there is no dependency between them
>
>>
>> With gratitude,
>> Lewis
>>
>>
>
> --
> Problem reports: http://cygwin.com/problems.html
> FAQ: http://cygwin.com/faq/
> Documentation: http://cygwin.com/docs.html
> Unsubscribe info: http://cygwin.com/ml/#unsubscribe-simple
>
--
Problem reports: http://cygwin.com/problems.html
FAQ: http://cygwin.com/faq/
Documentation: http://cygwin.com/docs.html
Unsubscribe info: http://cygwin.com/ml/#unsubscribe-simple