summaryrefslogtreecommitdiff
path: root/dev-util/cmake/files/cmake-3.1.0-FindPythonInterp.patch
diff options
context:
space:
mode:
authorMichael Palimaka <kensington@gentoo.org>2015-04-02 00:19:31 +1100
committerMichael Palimaka <kensington@gentoo.org>2015-04-02 00:19:31 +1100
commita1c2506d564ca4527b029d542eef35d38d466570 (patch)
tree48e340d5657eda33ea96f16ecf034f21f32f1299 /dev-util/cmake/files/cmake-3.1.0-FindPythonInterp.patch
parent3e89d59a1edfbf738870ab918ce46cea74243e05 (diff)
downloadkde-a1c2506d564ca4527b029d542eef35d38d466570.tar.gz
kde-a1c2506d564ca4527b029d542eef35d38d466570.tar.bz2
kde-a1c2506d564ca4527b029d542eef35d38d466570.zip
[dev-util/cmake] Version bump wrt bug #543700.
Package-Manager: portage-2.2.18
Diffstat (limited to 'dev-util/cmake/files/cmake-3.1.0-FindPythonInterp.patch')
-rw-r--r--dev-util/cmake/files/cmake-3.1.0-FindPythonInterp.patch29
1 files changed, 29 insertions, 0 deletions
diff --git a/dev-util/cmake/files/cmake-3.1.0-FindPythonInterp.patch b/dev-util/cmake/files/cmake-3.1.0-FindPythonInterp.patch
new file mode 100644
index 00000000000..78f622d886a
--- /dev/null
+++ b/dev-util/cmake/files/cmake-3.1.0-FindPythonInterp.patch
@@ -0,0 +1,29 @@
+--- Modules/FindPythonInterp.cmake.orig 2015-01-06 11:50:03.376357898 +0100
++++ Modules/FindPythonInterp.cmake 2015-01-06 12:25:48.614989290 +0100
+@@ -75,6 +75,11 @@
+ else()
+ set(_PYTHON_FIND_OTHER_VERSIONS ${_PYTHON3_VERSIONS} ${_PYTHON2_VERSIONS} ${_PYTHON1_VERSIONS})
+ endif()
++
++if (CMAKE_BUILD_TYPE STREQUAL Gentoo)
++ set(_Python_NAMES python)
++endif()
++
+ find_program(PYTHON_EXECUTABLE NAMES ${_Python_NAMES})
+
+ # Set up the versions we know about, in the order we will search. Always add
+@@ -99,12 +104,13 @@
+ unset(_PYTHON3_VERSIONS)
+
+ # Search for newest python version if python executable isn't found
+-if(NOT PYTHON_EXECUTABLE)
++if(NOT PYTHON_EXECUTABLE AND NOT CMAKE_BUILD_TYPE STREQUAL Gentoo)
+ foreach(_CURRENT_VERSION IN LISTS _Python_VERSIONS)
+ set(_Python_NAMES python${_CURRENT_VERSION})
+ if(WIN32)
+ list(APPEND _Python_NAMES python)
+ endif()
++
+ find_program(PYTHON_EXECUTABLE
+ NAMES ${_Python_NAMES}
+ PATHS [HKEY_LOCAL_MACHINE\\SOFTWARE\\Python\\PythonCore\\${_CURRENT_VERSION}\\InstallPath]