diff mbox series

[bug#70395,kde-team,34/63] gnu: Add kpackage-6.

Message ID e309702fa9196a0840186934e96b0d2ba07b7e46.1713184499.git.zhengjunjie@iscas.ac.cn
State New
Headers show
Series some kde patch. | expand

Commit Message

Zheng Junjie April 15, 2024, 12:47 p.m. UTC
* gnu/packages/kde-frameworks.scm (kpackage-6): New variable.
(kpackage): Inherit above.

Change-Id: Ie0a0c6a5ad24280b386f5480f8fb0761950b157d
---
 gnu/packages/kde-frameworks.scm | 58 ++++++++++++++++++++++++++++-----
 1 file changed, 50 insertions(+), 8 deletions(-)
diff mbox series

Patch

diff --git a/gnu/packages/kde-frameworks.scm b/gnu/packages/kde-frameworks.scm
index 5801e14a06..1cc402c8f9 100644
--- a/gnu/packages/kde-frameworks.scm
+++ b/gnu/packages/kde-frameworks.scm
@@ -2730,8 +2730,56 @@  (define-public knotifications
                               (setenv "DBUS_FATAL_WARNINGS" "0")
                               (invoke "dbus-launch" "ctest")))))))))
 
+(define-public kpackage-6
+  (package
+    (name "kpackage")
+    (version "6.1.0")
+    (source (origin
+              (method url-fetch)
+              (uri (string-append
+                    "mirror://kde/stable/frameworks/"
+                    (version-major+minor version) "/"
+                    name "-" version ".tar.xz"))
+              (sha256
+               (base32
+                "1bsjdc8m31yj7ahxx8fdazhrgcchwlqyxvfvmkws903584mr2xgd"))))
+    (build-system cmake-build-system)
+    (native-inputs
+     (list extra-cmake-modules))
+    (propagated-inputs (list kcoreaddons-6))
+    (inputs
+     (list karchive-6
+           kconfig-6
+           kdoctools-6
+           ki18n-6
+           qtbase))
+    (arguments
+     (list
+      ;; The `plasma-querytest' test is known to fail when tests are run in parallel:
+      ;; <https://sources.debian.org/src/kpackage/5.107.0-1/debian/changelog/#L92>
+      #:parallel-tests? #f
+      #:phases
+      #~(modify-phases %standard-phases
+          (add-after 'unpack 'patch
+            (lambda _
+              (substitute* "src/kpackage/package.cpp"
+                (("bool externalPaths = false;")
+                 "bool externalPaths = true;"))
+              (substitute* '("src/kpackage/packageloader.cpp")
+                (("QDirIterator::Subdirectories")
+                 "QDirIterator::Subdirectories | QDirIterator::FollowSymlinks"))))
+          (add-before 'check 'check-setup
+            (lambda _ (setenv "HOME" (getcwd)))))))
+    (home-page "https://community.kde.org/Frameworks")
+    (synopsis "Installation and loading of additional content as packages")
+    (description "The Package framework lets the user install and load packages
+of non binary content such as scripted extensions or graphic assets, as if they
+were traditional plugins.")
+    (license (list license:gpl2+ license:lgpl2.1+))))
+
 (define-public kpackage
   (package
+    (inherit kpackage-6)
     (name "kpackage")
     (version "5.114.0")
     (source (origin
@@ -2743,7 +2791,6 @@  (define-public kpackage
               (sha256
                (base32
                 "0v165az3k5lfszxy0kl2464573y0dcq92fyfiklwnkkcjsvba69d"))))
-    (build-system cmake-build-system)
     (native-inputs
      (list extra-cmake-modules))
     (inputs
@@ -2753,6 +2800,7 @@  (define-public kpackage
            kdoctools
            ki18n
            qtbase-5))
+    (propagated-inputs '())
     (arguments
      (list
       #:phases
@@ -2790,13 +2838,7 @@  (define-public kpackage
                  ""))))
           (add-before 'check 'check-setup
             (lambda _
-              (setenv "HOME" (getcwd)))))))
-    (home-page "https://community.kde.org/Frameworks")
-    (synopsis "Installation and loading of additional content as packages")
-    (description "The Package framework lets the user install and load packages
-of non binary content such as scripted extensions or graphic assets, as if they
-were traditional plugins.")
-    (license (list license:gpl2+ license:lgpl2.1+))))
+              (setenv "HOME" (getcwd)))))))))
 
 (define-public kpty-6
   (package