gnu: clementine: Update to 1.4.1-48.12e851937.

Also add support for visualisation.

* gnu/packages/music.scm (clementine): Update to 1.4.1-48.12e851937.
[version]: Change versioning scheme to use upstream revisions.
[#:configure-flags]: Add “-DENABLE_VISUALISATIONS=ON”.

Change-Id: Icce03534674c80e0078adead9bc7b75886da4582
Signed-off-by: Liliana Marie Prikler <liliana.prikler@gmail.com>
This commit is contained in:
Noé Lopez 2025-07-29 12:26:17 +02:00 committed by Liliana Marie Prikler
parent ff94136614
commit afaaee573d
No known key found for this signature in database
GPG key ID: 442A84B8C70E2F87

View file

@ -497,117 +497,121 @@ enables iPod support in music players such as Clementine.")
(license license:lgpl2.1+))) (license license:lgpl2.1+)))
(define-public clementine (define-public clementine
(package ;; Clementine has one automatic release per commit at
(name "clementine") ;; <https://github.com/clementine-player/Clementine/releases>.
(version "1.4.0rc1-450-g2725ef99d") (let ((commit "12e8519370e4e7af2daca280cd31f039289a6450")
(source (origin (revision "48"))
(method git-fetch) (package
(uri (git-reference (name "clementine")
(url "https://github.com/clementine-player/Clementine") (version (git-version "1.4.1" revision commit))
(commit version))) (source (origin
(file-name (git-file-name name version)) (method git-fetch)
(sha256 (uri (git-reference
(base32 (url "https://github.com/clementine-player/Clementine")
"1pcwwi9b2qcfjn748577gqx6d1hgg7cisw2dn43npwafdvvkdb90")) (commit commit)))
(modules '((guix build utils) (file-name (git-file-name name version))
(ice-9 regex))) (sha256
(snippet (base32
'(begin "06sl9ywrpkmwdr3v75q0x6j111xgb4w2d1fcykmfwp26i77hvh1g"))
(use-modules ((ice-9 regex))) (modules '((guix build utils)
(for-each (ice-9 regex)))
(lambda (dir) (snippet
;; TODO: The following dependencies are still bundled: '(begin
;; - "qxt": Appears to be unmaintained upstream. (use-modules ((ice-9 regex)))
;; - "qsqlite" (for-each
;; - "qtsingleapplication" (lambda (dir)
;; - "qocoa" ;; TODO: The following dependencies are still bundled:
;; - "qtiocompressor" ;; - "qxt": Appears to be unmaintained upstream.
(let ((bundled '("qsqlite" ;; - "qsqlite"
"qtsingleapplication" ;; - "qtsingleapplication"
"qxt" ;; - "qocoa"
"qocoa" ;; - "qtiocompressor"
"qtiocompressor"))) ;; - "projectm" Uses an old version with custom patches.
(if (not (let ((bundled '("qsqlite"
(string-match "qtsingleapplication"
(string-append ".?*(" (string-join bundled "|") ")") "qxt"
dir)) "qocoa"
(delete-file-recursively dir)))) "qtiocompressor"
(find-files "3rdparty" "projectm")))
(lambda (file stat) (if (not
(string-match "^3rdparty/[^/]*$" file)) (string-match
#:directories? #t)))))) (string-append ".?*(" (string-join bundled "|") ")")
(build-system cmake-build-system) dir))
(arguments (delete-file-recursively dir))))
(list (find-files "3rdparty"
#:configure-flags (lambda (file stat)
#~(list ;; Requires unpackaged "projectm" (string-match "^3rdparty/[^/]*$" file))
"-DENABLE_VISUALISATIONS=OFF" #:directories? #t))))))
;; Otherwise it may try to download a non-free library at run-time. (build-system cmake-build-system)
;; TODO In an origin snippet, remove the code that performs the (arguments
;; download. (list
"-DHAVE_SPOTIFY_DOWNLOADER=FALSE" #:configure-flags
;; Clementine checks that the taglib version is higher than 1.11, #~(list
;; because of https://github.com/taglib/taglib/issues/864. Remove "-DENABLE_VISUALISATIONS=ON"
;; this flag when 1.12 is released. ;; Otherwise it may try to download a non-free library at run-time.
"-DUSE_SYSTEM_TAGLIB=TRUE") ;; TODO In an origin snippet, remove the code that performs the
#:modules '((guix build cmake-build-system) ;; download.
((guix build gnu-build-system) #:prefix gnu:) "-DHAVE_SPOTIFY_DOWNLOADER=FALSE"
(guix build utils)) (string-append "-DFORCE_GIT_REVISION=" #$commit))
#:phases #:modules '((guix build cmake-build-system)
#~(modify-phases %standard-phases ((guix build gnu-build-system) #:prefix gnu:)
(replace 'check (guix build utils))
(lambda* (#:rest args) #:phases
(apply (assoc-ref gnu:%standard-phases 'check) #~(modify-phases %standard-phases
#:test-target "clementine_test" args))) (replace 'check
(add-after 'install 'wrap-program (lambda* (#:rest args)
(lambda* (#:key inputs outputs #:allow-other-keys) (apply (assoc-ref gnu:%standard-phases 'check)
(let ((out (assoc-ref outputs "out")) #:test-target "clementine_test" args)))
(gst-plugin-path (getenv "GST_PLUGIN_SYSTEM_PATH"))) (add-after 'install 'wrap-program
(wrap-program (string-append out "/bin/clementine") (lambda* (#:key inputs outputs #:allow-other-keys)
`("GST_PLUGIN_SYSTEM_PATH" ":" prefix (let ((out (assoc-ref outputs "out"))
(,gst-plugin-path))))))))) (gst-plugin-path (getenv "GST_PLUGIN_SYSTEM_PATH")))
(native-inputs (wrap-program (string-append out "/bin/clementine")
(list gettext-minimal `("GST_PLUGIN_SYSTEM_PATH" ":" prefix
googletest (,gst-plugin-path)))))))))
pkg-config (native-inputs
qttools-5)) (list gettext-minimal
(inputs googletest
(list bash-minimal pkg-config
boost qttools-5))
chromaprint (inputs
fftw (list bash-minimal
glib boost
glu chromaprint
gstreamer fftw
gst-plugins-base glib
gst-plugins-good glu
gst-libav gstreamer
libcdio gst-plugins-base
libmygpo-qt gst-plugins-good
libgpod gst-libav
libmtp libcdio
libxml2 libmygpo-qt
protobuf libgpod
pulseaudio libmtp
qtbase-5 libxml2
qtx11extras glew
sqlite protobuf
sparsehash pulseaudio
taglib)) qtbase-5
(home-page "https://clementine-player.org") qtx11extras
(synopsis "Music player and library organizer") sqlite
(description "Clementine is a multiplatform music player. It is inspired sparsehash
taglib))
(home-page "https://clementine-player.org")
(synopsis "Music player and library organizer")
(description "Clementine is a multiplatform music player. It is inspired
by Amarok 1.4, focusing on a fast and easy-to-use interface for searching and by Amarok 1.4, focusing on a fast and easy-to-use interface for searching and
playing your music.") playing your music.")
(license (list (license (list
;; clementine and qtiocompressor are under GPLv3. ;; clementine and qtiocompressor are under GPLv3.
license:gpl3+ license:gpl3+
;; qxt is under CPL1.0. ;; qxt is under CPL1.0.
license:cpl1.0 license:cpl1.0
;; qsqlite and qtsingleapplication are under LGPL2.1+. ;; qsqlite, libprojectm and qtsingleapplication are under LGPL2.1+.
license:lgpl2.1+ license:lgpl2.1+
;; qocoa is under MIT and CC by-sa for the icons. ;; qocoa is under MIT and CC by-sa for the icons.
license:cc-by-sa3.0)))) license:cc-by-sa3.0)))))
(define-public ctrlr (define-public ctrlr
;; The latest release from 2021 does not have a build system. ;; The latest release from 2021 does not have a build system.