X-Git-Url: http://mmka.chem.univ.gda.pl/gitweb/?a=blobdiff_plain;f=source%2Fwham%2Fsrc-M%2FCMakeLists.txt;h=4b3eb49cc330eaa0141073d1e3353660d1293e57;hb=6f0e7ef07e02a56fff97df63bd7f07d4b6fb50ce;hp=7f6c29541e92ca799245e3066dcb3c1d3764ce31;hpb=d635b1b4a9826a8cac0a4a20eff8c83465800187;p=unres.git diff --git a/source/wham/src-M/CMakeLists.txt b/source/wham/src-M/CMakeLists.txt index 7f6c295..4b3eb49 100644 --- a/source/wham/src-M/CMakeLists.txt +++ b/source/wham/src-M/CMakeLists.txt @@ -96,11 +96,13 @@ set(UNRES_WHAM_M_PP_SRC # Set comipiler flags for different sourcefiles #================================================ if (Fortran_COMPILER_NAME STREQUAL "ifort") - set(FFLAGS0 "-g -CB -I. -I${CMAKE_CURRENT_SOURCE_DIR}/include_unres" ) + set(FFLAGS0 "-mcmodel=medium -shared-intel -I. -I${CMAKE_CURRENT_SOURCE_DIR}/include_unres" ) elseif (Fortran_COMPILER_NAME STREQUAL "gfortran") - set(FFLAGS0 "-std=legacy -g -I. -I${CMAKE_CURRENT_SOURCE_DIR}/include_unres" ) + set(FFLAGS0 "-std=legacy -mcmodel=medium -g -I. -I${CMAKE_CURRENT_SOURCE_DIR}/include_unres" ) +elseif (Fortran_COMPILER_NAME STREQUAL "pgf90") + set(FFLAGS0 "-mcmodel=medium -Mlarge_arrays -I. -I${CMAKE_CURRENT_SOURCE_DIR}/include_unres" ) else () - set(FFLAGS0 "-g -I. -I${CMAKE_CURRENT_SOURCE_DIR}/include_unres" ) + set(FFLAGS0 "-g -mcmodel=medium -I. -I${CMAKE_CURRENT_SOURCE_DIR}/include_unres" ) endif (Fortran_COMPILER_NAME STREQUAL "ifort") @@ -155,6 +157,11 @@ elseif (Fortran_COMPILER_NAME STREQUAL "f95") elseif (Fortran_COMPILER_NAME STREQUAL "gfortran") # Add old gfortran flags set(CPPFLAGS "${CPPFLAGS} -DG77") +elseif (Fortran_COMPILER_NAME STREQUAL "pgf90") + set(CPPFLAGS "${CPPFLAGS} -DPGI") + FILE(COPY ${CMAKE_SOURCE_DIR}/source/lib/isnan_pgi.f DESTINATION ${CMAKE_CURRENT_BINARY_DIR} ) + list(APPEND UNRES_WHAM_M_SRC0 ${CMAKE_CURRENT_BINARY_DIR}/isnan_pgi.f) + set(CMAKE_EXE_LINKER_FLAGS "-Bdynamic") endif (Fortran_COMPILER_NAME STREQUAL "ifort") #========================================= @@ -255,6 +262,9 @@ install(TARGETS UNRES_WHAM_M_BIN DESTINATION ${CMAKE_INSTALL_PREFIX}/wham) if (UNRES_SRUN) set (np "-n") set (mpiexec "srun") + elseif(UNRES_MPIRUN) + set (np "-np") + set (mpiexec "mpirun") else() set (np "-np") set (mpiexec "mpiexec")