Skip to content

Cray build issue problems - advice? #101

@dtaller

Description

@dtaller

I recently tried to build scalapack on a Cray machine, but ran into issues. The first issue occured with the code block

find_package(MPI)
if (MPI_FOUND)
   message(STATUS "Found MPI_LIBRARY : ${MPI_FOUND} ")
   INCLUDE_DIRECTORIES(${MPI_INCLUDE_PATH})

   find_program(MPI_C_COMPILER
      NAMES mpicc
      HINTS "${MPI_BASE_DIR}"
      PATH_SUFFIXES bin
      DOC "MPI C compiler.")
   MARK_AS_ADVANCED(MPI_C_COMPILER)
   if ("${MPI_C_COMPILER}" STREQUAL "MPI_C_COMPILER-NOTFOUND")
      message(ERROR "--> MPI C Compiler NOT FOUND (please set MPI_BASE_DIR accordingly")

Basically, on the Cray machine, I am supposed to load the modules I want, and then use compiler wrappers CC, cc, and ftn (point to whichever compiler and mpi I need). So this logic where we search for mpicc failed.

In addition, the logic

if (UNIX)
   if ("${CMAKE_Fortran_COMPILER_ID}" STREQUAL "Intel")
      set( CMAKE_Fortran_FLAGS "${CMAKE_Fortran_FLAGS} -fltconsistency -fp_port" )
   endif ()
endif ()

failed because the cray-compatible intel compiler did not support the -fp_port flag.

I was able to resolve these issues by commenting out the offending lines in the cmake file. But I was wondering if you can think of a better solution?

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions