diff --git a/cmake_modules/morse/find/FindSTARPU.cmake b/cmake_modules/morse/find/FindSTARPU.cmake index 4de459a6b0da0c3e463d311a35b320f40ad820bc..376ee95f3777032dd233d69dba87c9c8a04daf35 100644 --- a/cmake_modules/morse/find/FindSTARPU.cmake +++ b/cmake_modules/morse/find/FindSTARPU.cmake @@ -368,14 +368,18 @@ if( (NOT STARPU_SHM_FOUND) OR (NOT STARPU_SHM_LIBRARIES) OR message(STATUS "Looking for starpu -- ${starpu_hdr} not found") endif() if(starpu_hdr STREQUAL "starpu_mpi.h") - if(NOT ${STARPU_FIND_REQUIRED_MPI} STREQUAL 1 AND NOT STARPU_FIND_QUIETLY) - message(STATUS "Looking for starpu -- ${starpu_hdr} not required") + if(NOT ${STARPU_FIND_REQUIRED_MPI} STREQUAL 1) + if (NOT STARPU_FIND_QUIETLY) + message(STATUS "Looking for starpu -- ${starpu_hdr} not required") + endif() else() list(APPEND STARPU_INCLUDE_DIRS "${STARPU_${starpu_hdr}_INCLUDE_DIRS}" ) endif() elseif( (starpu_hdr STREQUAL "starpu_cuda.h") OR (starpu_hdr STREQUAL "starpu_scheduler.h") ) - if(NOT ${STARPU_FIND_REQUIRED_CUDA} STREQUAL 1 AND NOT STARPU_FIND_QUIETLY) - message(STATUS "Looking for starpu -- ${starpu_hdr} not required") + if(NOT ${STARPU_FIND_REQUIRED_CUDA} STREQUAL 1) + if (NOT STARPU_FIND_QUIETLY) + message(STATUS "Looking for starpu -- ${starpu_hdr} not required") + endif() else() list(APPEND STARPU_INCLUDE_DIRS "${STARPU_${starpu_hdr}_INCLUDE_DIRS}" ) endif()