diff options
author | Michał Górny <mgorny@gentoo.org> | 2016-11-27 13:30:35 +0100 |
---|---|---|
committer | Michał Górny <mgorny@gentoo.org> | 2016-11-30 10:42:07 +0100 |
commit | beaae227169e69fea254a848ce1313f4491f53b1 (patch) | |
tree | 4a032a5848ba4785625ae5b7bdb88964164c4c2c /dev-util/cmake | |
parent | media-sound/zynaddsubfx: remove old (diff) | |
download | gentoo-beaae227169e69fea254a848ce1313f4491f53b1.tar.gz gentoo-beaae227169e69fea254a848ce1313f4491f53b1.tar.bz2 gentoo-beaae227169e69fea254a848ce1313f4491f53b1.zip |
dev-util/cmake: Support indicating Gentoo build via CMAKE_GENTOO_BUILD
Support indicating Gentoo package build using a new CMAKE_GENTOO_BUILD
CMake variable, as an alternative to relying on CMAKE_BUILD_TYPE being
equal to Gentoo. This makes it possible to reduce reliance on a custom
build type in the future.
Diffstat (limited to 'dev-util/cmake')
-rw-r--r-- | dev-util/cmake/cmake-3.7.0-r1.ebuild (renamed from dev-util/cmake/cmake-3.7.0.ebuild) | 0 | ||||
-rw-r--r-- | dev-util/cmake/files/cmake-2.8.10.2-FindPythonLibs.patch | 2 | ||||
-rw-r--r-- | dev-util/cmake/files/cmake-3.1.0-FindPythonInterp.patch | 4 | ||||
-rw-r--r-- | dev-util/cmake/files/cmake-3.5.2-FindQt4.patch | 2 |
4 files changed, 4 insertions, 4 deletions
diff --git a/dev-util/cmake/cmake-3.7.0.ebuild b/dev-util/cmake/cmake-3.7.0-r1.ebuild index ab23f3b37039..ab23f3b37039 100644 --- a/dev-util/cmake/cmake-3.7.0.ebuild +++ b/dev-util/cmake/cmake-3.7.0-r1.ebuild diff --git a/dev-util/cmake/files/cmake-2.8.10.2-FindPythonLibs.patch b/dev-util/cmake/files/cmake-2.8.10.2-FindPythonLibs.patch index 2a83ff7abb69..5f9c26658f31 100644 --- a/dev-util/cmake/files/cmake-2.8.10.2-FindPythonLibs.patch +++ b/dev-util/cmake/files/cmake-2.8.10.2-FindPythonLibs.patch @@ -7,7 +7,7 @@ index bffa9fb..8fc90ee 100644 ) +# Gentoo portage requires that you use exactly the given python version -+if (CMAKE_BUILD_TYPE STREQUAL Gentoo) ++if (CMAKE_GENTOO_BUILD OR CMAKE_BUILD_TYPE STREQUAL Gentoo) + execute_process(COMMAND python -c "import sys; sys.stdout.write('.'.join([str(x) for x in sys.version_info[:2]]))" + OUTPUT_VARIABLE _Gentoo_Python_VERSION) + list(FIND _Python_VERSIONS "${_Gentoo_Python_VERSION}" _Gentoo_Python_INDEX) diff --git a/dev-util/cmake/files/cmake-3.1.0-FindPythonInterp.patch b/dev-util/cmake/files/cmake-3.1.0-FindPythonInterp.patch index 3abb2e4065e8..bb3ca9580ad9 100644 --- a/dev-util/cmake/files/cmake-3.1.0-FindPythonInterp.patch +++ b/dev-util/cmake/files/cmake-3.1.0-FindPythonInterp.patch @@ -5,7 +5,7 @@ set(_PYTHON_FIND_OTHER_VERSIONS ${_PYTHON3_VERSIONS} ${_PYTHON2_VERSIONS} ${_PYTHON1_VERSIONS}) endif() + -+if (CMAKE_BUILD_TYPE STREQUAL Gentoo) ++if (CMAKE_GENTOO_BUILD OR CMAKE_BUILD_TYPE STREQUAL Gentoo) + set(_Python_NAMES python) +endif() + @@ -17,7 +17,7 @@ # 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) ++if(NOT PYTHON_EXECUTABLE AND NOT (CMAKE_GENTOO_BUILD OR CMAKE_BUILD_TYPE STREQUAL Gentoo)) foreach(_CURRENT_VERSION IN LISTS _Python_VERSIONS) set(_Python_NAMES python${_CURRENT_VERSION}) if(WIN32) diff --git a/dev-util/cmake/files/cmake-3.5.2-FindQt4.patch b/dev-util/cmake/files/cmake-3.5.2-FindQt4.patch index 845fc6e75d85..2f2764d30cf6 100644 --- a/dev-util/cmake/files/cmake-3.5.2-FindQt4.patch +++ b/dev-util/cmake/files/cmake-3.5.2-FindQt4.patch @@ -23,7 +23,7 @@ Gentoo-bug: 547222 - PATH_SUFFIXES bin - DOC "The qmake executable for the Qt installation to use" - ) -+ if(CMAKE_BUILD_TYPE STREQUAL Gentoo) ++ if(CMAKE_GENTOO_BUILD OR CMAKE_BUILD_TYPE STREQUAL Gentoo) + find_program(QT_QMAKE_EXECUTABLE NAMES ${QMAKE_NAME} + PATHS + $ENV{EPREFIX}/usr/${CMAKE_INSTALL_LIBDIR}/qt4/bin |