public inbox for gentoo-commits@lists.gentoo.org
 help / color / mirror / Atom feed
From: "Andreas Sturmlechner" <asturm@gentoo.org>
To: gentoo-commits@lists.gentoo.org
Subject: [gentoo-commits] proj/qt:master commit in: app-crypt/qca/
Date: Tue, 11 Oct 2022 15:57:55 +0000 (UTC)	[thread overview]
Message-ID: <1665503777.18bbf0c4c9b94e3c41fc91a7c67a772737d9257c.asturm@gentoo> (raw)

commit:     18bbf0c4c9b94e3c41fc91a7c67a772737d9257c
Author:     Andreas Sturmlechner <asturm <AT> gentoo <DOT> org>
AuthorDate: Tue Oct 11 15:56:17 2022 +0000
Commit:     Andreas Sturmlechner <asturm <AT> gentoo <DOT> org>
CommitDate: Tue Oct 11 15:56:17 2022 +0000
URL:        https://gitweb.gentoo.org/proj/qt.git/commit/?id=18bbf0c4

app-crypt/qca: Add IUSE qt6

Signed-off-by: Andreas Sturmlechner <asturm <AT> gentoo.org>

 app-crypt/qca/qca-9999.ebuild | 85 ++++++++++++++++++++++++++++++-------------
 1 file changed, 59 insertions(+), 26 deletions(-)

diff --git a/app-crypt/qca/qca-9999.ebuild b/app-crypt/qca/qca-9999.ebuild
index b44a8ff2..492d5b29 100644
--- a/app-crypt/qca/qca-9999.ebuild
+++ b/app-crypt/qca/qca-9999.ebuild
@@ -1,9 +1,9 @@
-# Copyright 1999-2021 Gentoo Authors
+# Copyright 1999-2022 Gentoo Authors
 # Distributed under the terms of the GNU General Public License v2
 
 EAPI=8
 
-inherit cmake kde.org qmake-utils
+inherit cmake kde.org multibuild qmake-utils
 
 DESCRIPTION="Qt Cryptographic Architecture (QCA)"
 HOMEPAGE="https://userbase.kde.org/QCA"
@@ -11,12 +11,12 @@ HOMEPAGE="https://userbase.kde.org/QCA"
 LICENSE="LGPL-2.1"
 SLOT="2"
 KEYWORDS=""
-IUSE="botan debug doc examples gcrypt gpg logger nss pkcs11 sasl softstore +ssl test"
+IUSE="botan debug doc examples gcrypt gpg logger nss pkcs11 qt5 qt6 sasl softstore +ssl test"
+REQUIRED_USE="|| ( qt5 qt6 )"
 
 RESTRICT="!test? ( test )"
 
 RDEPEND="
-	>=dev-qt/qtcore-5.14:5
 	botan? ( dev-libs/botan:= )
 	gcrypt? ( dev-libs/libgcrypt:= )
 	gpg? ( app-crypt/gnupg )
@@ -25,16 +25,29 @@ RDEPEND="
 		>=dev-libs/openssl-1.1
 		dev-libs/pkcs11-helper
 	)
+	qt5? ( >=dev-qt/qtcore-5.14:5 )
+	qt6? (
+		dev-qt/qtbase:6
+		dev-qt/qt5compat:6
+	)
 	sasl? ( dev-libs/cyrus-sasl:2 )
-	ssl? ( >=dev-libs/openssl-1.1:0= )
+	ssl? ( >=dev-libs/openssl-1.1:= )
 "
 DEPEND="${RDEPEND}
 	test? (
-		dev-qt/qtnetwork:5
-		dev-qt/qttest:5
+		qt5? (
+			dev-qt/qtnetwork:5
+			dev-qt/qttest:5
+		)
+		qt6? ( dev-qt/qtbase:6[network,test] )
+	)
+"
+BDEPEND="
+	doc? (
+		app-doc/doxygen[dot]
+		virtual/latex-base
 	)
 "
-BDEPEND="doc? ( app-doc/doxygen )"
 
 PATCHES=( "${FILESDIR}/${PN}-disable-pgp-test.patch" )
 
@@ -42,31 +55,51 @@ qca_plugin_use() {
 	echo -DWITH_${2:-$1}_PLUGIN=$(usex "$1")
 }
 
