Testing Boost:threads on windows w/ cygwin/gcc help
Howdy,
I have cygwin running on a WinXP box and am trying to get the threads
up and running. I built the Boost.Threads and things look good.
Then I try:
"bjam -sTOOLS=gcc test"
from the /lib/thread/test directory and the test fails with:
<build>
...found 1203 targets...
...using 1 temp target...
...updating 181 targets...
...using
"sam
...using
test_thread.run... succeeded-test-file ../../../libs/thread/test/bin/test_thread.test/gcc/debug/runtime-link- static/threading-multi/test_thread.test
Syntax error: "fi" unexpected (expecting "then")
Try the boost CVS state; it now has shell-insensitive testing code. You may need a bjam update: http://sourceforge.net/project/showfiles.php?group_id=7586 (at the bottom) -- Dave Abrahams Boost Consulting www.boost-consulting.com
--- In Boost-Users@yahoogroups.com, David Abrahams
Try the boost CVS state; it now has shell-insensitive testing code.
You may need a bjam update:
(at the bottom)
--
Dave Abrahams
Boost Consulting
www.boost-consulting.com
I got the newest bjam.exe and had the same results. When I go into the $boost/lib/thread/test/bin/ and run the tests, test_mutex has errors, the others don't. So I assume my linking to the pthreads is not working properly. is there info on how to tell boost which threads to use? Is that located in the threads.jam file? Or do I just set the PTW32 ENV variable to point to the installation? thanks Sam
Ok, I'm a big nob, I have been setting the PTW32 to point to the pthreads installation I downloaded. So I have the boost.threads built with 'bjam -sTOOLS=gcc -sPTW32="c:\pthreads\ VC...lib" ' and the tests still fail. To use the standard threads I know you have to have threadmon.dll created, correct? How to do that?
sam said:
Ok,
I'm a big nob, I have been setting the PTW32 to point to the pthreads installation I downloaded. So I have the boost.threads built with 'bjam -sTOOLS=gcc -sPTW32="c:\pthreads\ VC...lib" ' and the tests still fail.
To use the standard threads I know you have to have threadmon.dll created, correct? How to do that?
With Boost 1.29.0, yes (the current CVS state is quite different, and always creates shared libraries instead of static libraries). The Jamfiles will create this DLL for you (provided you don't use PTW32!). -- William E. Kempf
sam said:
I got the newest bjam.exe and had the same results. When I go into the $boost/lib/thread/test/bin/ and run the tests, test_mutex has errors, the others don't.
So I assume my linking to the pthreads is not working properly. is there info on how to tell boost which threads to use?
MinGW and Cygwin with -mno-cygwin should both link against the native threads. I'm still trying to track down some GCC specific issues, however.
Is that located in the threads.jam file?
Sort of.
Or do I just set the PTW32 ENV variable to point to the installation?
If you're using MinGW and for some reason want to use pthreads-win32 as the implementation, then yes, this would be what you'd do. Note, however, that this particular build hasn't been tested in quite some time, and I can't tell you what you're results will be. -- William E. Kempf
participants (3)
-
David Abrahams
-
sam <samijackson@yahoo.com>
-
William E. Kempf