summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorRepository mirror & CI <repomirrorci@gentoo.org>2025-11-11 16:16:02 +0000
committerRepository mirror & CI <repomirrorci@gentoo.org>2025-11-11 16:16:02 +0000
commitdb51d60ceb73d639bb88c37281587ff810c97dd4 (patch)
treec0271524876816010f302562a43810db06b48062
parent61425666363fb7b9031e88a49ce1e1ecb22df6ba (diff)
parent2a406ad371552961d404b79ee49d43c0e6810035 (diff)
downloadkde-db51d60ceb73d639bb88c37281587ff810c97dd4.tar.gz
kde-db51d60ceb73d639bb88c37281587ff810c97dd4.tar.bz2
kde-db51d60ceb73d639bb88c37281587ff810c97dd4.zip
Merge updates from master
-rw-r--r--eclass/cmake.eclass41
-rw-r--r--kde-apps/kate-addons/kate-addons-9999.ebuild4
-rw-r--r--kde-apps/kate/kate-9999.ebuild4
-rw-r--r--kde-apps/kmail/kmail-9999.ebuild2
-rw-r--r--kde-apps/kwrite/kwrite-9999.ebuild4
-rw-r--r--kde-apps/libkcddb/libkcddb-9999.ebuild2
-rw-r--r--kde-frameworks/kwallet-runtime/kwallet-runtime-6.20.0.ebuild2
-rw-r--r--kde-frameworks/kwallet-runtime/kwallet-runtime-9999.ebuild2
-rw-r--r--kde-frameworks/purpose/purpose-6.20.0.ebuild2
-rw-r--r--kde-frameworks/purpose/purpose-9999.ebuild2
-rw-r--r--kde-plasma/kscreenlocker/kscreenlocker-6.5.49.9999.ebuild2
-rw-r--r--kde-plasma/kscreenlocker/kscreenlocker-9999.ebuild2
-rw-r--r--kde-plasma/plasma-workspace/plasma-workspace-6.5.49.9999.ebuild2
-rw-r--r--kde-plasma/plasma-workspace/plasma-workspace-9999.ebuild2
14 files changed, 48 insertions, 25 deletions
diff --git a/eclass/cmake.eclass b/eclass/cmake.eclass
index b853727b473..98f10f8d9aa 100644
--- a/eclass/cmake.eclass
+++ b/eclass/cmake.eclass
@@ -207,21 +207,44 @@ cmake_run_in() {
}
# @FUNCTION: cmake_comment_add_subdirectory
-# @USAGE: <subdirectory>
+# @USAGE: [-f <filename or directory>] <subdirectory> [<subdirectories>]
# @DESCRIPTION:
-# Comment out one or more add_subdirectory calls in CMakeLists.txt in the current directory
+# Comment out one or more add_subdirectory calls with #DONOTBUILD in
+# a) a given file path (error out on nonexisting path)
+# b) a CMakeLists.txt file inside a given directory (ewarn if not found)
+# c) CMakeLists.txt in current directory (do nothing if not found).
cmake_comment_add_subdirectory() {
- if [[ -z ${1} ]]; then
- die "${FUNCNAME[0]} must be passed at least one directory name to comment"
+ local d filename="CMakeLists.txt"
+ if [[ $# -lt 1 ]]; then
+ die "${FUNCNAME} must be passed at least one subdirectory name to comment"
fi
+ case ${1} in
+ -f)
+ if [[ $# -ge 2 ]]; then
+ filename="${2}"
+ if [[ -d ${filename} ]]; then
+ filename+="/CMakeLists.txt"
+ if [[ ! -e ${filename} ]]; then
+ ewarn "You've given me nothing to work with in ${filename}!"
+ return
+ fi
+ elif [[ ! -e ${filename} ]]; then
+ die "${FUNCNAME}: called on non-existing ${filename}"
+ fi
+ else
+ die "${FUNCNAME}: bad number of arguments: -f <filename or directory> <subdirectory> expected"
+ fi
+ shift 2
+ ;;
+ *)
+ [[ -e ${filename} ]] || return
+ ;;
+ esac
- [[ -e "CMakeLists.txt" ]] || return
-
- local d
for d in $@; do
d=${d//\//\\/}
- sed -e "/add_subdirectory[[:space:]]*([[:space:]]*${d}[[:space:]]*)/I s/^/#DONOTCOMPILE /" \
- -i CMakeLists.txt || die "failed to comment add_subdirectory(${d})"
+ sed -e "/add_subdirectory[[:space:]]*([[:space:]]*${d}[[:space:]]*)/I s/^/#DONOTBUILD /" \
+ -i ${filename} || die "failed to comment add_subdirectory(${d})"
done
}
diff --git a/kde-apps/kate-addons/kate-addons-9999.ebuild b/kde-apps/kate-addons/kate-addons-9999.ebuild
index 04fd4cdcb5a..2b5ab898657 100644
--- a/kde-apps/kate-addons/kate-addons-9999.ebuild
+++ b/kde-apps/kate-addons/kate-addons-9999.ebuild
@@ -66,10 +66,10 @@ src_prepare() {
ecm_punt_po_install
# these tests are run in kde-apps/kate-lib
- cmake_run_in apps/lib cmake_comment_add_subdirectory autotests
+ cmake_comment_add_subdirectory -f apps/lib autotests
# Don't build kio plugin
- cmake_run_in apps/lib cmake_comment_add_subdirectory io
+ cmake_comment_add_subdirectory -f apps/lib io
}
src_configure() {
diff --git a/kde-apps/kate/kate-9999.ebuild b/kde-apps/kate/kate-9999.ebuild
index ddb2585ea4b..3f8168c31c2 100644
--- a/kde-apps/kate/kate-9999.ebuild
+++ b/kde-apps/kate/kate-9999.ebuild
@@ -38,10 +38,10 @@ src_prepare() {
ecm_punt_po_install
# these tests are run in kde-apps/kate-lib
- cmake_run_in apps/lib cmake_comment_add_subdirectory autotests
+ cmake_comment_add_subdirectory -f apps/lib autotests
# Don't build kio plugin
- cmake_run_in apps/lib cmake_comment_add_subdirectory io
+ cmake_comment_add_subdirectory -f apps/lib io
}
src_configure() {
diff --git a/kde-apps/kmail/kmail-9999.ebuild b/kde-apps/kmail/kmail-9999.ebuild
index 5502cd23279..0afecebc509 100644
--- a/kde-apps/kmail/kmail-9999.ebuild
+++ b/kde-apps/kmail/kmail-9999.ebuild
@@ -95,7 +95,7 @@ BDEPEND="
src_prepare() {
ecm_src_prepare
- use handbook || cmake_run_in ktnef cmake_comment_add_subdirectory doc
+ use handbook || cmake_comment_add_subdirectory -f ktnef doc
}
src_configure() {
diff --git a/kde-apps/kwrite/kwrite-9999.ebuild b/kde-apps/kwrite/kwrite-9999.ebuild
index 566d35eeae3..15384982439 100644
--- a/kde-apps/kwrite/kwrite-9999.ebuild
+++ b/kde-apps/kwrite/kwrite-9999.ebuild
@@ -34,10 +34,10 @@ src_prepare() {
ecm_punt_po_install
# these tests are run in kde-apps/kate-lib
- cmake_run_in apps/lib cmake_comment_add_subdirectory autotests
+ cmake_comment_add_subdirectory -f apps/lib autotests
# Don't build kio plugin
- cmake_run_in apps/lib cmake_comment_add_subdirectory io
+ cmake_comment_add_subdirectory -f apps/lib io
}
src_configure() {
diff --git a/kde-apps/libkcddb/libkcddb-9999.ebuild b/kde-apps/libkcddb/libkcddb-9999.ebuild
index 5fa35dce592..549128738c4 100644
--- a/kde-apps/libkcddb/libkcddb-9999.ebuild
+++ b/kde-apps/libkcddb/libkcddb-9999.ebuild
@@ -44,7 +44,7 @@ ECM_REMOVE_FROM_INSTALL=(
src_prepare() {
ecm_src_prepare
ecm_punt_po_install
- cmake_run_in kcmcddb cmake_comment_add_subdirectory doc
+ cmake_comment_add_subdirectory -f kcmcddb doc
}
src_configure() {
diff --git a/kde-frameworks/kwallet-runtime/kwallet-runtime-6.20.0.ebuild b/kde-frameworks/kwallet-runtime/kwallet-runtime-6.20.0.ebuild
index d7d3c553118..e72d9c3a966 100644
--- a/kde-frameworks/kwallet-runtime/kwallet-runtime-6.20.0.ebuild
+++ b/kde-frameworks/kwallet-runtime/kwallet-runtime-6.20.0.ebuild
@@ -42,7 +42,7 @@ PATCHES=( "${FILESDIR}/${PN}-6.14.0-stdalone.patch" )
src_prepare() {
ecm_src_prepare
- cmake_run_in src cmake_comment_add_subdirectory api
+ cmake_comment_add_subdirectory -f src api
}
src_configure() {
diff --git a/kde-frameworks/kwallet-runtime/kwallet-runtime-9999.ebuild b/kde-frameworks/kwallet-runtime/kwallet-runtime-9999.ebuild
index 57aa194aeb1..54617e60a3c 100644
--- a/kde-frameworks/kwallet-runtime/kwallet-runtime-9999.ebuild
+++ b/kde-frameworks/kwallet-runtime/kwallet-runtime-9999.ebuild
@@ -42,7 +42,7 @@ PATCHES=( "${FILESDIR}/${PN}-6.14.0-stdalone.patch" )
src_prepare() {
ecm_src_prepare
- cmake_run_in src cmake_comment_add_subdirectory api
+ cmake_comment_add_subdirectory -f src api
}
src_configure() {
diff --git a/kde-frameworks/purpose/purpose-6.20.0.ebuild b/kde-frameworks/purpose/purpose-6.20.0.ebuild
index ce31b0050a1..1f81cec7ddf 100644
--- a/kde-frameworks/purpose/purpose-6.20.0.ebuild
+++ b/kde-frameworks/purpose/purpose-6.20.0.ebuild
@@ -49,7 +49,7 @@ src_prepare() {
ecm_src_prepare
use bluetooth ||
- cmake_run_in src/plugins cmake_comment_add_subdirectory bluetooth
+ cmake_comment_add_subdirectory -f src/plugins bluetooth
}
src_configure() {
diff --git a/kde-frameworks/purpose/purpose-9999.ebuild b/kde-frameworks/purpose/purpose-9999.ebuild
index c3007dd920c..30c9d2d35b6 100644
--- a/kde-frameworks/purpose/purpose-9999.ebuild
+++ b/kde-frameworks/purpose/purpose-9999.ebuild
@@ -49,7 +49,7 @@ src_prepare() {
ecm_src_prepare
use bluetooth ||
- cmake_run_in src/plugins cmake_comment_add_subdirectory bluetooth
+ cmake_comment_add_subdirectory -f src/plugins bluetooth
}
src_configure() {
diff --git a/kde-plasma/kscreenlocker/kscreenlocker-6.5.49.9999.ebuild b/kde-plasma/kscreenlocker/kscreenlocker-6.5.49.9999.ebuild
index a41104d2376..2c16ff672d4 100644
--- a/kde-plasma/kscreenlocker/kscreenlocker-6.5.49.9999.ebuild
+++ b/kde-plasma/kscreenlocker/kscreenlocker-6.5.49.9999.ebuild
@@ -60,7 +60,7 @@ BDEPEND="
src_prepare() {
ecm_src_prepare
- use test || cmake_run_in greeter cmake_comment_add_subdirectory autotests
+ use test || cmake_comment_add_subdirectory -f greeter autotests
}
src_test() {
diff --git a/kde-plasma/kscreenlocker/kscreenlocker-9999.ebuild b/kde-plasma/kscreenlocker/kscreenlocker-9999.ebuild
index c91ed963883..5252497070e 100644
--- a/kde-plasma/kscreenlocker/kscreenlocker-9999.ebuild
+++ b/kde-plasma/kscreenlocker/kscreenlocker-9999.ebuild
@@ -60,7 +60,7 @@ BDEPEND="
src_prepare() {
ecm_src_prepare
- use test || cmake_run_in greeter cmake_comment_add_subdirectory autotests
+ use test || cmake_comment_add_subdirectory -f greeter autotests
}
src_test() {
diff --git a/kde-plasma/plasma-workspace/plasma-workspace-6.5.49.9999.ebuild b/kde-plasma/plasma-workspace/plasma-workspace-6.5.49.9999.ebuild
index 2a03555de22..37b65de5d55 100644
--- a/kde-plasma/plasma-workspace/plasma-workspace-6.5.49.9999.ebuild
+++ b/kde-plasma/plasma-workspace/plasma-workspace-6.5.49.9999.ebuild
@@ -174,7 +174,7 @@ src_prepare() {
fi
if ! use policykit; then
- cmake_run_in kcms cmake_comment_add_subdirectory users
+ cmake_comment_add_subdirectory -f kcms users
fi
if ! use fontconfig; then
diff --git a/kde-plasma/plasma-workspace/plasma-workspace-9999.ebuild b/kde-plasma/plasma-workspace/plasma-workspace-9999.ebuild
index c5c7ecd4863..3150c1d9f29 100644
--- a/kde-plasma/plasma-workspace/plasma-workspace-9999.ebuild
+++ b/kde-plasma/plasma-workspace/plasma-workspace-9999.ebuild
@@ -168,7 +168,7 @@ src_prepare() {
cmake_comment_add_subdirectory login-sessions
if ! use policykit; then
- cmake_run_in kcms cmake_comment_add_subdirectory users
+ cmake_comment_add_subdirectory -f kcms users
fi
if ! use fontconfig; then