Modernize the spec file

This commit is contained in:
Kalev Lember 2011-07-29 04:51:13 +03:00
parent 3f115e9a94
commit 06d96df649

View File

@ -9,7 +9,6 @@ URL: http://www.cairographics.org
License: LGPLv2+ License: LGPLv2+
Group: System Environment/Libraries Group: System Environment/Libraries
Source: http://www.cairographics.org/releases/%{name}-%{version}.tar.gz Source: http://www.cairographics.org/releases/%{name}-%{version}.tar.gz
BuildRoot: %{_tmppath}/%{name}-%{version}-%{release}-root-%(%{__id_u} -n)
BuildRequires: cairo-devel >= %{cairover} BuildRequires: cairo-devel >= %{cairover}
BuildRequires: pkgconfig BuildRequires: pkgconfig
BuildRequires: libsigc++20-devel BuildRequires: libsigc++20-devel
@ -24,7 +23,6 @@ Summary: Headers for developing programs that will use %{name}
Group: Development/Libraries Group: Development/Libraries
Requires: %{name} = %{version}-%{release} Requires: %{name} = %{version}-%{release}
Requires: cairo-devel >= %{cairover} Requires: cairo-devel >= %{cairover}
Requires: pkgconfig
Requires: libsigc++20-devel Requires: libsigc++20-devel
%description devel %description devel
@ -35,13 +33,10 @@ Standard Template Library where it makes sense.
This package contains the libraries and header files needed for This package contains the libraries and header files needed for
developing %{name} applications. developing %{name} applications.
%package doc %package doc
Summary: Developer's documentation for the cairomm library Summary: Developer's documentation for the cairomm library
Group: Documentation Group: Documentation
%if 0%{?fedora} > 9 || 0%{?rhel} > 5 BuildArch: noarch
BuildArch: noarch
%endif
BuildRequires: doxygen graphviz
Requires: %{name} = %{version}-%{release} Requires: %{name} = %{version}-%{release}
Requires: libsigc++20-doc Requires: libsigc++20-doc
@ -59,29 +54,22 @@ hierarchy and can be found at /usr/share/doc/cairomm-1.0
%setup -q %setup -q
%build %build
%configure --enable-static=no %configure --disable-static
%{__make} %{?_smp_mflags} make %{?_smp_mflags}
%install %install
%{__rm} -rf $RPM_BUILD_ROOT make install DESTDIR=$RPM_BUILD_ROOT INSTALL="install -p"
%{__make} install DESTDIR=$RPM_BUILD_ROOT INSTALL="%{__install} -p"
find $RPM_BUILD_ROOT -type f -name "*.la" -exec rm -f {} ';' find $RPM_BUILD_ROOT -type f -name "*.la" -exec rm -f {} ';'
%clean
%{__rm} -rf $RPM_BUILD_ROOT
%post -p /sbin/ldconfig %post -p /sbin/ldconfig
%postun -p /sbin/ldconfig %postun -p /sbin/ldconfig
%files %files
%defattr(-,root,root,-)
%doc AUTHORS COPYING README NEWS %doc AUTHORS COPYING README NEWS
%{_libdir}/lib*.so.* %{_libdir}/lib*.so.*
%files devel %files devel
%defattr(-,root,root,-)
%doc ChangeLog %doc ChangeLog
%{_includedir}/%{name}-%{apiver} %{_includedir}/%{name}-%{apiver}
%{_libdir}/*.so %{_libdir}/*.so
@ -89,7 +77,6 @@ find $RPM_BUILD_ROOT -type f -name "*.la" -exec rm -f {} ';'
%{_libdir}/%{name}-%{apiver} %{_libdir}/%{name}-%{apiver}
%files doc %files doc
%defattr(-,root,root,-)
%doc %{_datadir}/doc/%{name}-%{apiver}/ %doc %{_datadir}/doc/%{name}-%{apiver}/
%doc %{_datadir}/devhelp/books/%{name}-%{apiver}/ %doc %{_datadir}/devhelp/books/%{name}-%{apiver}/
@ -97,6 +84,7 @@ find $RPM_BUILD_ROOT -type f -name "*.la" -exec rm -f {} ';'
* Fri Jul 29 2011 Kalev Lember <kalevlember@gmail.com> - 1.10.0-1 * Fri Jul 29 2011 Kalev Lember <kalevlember@gmail.com> - 1.10.0-1
- Update to 1.10.0 - Update to 1.10.0
- Have the -doc subpackage depend on the base package - Have the -doc subpackage depend on the base package
- Modernize the spec file
* Mon Feb 21 2011 Haïkel Guémar <hguemar@fedoraproject.org> - 1.9.8-2 * Mon Feb 21 2011 Haïkel Guémar <hguemar@fedoraproject.org> - 1.9.8-2
- fix documentation location - fix documentation location