[CMake] FindThreads: the odd one out?

Marcel Loose loose at astron.nl
Fri Aug 28 04:29:19 EDT 2009


Hi all,

Up till now I've been using the not officially supported and released
FindPthreads.cmake macro to check for the presence of pthreads. However,
the maintainer of that macro wrote (a comment in Mantis) that he would
drop support for FindPthreads in favor of the more general and
officially supported FindThreads.cmake macro.

However, I have some difficulty understandig how to properly use
FindThreads.cmake. Contrary to most FindXXX macros it does not set
THREADS_INCLUDE_DIR and THREADS_LIBRARY. It does set some *_INIT
variables, but I thought that *_INIT variables were only used by CMake
itself to preset compiler and linker flags, and that these were not to
be used outside.

Could someone shed a light on this?

Best regards,
Marcel Loose.




More information about the CMake mailing list