summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorBrad King <brad.king@kitware.com>2021-08-24 13:54:36 (GMT)
committerKitware Robot <kwrobot@kitware.com>2021-08-24 13:54:57 (GMT)
commit1dd9c964277102718fa1930bef9f118dc7cc4060 (patch)
treef12c891633a5d16d457d08160b110e5490f15137
parent30dd9b33a048ec76fd48665f3793cf282cd75f12 (diff)
parent2b2a6a7170c2253c1f97647a03c190aa906e194a (diff)
downloadCMake-1dd9c964277102718fa1930bef9f118dc7cc4060.zip
CMake-1dd9c964277102718fa1930bef9f118dc7cc4060.tar.gz
CMake-1dd9c964277102718fa1930bef9f118dc7cc4060.tar.bz2
Merge topic 'FindMPI-framework-not-a-compile-flag' into release-3.21
2b2a6a7170 FindMPI: do not detect `-framework` as a compile flag Acked-by: Kitware Robot <kwrobot@kitware.com> Acked-by: Utkarsh Ayachit <utkarsh.ayachit@kitware.com> Merge-request: !6467
-rw-r--r--Modules/FindMPI.cmake3
1 files changed, 2 insertions, 1 deletions
diff --git a/Modules/FindMPI.cmake b/Modules/FindMPI.cmake
index c48decb..d8f0334 100644
--- a/Modules/FindMPI.cmake
+++ b/Modules/FindMPI.cmake
@@ -624,7 +624,8 @@ function (_MPI_interrogate_compiler LANG)
# we won't match the accompanying --param-ssp-size and -Wp,-D_FORTIFY_SOURCE flags and therefore
# produce inconsistent results with the regularly flags.
# Similarly, aliasing flags do not belong into our flag array.
- if(NOT "${_MPI_COMPILE_OPTION}" MATCHES "^-f((no-|)(stack-protector|strict-aliasing)|PI[CE]|pi[ce])")
+ # Also strip out `-framework` flags.
+ if(NOT "${_MPI_COMPILE_OPTION}" MATCHES "^-f((no-|)(stack-protector|strict-aliasing)|PI[CE]|pi[ce]|ramework)")
list(APPEND MPI_COMPILE_OPTIONS_WORK "${_MPI_COMPILE_OPTION}")
endif()
endforeach()