Click here to Skip to main content
15,887,683 members
Please Sign up or sign in to vote.
0.00/5 (No votes)
I am porting my C++ application from windows to Linux.

While porting thread related stuff, what i observed is , we can use pthread. Is ther any other way out there in Linux for multithreading other than pthraed ?
Posted

1 solution

You can use the Thread module from the open source C++ library Boost. If you dont know Boost yet it is something you should look into anyway.
http://www.boost.org/doc/libs/1_51_0/doc/html/thread.html[^]
 
Share this answer
 
v2
Comments
PrafullaVedante 22-Oct-12 3:20am    
is ther anything which is native ? and not third party ?
Legor 22-Oct-12 3:51am    
I'm not aware of anything else. But also Boost is a third party library which is very advisable. Many of the new features in C++0x for example were first provided in Boost (which isn't a suprise since Boost was founded by members of the C++ standardization commitee). In my opinion (and many others) every C++ developer should get known to Boost. It is especially for your case since Boost is designed to enable the development of portable code.
markkuk 22-Oct-12 7:32am    
Pthreads are the native way of multithreading on Linux and all other Unix/Posix -style operating systems. C++11 http://en.wikipedia.org/wiki/C%2B%2B11 has threads in its standard library, so you don't need third-party classes when a C++11 compatible G++ becomes available.

This content, along with any associated source code and files, is licensed under The Code Project Open License (CPOL)



CodeProject, 20 Bay Street, 11th Floor Toronto, Ontario, Canada M5J 2N8 +1 (416) 849-8900