From 0dec6fe712942c6ce7676160234a292d095b1604 Mon Sep 17 00:00:00 2001 From: do-jason Date: Wed, 24 Aug 2022 19:31:42 -0700 Subject: [PATCH] Check additional MPI header's emptiness --- CMakeLists.txt | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/CMakeLists.txt b/CMakeLists.txt index 973a60733..ebd89be45 100644 --- a/CMakeLists.txt +++ b/CMakeLists.txt @@ -215,7 +215,9 @@ endif(ALTCPU) find_package(MPI REQUIRED) if ("${MPI_CXX_INCLUDE_DIRS}" STREQUAL "") - include_directories("${MPI_CXX_INCLUDE_PATH}") + if (NOT "${MPI_CXX_INCLUDE_PATH}" STREQUAL "") + include_directories("${MPI_CXX_INCLUDE_PATH}") + endif() else() include_directories("${MPI_CXX_INCLUDE_DIRS}") endif()