All pastes #985986 Raw Edit

Something

public text v1 · immutable
·published 2008-04-15 13:23 UTC
rendered paste body
%define plugins jack portaudio sdl

Name:           mpg123
Version:        1.2.1
Release:        1%{?dist}
Summary:        A fast console MPEG Audio Player

Group:          Applications/Multimedia
License:        GPLv2+ and LGPLv2+
URL:            http://www.mpg123.de
Source0:        http://www.mpg123.de/download/mpg123-%{version}.tar.bz2
BuildRoot:      %{_tmppath}/%{name}-%{version}-%{release}-root-%(%{__id_u} -n)

BuildRequires: alsa-lib-devel libtool-ltdl-devel
%{!?_with_arts:BuildRequires: arts-devel}
%{!?_with_esd:BuildRequires: esound-devel}
%{!?_without_jack:BuildRequires: jack-audio-connection-kit-devel}
%{!?_with_nas:BuildRequires: nas-devel}
%{!?_without_oss:BuildRequires: alsa-oss-devel}
%{!?_without_portaudio:BuildRequires: portaudio-devel}
%{!?_without_pulse:BuildRequires: pulseaudio-libs-devel}
%{!?_without_sdl:BuildRequires: SDL-devel}


%description
mpg123 is a real time MPEG Audio Player for Layer 1,2 and Layer3 
(MPEG 2.0 with Layer1/2 not heavily tested).
Among others, it is working with Linux, FreeBSD, SunOS4.1.3, 
Solaris 2.5, HPUX 9.x and SGI Irix.
It is a free software licensed under LGPL (the officially released sources, 
but some files in subversion repository may differ).


%package        devel
Summary:        Development files for %{name}
Group:          Development/Libraries
Requires:       %{name} = %{version}-%{release}

%description    devel
The %{name}-devel package contains libraries and header files for
developing applications that use %{name}.

%package        plugin-jack
Summary:        Development files for %{name}
Group:          Applications/Multimedia
Requires:       %{name} = %{version}-%{release}

%description    plugin-jack
The %{name}-plugin-arts package contains the jack plugin for %{name}.

%package        plugin-portaudio
Summary:        Development files for %{name}
Group:          Applications/Multimedia
Requires:       %{name} = %{version}-%{release}

%description    plugin-portaudio
The %{name}-plugin-arts package contains the portaudio plugin for %{name}.

%package        plugin-sdl
Summary:        Development files for %{name}
Group:          Applications/Multimedia
Requires:       %{name} = %{version}-%{release}

%description    plugin-sdl
The %{name}-plugin-arts package contains the SDL plugin for %{name}.

%prep
%setup -q


%build
%configure --disable-static --with-default-audio=pulse

# Remove rpath from libtool
sed -i 's|^hardcode_libdir_flag_spec=.*|hardcode_libdir_flag_spec=""|g' libtool
sed -i 's|^runpath_var=LD_RUN_PATH|runpath_var=DIE_RPATH_DIE|g' libtool

make %{?_smp_mflags}


%install
rm -rf $RPM_BUILD_ROOT
make install DESTDIR=$RPM_BUILD_ROOT INSTALL="install -p"
find $RPM_BUILD_ROOT -name '*.la' -exec rm -f {} ';'


%clean
rm -rf $RPM_BUILD_ROOT


%post -p /sbin/ldconfig

%postun -p /sbin/ldconfig


%files
%defattr(-,root,root,-)
%doc ChangeLog COPYING NEWS README
# This part is GPLv2+
%{_bindir}/mpg123
# This part is LGPLv2+
%{_libdir}/*.so.*
%{_libdir}/mpg123/
%{_mandir}/man1/mpg123.1.*

%files devel
%defattr(-,root,root,-)
%{_includedir}/*.h
%{_libdir}/*.so
%{_libdir}/pkgconfig/libmpg123.pc

%changelog
* Tue Apr 15 2008 kwizart < kwizart at gmail.com > - 1.2.1-1
- Initial spec