cmake
Luca Pepè Sciarria 12 months ago
parent 7c153de54a
commit 0cb2c1c0c6

@ -75,10 +75,10 @@ endmacro()
# Create executables # Create executables
create_amg_executable(amg_df_sample ${DFSOBJS}) create_amg_executable(amg_df_sample "${DFSOBJS}")
create_amg_executable(amg_sf_sample ${SFSOBJS}) create_amg_executable(amg_sf_sample "${SFSOBJS}")
create_amg_executable(amg_cf_sample ${CFSOBJS}) create_amg_executable(amg_cf_sample "${CFSOBJS}")
create_amg_executable(amg_zf_sample ${ZFSOBJS}) create_amg_executable(amg_zf_sample "${ZFSOBJS}")
# Create "runs" directory (if it doesn't exist) # Create "runs" directory (if it doesn't exist)
add_custom_target(create_runs_dir add_custom_target(create_runs_dir

@ -18,6 +18,7 @@ endif()
find_package(psblas REQUIRED PATHS ${PSBLAS_INSTALL_DIR}) find_package(psblas REQUIRED PATHS ${PSBLAS_INSTALL_DIR})
find_package(amg4psblas REQUIRED PATHS ${AMG4PSBLAS_INSTALL_DIR}) find_package(amg4psblas REQUIRED PATHS ${AMG4PSBLAS_INSTALL_DIR})
set(CMAKE_CXX_STANDARD 17)
# Include directories # Include directories
include_directories( include_directories(
@ -25,6 +26,7 @@ include_directories(
"${AMG4PSBLAS_INSTALL_DIR}/include" "${AMG4PSBLAS_INSTALL_DIR}/include"
"${AMG4PSBLAS_INSTALL_DIR}/modules" "${AMG4PSBLAS_INSTALL_DIR}/modules"
"${PSBLAS_INSTALL_DIR}/include" "${PSBLAS_INSTALL_DIR}/include"
"${PSBLAS_INSTALL_DIR}/modules"
) )
# Fortran module directory # Fortran module directory
@ -115,7 +117,7 @@ macro(create_amg_executable target sources)
target_link_libraries(${target} PUBLIC target_link_libraries(${target} PUBLIC
${AMG_LIBS} ${AMG_LIBS}
${PSBLAS_LIBS} ${PSBLAS_LIBS}
stdc++
) )
# Move executable to EXEDIR (post-build) # Move executable to EXEDIR (post-build)
@ -129,10 +131,10 @@ endmacro()
# Create executables # Create executables
create_amg_executable(amg_d_pde3d ${amg_d_pde3d_SOURCES}) create_amg_executable(amg_d_pde3d "${amg_d_pde3d_SOURCES}")
create_amg_executable(amg_s_pde3d ${amg_s_pde3d_SOURCES}) create_amg_executable(amg_s_pde3d "${amg_s_pde3d_SOURCES}")
create_amg_executable(amg_d_pde2d ${amg_d_pde2d_SOURCES}) create_amg_executable(amg_d_pde2d "${amg_d_pde2d_SOURCES}")
create_amg_executable(amg_s_pde2d ${amg_s_pde2d_SOURCES}) create_amg_executable(amg_s_pde2d "${amg_s_pde2d_SOURCES}")
# Create "runs" directory (if it doesn't exist) # Create "runs" directory (if it doesn't exist)
add_custom_target(create_runs_dir add_custom_target(create_runs_dir

@ -76,14 +76,14 @@ macro(create_amg_executable target sources)
endmacro() endmacro()
# Create executables # Create executables
create_amg_executable(amg_dexample_ml ${DMOBJS}) create_amg_executable(amg_dexample_ml "${DMOBJS}")
create_amg_executable(amg_dexample_1lev ${D1OBJS}) create_amg_executable(amg_dexample_1lev "${D1OBJS}")
create_amg_executable(amg_zexample_ml ${ZMOBJS}) create_amg_executable(amg_zexample_ml "${ZMOBJS}")
create_amg_executable(amg_zexample_1lev ${Z1OBJS}) create_amg_executable(amg_zexample_1lev "${Z1OBJS}")
create_amg_executable(amg_sexample_ml ${SMOBJS}) create_amg_executable(amg_sexample_ml "${SMOBJS}")
create_amg_executable(amg_sexample_1lev ${S1OBJS}) create_amg_executable(amg_sexample_1lev "${S1OBJS}")
create_amg_executable(amg_cexample_ml ${CMOBJS}) create_amg_executable(amg_cexample_ml "${CMOBJS}")
create_amg_executable(amg_cexample_1lev ${C1OBJS}) create_amg_executable(amg_cexample_1lev "${C1OBJS}")
# Create "runs" directory (if it doesn't exist) # Create "runs" directory (if it doesn't exist)
add_custom_target(create_runs_dir add_custom_target(create_runs_dir

@ -73,10 +73,10 @@ macro(create_amg_executable target sources)
) )
endmacro() endmacro()
# Create executables # Create executables
create_amg_executable(amg_dexample_ml ${DMOBJS}) create_amg_executable(amg_dexample_ml "${DMOBJS}")
create_amg_executable(amg_dexample_1lev ${D1OBJS}) create_amg_executable(amg_dexample_1lev "${D1OBJS}")
create_amg_executable(amg_sexample_ml ${SMOBJS}) create_amg_executable(amg_sexample_ml "${SMOBJS}")
create_amg_executable(amg_sexample_1lev ${S1OBJS}) create_amg_executable(amg_sexample_1lev "${S1OBJS}")
# Create "runs" directory (if it doesn't exist) # Create "runs" directory (if it doesn't exist)
add_custom_target(create_runs_dir add_custom_target(create_runs_dir

Loading…
Cancel
Save