[CMake] Cray wrappers and Intel compilers
Thompson, KT
kgt at lanl.gov
Tue May 5 12:42:30 EDT 2015
Lucas,
When using CMake on our Cray environments (XE6, Intel compilers under the Cray wrappers), I do the following:
1. Create CMakeCache.txt in the build directory with these contents:
CMAKE_SYSTEM_NAME:STRING=Catamount
CMAKE_C_COMPILER:FILEPATH=cc
CMAKE_CXX_COMPILER:FILEPATH=CC
CMAKE_Fortran_COMPILER:FILEPATH=ftn
2. cmake /path/to/source
Maybe the CMake experts on the list can tell us a better way.
-kt
From: CMake [mailto:cmake-bounces at cmake.org] On Behalf Of Lucas.Pettey at engilitycorp.com
Sent: Tuesday, May 05, 2015 10:14 AM
To: cmake [cmake at cmake.org]
Subject: [CMake] Cray wrappers and Intel compilers
Hello,
I have been trying to use Cmake 3.2.2 on a Cray XC30 with the Intel compilers loaded. I encounter the following error:
/opt/cray/craype/2.2.0/bin/cc -o
CMakeFiles/cmTryCompileExec2303156381.dir/testCCompiler.c.o -c
/p/home/lpettey/adh/parmetis-4.0.3/build/Linux-x86_64/CMakeFiles/CMakeTmp/testCCompiler.c
Linking C executable cmTryCompileExec2303156381
/p/home/lpettey/cmake-3.2.2/install/bin/cmake -E cmake_link_script
CMakeFiles/cmTryCompileExec2303156381.dir/link.txt --verbose=1
/opt/cray/craype/2.2.0/bin/cc
CMakeFiles/cmTryCompileExec2303156381.dir/testCCompiler.c.o -o
cmTryCompileExec2303156381 -rdynamic
ld: dynamic STT_GNU_IFUNC symbol `strcmp' with pointer equality in
`/usr/lib64/gcc/x86_64-suse-linux/4.3/../../../../lib64/libc.a(strcmp.o)'
can not be used when making an executable; recompile with -fPIE and relink
with -pie
Is there any way to ask Cmake not to add the -rdynamic to the link line? I believe this is what is causing the error.
Thanks,
Lucas Pettey, PhD
HPCMP PETTT EQM CTA Lead
ERDC-DSRC OnSite
Vicksburg, MS
512-297-9833 Mobile (preferred)
601-634-2980 Office
lucas.pettey at engilitycorp.com<mailto:lucas.pettey at engilitycorp.com>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://public.kitware.com/pipermail/cmake/attachments/20150505/9e4aa555/attachment.html>
More information about the CMake
mailing list