+pkg_setup() {
+	MULTIBUILD_VARIANTS=( $(usev qt5) $(usev qt6) )
+}
+
 src_configure() {
-	local mycmakeargs=(
-		-DQCA_FEATURE_INSTALL_DIR="${EPREFIX}$(qt5_get_mkspecsdir)/features"
-		-DQCA_PLUGINS_INSTALL_DIR="${EPREFIX}$(qt5_get_plugindir)"
-		$(qca_plugin_use botan)
-		$(qca_plugin_use gcrypt)
-		$(qca_plugin_use gpg gnupg)
-		$(qca_plugin_use logger)
-		$(qca_plugin_use nss)
-		$(qca_plugin_use pkcs11)
-		$(qca_plugin_use sasl cyrus-sasl)
-		$(qca_plugin_use softstore)
-		$(qca_plugin_use ssl ossl)
-		-DBUILD_TESTS=$(usex test)
-	)
-	cmake_src_configure
+	myconfigure() {
+		local mycmakeargs=(
+			-DQCA_FEATURE_INSTALL_DIR="${EPREFIX}$(${MULTIBUILD_VARIANT}_get_mkspecsdir)/features"
+			-DQCA_PLUGINS_INSTALL_DIR="${EPREFIX}$(${MULTIBUILD_VARIANT}_get_plugindir)"
+			$(qca_plugin_use botan)
+			$(qca_plugin_use gcrypt)
+			$(qca_plugin_use gpg gnupg)
+			$(qca_plugin_use logger)
+			$(qca_plugin_use nss)
+			$(qca_plugin_use pkcs11)
+			$(qca_plugin_use sasl cyrus-sasl)
+			$(qca_plugin_use softstore)
+			$(qca_plugin_use ssl ossl)
+			-DBUILD_TESTS=$(usex test)
+		)
+		if [[ ${MULTIBUILD_VARIANT} == qt6 ]]; then
+				mycmakeargs+=( -DBUILD_WITH_QT6=ON )
+		else
+				mycmakeargs+=( -DBUILD_WITH_QT6=OFF )
+		fi
+		cmake_src_configure
+	}
+
+	multibuild_foreach_variant myconfigure
+}
+
+src_compile() {
+	multibuild_foreach_variant cmake_src_compile
 }
 
 src_test() {
-	local -x QCA_PLUGIN_PATH="${BUILD_DIR}/lib/qca"
-	cmake_src_test
+	mytest() {
+		local -x QCA_PLUGIN_PATH="${BUILD_DIR}/lib/qca"
+		cmake_src_test
+	}
+	multibuild_foreach_variant mytest
 }
 
 src_install() {
-	cmake_src_install
+	multibuild_foreach_variant cmake_src_install
 
 	if use doc; then
 		pushd "${BUILD_DIR}" >/dev/null || die


             reply	other threads:[~2022-10-11 15:57 UTC|newest]

Thread overview: 33+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2022-10-11 15:57 Andreas Sturmlechner [this message]
  -- strict thread matches above, loose matches on Subject: below --
2024-01-13 16:45 [gentoo-commits] proj/qt:master commit in: app-crypt/qca/ Sam James
2023-06-18 17:58 Andreas Sturmlechner
2023-06-18 15:32 Andreas Sturmlechner
2023-06-18 15:32 Andreas Sturmlechner
2023-06-13 12:16 Andreas Sturmlechner
2023-04-12  2:20 Sam James
2022-10-11 16:16 Andreas Sturmlechner
2021-05-02 19:52 Andreas Sturmlechner
2021-05-02 19:52 Andreas Sturmlechner
2020-02-11 15:38 Andreas Sturmlechner
2019-12-31 16:44 Andreas Sturmlechner
2019-10-26 16:12 Andreas Sturmlechner
2018-06-12 16:05 Andreas Sturmlechner
2018-04-11 23:10 Andreas Sturmlechner
2018-04-11 23:10 Andreas Sturmlechner
2018-04-11 23:10 Andreas Sturmlechner
2017-04-25 11:36 Michael Palimaka
2017-04-25 11:32 Michael Palimaka
2016-10-28 15:19 Michael Palimaka
2015-06-30 21:47 Davide Pesavento
2015-03-04  7:55 git@oystercatcher mirror+tproxy
2015-03-04  7:55 Michael Palimaka
2015-01-29  0:27 Davide Pesavento
2014-12-02 15:50 Michael Palimaka
2014-11-29 14:15 Michael Palimaka
2014-11-29 14:15 Michael Palimaka
2014-11-28 18:53 Michael Palimaka
2014-09-24 23:19 Davide Pesavento
2014-08-21  1:00 Davide Pesavento
2014-08-21  0:34 Davide Pesavento
2014-08-20 23:52 Davide Pesavento
2014-06-29 23:24 Davide Pesavento

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=1665503777.18bbf0c4c9b94e3c41fc91a7c67a772737d9257c.asturm@gentoo \
    --to=asturm@gentoo.org \
    --cc=gentoo-commits@lists.gentoo.org \
    --cc=gentoo-dev@lists.gentoo.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox