]> git.pld-linux.org Git - packages/mpd.git/blob - mpd.spec
- up to 0.16
[packages/mpd.git] / mpd.spec
1 # - add logrotate
2 #
3 # Conditional build:
4 %bcond_without  mod             # enable MOD support
5 %bcond_without  pulseaudio      # disable PulseAudio support
6 #
7 Summary:        Music Player Daemon
8 Summary(hu.UTF-8):      Music Player Daemon
9 Summary(pl.UTF-8):      Music Player Daemon - demon odtwarzający muzykę
10 Name:           mpd
11 Version:        0.16
12 Release:        0.1
13 License:        GPL v2+
14 Group:          Applications/Multimedia
15 Source0:        http://downloads.sourceforge.net/musicpd/%{name}-%{version}.tar.bz2
16 # Source0-md5:  3fc8ccc4488cbaadc1a10f415eada35f
17 Source1:        %{name}.conf
18 Source2:        %{name}.init
19 URL:            http://www.musicpd.org/
20 BuildRequires:  OpenAL-devel
21 BuildRequires:  alsa-lib-devel >= 0.9.0
22 BuildRequires:  audiofile-devel >= 0.1.7
23 BuildRequires:  avahi-glib-devel
24 BuildRequires:  bzip2-devel
25 BuildRequires:  curl-devel
26 BuildRequires:  doxygen
27 BuildRequires:  faad2-devel >= 2.6.1-5
28 BuildRequires:  ffmpeg-devel
29 BuildRequires:  flac-devel >= 1.1.0
30 BuildRequires:  fluidsynth-devel
31 BuildRequires:  glib2-devel >= 2.12
32 BuildRequires:  jack-audio-connection-kit-devel >= 0.4
33 BuildRequires:  lame-libs-devel
34 BuildRequires:  libao-devel >= 0.8.3
35 BuildRequires:  libcdio-devel
36 BuildRequires:  libcue-devel
37 BuildRequires:  libid3tag-devel
38 BuildRequires:  libmad-devel
39 %{?with_mod:BuildRequires:      libmikmod-devel >= 3.1.7}
40 BuildRequires:  libmms-devel
41 BuildRequires:  libmodplug-devel
42 BuildRequires:  libmpcdec-devel
43 BuildRequires:  libogg-devel
44 BuildRequires:  libsamplerate-devel >= 0.0.15
45 BuildRequires:  libshout-devel
46 BuildRequires:  libvorbis-devel
47 BuildRequires:  pkgconfig >= 1:0.9.0
48 %{?with_pulseaudio:BuildRequires:       pulseaudio-devel}
49 BuildRequires:  sqlite3-devel
50 BuildRequires:  twolame-devel
51 BuildRequires:  wavpack-devel
52 BuildRequires:  wildmidi-devel
53 BuildRequires:  xmlto
54 BuildRequires:  zlib-devel
55 BuildRequires:  zziplib-devel
56 Provides:       group(mpd)
57 Provides:       user(mpd)
58 BuildRoot:      %{tmpdir}/%{name}-%{version}-root-%(id -u -n)
59
60 %description
61 Music Player Daemon (MPD) allows remote access for playing music (MP3,
62 Ogg Vorbis, FLAC, AAC, Mod, and wave files) and managing playlists.
63 MPD is designed for integrating a computer into a stereo system that
64 provides control for music playback over a local network. It is also
65 makes a great desktop music player, especially if you are a console
66 junkie, like frontend options, or restart X often.
67
68 %description -l hu.UTF-8
69 Music Player Daemon (MPD)-vel lehetővé válik távoli zenelejátszás
70 (MP3, Ogg Vorbis, FLAC, AAC, Mod és wav fájlok) és lejátszási listák
71 menedzselése. Az MPD a számítógépben egy zenelejátszó, amelyet
72 irányíthatsz helyi hálózaton keresztül. Egyben egy zseniális desktop
73 zenelejátszó is, különösen a konzol-mániásoknak, vagy azoknak, akik
74 sűrűn indítják újra az X-et.
75
76 %description -l pl.UTF-8
77 Music Player Daemon (MPD) pozwala na zdalny dostęp do odtwarzania
78 muzyki (plików MP3, Ogg Vorbis, FLAC, AAC, Mod i wave) oraz
79 zarządzania playlistami. MPD jest zaprojektowany do integrowania
80 komputera w system stereo umożliwiający sterowanie odtwarzaniem muzyki
81 w sieci lokalnej. Służy także za dobry odtwarzacz muzyki dla
82 komputerów biurkowych, zwłaszcza dla miłośników konsoli, różnych opcji
83 frontendów albo często restartujących X.
84
85 %prep
86 %setup -q
87
88 %build
89 # ac_cv_* hacks to avoid unwanted linking
90 %configure \
91         ac_cv_lib_iconv_main=no \
92         ac_cv_lib_nsl_gethostbyname=no \
93         %{!?with_pulseaudio:--disable-pulse} \
94         %{?with_mod:--enable-mikmod} \
95         --disable-sidplay \
96         --enable-alsa \
97         --enable-ao \
98         --enable-audiofile \
99         --enable-bzip2 \
100         --enable-cue \
101         --enable-curl \
102         --enable-documentation \
103         --enable-ffmpeg \
104         --enable-fluidsynth \
105         --enable-httpd-output \
106         --enable-iso9660 \
107         --enable-jack \
108         --enable-lame-encoder \
109         --enable-lastfm \
110         --enable-lsr \
111         --enable-mad \
112         --enable-mms \
113         --enable-modplug \
114         --enable-mvp \
115         --enable-openal \
116         --enable-pipe-output \
117         --enable-recorder-output \
118         --enable-shout \
119         --enable-sqlite \
120         --enable-twolame-encoder \
121         --enable-vorbis-encoder \
122         --enable-wave-encoder \
123         --enable-wavpack \
124         --enable-wildmidi \
125         --enable-zzip \
126         --with-zeroconf=avahi \
127         --without-tremor
128 %{__make}
129
130 %install
131 rm -rf $RPM_BUILD_ROOT
132 install -d $RPM_BUILD_ROOT{%{_sysconfdir},/etc/rc.d/init.d} \
133         $RPM_BUILD_ROOT{/var/lib/mpd/playlists,/var/log/mpd,/var/run/mpd}
134
135 %{__make} install \
136         DESTDIR=$RPM_BUILD_ROOT
137
138 install %{SOURCE1} $RPM_BUILD_ROOT%{_sysconfdir}
139 install %{SOURCE2} $RPM_BUILD_ROOT/etc/rc.d/init.d/mpd
140
141 touch $RPM_BUILD_ROOT/var/lib/mpd/mpd.db
142 touch $RPM_BUILD_ROOT/var/lib/mpd/mpdstate
143 touch $RPM_BUILD_ROOT/var/lib/mpd/sticker.sql
144 touch $RPM_BUILD_ROOT/var/log/mpd/mpd.log
145
146 rm -rf $RPM_BUILD_ROOT%{_docdir}/mpd
147
148 %clean
149 rm -rf $RPM_BUILD_ROOT
150
151 %pre
152 %groupadd -g 204 mpd
153 %useradd -u 204 -r -d /home/services/mpd -s /bin/false -c "Music Player Daemon (MPD) user" -g audio -G mpd mpd
154
155 %post
156 for f in mpd.log; do
157         if [ ! -f /var/log/%{name}/$f ]; then
158                 touch /var/log/%{name}/$f
159                 chown mpd:mpd /var/log/%{name}/$f
160                 chmod 644 /var/log/%{name}/$f
161         fi
162 done
163 /sbin/chkconfig --add mpd
164
165 %preun
166 if [ "$1" = "0" ]; then
167         %service mpd stop
168         /sbin/chkconfig --del mpd
169 fi
170
171 %postun
172 if [ "$1" = "0" ]; then
173         %userremove mpd
174         %groupremove mpd
175 fi
176
177 %files
178 %defattr(644,root,root,755)
179 %doc AUTHORS NEWS README doc/mpdconf.example UPGRADING doc/api doc/developer doc/protocol doc/user
180 %attr(755,root,root) %{_bindir}/*
181 %config(noreplace) %verify(not md5 mtime size) %{_sysconfdir}/mpd.conf
182 %attr(754,root,root) /etc/rc.d/init.d/mpd
183 %dir %attr(770,root,mpd) /var/lib/%{name}
184 %dir %attr(770,root,mpd) /var/lib/%{name}/playlists
185 %dir %attr(751,root,root) /var/log/%{name}
186 %dir %attr(770,root,mpd) /var/run/%{name}
187 %attr(644,mpd,mpd) %ghost /var/lib/%{name}/mpd.db
188 %attr(644,mpd,mpd) %ghost /var/lib/%{name}/mpdstate
189 %attr(644,mpd,mpd) %ghost /var/lib/%{name}/sticker.sql
190 %attr(644,mpd,mpd) %ghost /var/log/%{name}/mpd.log
191 %{_mandir}/man1/mpd.1*
192 %{_mandir}/man5/mpd.conf.5*
This page took 0.071862 seconds and 4 git commands to generate.