@@ -41,6 +41,7 @@
#:use-module (gnu packages algebra)
#:use-module (gnu packages apr)
#:use-module (gnu packages audio)
+ #:use-module (gnu packages backup)
#:use-module (gnu packages bison)
#:use-module (gnu packages boost)
#:use-module (gnu packages code)
@@ -79,6 +80,74 @@
#:use-module (gnu packages xml)
#:use-module (gnu packages xorg))
+(define-public ark
+ (package
+ (name "ark")
+ ;; 20.12.0 need ECM 5.71.0, but guix extra-cmake-modules ECM is 5.70.1.
+ (version "20.04.1")
+ (source (origin
+ (method url-fetch)
+ (uri (string-append "mirror://kde/stable/release-service/" version
+ "/src/ark-" version ".tar.xz"))
+
+ (sha256
+ (base32
+ "0g5bfa1lc7mhrc2ngd4ldf33dpwr7gqrj95kp897pf632wwj23iw"))
+ (patches (search-patches
+ ;; guix libarchive no support xar.
+ "ark-skip-xar-test.patch"))))
+ (build-system qt-build-system)
+ (arguments
+ `(#:phases
+ (modify-phases %standard-phases
+ (add-before 'check 'start-xserver
+ ;;; adddialogtest need DISPLAY.
+ (lambda* (#:key inputs #:allow-other-keys)
+ (let ((xorg-server (assoc-ref inputs "xorg-server")))
+ (setenv "HOME" (getcwd))
+ (system (format #f "~a/bin/Xvfb :1 &" xorg-server))
+ (setenv "DISPLAY" ":1")
+ #t))))))
+ (native-inputs
+ `(("extra-cmake-modules" ,extra-cmake-modules)
+ ("pkg-config" ,pkg-config)
+ ("kdoctools" ,kdoctools)))
+ (inputs
+ `(("breeze-icons" ,breeze-icons)
+ ("karchive" ,karchive)
+ ("kconfig" ,kconfig)
+ ("kcrash" ,kcrash)
+ ("kdbusaddons" ,kdbusaddons)
+ ("khtml" ,khtml)
+ ("ki18n" ,ki18n)
+ ("kio" ,kio)
+ ("kitemmodels" ,kitemmodels)
+ ("kparts" ,kparts)
+ ("kpty" ,kpty)
+ ("kservice" ,kservice)
+ ("kwidgetsaddons" ,kwidgetsaddons)
+ ("libarchive" ,libarchive)
+ ("libzip" ,libzip)
+ ("qtbase" ,qtbase)
+ ("zlib" ,zlib)
+
+ ;; test
+ ("lz4" ,lz4)
+ ("xorg-server" ,xorg-server)))
+ (propagated-inputs
+ `(("unzip" ,unzip)
+ ("zip" ,zip)
+ ("lrzip" ,lrzip)
+ ("lzop" ,lzop)
+ ("zstd" ,zstd)
+ ("p7zip" ,p7zip)))
+ (home-page "https://apps.kde.org/en/ark")
+ (synopsis "Archiving Tool")
+ (description "Ark is a graphical file compression/decompression utility with
+ support for multiple formats, including tar, gzip, bzip2, rar and zip, as well
+as CD-ROM images.")
+ (license license:gpl2+)))
+
(define-public baloo-widgets
(package
(name "baloo-widgets")
new file mode 100644
@@ -0,0 +1,44 @@
+Guix libarchive no support xar.
+
+--- ark-20.04.1.orig/autotests/kerfuffle/loadtest.cpp 2020-12-23 08:46:15.780782601 +0800
++++ ark-20.04.1/autotests/kerfuffle/loadtest.cpp 2020-12-23 11:13:17.101724042 +0800
+@@ -181,13 +181,6 @@
+ qDebug() << "lz4 executable not found in path. Skipping lz4 test.";
+ }
+
+- QTest::newRow("xar archive")
+- << QFINDTESTDATA("data/simplearchive.xar")
+- << QStringLiteral("simplearchive")
+- << true << false << false << false << false << 0 << Archive::Unencrypted
+- << QStringLiteral("simplearchive")
+- << QString();
+-
+ QTest::newRow("mimetype child of application/zip")
+ << QFINDTESTDATA("data/test.odt")
+ << QStringLiteral("test")
+--- ark-20.04.1.orig/autotests/kerfuffle/extracttest.cpp 2020-12-23 08:46:15.780782601 +0800
++++ ark-20.04.1/autotests/kerfuffle/extracttest.cpp 2020-12-23 11:14:02.801809620 +0800
+@@ -350,23 +350,6 @@
+ qDebug() << "lz4 executable not found in path. Skipping lz4 test.";
+ }
+
+- archivePath = QFINDTESTDATA("data/simplearchive.xar");
+- QTest::newRow("extract selected entries from a xar archive without path")
+- << archivePath
+- << QVector<Archive::Entry*> {
+- new Archive::Entry(this, QStringLiteral("dir1/file11.txt"), QString()),
+- new Archive::Entry(this, QStringLiteral("file4.txt"), QString())
+- }
+- << optionsNoPaths
+- << 2;
+-
+- archivePath = QFINDTESTDATA("data/simplearchive.xar");
+- QTest::newRow("extract all entries from a xar archive with path")
+- << archivePath
+- << QVector<Archive::Entry*>()
+- << optionsPreservePaths
+- << 6;
+-
+ archivePath = QFINDTESTDATA("data/hello-1.0-x86_64.AppImage");
+ QTest::newRow("extract all entries from an AppImage with path")
+ << archivePath