[CMake] hpux (cma vs. pthreads)

George Neill georgen at neillnet.com
Thu Aug 14 23:14:57 EDT 2008


Alexander,

On Thu, Aug 14, 2008 at 2:45 PM, Alexander Neundorf
<a.neundorf-work at gmx.net> wrote:
> On Thursday 14 August 2008, George Neill wrote:
>> Hi All,
>>
>>   I am trying to compile a multi-threaded app (using pthreads) on hpux
>> 11.23 IA
>>
>> -- CMAKE_SYSTEM ...............................HP-UX-B.11.23
>> -- CMAKE_SYSTEM_NAME...........................HP-UX
>> -- CMAKE_SYSTEM_VERSION .......................B.11.23
>> -- CMAKE_C_COMPILER: ........................../opt/aCC/bin/cc
>> -- CMAKE_CXX_COMPILER: ......................../opt/aCC/bin/aCC
>>
>> It seems as though FindThreads.cmake is not complete.  I do _not_ want
>> to link with the cma thread library
>> (http://docs.hp.com/en/5187-0172/ch10s03.html).  There doesn't seem to
>> be an obvious way to tell FindThreads.cmake this.  I am thinking it
>> should prefer -lpthread over -lcma, if it exists.  Anyone have
>> suggestions on the best way to change FindThreads.cmake to handle
>> this?
>
> There is a feature request in the bug tracker for a FindPThreads.cmake:
> http://public.kitware.com/Bug/view.php?id=6399
>
> Please try the module attached there and let me know if it works for you.

It does work, however I am not using just pthreads on all platforms.
For now I have just copied FindThreads.cmake and commented out the
HPUX cma thread hack.  I will try to put together a patch for
FindThreads.cmake at a later date.

Thanks,
George.


More information about the CMake mailing list