.spec cleanup

track library soname
use %%license, %%make_build, %%make_install
drop deprecated Group:, %%defattr tags
-devel: rely solely on pkgconfig auto deps
-devel: tigten dep using %%{?_isa}
This commit is contained in:
Rex Dieter 2018-04-29 08:05:52 -05:00
parent e72b474d97
commit 00667b06d8

View File

@ -1,9 +1,8 @@
Name: libshout Name: libshout
Version: 2.2.2 Version: 2.2.2
Release: 18%{?dist} Release: 19%{?dist}
Summary: Icecast source streaming library Summary: Icecast source streaming library
Group: System Environment/Libraries
License: LGPLv2+ License: LGPLv2+
URL: http://www.icecast.org/ URL: http://www.icecast.org/
Source: http://downloads.us.xiph.org/releases/libshout/libshout-%{version}.tar.gz Source: http://downloads.us.xiph.org/releases/libshout/libshout-%{version}.tar.gz
@ -12,10 +11,9 @@ Patch0: libshout-2.2.2-fix_speex.patch
BuildRequires: libogg-devel BuildRequires: libogg-devel
BuildRequires: libvorbis-devel BuildRequires: libvorbis-devel
BuildRequires: libtheora-devel BuildRequires: libtheora-devel
BuildRequires: pkgconfig
BuildRequires: speex-devel BuildRequires: speex-devel
%description %description
libshout is a library for communicating with and sending data to an libshout is a library for communicating with and sending data to an
icecast server. It handles the socket connection, the timing of the icecast server. It handles the socket connection, the timing of the
@ -24,12 +22,7 @@ data, and prevents most bad data from getting to the icecast server.
%package devel %package devel
Summary: static libraries and header files for %{name} development. Summary: static libraries and header files for %{name} development.
Group: Development/Libraries Group: Development/Libraries
Requires: %{name} = %{version}-%{release} Requires: %{name}%{?_isa} = %{version}-%{release}
Requires: libogg-devel
Requires: libvorbis-devel
Requires: libtheora-devel
Requires: speex-devel
%description devel %description devel
The libshout-devel package contains the header files needed for developing The libshout-devel package contains the header files needed for developing
@ -41,41 +34,40 @@ you want to develop applications using libshout.
%patch0 -p1 -b .fix_speex %patch0 -p1 -b .fix_speex
%build %build
%configure --disable-static %configure \
--disable-silent-rules \
--disable-static
# clean unused-direct-shlib-dependencies # clean unused-direct-shlib-dependencies
sed -i -e 's! -shared ! -Wl,--as-needed\0!g' libtool sed -i -e 's! -shared ! -Wl,--as-needed\0!g' libtool
make %{?_smp_mflags} %make_build
%install %install
rm -rf $RPM_BUILD_ROOT %make_install
make DESTDIR="$RPM_BUILD_ROOT" INSTALL="install -p " install
find $RPM_BUILD_ROOT -type f -name "*.la" -exec rm -f {} ';' find $RPM_BUILD_ROOT -type f -name "*.la" -exec rm -f {} ';'
rm -rf $RPM_BUILD_ROOT%{_docdir} rm -rf $RPM_BUILD_ROOT%{_docdir}
%post -p /sbin/ldconfig %ldconfig_scriptlets
%postun -p /sbin/ldconfig
%files %files
%defattr(-,root,root,-) %doc NEWS README
%doc COPYING NEWS README %license COPYING
%{_libdir}/libshout.so.* %{_libdir}/libshout.so.3*
%files devel %files devel
%defattr(-,root,root,-)
%doc examples/*.c doc/*.xml doc/*.xsl %doc examples/*.c doc/*.xml doc/*.xsl
%{_libdir}/libshout.so %{_libdir}/libshout.so
%{_libdir}/pkgconfig/shout.pc %{_libdir}/pkgconfig/shout.pc
%dir %{_includedir}/shout/ %{_includedir}/shout/
%{_includedir}/shout/shout.h
%{_datadir}/aclocal/shout.m4 %{_datadir}/aclocal/shout.m4
%changelog %changelog
* Sun Apr 29 2018 Rex Dieter <rdieter@fedoraproject.org> - 2.2.2-19
- .spec cleanup
* Wed Feb 07 2018 Fedora Release Engineering <releng@fedoraproject.org> - 2.2.2-18 * Wed Feb 07 2018 Fedora Release Engineering <releng@fedoraproject.org> - 2.2.2-18
- Rebuilt for https://fedoraproject.org/wiki/Fedora_28_Mass_Rebuild - Rebuilt for https://fedoraproject.org/wiki/Fedora_28_Mass_Rebuild