Name: ices0
Version: 0.4
Release: 1%{?dist}
Summary: Source streaming of audio for Icecast
Group: System Environment/Daemons
License: GPL
URL: http://www.icecast.org
Source0: http://downloads.us.xiph.org/releases/ices/ices-%{version}.tar.gz
Source1: ices0.init
Source2: ices0.logrotate
BuildRequires: libxml-devel
BuildRequires: perl, python, lame
BuildRequires: libshout-devel
BuildRequires: libvorbis-devel alsa-lib-devel
BuildRequires: pkgconfig
Requires: streaming-server
BuildRoot: %{_tmppath}/%{name}-%{version}-%{release}-root-%(%{__id_u} -n)
%description
IceS is a source client for a streaming server. The purpose of this client is
to provide an audio stream to a streaming server such that one or more
listeners can access the stream. With this layout, this source client can be
situated remotely from the icecast server.
This is the ices0 version, which supports mp3 streaming.
%prep
%setup -q -n ices-%{version}
perl -pi -e 's|0|1|' conf/*.dist
%build
%configure \
--with-python \
--with-perl \
--with-lame \
--with-vorbis \
--with-faad \
--with-flac
%{__make} %{?_smp_mflags}
%install
rm -rf %{buildroot}
install -d -m 755 %{buildroot}%{_bindir}
install -m 755 src/ices %{buildroot}%{_bindir}
install -d -m 755 %{buildroot}%{_sysconfdir}
install -m 644 conf/ices-playlist.xml %{buildroot}%{_sysconfdir}/ices.conf
install -d -m 755 %{buildroot}%{_initrddir}
install -m 755 %{SOURCE0} %{buildroot}%{_initrddir}/ices
install -d -m 755 %{buildroot}%{_sysconfdir}/logrotate.d
install -m 644 %{SOURCE1} %{buildroot}%{_sysconfdir}/logrotate.d/ices
install -d -m 755 %{buildroot}%{_var}/log/ices
%clean
rm -rf $RPM_BUILD_ROOT
%pre
/usr/sbin/useradd -c "IceS Shoutcast source" \
-s /sbin/nologin -r -d /dev/null ices 2> /dev/null || :
%post
if [ $1 = 1 ]; then
/sbin/chkconfig --add ices
fi
%preun
if [ $1 = 0 ]; then
/sbin/service ices stop > /dev/null 2>&1
/sbin/chkconfig --del ices
fi
%files
%defattr(-,root,root)
%doc AUTHORS COPYING README TODO doc/*.html doc/*.css conf/*.xml
%{_bindir}/ices
%config(noreplace) %{_sysconfdir}/ices.conf
%config(noreplace) %{_sysconfdir}/logrotate.d/ices
%config(noreplace) %{_initrddir}/ices
%attr(-,ices,ices) %{_var}/log/ices
%changelog
* Tue Mar 28 2006 Andreas Thienemann 0.4-1
- Spec for 0.4, based on the ices 2.x spec.