summaryrefslogtreecommitdiff
path: root/Tests/FindPython/FindPythonScript.cmake
diff options
context:
space:
mode:
authorMarc Chevrier <marc.chevrier@gmail.com>2019-06-05 13:08:52 +0200
committerMarc Chevrier <marc.chevrier@gmail.com>2019-06-24 12:00:21 +0200
commit9201908ca5c10a6142c0558401445320773f1f1e (patch)
tree8f1889628d8c87e50d259931b08a40596bbd92a0 /Tests/FindPython/FindPythonScript.cmake
parent512013e276e66551c19c12af01336f96c26965a5 (diff)
downloadcmake-9201908ca5c10a6142c0558401445320773f1f1e.tar.gz
FindPython: add Python_FIND_ABI hint.
This variable will enable to specify will ABIs will be searched.
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 94500920eb..bc7e0d1953 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()