$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 @@ # (To distribute this file outside of CMake, substitute the full # License text for the above reference.) +SET(MODPY_VERSION $ENV{MODPY_VERSION}) + # 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})