summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorIonen Wolkens <ionen@gentoo.org>2024-08-31 09:31:13 -0400
committerIonen Wolkens <ionen@gentoo.org>2024-08-31 09:52:42 -0400
commit4dc4fefa1ee6b207255fdd41af159778728810c8 (patch)
tree24f7cdc143dfac605f2ab43fc9f736f3d373abcf /dev-util
parentx11-drivers/nvidia-drivers: add 550.40.71:0/vulkan, drop 550.40.70 (diff)
downloadgentoo-4dc4fefa1ee6b207255fdd41af159778728810c8.tar.gz
gentoo-4dc4fefa1ee6b207255fdd41af159778728810c8.tar.bz2
gentoo-4dc4fefa1ee6b207255fdd41af159778728810c8.zip
dev-util/qbs: add 2.4.1
Signed-off-by: Ionen Wolkens <ionen@gentoo.org>
Diffstat (limited to 'dev-util')
-rw-r--r--dev-util/qbs/Manifest1
-rw-r--r--dev-util/qbs/qbs-2.4.1.ebuild90
2 files changed, 91 insertions, 0 deletions
diff --git a/dev-util/qbs/Manifest b/dev-util/qbs/Manifest
index f1834e3241d5..0431f1ee1f2a 100644
--- a/dev-util/qbs/Manifest
+++ b/dev-util/qbs/Manifest
@@ -1 +1,2 @@
DIST qbs-src-2.3.1.tar.gz 5614581 BLAKE2B 92fa24d75248a3732cbd99b660141e56654574f1388d50d5359afef7b442889fa59c4ab4f029f055ee618c0222f94faba47ae9fff85f0fae26e95f2ba34995f9 SHA512 27ba33805b942cf8180e55bdd6c37ccfd2aeaa2e8c01ca7e7485720030dfad7c5f1a3f92b77bff97a7ebf8878e455758c8729005e8b03959d18106f945d8d42c
+DIST qbs-src-2.4.1.tar.gz 5739646 BLAKE2B 5455779be27a5eed316372303ec4264a6af8238684e9c4ae46dffcf7f9038b9aaff75dab29c84e761808158ce60f408c46eac829ef226168ad86c85df2fe7cd2 SHA512 caeb9289a208ca227fc2a16c38d88594b3b958c33f9108f74463bfad412a07ac7f7c4f85b6a741d3ee4c842e5a5d980d88b9c279ff8636cb2e98f67a70ee54b3
diff --git a/dev-util/qbs/qbs-2.4.1.ebuild b/dev-util/qbs/qbs-2.4.1.ebuild
new file mode 100644
index 000000000000..45c3e36f74e4
--- /dev/null
+++ b/dev-util/qbs/qbs-2.4.1.ebuild
@@ -0,0 +1,90 @@
+# Copyright 2024 Gentoo Authors
+# Distributed under the terms of the GNU General Public License v2
+
+EAPI=8
+
+PYTHON_COMPAT=( python3_{10..13} )
+inherit cmake flag-o-matic python-any-r1 toolchain-funcs
+
+DESCRIPTION="Modern build tool for software projects"
+HOMEPAGE="https://doc.qt.io/qbs/"
+SRC_URI="https://download.qt.io/official_releases/qbs/${PV}/${PN}-src-${PV}.tar.gz"
+S=${WORKDIR}/${PN}-src-${PV}
+
+LICENSE="|| ( LGPL-2.1 LGPL-3 ) BSD"
+SLOT="0"
+KEYWORDS="~amd64 ~arm ~x86"
+IUSE="doc test"
+RESTRICT="!test? ( test )"
+
+RDEPEND="
+ dev-qt/qt5compat:6
+ dev-qt/qtbase:6[concurrent,gui,network,widgets,xml]
+"
+DEPEND="${RDEPEND}"
+BDEPEND="
+ doc? (
+ $(python_gen_any_dep '
+ dev-python/beautifulsoup4[${PYTHON_USEDEP}]
+ dev-python/lxml[${PYTHON_USEDEP}]
+ ')
+ dev-qt/qttools:6[assistant,qdoc]
+ )
+"
+
+CMAKE_SKIP_TESTS=(
+ # QBS does not inherit toolchain/flags knowledge from cmake, and
+ # while can use ${BUILD_DIR}/bin/qbs-config to improve this it
+ # remains very fickle and will fail in varied ways with clang,
+ # musl, -native-symlinks, and libc++. After consideration it feels
+ # not worth worrying about affected tests here (even if notable).
+ tst_api
+ tst_blackbox # also skips blackbox-* (intended)
+ tst_language
+)
+
+PATCHES=(
+ "${FILESDIR}"/${PN}-2.3.1-qtver.patch
+)
+
+python_check_deps() {
+ # _find_python_module in cmake/QbsDocumentation.cmake
+ python_has_version "dev-python/beautifulsoup4[${PYTHON_USEDEP}]" &&
+ python_has_version "dev-python/lxml[${PYTHON_USEDEP}]"
+}
+
+pkg_setup() {
+ use doc && python-any-r1_pkg_setup
+}
+
+src_configure() {
+ # temporary workaround for musl-1.2.4 (bug #906929), this ideally
+ # needs fixing in qtbase as *64 usage comes from its headers' macros
+ use elibc_musl && append-lfs-flags
+
+ # tests build failure w/ gcc:14 + -O3 (bug #933187, needs looking into)
+ use test && tc-is-gcc && [[ $(gcc-major-version) -ge 14 ]] &&
+ replace-flags -O3 -O2
+
+ local mycmakeargs=(
+ -DQBS_DOC_INSTALL_DIR="${EPREFIX}"/usr/share/doc/${PF}
+ -DQBS_INSTALL_HTML_DOCS=$(usex doc)
+ -DQBS_INSTALL_MAN_PAGE=yes
+ -DQBS_INSTALL_QCH_DOCS=$(usex doc)
+ -DQBS_LIB_INSTALL_DIR="$(get_libdir)"
+ -DQT_VERSION_MAJOR=6 #931596
+ -DWITH_TESTS=$(usex test)
+ -DWITH_UNIT_TESTS=$(usex test)
+ )
+
+ cmake_src_configure
+}
+
+src_install() {
+ local DOCS=( README.md changelogs )
+ cmake_src_install
+
+ use !test || rm -- "${ED}"/usr/bin/{tst_*,qbs_*,clang-format-test} || die
+
+ docompress -x /usr/share/doc/${PF}/qbs.qch
+}