<div dir="ltr"><div><div><div><div><div>Hi Tim,<br><br></div>When building CMake on a Cray, you'll want to build using the host system compilers, i.e. /usr/bin/gcc and /usr/bin/g++, not with the cray compiler wrappers. Usually I just do:<br><br></div><span style="font-family:monospace,monospace">module purge<br></span></div><span style="font-family:monospace,monospace">CC=/usr/bin/gcc CXX=/usr/bin/g++ /path/to/cmake_source/bootstrap --prefix=/path/to/cmake/install --parallel=8<br></span></div><span style="font-family:monospace,monospace">make -j8 install</span><br><br></div>The resulting CMake binary can then run on either the login nodes or compute nodes and target anything that CMake supports. I would also suggest building CMake from either the latest git master branch or the current 3.5 release candidate. I've added a new platform file for the Cray Linux Environment that knows how to introspect the compiler wrappers, correctly deal with static / shared, etc, not currently available in the 3.4 release. You can use it by loading your appropriate PrgEnv module setting CMAKE_SYSTEM_NAME=CrayLinuxEnvironment or using a toolchain file like this:<br><br><span style="font-family:monospace,monospace"># The name of the target operating system<br>set(CMAKE_SYSTEM_NAME CrayLinuxEnvironment) # This handles all the oddball Cray stuff<br><br>if(DEFINED ENV{ASYNCPE_DIR}) # Older Cray programming environment<br> set(COMP_DIR $ENV{ASYNCPE_DIR})<br>elseif(DEFINED ENV{CRAYPE_DIR}) # Newer Cray programming environment<br> set(COMP_DIR $ENV{CRAYPE_DIR})<br>else()<br> message(FATAL_ERROR "Unable to determine compiler dir")<br>endif()<br><br># Set the compilers<br>set(CMAKE_C_COMPILER ${COMP_DIR}/bin/cc)<br>set(CMAKE_CXX_COMPILER ${COMP_DIR}/bin/CC)<br>set(CMAKE_Fortran_COMPILER ${COMP_DIR}/bin/ftn)</span><br><br><div class="gmail_extra"><br clear="all"><div><div><div dir="ltr">- Chuck<br></div></div></div>
<br><div class="gmail_quote">On Fri, Feb 5, 2016 at 5:36 AM, Tim Gallagher <span dir="ltr"><<a href="mailto:tim.gallagher@gatech.edu" target="_blank">tim.gallagher@gatech.edu</a>></span> wrote:<br><blockquote class="gmail_quote" style="margin:0px 0px 0px 0.8ex;border-left:1px solid rgb(204,204,204);padding-left:1ex"><div><div style="font-family:times new roman,new york,times,serif;font-size:12pt;color:rgb(0,0,0)">Sorry if you get this multiple times -- the original was blocked from the PV list because the output log was too big. I can send the log I referred to off-list to anybody who is interested.<br><br>--------------------------------------------------<br><br>Good morning!<br><br>Thanks Andy and Richard for the advice.<br><br>After banging my head on my keyboard for most of the day <span>yesterday</span>, neither approach worked on Copper. <br><br>For
Andy's suggestion of building pv5.0 with the Cray cross compiling
script, I got a bunch of errors towards the end. It looks like many
things did build, but then those errors about an unknown system kicked
in and it seemed to all fall apart. I attached the output log as
cray_build_pv5.0.txt <br><br>Richard, I tried your setup as well. I
initially was trying to avoid the building CMake step but eventually
something in the ParaviewSuperbuild failed because it said it needed
CMake 2.8.11 and Copper only has 2.8.10. So, I took a step back and
tried to build CMake. When I just do what is in your script -- configure
and then make -- the build fails quickly because it says it cannot
statically link shared libraries. So I tried to build CMake using the
Catamount.cmake toolchain that we use for our application code as well.
The initial configuration took over an hour, it sits at 95% for a long
time going through the portion where it looks for various
headers/features. But eventually it finishes and I tried to build but
that failed. I get:<br><br>tgallagh@copper01:~/cmake/build> make<br>[ 3%] Built target cmsys<br>[ 4%] Built target cmsys_c<br>[ 6%] Built target cmzlib<br>[ 6%] Building C object Utilities/cmcurl/lib/CMakeFiles/cmcurl.dir/strerror.c.o<br>/u/tgallagh/cmake/cmake/Utilities/cmcurl/lib/strerror.c:32:6:
error: #error "strerror_r MUST be either POSIX, glibc or vxworks-style"<br> # error "strerror_r MUST be either POSIX, glibc or vxworks-style"<br> ^<br>make[2]: *** [Utilities/cmcurl/lib/CMakeFiles/cmcurl.dir/strerror.c.o] Error 1<br>make[1]: *** [Utilities/cmcurl/lib/CMakeFiles/cmcurl.dir/all] Error 2<br><br>So
taking a big step backwards here to look at the big picture -- am I
(and our lab) just using Cray systems in a fundamentally incorrect way?
We've always struggled to get things to build when we never have had
issues with SGI/Intel, BlueGene, or IBM machines (even when they were
using PowerPC). We used to have all these same issues with our CFD code
on Cray as well and the only solution we found was to build all of our
codes' libraries statically and drop support for shared libraries. <br><br>I
appreciate the help with the scripts. If there's any follow-up advice
on what I'm doing wrong in both/either approach, that would be great.<br><br>Thanks,<br><br>Tim</div></div><br>_______________________________________________<br>
Powered by <a href="http://www.kitware.com" rel="noreferrer" target="_blank">www.kitware.com</a><br>
<br>
Visit other Kitware open-source projects at <a href="http://www.kitware.com/opensource/opensource.html" rel="noreferrer" target="_blank">http://www.kitware.com/opensource/opensource.html</a><br>
<br>
Please keep messages on-topic and check the ParaView Wiki at: <a href="http://paraview.org/Wiki/ParaView" rel="noreferrer" target="_blank">http://paraview.org/Wiki/ParaView</a><br>
<br>
Search the list archives at: <a href="http://markmail.org/search/?q=ParaView" rel="noreferrer" target="_blank">http://markmail.org/search/?q=ParaView</a><br>
<br>
Follow this link to subscribe/unsubscribe:<br>
<a href="http://public.kitware.com/mailman/listinfo/paraview" rel="noreferrer" target="_blank">http://public.kitware.com/mailman/listinfo/paraview</a><br>
<br></blockquote></div><br></div></div>