commit:     3988b47f84f5051001afbfa6b30b5c97c4fd72ea
Author:     Andreas Sturmlechner <asturm <AT> gentoo <DOT> org>
AuthorDate: Wed Nov 15 21:33:29 2023 +0000
Commit:     Andreas Sturmlechner <asturm <AT> gentoo <DOT> org>
CommitDate: Sat Nov 25 23:25:47 2023 +0000
URL:        https://gitweb.gentoo.org/proj/kde.git/commit/?id=3988b47f

frameworks.kde.org.eclass: Define SLOT=6 for >=5.240, set ECM to SLOT=0

Exclude 5.9999 from SLOT=6.

git master was set to 5.240 for KF6 ports, unstable KF6 releases use
numbers 5.245 and above.

Also do it with less lines and no intermediate vars.

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

 eclass/frameworks.kde.org.eclass | 21 +++++++++++----------
 1 file changed, 11 insertions(+), 10 deletions(-)

diff --git a/eclass/frameworks.kde.org.eclass b/eclass/frameworks.kde.org.eclass
index 456902d39c..5d54b736c9 100644
--- a/eclass/frameworks.kde.org.eclass
+++ b/eclass/frameworks.kde.org.eclass
@@ -35,18 +35,19 @@ inherit kde.org
 
 HOMEPAGE="https://develop.kde.org/products/frameworks/";
 
-_SLOT=6
-_SUBSLOT=${PV}
-if [[ ${KDE_BUILD_TYPE} == release ]]; then
-       _SUBSLOT=$(ver_cut 1-2)
-else
-       _SUBSLOT=9999
+SLOT=6
+if [[ ${PV} == 5.9999 ]] || ver_test ${PV} -lt 5.240; then
+       SLOT=5
 fi
-if [[ ${PV/.*} == 5 ]]; then
-       _SLOT=5
+if [[ ${PN} == extra-cmake-modules ]]; then
+       SLOT=0
+else
+       if [[ ${KDE_BUILD_TYPE} == release ]]; then
+               SLOT=${SLOT}/$(ver_cut 1-2)
+       else
+               SLOT=${SLOT}/9999
+       fi
 fi
-SLOT=${_SLOT}/${_SUBSLOT}
-unset _SLOT _SUBSLOT
 
 # @ECLASS_VARIABLE: KDE_ORG_SCHEDULE_URI
 # @INTERNAL

Reply via email to