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 F2C4C138359 for ; Sun, 12 Jul 2020 23:08:01 +0000 (UTC) Received: from pigeon.gentoo.org (localhost [127.0.0.1]) by pigeon.gentoo.org (Postfix) with SMTP id D619BE0843; Sun, 12 Jul 2020 23:08:00 +0000 (UTC) Received: from smtp.gentoo.org (smtp.gentoo.org [140.211.166.183]) (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 A9460E0843 for ; Sun, 12 Jul 2020 23:08:00 +0000 (UTC) Received: from oystercatcher.gentoo.org (oystercatcher.gentoo.org [148.251.78.52]) (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 5AB3334F9AD for ; Sun, 12 Jul 2020 23:07:59 +0000 (UTC) Received: from localhost.localdomain (localhost [IPv6:::1]) by oystercatcher.gentoo.org (Postfix) with ESMTP id 0509E84 for ; Sun, 12 Jul 2020 23:07:58 +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: <1594595262.d94bc055c78c6c94bd16f71978787ee8876d1f4a.asturm@gentoo> Subject: [gentoo-commits] repo/gentoo:master commit in: kde-frameworks/extra-cmake-modules/files/, kde-frameworks/extra-cmake-modules/ X-VCS-Repository: repo/gentoo X-VCS-Files: kde-frameworks/extra-cmake-modules/extra-cmake-modules-5.72.0-r1.ebuild kde-frameworks/extra-cmake-modules/files/extra-cmake-modules-5.72.0-skip-ecm_add_test-early.patch X-VCS-Directories: kde-frameworks/extra-cmake-modules/files/ kde-frameworks/extra-cmake-modules/ X-VCS-Committer: asturm X-VCS-Committer-Name: Andreas Sturmlechner X-VCS-Revision: d94bc055c78c6c94bd16f71978787ee8876d1f4a X-VCS-Branch: master Date: Sun, 12 Jul 2020 23:07:58 +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: 631446af-d386-4a2c-9bdc-10aae4021913 X-Archives-Hash: 7325086c5d79fdea4f84685529b24977 commit: d94bc055c78c6c94bd16f71978787ee8876d1f4a Author: Andreas Sturmlechner gentoo org> AuthorDate: Sun Jul 12 16:11:53 2020 +0000 Commit: Andreas Sturmlechner gentoo org> CommitDate: Sun Jul 12 23:07:42 2020 +0000 URL: https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=d94bc055 kde-frameworks/extra-cmake-modules: Skip ecm_add_test w/o Qt5::Test Bug: https://bugs.gentoo.org/651978 Package-Manager: Portage-2.3.103, Repoman-2.3.23 Signed-off-by: Andreas Sturmlechner gentoo.org> .../extra-cmake-modules-5.72.0-r1.ebuild | 77 ++++++++++++++++++++++ ...ke-modules-5.72.0-skip-ecm_add_test-early.patch | 54 +++++++++++++++ 2 files changed, 131 insertions(+) diff --git a/kde-frameworks/extra-cmake-modules/extra-cmake-modules-5.72.0-r1.ebuild b/kde-frameworks/extra-cmake-modules/extra-cmake-modules-5.72.0-r1.ebuild new file mode 100644 index 00000000000..aedbbe8565e --- /dev/null +++ b/kde-frameworks/extra-cmake-modules/extra-cmake-modules-5.72.0-r1.ebuild @@ -0,0 +1,77 @@ +# Copyright 1999-2020 Gentoo Authors +# Distributed under the terms of the GNU General Public License v2 + +EAPI=7 + +PYTHON_COMPAT=( python3_{7,8,9} ) +QTMIN=5.14.2 +inherit cmake kde.org python-any-r1 + +DESCRIPTION="Extra modules and scripts for CMake" +HOMEPAGE="https://invent.kde.org/frameworks/extra-cmake-modules" + +LICENSE="BSD" +KEYWORDS="~amd64 ~arm ~arm64 ~hppa ~ppc ~ppc64 ~x86" +IUSE="doc test" + +BDEPEND=" + doc? ( + ${PYTHON_DEPS} + $(python_gen_any_dep 'dev-python/sphinx[${PYTHON_USEDEP}]') + >=dev-qt/qthelp-${QTMIN}:5 + ) + test? ( + >=dev-qt/linguist-tools-${QTMIN}:5 + >=dev-qt/qtcore-${QTMIN}:5 + ) +" +RDEPEND=" + app-arch/libarchive[bzip2] +" + +RESTRICT+=" !test? ( test )" + +PATCHES=( + "${FILESDIR}/${PN}-5.49.0-no-fatal-warnings.patch" + "${FILESDIR}/${PN}-5.65.0-disable-qmlplugindump.patch" + "${FILESDIR}/${PN}-5.72.0-skip-ecm_add_test-early.patch" +) + +python_check_deps() { + has_version "dev-python/sphinx[${PYTHON_USEDEP}]" +} + +pkg_setup() { + use doc && python-any-r1_pkg_setup +} + +src_prepare() { + cmake_src_prepare + # Requires PyQt5, bug #680256 + sed -i -e "/^if(NOT SIP_Qt5Core_Mod_FILE)/s/NOT SIP_Qt5Core_Mod_FILE/TRUE/" \ + tests/CMakeLists.txt || die "failed to disable GenerateSipBindings tests" +} + +src_configure() { + local mycmakeargs=( + -DDOC_INSTALL_DIR=/usr/share/doc/"${PF}" + -DBUILD_QTHELP_DOCS=$(usex doc) + -DBUILD_HTML_DOCS=$(usex doc) + -DBUILD_MAN_DOCS=$(usex doc) + -DBUILD_TESTING=$(usex test) + ) + + cmake_src_configure +} + +src_test() { + # ECMToolchainAndroidTest passes but then breaks src_install + # ECMPoQmToolsTest is broken, bug #627806 + # possible race condition with multiple jobs, bug #701854 + local myctestargs=( + -j1 + -E "(ECMToolchainAndroidTest|ECMPoQmToolsTest)" + ) + + cmake_src_test +} diff --git a/kde-frameworks/extra-cmake-modules/files/extra-cmake-modules-5.72.0-skip-ecm_add_test-early.patch b/kde-frameworks/extra-cmake-modules/files/extra-cmake-modules-5.72.0-skip-ecm_add_test-early.patch new file mode 100644 index 00000000000..72541d73e72 --- /dev/null +++ b/kde-frameworks/extra-cmake-modules/files/extra-cmake-modules-5.72.0-skip-ecm_add_test-early.patch @@ -0,0 +1,54 @@ +From ad3aec71ed7f8820e69fe55489368a19d0735ab5 Mon Sep 17 00:00:00 2001 +From: Andreas Sturmlechner +Date: Sat, 11 Jul 2020 23:04:16 +0200 +Subject: [PATCH] ECMAddTests.cmake: Skip ecm_add_test early if Qt5::Test is not available + +Signed-off-by: Andreas Sturmlechner +--- + modules/ECMAddTests.cmake | 9 +++++++++ + tests/ECMAddTests/CMakeLists.txt | 5 +++++ + 2 files changed, 14 insertions(+) + +diff --git a/modules/ECMAddTests.cmake b/modules/ECMAddTests.cmake +index 4bc7fb8..12825aa 100644 +--- a/modules/ECMAddTests.cmake ++++ b/modules/ECMAddTests.cmake +@@ -81,6 +81,10 @@ function(ecm_add_test) + message(FATAL_ERROR "ecm_add_test() called with multiple source files but without setting \"TEST_NAME\"") + endif() + ++ if(NOT TARGET Qt5::Test) ++ return() ++ endif() ++ + set(_testname ${ARG_NAME_PREFIX}${_targetname}) + set(gui_args) + if(ARG_GUI) +@@ -122,6 +126,11 @@ function(ecm_add_tests) + endif() + set(test_names) + set(target_names) ++ ++ if(NOT TARGET Qt5::Test) ++ return() ++ endif() ++ + foreach(_test_source ${ARG_UNPARSED_ARGUMENTS}) + ecm_add_test(${_test_source} + NAME_PREFIX ${ARG_NAME_PREFIX} +diff --git a/tests/ECMAddTests/CMakeLists.txt b/tests/ECMAddTests/CMakeLists.txt +index e77b33f..4e191fe 100644 +--- a/tests/ECMAddTests/CMakeLists.txt ++++ b/tests/ECMAddTests/CMakeLists.txt +@@ -1,3 +1,8 @@ ++if(NOT TARGET Qt5::Test) ++ message(STATUS "WARNING: skipping tests that require Qt5::Test") ++ return() ++endif() ++ + macro(add_check NAME) + string(REPLACE "." "/" dir "${NAME}") + string(REGEX REPLACE "[^.]*\\." "" proj "${NAME}") +-- +2.27.0 +