gnu: Add 'version-prefix' and 'version-major+minor'; use them.
[jackhill/guix/guix.git] / gnu / packages / mpd.scm
1 ;;; GNU Guix --- Functional package management for GNU
2 ;;; Copyright © 2014 David Thompson <dthompson2@worcester.edu>
3 ;;; Copyright © 2014 Andreas Enge <andreas@enge.fr>
4 ;;; Copyright © 2014 Cyrill Schenkel <cyrill.schenkel@gmail.com>
5 ;;; Copyright © 2014 Ian Denhardt <ian@zenhack.net>
6 ;;;
7 ;;; This file is part of GNU Guix.
8 ;;;
9 ;;; GNU Guix is free software; you can redistribute it and/or modify it
10 ;;; under the terms of the GNU General Public License as published by
11 ;;; the Free Software Foundation; either version 3 of the License, or (at
12 ;;; your option) any later version.
13 ;;;
14 ;;; GNU Guix is distributed in the hope that it will be useful, but
15 ;;; WITHOUT ANY WARRANTY; without even the implied warranty of
16 ;;; MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
17 ;;; GNU General Public License for more details.
18 ;;;
19 ;;; You should have received a copy of the GNU General Public License
20 ;;; along with GNU Guix. If not, see <http://www.gnu.org/licenses/>.
21
22 (define-module (gnu packages mpd)
23 #:use-module (gnu packages)
24 #:use-module ((guix licenses) #:prefix license:)
25 #:use-module (guix packages)
26 #:use-module (guix download)
27 #:use-module (guix utils)
28 #:use-module (guix build-system gnu)
29 #:use-module (gnu packages avahi)
30 #:use-module (gnu packages compression)
31 #:use-module (gnu packages curl)
32 #:use-module (gnu packages doxygen)
33 #:use-module (gnu packages glib)
34 #:use-module (gnu packages linux)
35 #:use-module (gnu packages mp3)
36 #:use-module (gnu packages ncurses)
37 #:use-module (gnu packages pkg-config)
38 #:use-module (gnu packages pulseaudio)
39 #:use-module (gnu packages databases)
40 #:use-module (gnu packages video)
41 #:use-module (gnu packages xiph)
42 #:export (libmpdclient
43 mpd
44 ncmpc
45 ncmpcpp))
46
47 (define libmpdclient
48 (package
49 (name "libmpdclient")
50 (version "2.9")
51 (source (origin
52 (method url-fetch)
53 (uri
54 (string-append "http://musicpd.org/download/libmpdclient/"
55 (car (string-split version #\.))
56 "/libmpdclient-" version ".tar.gz"))
57 (sha256
58 (base32
59 "0csb9r3nlmbwpiryixjr5k33x3zqd61xjhwmlps3a6prck1n1xw2"))))
60 (build-system gnu-build-system)
61 (native-inputs `(("doxygen" ,doxygen)))
62 (synopsis "Music Player Daemon client library")
63 (description "A stable, documented, asynchronous API library for
64 interfacing MPD in the C, C++ & Objective C languages.")
65 (home-page "http://www.musicpd.org/libs/libmpdclient/")
66 (license license:bsd-3)))
67
68 (define mpd
69 (package
70 (name "mpd")
71 (version "0.18.8")
72 (source (origin
73 (method url-fetch)
74 (uri
75 (string-append "http://musicpd.org/download/mpd/"
76 (version-major+minor version)
77 "/mpd-" version ".tar.gz"))
78 (sha256
79 (base32
80 "1ryqh0xf76xv4mpwy1gjwy275ar4wmbzifa9ccjim9r7lk2hgp5v"))))
81 (build-system gnu-build-system)
82 (inputs `(("ao" ,ao)
83 ("alsa-lib" ,alsa-lib)
84 ("avahi" ,avahi)
85 ("curl" ,curl)
86 ("ffmpeg" ,ffmpeg)
87 ("flac" ,flac)
88 ("glib" ,glib)
89 ("lame" ,lame)
90 ("libid3tag" ,libid3tag)
91 ("libmad" ,libmad)
92 ("libmpdclient" ,libmpdclient)
93 ("libsamplerate" ,libsamplerate)
94 ("libsndfile" ,libsndfile)
95 ("libvorbis" ,libvorbis)
96 ("opus" ,opus)
97 ("pkg-config" ,pkg-config)
98 ("pulseaudio" ,pulseaudio)
99 ("sqlite" ,sqlite)
100 ("zlib" ,zlib)))
101 ;; Missing optional inputs:
102 ;; libyajl
103 ;; libcdio_paranoia
104 ;; libmms
105 ;; libadplug
106 ;; libaudiofile
107 ;; faad2
108 ;; fluidsynth
109 ;; libgme
110 ;; libshout
111 ;; libmpg123
112 ;; libmodplug
113 ;; libmpcdec
114 ;; libsidplay2
115 ;; libwavpack
116 ;; libwildmidi
117 ;; libtwolame
118 ;; libroar
119 ;; libjack
120 ;; OpenAL
121 (synopsis "Music Player Daemon")
122 (description "Music Player Daemon (MPD) is a flexible, powerful,
123 server-side application for playing music. Through plugins and libraries it
124 can play a variety of sound files while being controlled by its network
125 protocol.")
126 (home-page "http://www.musicpd.org/")
127 (license license:gpl2)))
128
129 (define ncmpc
130 (package
131 (name "ncmpc")
132 (version "0.21")
133 (source (origin
134 (method url-fetch)
135 (uri
136 (string-append "http://musicpd.org/download/ncmpc/"
137 (car (string-split version #\.))
138 "/ncmpc-" version ".tar.gz"))
139 (sha256
140 (base32
141 "1gpy6rr0awl6xgkswmr8rdvqfkrz83rmwk441c00a9d4z3zb1a16"))))
142 (build-system gnu-build-system)
143 (inputs `(("glib" ,glib)
144 ("libmpdclient" ,libmpdclient)
145 ("ncurses" ,ncurses)))
146 (native-inputs `(("pkg-config" ,pkg-config)))
147 (synopsis "Curses Music Player Daemon client")
148 (description "ncmpc is a fully featured MPD client, which runs in a
149 terminal using ncurses.")
150 (home-page "http://www.musicpd.org/clients/ncmpc/")
151 (license license:gpl2)))
152
153 (define ncmpcpp
154 (package
155 (name "ncmpcpp")
156 (version "0.5.10")
157 (source (origin
158 (method url-fetch)
159 (uri
160 (string-append "http://ncmpcpp.rybczak.net/stable/ncmpcpp-"
161 version ".tar.bz2"))
162 (sha256
163 (base32
164 "1a54g6dary1rirrny9fd0hpxpyyffypni3mpbdpvmjnrl9v56vgz"))))
165 (build-system gnu-build-system)
166 (inputs `(("libmpdclient" ,libmpdclient)
167 ("ncurses" ,ncurses)))
168 (native-inputs `(("pkg-config" ,pkg-config)))
169 (synopsis "Featureful ncurses based MPD client inspired by ncmpc")
170 (description "Ncmpcpp is an mpd client with a UI very similar to ncmpc,
171 but it provides new useful features such as support for regular expressions
172 for library searches, extended song format, items filtering, the ability to
173 sort playlists, and a local filesystem browser.")
174 (home-page "http://ncmpcpp.rybczak.net/")
175 (license license:gpl2+)))