Spec clean up

This commit is contained in:
Josef Ridky 2018-02-14 14:31:26 +01:00
parent a55aca9dea
commit b5a666da25

View File

@ -3,7 +3,7 @@
# concurrency-stress-test: https://bugzilla.gnome.org/show_bug.cgi?id=673419
%global skip_checks concurrency-stress-test
%if ! 0%{?fedora}%{?rhel} || 0%{?fedora} >= 20 || 0%{?rhel} >= 8
%if ! 0%{?fedora}%{?rhel} || 0%{?fedora} >= 20 || 0%{?rhel} > 7
%global develdocdir %{_docdir}/%{name}-devel/html
%else
%global develdocdir %{_docdir}/%{name}-devel-%{version}/html
@ -23,11 +23,11 @@ Release: 2%{?dist}
# The gggl codes contained in this package are under the GPL, with exceptions allowing their use under libraries covered under the LGPL
License: LGPLv3+ and GPLv3+
Group: System Environment/Libraries
URL: http://www.gegl.org/babl/
Source0: https://download.gimp.org/pub/babl/%{apiver}/%{name}-%{version}.tar.bz2
BuildRequires: librsvg2
BuildRequires: automake, autoconf
%description
Babl is a dynamic, any to any, pixel format conversion library. It
@ -37,10 +37,9 @@ facilitates creation of new and uncommon ones.
%package devel
Summary: Headers for developing programs that will use %{name}
Group: Development/Libraries
Requires: %{name}%{?_isa} = %{version}-%{release}
Requires: pkgconfig
%if ! (0%{?fedora} >= 22 || 0%{?rhel} >= 8)
%if ! (0%{?fedora} >= 22 || 0%{?rhel} > 7)
# Split off devel docs from 0.1.2-2 on
Obsoletes: %{name}-devel < 0.1.2-2%{?dist}
Conflicts: %{name}-devel < 0.1.2-2%{?dist}
@ -52,7 +51,6 @@ developing with %{name}.
%package devel-docs
Summary: Documentation for developing programs that will use %{name}
Group: Documentation
BuildArch: noarch
Requires: %{name}-devel = %{version}-%{release}
# Split off devel docs from 0.1.2-2 on
@ -63,7 +61,7 @@ Conflicts: %{name}-devel < 0.1.2-2%{?dist}
This package contains documentation needed for developing with %{name}.
%prep
%setup -q
%autosetup -p1
%build
# use PIC/PIE because babl is likely to deal with data coming from untrusted
@ -75,7 +73,6 @@ LDFLAGS="-pie"
make V=1 %{?_smp_mflags}
%install
rm -rf %{buildroot}
make DESTDIR=%{buildroot} install INSTALL='install -p'
mkdir -p "%{buildroot}/%{develdocdir}"
@ -100,27 +97,25 @@ popd
%endif
make check
%post -p /sbin/ldconfig
%postun -p /sbin/ldconfig
%ldconfig_scriptlets
%files
%defattr(-, root, root, -)
%doc AUTHORS COPYING README NEWS
%{_libdir}/*.so.*
%{_libdir}/babl-%{apiver}/
%files devel
%defattr(-, root, root, -)
%{_includedir}/babl-%{apiver}/
%{_libdir}/*.so
%{_libdir}/pkgconfig/%{name}.pc
%files devel-docs
%defattr(-, root, root, -)
%doc %{develdocdir}
%changelog
* Wed Feb 14 2018 Josef Ridky <jridky@redhat.com> - 0.1.42-3
- cleanup spec file (remove Group tag, apply new scriptlets)
* Wed Feb 07 2018 Fedora Release Engineering <releng@fedoraproject.org> - 0.1.42-2
- Rebuilt for https://fedoraproject.org/wiki/Fedora_28_Mass_Rebuild