[PATCH 1/3] qt-utils.eclass: New eclass, moved qt6_* functions from qmake-utils.eclass
Andreas Sturmlechner <[email protected]> Thu, 02 Jul 2026 20:49:30 +0200
| Newsgroups | gmane.linux.gentoo.devel |
|---|---|
| Message-ID | <[email protected]> |
Full patch series: https://github.com/gentoo/gentoo/pull/46502 Signed-off-by: Andreas Sturmlechner <[email protected]> --- eclass/qt-utils.eclass | 68 ++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 68 insertions(+) create mode 100644 eclass/qt-utils.eclass diff --git a/eclass/qt-utils.eclass b/eclass/qt-utils.eclass new file mode 100644 index 000000000000..e340d76329f0 --- /dev/null +++ b/eclass/qt-utils.eclass @@ -0,0 +1,68 @@ +# Copyright 1999-2026 Gentoo Authors +# Distributed under the terms of the GNU General Public License v2 + +# @ECLASS: qt-utils.eclass +# @MAINTAINER: +# [email protected] +# @AUTHOR: +# Davide Pesavento <[email protected]> +# @SUPPORTED_EAPIS: 8 9 +# @BLURB: Qt related helpers. +# @DESCRIPTION: +# Utility eclass providing query functions for Qt. +# +# This eclass does not set any metadata variables nor export any phase +# functions. It can be inherited safely. + +if [[ -z ${_QT_UTILS_ECLASS} ]]; then +_QT_UTILS_ECLASS=1 + +case ${EAPI} in + 8|9) ;; + *) die "${ECLASS}: EAPI ${EAPI:-0} not supported" ;; +esac + +# @FUNCTION: qt6_get_bindir +# @DESCRIPTION: +# Echoes the directory where Qt6 binaries are installed. +# EPREFIX is already prepended to the returned path. +qt6_get_bindir() { + echo "${EPREFIX}$(qt6_get_libdir)/qt6/bin" +} + +# @FUNCTION: qt6_get_headerdir +# @DESCRIPTION: +# Echoes the directory where Qt6 headers are installed. +qt6_get_headerdir() { + echo "/usr/include/qt6" +} + +# @FUNCTION: qt6_get_libdir +# @DESCRIPTION: +# Echoes the directory where Qt6 libraries are installed. +qt6_get_libdir() { + echo "/usr/$(get_libdir)" +} + +# @FUNCTION: qt6_get_libexecdir +# @DESCRIPTION: +# Echoes the directory where Qt6 libexec bins are installed. +qt6_get_libexecdir() { + echo "$(qt6_get_libdir)/qt6/libexec" +} + +# @FUNCTION: qt6_get_mkspecsdir +# @DESCRIPTION: +# Echoes the directory where Qt6 mkspecs are installed. +qt6_get_mkspecsdir() { + echo "$(qt6_get_libdir)/qt6/mkspecs" +} + +# @FUNCTION: qt6_get_plugindir +# @DESCRIPTION: +# Echoes the directory where Qt6 plugins are installed. +qt6_get_plugindir() { + echo "$(qt6_get_libdir)/qt6/plugins" +} + +fi -- 2.55.0
signature.asc
(application/pgp-signature, 829 B)
-----BEGIN PGP SIGNATURE----- iQIvBAABCgCZFiEE34gXUSooizdYNDu3S5FW4z0PgBkFAmpGsrobFIAAAAAABAAO bWFudTIsMi41KzEuMTIsMiwyXxSAAAAAAC4AKGlzc3Vlci1mcHJAbm90YXRpb25z Lm9wZW5wZ3AuZmlmdGhob3JzZW1hbi5uZXRERjg4MTc1MTJBMjg4QjM3NTgzNDNC Qjc0QjkxNTZFMzNEMEY4MDE5AAoJEEuRVuM9D4AZEWEL/RqXUsfG6PYBUbTetMGw Sm2vMC0dAyroJArCw1aqrCLQNNm7Tl6snbwZUVFz6defhHEDVme8LHwuglB+VOhy FZ6zCa/7ZjQF6zm57pOLH69Flr+eUueaUs/ib/Mv3s37aPLXjoCe6pKFjEA7/EEr Vs63p0+60RfpjEI42+whXaKUazihNvD+2i0x7KLVr+s2ZLYPdoquM7mqquElx91y jYkS/XBke6F337tgxOdrlZZIhcKwBaPSZGUH5PiGCtWxMdJxIZnwgse9lql05gqN 0qNlGwSLszu1xoDDlMS4cftcnlg56vgGUQMc2vqJNXbfpaGEBgt6AL+yswgTVD9T ZqKkhTA9rRpilQBEeQj1zxefzr7ZdGlHk7WxtkwG7ITZJYaVtJ2bnXK6qmzWTJW2 VOTFhx0PRq0SG54QUtG8Wf5uzNfEQShFAT23Mv40LjVz0z5wNNafBdF86KgeG5KD aN+Tl0Np2NNoUzCf2IBVglqlBT9IOqwCBRle6iTIxMZQsA== =ay9o -----END PGP SIGNATURE-----