2011-03-13 14:23:01 -04:00
|
|
|
$OpenBSD: patch-Modules_FindPythonInterp_cmake,v 1.3 2011/03/13 18:23:02 dcoppa Exp $
|
|
|
|
--- Modules/FindPythonInterp.cmake.orig Tue Feb 15 18:47:27 2011
|
|
|
|
+++ Modules/FindPythonInterp.cmake Mon Mar 7 11:29:02 2011
|
|
|
|
@@ -20,11 +20,17 @@
|
2010-11-15 06:39:08 -05:00
|
|
|
# (To distribute this file outside of CMake, substitute the full
|
2010-05-28 16:21:48 -04:00
|
|
|
# License text for the above reference.)
|
|
|
|
|
2011-03-13 14:23:01 -04:00
|
|
|
+SET(MODPY_VERSION $ENV{MODPY_VERSION})
|
2010-05-28 16:21:48 -04:00
|
|
|
+
|
2011-03-13 14:23:01 -04:00
|
|
|
# Set up the versions we know about, in the order we will search. Always add
|
|
|
|
# the user supplied additional versions to the front.
|
|
|
|
-set(_Python_VERSIONS
|
|
|
|
- ${Python_ADDITIONAL_VERSIONS}
|
|
|
|
- 2.7 2.6 2.5 2.4 2.3 2.2 2.1 2.0 1.6 1.5)
|
|
|
|
+IF(MODPY_VERSION)
|
|
|
|
+ set(_Python_VERSIONS ${MODPY_VERSION})
|
|
|
|
+ELSE(MODPY_VERSION)
|
|
|
|
+ set(_Python_VERSIONS
|
|
|
|
+ ${Python_ADDITIONAL_VERSIONS}
|
|
|
|
+ 2.7 2.6 2.5 2.4 2.3 2.2 2.1 2.0 1.6 1.5)
|
|
|
|
+ENDIF(MODPY_VERSION)
|
|
|
|
|
|
|
|
# Run first with the Python version in the executable
|
|
|
|
foreach(_CURRENT_VERSION ${_Python_VERSIONS})
|