Commit | Line | Data |
---|---|---|
892d8a81 | 1 | ;;; GNU Guix --- Functional package management for GNU |
927ff2c3 | 2 | ;;; Copyright © 2014, 2015 David Thompson <dthompson2@worcester.edu> |
b0193286 | 3 | ;;; Copyright © 2014 Andreas Enge <andreas@enge.fr> |
009c5b5c | 4 | ;;; Copyright © 2014 Cyrill Schenkel <cyrill.schenkel@gmail.com> |
29a7c98a | 5 | ;;; Copyright © 2014 Ian Denhardt <ian@zenhack.net> |
e42dc624 | 6 | ;;; Copyright © 2015 Paul van der Walt <paul@denknerd.org> |
c59ea46f | 7 | ;;; Copyright © 2016, 2018 Leo Famulari <leo@famulari.name> |
7da9e792 | 8 | ;;; Copyright © 2018 Tobias Geerinckx-Rice <me@tobias.gr> |
892d8a81 DT |
9 | ;;; |
10 | ;;; This file is part of GNU Guix. | |
11 | ;;; | |
12 | ;;; GNU Guix is free software; you can redistribute it and/or modify it | |
13 | ;;; under the terms of the GNU General Public License as published by | |
14 | ;;; the Free Software Foundation; either version 3 of the License, or (at | |
15 | ;;; your option) any later version. | |
16 | ;;; | |
17 | ;;; GNU Guix is distributed in the hope that it will be useful, but | |
18 | ;;; WITHOUT ANY WARRANTY; without even the implied warranty of | |
19 | ;;; MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the | |
20 | ;;; GNU General Public License for more details. | |
21 | ;;; | |
22 | ;;; You should have received a copy of the GNU General Public License | |
23 | ;;; along with GNU Guix. If not, see <http://www.gnu.org/licenses/>. | |
24 | ||
25 | (define-module (gnu packages mpd) | |
26 | #:use-module (gnu packages) | |
7dc68701 | 27 | #:use-module ((guix licenses) #:prefix license:) |
892d8a81 DT |
28 | #:use-module (guix packages) |
29 | #:use-module (guix download) | |
29a7c98a | 30 | #:use-module (guix utils) |
892d8a81 | 31 | #:use-module (guix build-system gnu) |
7da9e792 | 32 | #:use-module (guix build-system meson) |
efe0b143 | 33 | #:use-module (guix build-system python) |
7dc68701 | 34 | #:use-module (gnu packages avahi) |
e42dc624 | 35 | #:use-module (gnu packages boost) |
7c0ed27a | 36 | #:use-module (gnu packages gcc) |
6c86cef5 CB |
37 | #:use-module (gnu packages gettext) |
38 | #:use-module (gnu packages gnome) | |
39 | #:use-module (gnu packages gtk) | |
58acabc3 | 40 | #:use-module (gnu packages icu4c) |
e42dc624 | 41 | #:use-module (gnu packages readline) |
ac257f12 | 42 | #:use-module (gnu packages check) |
7dc68701 DT |
43 | #:use-module (gnu packages compression) |
44 | #:use-module (gnu packages curl) | |
99828fa7 | 45 | #:use-module (gnu packages documentation) |
7dc68701 DT |
46 | #:use-module (gnu packages glib) |
47 | #:use-module (gnu packages linux) | |
48 | #:use-module (gnu packages mp3) | |
4d01bd3c | 49 | #:use-module (gnu packages ncurses) |
cd220e60 | 50 | #:use-module (gnu packages pcre) |
7dc68701 | 51 | #:use-module (gnu packages pkg-config) |
efe0b143 | 52 | #:use-module (gnu packages python) |
7dc68701 | 53 | #:use-module (gnu packages pulseaudio) |
5f96f303 | 54 | #:use-module (gnu packages databases) |
7dc68701 | 55 | #:use-module (gnu packages video) |
654b27e5 | 56 | #:use-module (gnu packages xiph)) |
892d8a81 | 57 | |
654b27e5 | 58 | (define-public libmpdclient |
892d8a81 DT |
59 | (package |
60 | (name "libmpdclient") | |
69c69c2d | 61 | (version "2.16") |
892d8a81 DT |
62 | (source (origin |
63 | (method url-fetch) | |
64 | (uri | |
c59ea46f | 65 | (string-append "https://musicpd.org/download/libmpdclient/" |
892d8a81 | 66 | (car (string-split version #\.)) |
a53a925f | 67 | "/libmpdclient-" version ".tar.xz")) |
892d8a81 DT |
68 | (sha256 |
69 | (base32 | |
69c69c2d | 70 | "0r24cl3i9nvs6a47mvwaxk1kb5wmnhkhrw1q5cq9010fgjvdlszs")))) |
7da9e792 TGR |
71 | (build-system meson-build-system) |
72 | (native-inputs | |
73 | `(("pkg-config" ,pkg-config) | |
74 | ||
75 | ;; For building HTML documentation. | |
76 | ("doxygen" ,doxygen) | |
77 | ||
78 | ;; For tests. | |
79 | ("check" ,check))) | |
80 | (arguments | |
81 | `(#:configure-flags | |
82 | (list "-Ddocumentation=true" | |
83 | "-Dtest=true"))) | |
892d8a81 DT |
84 | (synopsis "Music Player Daemon client library") |
85 | (description "A stable, documented, asynchronous API library for | |
86 | interfacing MPD in the C, C++ & Objective C languages.") | |
e9aa6b5e | 87 | (home-page "https://www.musicpd.org/libs/libmpdclient/") |
7dc68701 DT |
88 | (license license:bsd-3))) |
89 | ||
654b27e5 | 90 | (define-public mpd |
7dc68701 DT |
91 | (package |
92 | (name "mpd") | |
567f0235 | 93 | (version "0.20.21") |
7dc68701 DT |
94 | (source (origin |
95 | (method url-fetch) | |
96 | (uri | |
943100f6 | 97 | (string-append "https://musicpd.org/download/mpd/" |
29a7c98a | 98 | (version-major+minor version) |
58acabc3 | 99 | "/mpd-" version ".tar.xz")) |
7dc68701 DT |
100 | (sha256 |
101 | (base32 | |
567f0235 | 102 | "1p2qrhdb1gzfv3y5dvvbc9s2wwmhg3azvzf8r02hzhk5q96pc8l3")))) |
7dc68701 | 103 | (build-system gnu-build-system) |
87b52095 LF |
104 | (arguments |
105 | `(#:phases | |
106 | (modify-phases %standard-phases | |
107 | (add-after 'install 'install-service-files | |
108 | (lambda* (#:key outputs #:allow-other-keys) | |
109 | (let* ((out (assoc-ref outputs "out")) | |
110 | (systemd (string-append out "/etc/systemd/system")) | |
111 | (systemd-user (string-append out "/etc/systemd/user"))) | |
112 | (install-file "systemd/system/mpd.service" systemd) | |
113 | (install-file "systemd/user/mpd.service" systemd-user) | |
114 | #t)))))) | |
7dc68701 DT |
115 | (inputs `(("ao" ,ao) |
116 | ("alsa-lib" ,alsa-lib) | |
117 | ("avahi" ,avahi) | |
58acabc3 | 118 | ("boost" ,boost) |
7dc68701 DT |
119 | ("curl" ,curl) |
120 | ("ffmpeg" ,ffmpeg) | |
121 | ("flac" ,flac) | |
122 | ("glib" ,glib) | |
58acabc3 | 123 | ("icu4c" ,icu4c) |
241caa62 LF |
124 | ;; The LAME decoder comes from FFmpeg, but is added here so that |
125 | ;; configure picks up the LAME encoder. | |
7dc68701 DT |
126 | ("lame" ,lame) |
127 | ("libid3tag" ,libid3tag) | |
7dc68701 DT |
128 | ("libmpdclient" ,libmpdclient) |
129 | ("libsamplerate" ,libsamplerate) | |
130 | ("libsndfile" ,libsndfile) | |
131 | ("libvorbis" ,libvorbis) | |
132 | ("opus" ,opus) | |
7dc68701 DT |
133 | ("pulseaudio" ,pulseaudio) |
134 | ("sqlite" ,sqlite) | |
135 | ("zlib" ,zlib))) | |
7641266b | 136 | (native-inputs `(("pkg-config" ,pkg-config))) |
7dc68701 DT |
137 | ;; Missing optional inputs: |
138 | ;; libyajl | |
139 | ;; libcdio_paranoia | |
140 | ;; libmms | |
141 | ;; libadplug | |
142 | ;; libaudiofile | |
143 | ;; faad2 | |
144 | ;; fluidsynth | |
145 | ;; libgme | |
146 | ;; libshout | |
147 | ;; libmpg123 | |
148 | ;; libmodplug | |
149 | ;; libmpcdec | |
150 | ;; libsidplay2 | |
151 | ;; libwavpack | |
152 | ;; libwildmidi | |
153 | ;; libtwolame | |
154 | ;; libroar | |
155 | ;; libjack | |
156 | ;; OpenAL | |
157 | (synopsis "Music Player Daemon") | |
158 | (description "Music Player Daemon (MPD) is a flexible, powerful, | |
159 | server-side application for playing music. Through plugins and libraries it | |
160 | can play a variety of sound files while being controlled by its network | |
161 | protocol.") | |
e9aa6b5e | 162 | (home-page "https://www.musicpd.org/") |
7dc68701 | 163 | (license license:gpl2))) |
4d01bd3c | 164 | |
654b27e5 | 165 | (define-public mpd-mpc |
773b2792 PW |
166 | (package |
167 | (name "mpd-mpc") | |
021469bc | 168 | (version "0.30") |
773b2792 PW |
169 | (source (origin |
170 | (method url-fetch) | |
171 | (uri | |
62d14d24 | 172 | (string-append "https://www.musicpd.org/download/mpc/" |
773b2792 PW |
173 | (car (string-split version #\.)) |
174 | "/mpc-" version ".tar.xz")) | |
175 | (sha256 | |
176 | (base32 | |
021469bc | 177 | "1kkzhrypkp0v6xv4d6db415pd0h6jqki29kfpsnfkvrhhh55pz35")))) |
62d14d24 | 178 | (build-system meson-build-system) |
773b2792 PW |
179 | (inputs `(("libmpdclient" ,libmpdclient))) |
180 | (native-inputs `(("pkg-config" ,pkg-config))) | |
181 | (synopsis "Music Player Daemon client") | |
182 | (description "MPC is a minimalist command line interface to MPD, the music | |
183 | player daemon.") | |
e9aa6b5e | 184 | (home-page "https://www.musicpd.org/clients/mpc/") |
773b2792 PW |
185 | (license license:gpl2))) |
186 | ||
654b27e5 | 187 | (define-public ncmpc |
4d01bd3c DT |
188 | (package |
189 | (name "ncmpc") | |
cd220e60 | 190 | (version "0.32") |
4d01bd3c DT |
191 | (source (origin |
192 | (method url-fetch) | |
193 | (uri | |
194 | (string-append "http://musicpd.org/download/ncmpc/" | |
195 | (car (string-split version #\.)) | |
3efee6a4 | 196 | "/ncmpc-" version ".tar.xz")) |
4d01bd3c DT |
197 | (sha256 |
198 | (base32 | |
cd220e60 | 199 | "1b01q1pcaw5yyhvmlffc3h0r3w8qy7rhn55a7xj4qkcfqvs8ap08")))) |
fbde7b08 TGR |
200 | (build-system meson-build-system) |
201 | (arguments | |
202 | `(#:configure-flags | |
cd220e60 LF |
203 | ;; Otherwise, they are installed incorrectly, in |
204 | ;; '$out/share/man/man/man1'. | |
205 | (list (string-append "-Dmandir=" (assoc-ref %outputs "out") | |
206 | "/share")) | |
7c0ed27a TGR |
207 | #:phases |
208 | (modify-phases %standard-phases | |
209 | (add-before 'configure 'expand-C++-include-path | |
210 | ;; Make <gcc>/include/c++/ext/string_conversions.h find <stdlib.h>. | |
211 | (lambda* (#:key inputs #:allow-other-keys) | |
212 | (let* ((path "CPLUS_INCLUDE_PATH") | |
213 | (gcc (assoc-ref inputs "gcc")) | |
214 | (c++ (string-append gcc "/include/c++"))) | |
215 | (setenv path (string-append c++ ":" (getenv path))) | |
216 | #t)))))) | |
217 | (inputs `(("gcc", gcc-8) ; for its C++14 support | |
cd220e60 LF |
218 | ("boost" ,boost) |
219 | ("pcre" ,pcre) | |
4d01bd3c DT |
220 | ("libmpdclient" ,libmpdclient) |
221 | ("ncurses" ,ncurses))) | |
fbde7b08 | 222 | (native-inputs `(("gettext" ,gettext-minimal) ; for xgettext |
cd220e60 LF |
223 | ("pkg-config" ,pkg-config) |
224 | ("python-sphinx" ,python-sphinx))) | |
9e771e3b | 225 | (synopsis "Curses Music Player Daemon client") |
4d01bd3c DT |
226 | (description "ncmpc is a fully featured MPD client, which runs in a |
227 | terminal using ncurses.") | |
e9aa6b5e | 228 | (home-page "https://www.musicpd.org/clients/ncmpc/") |
4d01bd3c | 229 | (license license:gpl2))) |
009c5b5c | 230 | |
654b27e5 | 231 | (define-public ncmpcpp |
009c5b5c CS |
232 | (package |
233 | (name "ncmpcpp") | |
93cbcc26 | 234 | (version "0.8.2") |
009c5b5c CS |
235 | (source (origin |
236 | (method url-fetch) | |
237 | (uri | |
a708fea4 | 238 | (string-append "https://ncmpcpp.rybczak.net/stable/ncmpcpp-" |
009c5b5c CS |
239 | version ".tar.bz2")) |
240 | (sha256 | |
241 | (base32 | |
93cbcc26 | 242 | "0m0mjb049sl62vx13h9waavysa30mk0rphacksnvf94n13la62v5")))) |
009c5b5c CS |
243 | (build-system gnu-build-system) |
244 | (inputs `(("libmpdclient" ,libmpdclient) | |
e42dc624 PW |
245 | ("boost" ,boost) |
246 | ("readline" ,readline) | |
a22722c1 | 247 | ("ncurses" ,ncurses) |
a4c7c57c | 248 | ("taglib" ,taglib) |
a708fea4 LF |
249 | ("icu4c" ,icu4c) |
250 | ("curl" ,curl))) | |
e42dc624 | 251 | (native-inputs |
c7794307 | 252 | `(("pkg-config" ,pkg-config))) |
e42dc624 PW |
253 | (arguments |
254 | '(#:configure-flags | |
c7794307 | 255 | '("BOOST_LIB_SUFFIX=" "--with-taglib"))) |
009c5b5c CS |
256 | (synopsis "Featureful ncurses based MPD client inspired by ncmpc") |
257 | (description "Ncmpcpp is an mpd client with a UI very similar to ncmpc, | |
258 | but it provides new useful features such as support for regular expressions | |
259 | for library searches, extended song format, items filtering, the ability to | |
8f65585b | 260 | sort playlists, and a local file system browser.") |
a708fea4 | 261 | (home-page "https://ncmpcpp.rybczak.net/") |
009c5b5c | 262 | (license license:gpl2+))) |
927ff2c3 DT |
263 | |
264 | (define-public mpdscribble | |
265 | (package | |
266 | (name "mpdscribble") | |
267 | (version "0.22") | |
268 | (source (origin | |
269 | (method url-fetch) | |
270 | (uri (string-append "http://www.musicpd.org/download/mpdscribble/" | |
271 | version "/mpdscribble-" version ".tar.gz")) | |
272 | (sha256 | |
273 | (base32 | |
274 | "0f0ybx380x2z2g1qvdndpvcrhkrgsfqckhz3ryydq2w3pl12v27z")))) | |
275 | (build-system gnu-build-system) | |
276 | (inputs `(("libmpdclient" ,libmpdclient) | |
277 | ("curl" ,curl) | |
278 | ("glib" ,glib))) | |
279 | (native-inputs `(("pkg-config" ,pkg-config))) | |
280 | (synopsis "MPD client for track scrobbling") | |
281 | (description "mpdscribble is a Music Player Daemon client which submits | |
282 | information about tracks being played to a scrobbler, such as Libre.FM.") | |
fc2847b1 | 283 | (home-page "https://www.musicpd.org/clients/mpdscribble/") |
927ff2c3 | 284 | (license license:gpl2+))) |
efe0b143 LF |
285 | |
286 | (define-public python-mpd2 | |
287 | (package | |
288 | (name "python-mpd2") | |
289 | (version "0.5.5") | |
290 | (source (origin | |
291 | (method url-fetch) | |
292 | (uri (pypi-uri "python-mpd2" version)) | |
293 | (sha256 | |
294 | (base32 | |
295 | "0laypd7h1j14b4vrmiayqlzdsh2j5hc3zv4l0fqvbrbw9y6763ii")))) | |
296 | (build-system python-build-system) | |
297 | (arguments | |
298 | '(#:phases | |
299 | (modify-phases %standard-phases | |
300 | (replace 'check | |
e8e3c357 | 301 | (lambda _ (invoke "python" "mpd_test.py")))))) |
efe0b143 LF |
302 | (native-inputs `(("python-mock" ,python-mock))) |
303 | (home-page "https://github.com/Mic92/python-mpd2") | |
304 | (synopsis "Python MPD client library") | |
305 | (description "Python-mpd2 is a Python library which provides a client | |
306 | interface for the Music Player Daemon.") | |
5c31f4aa | 307 | (license license:lgpl3+))) |
efe0b143 LF |
308 | |
309 | (define-public python2-mpd2 | |
5c31f4aa | 310 | (package-with-python2 python-mpd2)) |
6c86cef5 CB |
311 | |
312 | (define-public sonata | |
313 | (package | |
314 | (name "sonata") | |
315 | (version "1.7b1") | |
316 | (source (origin | |
317 | (method url-fetch) | |
318 | (uri | |
319 | (string-append "https://github.com/multani/sonata/archive/v" | |
320 | version ".tar.gz")) | |
321 | (file-name (string-append name "-" version ".tar.gz")) | |
322 | (sha256 | |
323 | (base32 | |
324 | "07gq2nxqwxs0qyxjbay7k5j25zd386bn7wdr2dl1gk53diwnn7s0")))) | |
325 | (build-system python-build-system) | |
326 | (arguments | |
327 | `(#:modules ((guix build gnu-build-system) | |
328 | (guix build python-build-system) | |
329 | ((guix build glib-or-gtk-build-system) #:prefix glib-or-gtk:) | |
330 | (guix build utils)) | |
331 | #:imported-modules (,@%gnu-build-system-modules | |
332 | (guix build python-build-system) | |
333 | (guix build glib-or-gtk-build-system)) | |
334 | #:phases | |
335 | (modify-phases %standard-phases | |
336 | (add-after 'install 'glib-or-gtk-wrap | |
337 | (assoc-ref glib-or-gtk:%standard-phases 'glib-or-gtk-wrap)) | |
338 | (add-after 'install 'wrap-sonata | |
339 | (lambda* (#:key outputs #:allow-other-keys) | |
340 | (let ((out (assoc-ref outputs "out")) | |
341 | (gi-typelib-path (getenv "GI_TYPELIB_PATH"))) | |
342 | (wrap-program (string-append out "/bin/sonata") | |
343 | `("GI_TYPELIB_PATH" ":" prefix (,gi-typelib-path)))) | |
344 | #t))))) | |
345 | (native-inputs | |
7c90d0f4 | 346 | `(("gettext" ,gettext-minimal))) |
6c86cef5 CB |
347 | (inputs |
348 | `(("python-mpd2" ,python-mpd2) | |
349 | ("gtk+" ,gtk+) | |
350 | ("gsettings-desktop-schemas" ,gsettings-desktop-schemas) | |
351 | ("gobject-introspection" ,gobject-introspection) | |
352 | ("adwaita-icon-theme" ,adwaita-icon-theme) | |
353 | ("python-pygobject" ,python-pygobject))) | |
354 | (synopsis "Elegant client for the Music Player Daemon") | |
355 | (description "Sonata is an elegant graphical client for the Music Player | |
356 | Daemon (MPD). It supports playlists, multiple profiles (connecting to different | |
357 | MPD servers, search and multimedia key support.") | |
340978d7 | 358 | (home-page "https://www.nongnu.org/sonata/") |
6c86cef5 | 359 | (license license:gpl3+))) |