Skip to content
Snippets Groups Projects

Fix OpenACC configuration for LUMI

Merged Yen-Chen Chen requested to merge openacc_for_lumi into master
2 files
+ 7
4
Compare changes
  • Side-by-side
  • Inline
Files
2
+ 7
2
@@ -84,8 +84,13 @@ check_macro_defined(HAS_OPENACC_MACRO _OPENACC QUIET)
@@ -84,8 +84,13 @@ check_macro_defined(HAS_OPENACC_MACRO _OPENACC QUIET)
if (FS_ENABLE_OPENACC)
if (FS_ENABLE_OPENACC)
# If _OPENACC is defined, assume that the required compiler flags are already
# If _OPENACC is defined, assume that the required compiler flags are already
# provided, e.g. in CMAKE_Fortran_FLAGS:
# provided, e.g. in CMAKE_Fortran_FLAGS:
if(NOT HAS_OPENACC_MACRO)
if (NOT HAS_OPENACC_MACRO)
find_package(OpenACC REQUIRED)
# On LUMI, we only have OpenACC_Fortran, but no OpenACC_C
 
find_package(OpenACC QUIET)
 
if (NOT OpenACC_Fortran_FOUND)
 
message(FATAL_ERROR
 
"Could NOT find OpenACC_Fortran.")
 
endif ()
target_compile_options(fortran-support PRIVATE ${OpenACC_Fortran_OPTIONS})
target_compile_options(fortran-support PRIVATE ${OpenACC_Fortran_OPTIONS})
# This make sures that unit tests (FortUTF) compiles without the need of
# This make sures that unit tests (FortUTF) compiles without the need of
# passing OpenACC compile option.
# passing OpenACC compile option.
Loading