$OpenBSD: patch-Modules_FindPythonInterp_cmake,v 1.7 2014/04/14 14:02:44 dcoppa Exp $
--- Modules/FindPythonInterp.cmake.orig	Thu Jan 16 18:15:08 2014
+++ Modules/FindPythonInterp.cmake	Mon Apr 14 15:58:48 2014
@@ -29,11 +29,13 @@
 # (To distribute this file outside of CMake, substitute the full
 #  License text for the above reference.)
 
+set(MODPY_VERSION $ENV{MODPY_VERSION})
+
 unset(_Python_NAMES)
 
 set(_PYTHON1_VERSIONS 1.6 1.5)
 set(_PYTHON2_VERSIONS 2.7 2.6 2.5 2.4 2.3 2.2 2.1 2.0)
-set(_PYTHON3_VERSIONS 3.3 3.2 3.1 3.0)
+set(_PYTHON3_VERSIONS 3.4 3.3 3.2 3.1 3.0)
 
 if(PythonInterp_FIND_VERSION)
     if(PythonInterp_FIND_VERSION MATCHES "^[0-9]+\\.[0-9]+(\\.[0-9]+.*)?$")
@@ -65,10 +67,14 @@ find_program(PYTHON_EXECUTABLE NAMES ${_Python_NAMES})
 
 # 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}
-  ${_PYTHON_FIND_OTHER_VERSIONS}
-  )
+if(MODPY_VERSION)
+  set(_Python_VERSIONS ${MODPY_VERSION})
+else(MODPY_VERSION)
+  set(_Python_VERSIONS
+    ${Python_ADDITIONAL_VERSIONS}
+    ${_PYTHON_FIND_OTHER_VERSIONS}
+    )
+endif(MODPY_VERSION)
 
 unset(_PYTHON_FIND_OTHER_VERSIONS)
 unset(_PYTHON1_VERSIONS)
