Name: mpd Version: 0.11.5 Release: 1 Summary: Music Player Daemon Group: Applications/Multimedia License: GPL URL: http://www.musicpd.org/ Source0: http://mercury.chem.pitt.edu/~shank/%{name}-%{version}.tar.gz Source1: mpd.init Source2: mpd.conf Source3: mpd.logrotate BuildRoot: %{_tmppath}/%{name}-%{version}-%{release}-root-%(%{__id_u} -n) BuildRequires: libao-devel libogg-devel libvorbis-devel flac-devel mikmod-devel audiofile-devel Requires: logrotate %description Music Player Daemon (MPD) allows remote access for playing music (MP3, Ogg Vorbis, FLAC, AAC, Mod, and wave files) and managing playlists. MPD is designed for integrating a computer into a stereo system that provides control for music playback over a local network. It is also makes a great desktop music player, especially if you are a console junkie, like frontend options, or restart X often. Packager's note: this package may be build without mp3 support due to the Fedora restrictions. To add support for MP3 format, just recompile it on a host which has lame-devel package installed. %prep %setup -q %build %configure make %{?_smp_mflags} %install rm -rf $RPM_BUILD_ROOT make install DESTDIR=$RPM_BUILD_ROOT mkdir -p $RPM_BUILD_ROOT/etc/rc.d/init.d $RPM_BUILD_ROOT/etc/logrotate.d \ $RPM_BUILD_ROOT/var/lib/mpd $RPM_BUILD_ROOT/var/log/mpd \ $RPM_BUILD_ROOT/var/lib/mpd/playlists $RPM_BUILD_ROOT/var/lib/mpd/music install -m 755 %{SOURCE1} $RPM_BUILD_ROOT/etc/rc.d/init.d/mpd install -m 644 %{SOURCE2} $RPM_BUILD_ROOT/etc/mpd.conf install -m 644 %{SOURCE3} $RPM_BUILD_ROOT/etc/logrotate.d/mpd # We will install this ourselves using the %doc directive rm -rf "$RPM_BUILD_ROOT"/usr/share/doc/mpd %clean rm -rf $RPM_BUILD_ROOT %files %defattr(-,root,root,-) %doc doc/COMMANDS doc/mpdconf.example README UPGRADING TODO AUTHORS %{_mandir}/man1/mpd.1.gz /usr/bin/mpd %config(noreplace) /etc/mpd.conf /etc/rc.d/init.d/mpd %config /etc/logrotate.d/mpd %attr(2775,mpd,mpd) /var/lib/mpd %attr(2775,mpd,mpd) /var/lib/mpd/music %attr(2775,mpd,mpd) /var/lib/mpd/playlists %attr(0755,mpd,mpd) /var/log/mpd %pre # Add the mpd user /usr/sbin/useradd -c 'Music Player Daemon' -s /sbin/nologin -r \ -d /var/lib/mpd mpd 2>/dev/null || : %post /sbin/chkconfig --add mpd if [ "$1" -ge 1 ]; then service mpd condrestart > /dev/null 2>&1 fi %preun if [ "$1" -eq 0 ]; then service mpd stop >/dev/null 2>&1 || : /sbin/chkconfig --del mpd /usr/sbin/userdel mpd >/dev/null 2>&1 || : /usr/sbin/groupdel mpd >/dev/null 2>&1 || : fi %changelog * Thu Oct 21 2004 Jan "Yenya" Kasprzak 0.11.5-1 - initial build