summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorSam James <sam@gentoo.org>2025-02-14 10:36:30 +0000
committerSam James <sam@gentoo.org>2025-02-14 10:40:11 +0000
commit792be1a00ab69ae88089144481b8bdd0fefbf6a1 (patch)
tree7db21a8f792303b4f8a73dc5fc6d7ee30ad25ace
parentded992d8cc03bd42a5ecb1c495d44153c6416ecc (diff)
downloadkde-792be1a00ab69ae88089144481b8bdd0fefbf6a1.tar.gz
kde-792be1a00ab69ae88089144481b8bdd0fefbf6a1.tar.bz2
kde-792be1a00ab69ae88089144481b8bdd0fefbf6a1.zip
kde-plasma/libksysguard: fix build w/ <libcxx-20
Per Robert on the bug: > libksysguard 9999 fails to build when using the LLVM profile because it now uses > std::jthread and std::stop_token that llvm's libc++ considers experimental > and does not build by default. They're unleashed in libcxx 20 which should be released shortly. In the meantime, pass -fexperimental-library. Closes: https://bugs.gentoo.org/949636 Thanks-to: Steffen Hau <steffen@hauihau.de> Thanks-to: Robert Holt <holt.r94@gmail.com> Signed-off-by: Sam James <sam@gentoo.org>
-rw-r--r--kde-plasma/libksysguard/libksysguard-6.3.49.9999.ebuild8
-rw-r--r--kde-plasma/libksysguard/libksysguard-9999.ebuild8
2 files changed, 14 insertions, 2 deletions
diff --git a/kde-plasma/libksysguard/libksysguard-6.3.49.9999.ebuild b/kde-plasma/libksysguard/libksysguard-6.3.49.9999.ebuild
index 69b562dcaec..458c7986f88 100644
--- a/kde-plasma/libksysguard/libksysguard-6.3.49.9999.ebuild
+++ b/kde-plasma/libksysguard/libksysguard-6.3.49.9999.ebuild
@@ -6,7 +6,7 @@ EAPI=8
ECM_TEST="true"
KFMIN=6.10.0
QTMIN=6.8.1
-inherit ecm fcaps plasma.kde.org
+inherit ecm fcaps flag-o-matic plasma.kde.org toolchain-funcs
DESCRIPTION="Task management and system monitoring library"
@@ -39,6 +39,12 @@ RDEPEND="${DEPEND}
FILECAPS=( -m 0755 cap_sys_nice=ep usr/libexec/ksysguard/ksgrd_network_helper )
src_configure() {
+ # support std::jthread and std::stop_token is not enabled per default
+ # in libc++ prior to version 20, need to add "-fexperimental-library"
+ if tc-is-clang && [[ $(tc-get-cxx-stdlib) == libc++ ]] && [[ "$(clang-major-version)" -lt 20 ]]; then
+ append-cxxflags "-fexperimental-library"
+ fi
+
local mycmakeargs=(
-DCMAKE_DISABLE_FIND_PACKAGE_Libcap=ON
)
diff --git a/kde-plasma/libksysguard/libksysguard-9999.ebuild b/kde-plasma/libksysguard/libksysguard-9999.ebuild
index 4a1abeb8b8d..12597285a10 100644
--- a/kde-plasma/libksysguard/libksysguard-9999.ebuild
+++ b/kde-plasma/libksysguard/libksysguard-9999.ebuild
@@ -6,7 +6,7 @@ EAPI=8
ECM_TEST="true"
KFMIN=9999
QTMIN=6.8.1
-inherit ecm fcaps plasma.kde.org
+inherit ecm fcaps flag-o-matic plasma.kde.org toolchain-funcs
DESCRIPTION="Task management and system monitoring library"
@@ -39,6 +39,12 @@ RDEPEND="${DEPEND}
FILECAPS=( -m 0755 cap_sys_nice=ep usr/libexec/ksysguard/ksgrd_network_helper )
src_configure() {
+ # support std::jthread and std::stop_token is not enabled per default
+ # in libc++ prior to version 20, need to add "-fexperimental-library"
+ if tc-is-clang && [[ $(tc-get-cxx-stdlib) == libc++ ]] && [[ "$(clang-major-version)" -lt 20 ]]; then
+ append-cxxflags "-fexperimental-library"
+ fi
+
local mycmakeargs=(
-DCMAKE_DISABLE_FIND_PACKAGE_Libcap=ON
)