Boost.Threads [message #159086] |
Sat, 26 November 2005 10:31  |
Eclipse User |
|
|
|
Originally posted by: ypox13p.yahoo.com
hello!
I am trying to compile/build a program which use the boost thread library.
I add the directoties(include,lib,link),the flag -mthreads but I still
have problem.Under CodeBlocks it's ok but not with cdt
the compiler output is the usuall:
**** Full rebuild of configuration Release for project threads ****
make -k clean all
rm -rf ./mutex.o ./mutex.d threads.exe
' '
'Building file: ../mutex.cpp'
'Invoking: GCC C++ Compiler'
g++ -I"C:\Program Files\CodeBlocks\include" -I"C:\Program
Files\CodeBlocks\the-agency\boost_1_31_0" -O0 -Wall -mthreads -omutex.o
../mutex.cpp
C:\DOCUME~1\george\LOCALS~1\Temp/cceibaaa.o:mutex.cpp:(.text +0x275):
undefined reference to `_imp___ZN5boost12thread_groupC1Ev'
C:\DOCUME~1\george\LOCALS~1\Temp/cceibaaa.o:mutex.cpp:(.text +0x2c9):
undefined reference to
`_imp___ZN5boost12thread_group13create_threadERKNS_9function 0IvSaINS_13function_baseEEEE'
C:\DOCUME~1\george\LOCALS~1\Temp/cceibaaa.o:mutex.cpp:(.text +0x34e):
undefined reference to `_imp___ZN5boost12thread_group8join_allEv'
C:\DOCUME~1\george\LOCALS~1\Temp/cceibaaa.o:mutex.cpp:(.text +0x365):
undefined reference to `_imp___ZN5boost12thread_groupD1Ev'
C:\DOCUME~1\george\LOCALS~1\Temp/cceibaaa.o:mutex.cpp:(.text +0x394):
undefined reference to `_imp___ZN5boost12thread_groupD1Ev'
C:\DOCUME~1\george\LOCALS~1\Temp/cceibaaa.o:mutex.cpp:(.text +0x41c):
undefined reference to `_imp___ZN5boost5mutexC1Ev'
C:\DOCUME~1\george\LOCALS~1\Temp/cceibaaa.o:mutex.cpp:(.text +0x46f):
undefined reference to `_imp___ZN5boost5mutexD1Ev'
C:\DOCUME~1\george\LOCALS~1\Temp/cceibaaa.o:mutex.cpp:(.text $_ZN5boost6detail6thread11scoped_lockINS_5mutexEE4lockEv[boo st::detail::thread::scoped_lock <boost::mutex>::lock()]+0x54):
undefined reference to `_imp___ZN5boost10lock_errorC1Ev'
C:\DOCUME~1\george\LOCALS~1\Temp/cceibaaa.o:mutex.cpp:(.text $_ZN5boost6detail6thread11scoped_lockINS_5mutexEE6unlockEv[b oost::detail::thread::scoped_lock <boost::mutex>::unlock()]+0x54):
undefined reference to `_imp___ZN5boost10lock_errorC1Ev'
C:\DOCUME~1\george\LOCALS~1\Temp/cceibaaa.o:mutex.cpp:(.text $_ZN5boost6detail6thread8lock_opsINS_5mutexEE4lockERS3_[boos t::detail::thread::lock_ops <boost::mutex>::lock(boost::mutex&)]+0xd):
undefined reference to `_imp___ZN5boost5mutex7do_lockEv'
C:\DOCUME~1\george\LOCALS~1\Temp/cceibaaa.o:mutex.cpp:(.text $_ZN5boost6detail6thread8lock_opsINS_5mutexEE6unlockERS3_[bo ost::detail::thread::lock_ops <boost::mutex>::unlock(boost::mutex&)]+0xd):
undefined reference to `_imp___ZN5boost5mutex9do_unlockEv'
C:\DOCUME~1\george\LOCALS~1\Temp/cceibaaa.o:mutex.cpp:(.text $_ZN7counterD1Ev[counter::~counter()]+0xd):
undefined reference to `_imp___ZN5boost5mutexD1Ev'
C:\DOCUME~1\george\LOCALS~1\Temp/cceibaaa.o:mutex.cpp:(.text $_ZN7counterC1Ev[counter::counter()]+0xd):
undefined reference to `_imp___ZN5boost5mutexC1Ev'
collect2: ld returned 1 exit status
make: *** [mutex.o] Error 1
make: Target `all' not remade because of errors.
Build complete for project threads
thanks.
|
|
|
|
|
Powered by
FUDForum. Page generated in 0.03455 seconds