
Le 22/03/12 17:41, John Maddock a écrit :
There is an issue on Boost.Thread regression test for PGI compiler. See https://svn.boost.org/trac/boost/ticket/6354.
"pgCC" -INLINE:none -Kieee -fpic -fPIC -gopt -Minform=warn -DBOOST_ALL_NO_LIB=1 -DBOOST_TEST_NO_AUTO_LINK=1 -DBOOST_THREAD_POSIX -DBOOST_THREAD_USE_DLL=1 -D__need_IOV_MAX -I".." -c -o "/scratch/kbelco/boost/results/boost/bin.v2/libs/thread/test/test_barrier.test/pgi-11.9/debug/threading-multi/test_barrier.o" "../libs/thread/test/test_barrier.cpp"
"../boost/config/requires_threads.hpp", line 86: catastrophic error: #error directive: "Compiler threading support is not turned on. Please consult your compiler's documentation for the appropriate options to use" # error "Compiler threading support is not turned on. Please consult your compiler's documentation for the appropriate options to use"
boost/config/compiler/pgi.hpp defines BOOST_HAS_PTHREADS but not BOOST_HAS_THREADS, resulting in failure in the requires_threads.hpp header.
It seems that adding
#define BOOST_HAS_THREADS
inboost/config/compiler/pgi.hpp solves the issue.
John, what do you think?
If it's true that the compiler always supports threads, then yes go for it.
Hi John, I have added it just fro version higher equal than 11 #if __PGIC__ >= 11 // options requested by configure --enable-test #define BOOST_HAS_PTHREADS *#define BOOST_HAS_THREADS* Committed revision 77487. I will check how this works on trunk. Vicente