Spec file cleanup
Use https source URL Drop obsolete spec elements Use license macro Update libusbx-devel build dependency Drop ancient (F15) Obsoletes: Tighten file list
This commit is contained in:
parent
464e05e834
commit
477d8c3e85
46
libmtp.spec
46
libmtp.spec
@ -1,24 +1,19 @@
|
||||
# SPEC file for libmtp, primary target is the Fedora
|
||||
# RPM repository.
|
||||
|
||||
%{!?_pkgdocdir: %global _pkgdocdir %{_docdir}/%{name}-%{version}}
|
||||
|
||||
Name: libmtp
|
||||
Version: 1.1.13
|
||||
Release: 1%{?dist}
|
||||
Release: 2%{?dist}
|
||||
Summary: A software library for MTP media players
|
||||
URL: http://libmtp.sourceforge.net/
|
||||
|
||||
Group: System Environment/Libraries
|
||||
Source0: http://download.sourceforge.net/%{name}/%{name}-%{version}.tar.gz
|
||||
BuildRoot: %{_tmppath}/%{name}-%{version}-%{release}-root-%(%{__id_u} -n)
|
||||
Source0: https://download.sourceforge.net/%{name}/%{name}-%{version}.tar.gz
|
||||
License: LGPLv2+
|
||||
Requires: udev
|
||||
BuildRequires: libusb1-devel
|
||||
BuildRequires: libusbx-devel
|
||||
BuildRequires: doxygen
|
||||
BuildRequires: libgcrypt-devel
|
||||
BuildRequires: chrpath
|
||||
Obsoletes: libmtp-hal
|
||||
|
||||
%description
|
||||
This package provides a software library for communicating with MTP
|
||||
@ -27,7 +22,6 @@ players etc.
|
||||
|
||||
%package examples
|
||||
Summary: Example programs for libmtp
|
||||
Group: Applications/Multimedia
|
||||
Requires: %{name}%{?_isa} = %{version}-%{release}
|
||||
|
||||
%description examples
|
||||
@ -36,7 +30,6 @@ devices.
|
||||
|
||||
%package devel
|
||||
Summary: Development files for libmtp
|
||||
Group: System Environment/Libraries
|
||||
Requires: %{name}%{?_isa} = %{version}-%{release}
|
||||
Requires: pkgconfig
|
||||
Requires: libusb1-devel
|
||||
@ -52,11 +45,10 @@ library for MTP media players.
|
||||
%build
|
||||
%configure --disable-static \
|
||||
--with-udev-rules=69-libmtp.rules
|
||||
make %{?_smp_mflags}
|
||||
%make_build
|
||||
|
||||
%install
|
||||
rm -rf $RPM_BUILD_ROOT
|
||||
make DESTDIR=$RPM_BUILD_ROOT install
|
||||
%make_install
|
||||
# Remove libtool archive remnant
|
||||
rm -f $RPM_BUILD_ROOT%{_libdir}/libmtp.la
|
||||
# Replace links with relative links
|
||||
@ -77,7 +69,7 @@ iconv -f iso-8859-1 -t utf-8 -o COPYING.utf8 COPYING
|
||||
touch -r COPYING COPYING.utf8; mv -f COPYING.utf8 COPYING
|
||||
# Copy documentation to a good place
|
||||
mkdir -p -m 755 $RPM_BUILD_ROOT%{_pkgdocdir}
|
||||
install -p -m 644 AUTHORS ChangeLog COPYING INSTALL README TODO \
|
||||
install -p -m 644 AUTHORS ChangeLog README TODO \
|
||||
$RPM_BUILD_ROOT%{_pkgdocdir}
|
||||
# Move some autogenerated documentation where we want it
|
||||
mv $RPM_BUILD_ROOT/usr/share/doc/%{name}-%{version}/html \
|
||||
@ -89,34 +81,36 @@ touch -r configure.ac \
|
||||
# Get rid of -rpath
|
||||
chrpath --delete $RPM_BUILD_ROOT{%{_bindir},/usr/lib/udev}/mtp*
|
||||
|
||||
%clean
|
||||
rm -rf $RPM_BUILD_ROOT
|
||||
|
||||
%post -p /sbin/ldconfig
|
||||
%postun -p /sbin/ldconfig
|
||||
|
||||
%files
|
||||
%defattr(-, root,root,-)
|
||||
%dir %{_pkgdocdir}
|
||||
%{_pkgdocdir}/COPYING
|
||||
%license COPYING
|
||||
%{_libdir}/libmtp.so.9*
|
||||
/usr/lib/udev/rules.d/*
|
||||
/usr/lib/udev/hwdb.d/*
|
||||
/usr/lib/udev/rules.d/69-libmtp.rules
|
||||
/usr/lib/udev/hwdb.d/69-libmtp.hwdb
|
||||
/usr/lib/udev/mtp-probe
|
||||
|
||||
%files examples
|
||||
%defattr(-,root,root,-)
|
||||
%{_bindir}/*
|
||||
%{_bindir}/mtp-*
|
||||
|
||||
%files devel
|
||||
%defattr(-,root,root,-)
|
||||
%{_libdir}/libmtp.so
|
||||
%{_pkgdocdir}/*
|
||||
%exclude %{_pkgdocdir}/COPYING
|
||||
%{_includedir}/*.h
|
||||
%{_pkgdocdir}
|
||||
%{_includedir}/libmtp.h
|
||||
%{_libdir}/pkgconfig/libmtp.pc
|
||||
|
||||
%changelog
|
||||
* Mon Jul 10 2017 Dominik Mierzejewski <dominik@greysector.net> - 1.1.13-2
|
||||
- Use https source URL
|
||||
- Drop obsolete spec elements
|
||||
- Use license macro
|
||||
- Update libusbx-devel build dependency
|
||||
- Drop ancient (F15) Obsoletes:
|
||||
- Tighten file list
|
||||
|
||||
* Tue Jun 27 2017 Robert Scheck <robert@fedoraproject.org> - 1.1.13-1
|
||||
- Update to 1.1.13 (#1412546, #1465038, #1465040)
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user