Commit 34f4a26b authored by Nikos Nikoloutsakos's avatar Nikos Nikoloutsakos
Browse files

pddp2means: Add offload support cmakelists.txt

 Changes to be committed:
	modified:   ../CMakeLists.txt
parent 390d2533
......@@ -33,10 +33,11 @@ if("${CMAKE_C_COMPILER_ID}" STREQUAL "Intel")
message("** Enabling '${NAME_ICC}': with OpenMP")
else()
message("## Skipping '${NAME_ICC}': no OpenMP support found")
dummy_install(${NAME_ICC} "OpenMP")
#dummy_install(${NAME_ICC} "OpenMP")
endif()
if (MIC_FOUND)
# if MIC is found on the system
if (EXISTS "/usr/linux-k1om-4.7")
set(C_FLAGS "${C_FLAGS} -offload")
add_executable(${NAME_MIC} src/pddp_2means.c )
install(TARGETS ${NAME_MIC} DESTINATION bin)
......@@ -47,6 +48,15 @@ if("${CMAKE_C_COMPILER_ID}" STREQUAL "Intel")
endif()
# Else use GNU
else()
message("## Please use Intel Compilers for Offload mode")
if (OPENMP_FOUND)
set (CMAKE_C_FLAGS "${CMAKE_C_FLAGS} ${OpenMP_C_FLAGS} -lm")
add_executable(${NAME_GNU} src/pddp_2means.c )
install(TARGETS ${NAME_GNU} DESTINATION bin)
message("** Enabling '${NAME_GNU}': with OpenMP")
else()
message("## Skipping '${NAME_GNU}': no OpenMP support found")
#dummy_install(${NAME_GNU} "OpenMP")
endif()
endif()
# ==================================================================================================
Supports Markdown
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment