summaryrefslogtreecommitdiffstats
path: root/Tests/FindPython/FindPythonScript.cmake
diff options
context:
space:
mode:
authorBrad King <brad.king@kitware.com>2019-06-25 11:06:14 (GMT)
committerKitware Robot <kwrobot@kitware.com>2019-06-25 11:06:35 (GMT)
commitb4a882cf10874fbd04bda81d9dfeeea29dcf3f8b (patch)
treeb315b6dbd25904ab19cd6c984b6cb93466cdb4be /Tests/FindPython/FindPythonScript.cmake
parent2e8b8eb857037a4c0f08a1c7c0ce5a778ebfbc54 (diff)
parent9201908ca5c10a6142c0558401445320773f1f1e (diff)
downloadCMake-b4a882cf10874fbd04bda81d9dfeeea29dcf3f8b.zip
CMake-b4a882cf10874fbd04bda81d9dfeeea29dcf3f8b.tar.gz
CMake-b4a882cf10874fbd04bda81d9dfeeea29dcf3f8b.tar.bz2
Merge topic 'FindPython-FIND_ABI'
9201908ca5 FindPython: add Python_FIND_ABI hint. Acked-by: Kitware Robot <kwrobot@kitware.com> Merge-request: !3463
Diffstat (limited to 'Tests/FindPython/FindPythonScript.cmake')
-rw-r--r--Tests/FindPython/FindPythonScript.cmake10
1 files changed, 9 insertions, 1 deletions
diff --git a/Tests/FindPython/FindPythonScript.cmake b/Tests/FindPython/FindPythonScript.cmake
index 9450092..bc7e0d1 100644
--- a/Tests/FindPython/FindPythonScript.cmake
+++ b/Tests/FindPython/FindPythonScript.cmake
@@ -1 +1,9 @@
-find_package(${PYTHON_PACKAGE_NAME} REQUIRED QUIET)
+
+if (PYTHON_MUST_NOT_BE_FOUND)
+ find_package(${PYTHON_PACKAGE_NAME} QUIET)
+ if (${PYTHON_PACKAGE_NAME}_FOUND)
+ message(FATAL_ERROR "${PYTHON_PACKAGE_NAME}: unexpectedly founded.")
+ endif()
+else()
+ find_package(${PYTHON_PACKAGE_NAME} REQUIRED QUIET)
+endif()