This commit is contained in:
Vitor Santos Costa
2018-03-17 10:38:56 +00:00
parent c33a0d72db
commit cc6eca6903
30 changed files with 435 additions and 345 deletions

View File

@@ -1,10 +1,11 @@
set (MPI_SOURCES
set (MPI_YAP_SOURCES
hash.c prologterms2c.c yap_mpi.c)
macro_optional_find_package(MPI ON)
if (MPI_C_FOUND)
if (MPI_FOUND)
if (MPI_C_FOUND)
# === Variables ===
#
# This module will set the following variables per language in your
@@ -67,7 +68,7 @@ if (MPI_C_FOUND)
# pass to the MPI program.
#
add_lib (yap_mpi ${MPI_SOURCES})
add_executable (yap_mpi ${MPI_YAP_SOURCES} Yaplib ../../console/yap.c)
target_link_libraries(yap_mpi libYap ${MPI_C_LIBRARIES})
@@ -76,11 +77,11 @@ if (MPI_C_FOUND)
include_directories (${MPI_C_INCLUDE_PATH})
add_definitions (-DHAVE_MPI_H=1)
target_compile_definitions(yap_mpi ${MPI_C_COMPILE_FLAGS})
install(TARGETS yap_mpi
LIBRARY DESTINATION ${YAP_INSTALL_DLLDIR}
RUNTIME DESTINATION ${YAP_INSTALL_DLLDIR}
ARCHIVE DESTINATION ${YAP_INSTALL_DLLDIR}
RUNTIME DESTINATION ${YAP_INSTALL_BDIR}
)
endif (MPI_C_FOUND)
endif (MPI_C_FOUND)
endif (MPI_FOUND)