From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from lists.gentoo.org (pigeon.gentoo.org [208.92.234.80]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by finch.gentoo.org (Postfix) with ESMTPS id 7AF12138334 for ; Sat, 21 Dec 2019 10:40:53 +0000 (UTC) Received: from pigeon.gentoo.org (localhost [127.0.0.1]) by pigeon.gentoo.org (Postfix) with SMTP id 3F2B9E090A; Sat, 21 Dec 2019 10:40:51 +0000 (UTC) Received: from smtp.gentoo.org (woodpecker.gentoo.org [IPv6:2001:470:ea4a:1:5054:ff:fec7:86e4]) (using TLSv1.2 with cipher ECDHE-RSA-AES128-GCM-SHA256 (128/128 bits)) (No client certificate requested) by pigeon.gentoo.org (Postfix) with ESMTPS id 28531E090A for ; Sat, 21 Dec 2019 10:40:51 +0000 (UTC) Received: from oystercatcher.gentoo.org (unknown [IPv6:2a01:4f8:202:4333:225:90ff:fed9:fc84]) (using TLSv1.2 with cipher ECDHE-RSA-AES128-GCM-SHA256 (128/128 bits)) (No client certificate requested) by smtp.gentoo.org (Postfix) with ESMTPS id 3855F34D49C for ; Sat, 21 Dec 2019 10:40:50 +0000 (UTC) Received: from localhost.localdomain (localhost [IPv6:::1]) by oystercatcher.gentoo.org (Postfix) with ESMTP id 750D9993 for ; Sat, 21 Dec 2019 10:40:46 +0000 (UTC) From: "Andreas Sturmlechner" To: gentoo-commits@lists.gentoo.org Content-Transfer-Encoding: 8bit Content-type: text/plain; charset=UTF-8 Reply-To: gentoo-dev@lists.gentoo.org, "Andreas Sturmlechner" Message-ID: <1576924822.1bd953502f96253a87c36085d356944621ba00c9.asturm@gentoo> Subject: [gentoo-commits] proj/kde:master commit in: eclass/ X-VCS-Repository: proj/kde X-VCS-Files: eclass/cmake.eclass X-VCS-Directories: eclass/ X-VCS-Committer: asturm X-VCS-Committer-Name: Andreas Sturmlechner X-VCS-Revision: 1bd953502f96253a87c36085d356944621ba00c9 X-VCS-Branch: master Date: Sat, 21 Dec 2019 10:40:46 +0000 (UTC) Precedence: bulk List-Post: List-Help: List-Unsubscribe: List-Subscribe: List-Id: Gentoo Linux mail X-BeenThere: gentoo-commits@lists.gentoo.org X-Auto-Response-Suppress: DR, RN, NRN, OOF, AutoReply X-Archives-Salt: e759f9cb-edb4-40a7-b02a-286401320a50 X-Archives-Hash: eff72b1ae300f1362336a4554ae7e38d commit: 1bd953502f96253a87c36085d356944621ba00c9 Author: Andreas Sturmlechner gentoo org> AuthorDate: Sun Nov 17 15:40:11 2019 +0000 Commit: Andreas Sturmlechner gentoo org> CommitDate: Sat Dec 21 10:40:22 2019 +0000 URL: https://gitweb.gentoo.org/proj/kde.git/commit/?id=1bd95350 cmake.eclass: Drop _cmake_ninja_build() and _cmake_emake_build() Do it all in cmake_build() Signed-off-by: Andreas Sturmlechner gentoo.org> eclass/cmake.eclass | 41 +++++++++++------------------------------ 1 file changed, 11 insertions(+), 30 deletions(-) diff --git a/eclass/cmake.eclass b/eclass/cmake.eclass index ef6a5c3d7f..20ba229377 100644 --- a/eclass/cmake.eclass +++ b/eclass/cmake.eclass @@ -547,35 +547,6 @@ cmake_src_compile() { cmake_build "$@" } -# @FUNCTION: _cmake_ninja_build -# @INTERNAL -# @DESCRIPTION: -# Build the package using ninja generator -_cmake_ninja_build() { - debug-print-function ${FUNCNAME} "$@" - - [[ -e build.ninja ]] || die "build.ninja not found. Error during configure stage." - - eninja "$@" -} - -# @FUNCTION: _cmake_emake_build -# @INTERNAL -# @DESCRIPTION: -# Build the package using make generator -_cmake_emake_build() { - debug-print-function ${FUNCNAME} "$@" - - [[ -e Makefile ]] || die "Makefile not found. Error during configure stage." - - if [[ "${CMAKE_VERBOSE}" != "OFF" ]]; then - emake VERBOSE=1 "$@" - else - emake "$@" - fi - -} - # @FUNCTION: cmake_build # @DESCRIPTION: # Function for building the package. Automatically detects the build type. @@ -586,7 +557,17 @@ cmake_build() { _cmake_check_build_dir pushd "${BUILD_DIR}" > /dev/null || die - _cmake_${CMAKE_MAKEFILE_GENERATOR}_build "$@" + case ${CMAKE_MAKEFILE_GENERATOR} in + emake) + [[ -e Makefile ]] || die "Makefile not found. Error during configure stage." + [[ "${CMAKE_VERBOSE}" != "OFF" ]] && local verbosity="VERBOSE=1" + emake "${verbosity} ""$@" + ;; + ninja) + [[ -e build.ninja ]] || die "build.ninja not found. Error during configure stage." + eninja "$@" + ;; + esac popd > /dev/null || die }