diff options
author | orbea <orbea@riseup.net> | 2021-04-09 11:43:53 -0700 |
---|---|---|
committer | Sam James <sam@gentoo.org> | 2022-06-22 05:09:27 +0100 |
commit | 759cec852497f888d93cccfedbc83f16eb765fb4 (patch) | |
tree | 7b7694a2910d7bbfa3a3b8493ad6ea534afa872d /eclass/cmake.eclass | |
parent | media-sound/yoshimi: dropped obsolete 2.1.2.2 (diff) | |
download | gentoo-759cec852497f888d93cccfedbc83f16eb765fb4.tar.gz gentoo-759cec852497f888d93cccfedbc83f16eb765fb4.tar.bz2 gentoo-759cec852497f888d93cccfedbc83f16eb765fb4.zip |
cmake.eclass: Support dev-util/samurai
samurai is a ninja-compatible build tool written in C which
works with cmake, meson and other users of ninja.
It is feature-complete and supports most of the same options
as ninja.
Signed-off-by: orbea <orbea@riseup.net>
Signed-off-by: Sam James <sam@gentoo.org>
Diffstat (limited to 'eclass/cmake.eclass')
-rw-r--r-- | eclass/cmake.eclass | 15 |
1 files changed, 2 insertions, 13 deletions
diff --git a/eclass/cmake.eclass b/eclass/cmake.eclass index 59e5b60957c2..bd7e64cfe6c7 100644 --- a/eclass/cmake.eclass +++ b/eclass/cmake.eclass @@ -136,7 +136,7 @@ case ${CMAKE_MAKEFILE_GENERATOR} in BDEPEND="sys-devel/make" ;; ninja) - BDEPEND="dev-util/ninja" + BDEPEND="${NINJA_DEPEND}" ;; *) eerror "Unknown value for \${CMAKE_MAKEFILE_GENERATOR}" @@ -363,13 +363,6 @@ cmake_src_prepare() { die "FATAL: Unable to find CMakeLists.txt" fi - # if ninja is enabled but not installed, the build could fail - # this could happen if ninja is manually enabled (eg. make.conf) but not installed - if [[ ${CMAKE_MAKEFILE_GENERATOR} == ninja ]] && ! has_version -b dev-util/ninja; then - eerror "CMAKE_MAKEFILE_GENERATOR is set to ninja, but ninja is not installed." - die "Please install dev-util/ninja or unset CMAKE_MAKEFILE_GENERATOR." - fi - local modules_list if [[ ${EAPI} == 7 && $(declare -p CMAKE_REMOVE_MODULES_LIST) != "declare -a"* ]]; then modules_list=( ${CMAKE_REMOVE_MODULES_LIST} ) @@ -705,11 +698,7 @@ cmake_src_test() { cmake_src_install() { debug-print-function ${FUNCNAME} "$@" - _cmake_check_build_dir - pushd "${BUILD_DIR}" > /dev/null || die - DESTDIR="${D}" ${CMAKE_MAKEFILE_GENERATOR} install "$@" || - die "died running ${CMAKE_MAKEFILE_GENERATOR} install" - popd > /dev/null || die + DESTDIR="${D}" cmake_build install "$@" if [[ ${EAPI} == 7 ]]; then pushd "${S}" > /dev/null || die |