Subject: [PATCH] gnu: Add kid3.

From: Vinicius Monego <[email-masked]>
Date: Mon, 3 Jan 2022 22:38:53 +0000

* gnu/packages/kde.scm (kid3): New variable.
---
 gnu/packages/kde.scm | 65 +++++++++++++++++++++++++++++++++++++++++++-
 1 file changed, 64 insertions(+), 1 deletion(-)

diff --git a/gnu/packages/kde.scm b/gnu/packages/kde.scm
index dfd4cd197c..b7806a6b7a 100644
--- a/gnu/packages/kde.scm
+++ b/gnu/packages/kde.scm
@@ -14,7 +14,7 @@
 ;;; Copyright © 2020, 2021 Zheng Junjie <[email-masked]>
 ;;; Copyright © 2021 Alexandros Theodotou <[email-masked]>
 ;;; Copyright © 2021 la snesne <[email-masked]>
-;;; Copyright © 2021 Vinicius Monego <[email-masked]>
+;;; Copyright © 2021, 2022 Vinicius Monego <[email-masked]>
 ;;;
 ;;; This file is part of GNU Guix.
 ;;;
@@ -36,6 +36,7 @@
   #:use-module (guix build-system qt)
   #:use-module (guix deprecation)
   #:use-module (guix download)
+  #:use-module (guix gexp)
   #:use-module (guix git-download)
   #:use-module ((guix licenses) #:prefix license:)
   #:use-module (guix packages)
@@ -53,6 +54,7 @@
   #:use-module (gnu packages compression)
   #:use-module (gnu packages curl)
   #:use-module (gnu packages djvu)
+  #:use-module (gnu packages docbook)
   #:use-module (gnu packages documentation)
   #:use-module (gnu packages gnupg)
   #:use-module (gnu packages ebook)
@@ -75,6 +77,7 @@
   #:use-module (gnu packages llvm)
   #:use-module (gnu packages markup)
   #:use-module (gnu packages maths)
+  #:use-module (gnu packages mp3)
   #:use-module (gnu packages pdf)
   #:use-module (gnu packages perl)
   #:use-module (gnu packages photo)
@@ -84,9 +87,11 @@
   #:use-module (gnu packages python)
   #:use-module (gnu packages tls)
   #:use-module (gnu packages qt)
+  #:use-module (gnu packages readline)
   #:use-module (gnu packages version-control)
   #:use-module (gnu packages video)
   #:use-module (gnu packages xdisorg)
+  #:use-module (gnu packages xiph)
   #:use-module (gnu packages xml)
   #:use-module (gnu packages xorg))
 
@@ -1035,6 +1040,64 @@ supports searching for places of interest, viewing Wikipedia articles,
 creating routes by drag and drop and more.")
     (license license:lgpl2.1+)))
 
+(define-public kid3
+  (package
+    (name "kid3")
+    (version "3.9.0")
+    (source
+     (origin
+       (method git-fetch)
+       (uri (git-reference
+             (url "https://invent.kde.org/multimedia/kid3.git/")
+             (commit (string-append "v" version))))
+       (file-name (git-file-name name version))
+       (sha256
+        (base32 "02r3cnwr05mcxjawzip3jl1lfijvzfbbafq3saipjjjp4kiq9bk4"))))
+    (build-system qt-build-system)
+    (arguments
+     (list
+      #:configure-flags
+      #~(list (string-append "-DDOCBOOK_XSL_DIR="
+                             #$(this-package-native-input "docbook-xsl")))
+      #:phases
+      `(modify-phases %standard-phases
+         ;; FIXME: Documentation build scripts use unix pipes, which will fail
+         ;; in the build environment.
+         (add-after 'unpack 'skip-docs
+           (lambda _
+             (substitute* "CMakeLists.txt"
+               (("add_subdirectory\\(doc\\)") "")))))))
+    (native-inputs
+     (list docbook-xsl
+           extra-cmake-modules
+           ffmpeg
+           kdoctools
+           libxslt
+           python-wrapper
+           qttools))
+    (inputs
+     (list chromaprint
+           flac
+           id3lib
+           kconfig
+           kconfigwidgets
+           kcoreaddons
+           kio
+           kwidgetsaddons
+           kxmlgui
+           libvorbis
+           qtbase-5
+           qtdeclarative
+           qtmultimedia
+           readline
+           taglib
+           zlib))
+    (home-page "https://kid3.kde.org/")
+    (synopsis "Audio tagger")
+    (description "Kid3 is an audio tagger for KDE that supports a large
+variety of formats.")
+    (license license:gpl2+)))
+
 (define-public okular
   (package
     (name "okular")

base-commit: 861bac1dfbeaaf40b9c11a287ef7607f0fd105a8
-- 
2.30.2