Subj : Re: Where to download a pthread library To : comp.programming.threads From : David Hopwood Date : Thu Mar 31 2005 06:42 pm Marcin 'Qrczak' Kowalczyk wrote: > I'm now checking -pthread, -pthreads and -mt. That is: > > 1. Find first of these options which doesn't cause an error message > from the compiler. Don't add any options if none are recognized. > > 2. Under these settings, check if pthread_create returns 0. > > 3. If pthread_create works, keep the options and use pthreads. > Otherwise revert the options and don't use pthreads. > > Anything else? Should I try -lpthread too? Something this useful must have been done before. And indeed it has: > GCC docs describe -pthread, -pthreads and -mt only in architecture-specific > chapters. They don't say anything about an option which is portable to > all GCC ports. Mentioned briefly in and but there doesn't appear to be a specific bug/RFE about this, so I submitted one: -- David Hopwood .