[CMake] cmake on the BGP

Mathieu Malaterre mathieu.malaterre at gmail.com
Tue Sep 1 09:48:40 EDT 2009


On Tue, Sep 1, 2009 at 3:31 PM, John R. Cary<cary at txcorp.com> wrote:
> Mathieu Malaterre wrote:
>>
>> On Tue, Sep 1, 2009 at 2:49 PM, Mathieu
>> Malaterre<mathieu.malaterre at gmail.com> wrote:
>>
>>>
>>> On Tue, Sep 1, 2009 at 2:41 PM, Brad King<brad.king at kitware.com> wrote:
>>>
>>>>
>>>> Mathieu Malaterre wrote:
>>>>
>>>>>
>>>>> [  4%] Built target cmsys
>>>>> Linking C shared module libcmsysTestDynload.so
>>>>>
>>>>> /usr/lib/gcc/powerpc64-suse-linux/4.1.2/../../../../lib/crt1.o:(.rodata+0x4):
>>>>> undefined reference to `main'
>>>>>
>>>>
>>>> What does "make VERBOSE=1" say?  Clearly this linker
>>>> line is missing the flag to make it a shared library
>>>> instead of an executable.
>>>>
>>
>> Copying from Darwin-xlC I get now:
>>
>>
>>>
>>> cat Linux-XL-CXX.cmake
>>>
>>
>> SET(CMAKE_SHARED_LIBRARY_C_FLAGS "")
>> SET(CMAKE_SHARED_LIBRARY_LINK_C_FLAGS "")
>> SET(CMAKE_SHARED_LIBRARY_CXX_FLAGS "")
>> SET(CMAKE_SHARED_LIBRARY_LINK_CXX_FLAGS "")
>> SET(CMAKE_SHARED_LIBRARY_CREATE_C_FLAGS "-qmkshrobj")
>>
>
>
> I can verify that this made all work on intrepid.alcf.anl.gov.
>
> BTW - should a 'CXX.cmake' file include *_C_FLAGS?
>
> Curious about how these work.  I assume that cmake does
> a mapping from the OS and compiler to a Platform file, but
> then there are also Compiler files.   Could one put
> the above into Modules/Compiler/XL-CXX.cmake and have
> it work for all platforms?
>

Works for me too:

One compiler error:

http://www.cdash.org/CDash/viewBuildError.php?buildid=415252

Some test failing :

http://www.cdash.org/CDash/viewTest.php?onlyfailed&buildid=415252

hth
-- 
Mathieu


More information about the CMake mailing list