babl/babl.spec

128 lines
3.4 KiB
RPMSpec
Raw Normal View History

2012-04-03 10:06:49 +00:00
# skip tests known to be problematic in a specific version
2018-11-09 23:00:20 +00:00
%global skip_checks_version 0.1.58
2018-05-21 13:24:45 +00:00
%ifarch ppc64 ppc64le
%global skip_checks %nil
%else
%ifarch s390x
%global skip_checks float-to-8bit
%else
%global skip_checks %nil
%endif
2018-05-17 13:54:53 +00:00
%endif
2018-02-14 13:31:26 +00:00
%if ! 0%{?fedora}%{?rhel} || 0%{?fedora} >= 20 || 0%{?rhel} > 7
%global develdocdir %{_docdir}/%{name}-devel/html
%else
%global develdocdir %{_docdir}/%{name}-devel-%{version}/html
%endif
2007-10-23 02:01:27 +00:00
Summary: A dynamic, any to any, pixel format conversion library
Name: babl
Version: 0.1.106
Release: %autorelease
2012-04-03 09:18:36 +00:00
# Compute some version related macros
# Ugly hack, you need to get your quoting backslashes/percent signs straight
%global major %(ver=%version; echo ${ver%%%%.*})
%global minor %(ver=%version; ver=${ver#%major.}; echo ${ver%%%%.*})
%global micro %(ver=%version; ver=${ver#%major.%minor.}; echo ${ver%%%%.*})
%global apiver %major.%minor
# The gggl codes contained in this package are under the GPL, with exceptions allowing their use under libraries covered under the LGPL
2023-05-02 09:34:23 +00:00
License: LGPL-3.0-or-later AND GPL-3.0-or-later
2023-03-07 10:41:52 +00:00
URL: https://www.gegl.org/babl/
Source0: https://download.gimp.org/pub/babl/%{apiver}/%{name}-%{version}.tar.xz
2017-10-17 16:07:57 +00:00
BuildRequires: gcc
2021-08-02 07:39:56 +00:00
BuildRequires: openssh-clients
BuildRequires: gobject-introspection-devel
2019-11-05 09:35:06 +00:00
BuildRequires: librsvg2-tools
2020-06-15 07:41:17 +00:00
BuildRequires: meson, vala
2019-02-09 22:35:33 +00:00
BuildRequires: pkgconfig(lcms2)
2007-10-23 02:01:27 +00:00
%description
Babl is a dynamic, any to any, pixel format conversion library. It
provides conversions between the myriad of buffer types images can be
stored in. Babl doesn't only help with existing pixel formats, but also
facilitates creation of new and uncommon ones.
%package devel
Summary: Headers for developing programs that will use %{name}
Requires: %{name}%{?_isa} = %{version}-%{release}
2007-10-23 02:01:27 +00:00
Requires: pkgconfig
2018-02-14 13:31:26 +00:00
%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}
%endif
2007-10-23 02:01:27 +00:00
%description devel
This package contains the libraries and header files needed for
developing with %{name}.
%package devel-docs
Summary: Documentation for developing programs that will use %{name}
BuildArch: noarch
Requires: %{name}-devel = %{version}-%{release}
# 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}
2010-06-14 12:44:54 +00:00
%description devel-docs
This package contains documentation needed for developing with %{name}.
2007-10-23 02:01:27 +00:00
%prep
2018-02-14 13:31:26 +00:00
%autosetup -p1
2007-10-23 02:01:27 +00:00
%build
%meson
%meson_build
2007-10-23 02:01:27 +00:00
%install
%meson_install
2007-10-23 02:01:27 +00:00
mkdir -p "%{buildroot}/%{develdocdir}"
2022-03-14 12:25:28 +00:00
cp -pr "%{_vpath_builddir}"/docs/* "%{buildroot}/%{develdocdir}"
rm -f "%{buildroot}/%{develdocdir}/index.html.tmp"
2007-10-23 02:01:27 +00:00
%check
2012-04-03 10:06:49 +00:00
# skip tests known to be problematic in a specific version
%if "%version" == "%skip_checks_version"
pushd tests
2012-04-03 10:06:49 +00:00
for problematic in %skip_checks; do
rm -f "$problematic"
cat << EOF > "$problematic"
#!/bin/sh
echo Skipping test "$problematic"
EOF
chmod +x "$problematic"
done
popd
%endif
%meson_test
2007-10-23 02:01:27 +00:00
2018-02-14 13:31:26 +00:00
%ldconfig_scriptlets
2007-10-23 02:01:27 +00:00
%files
2019-11-05 09:35:48 +00:00
%license docs/COPYING*
%doc AUTHORS NEWS
2023-03-07 10:41:52 +00:00
%{_bindir}/babl
%{_libdir}/libbabl-%{apiver}.so.0*
2012-04-03 09:18:36 +00:00
%{_libdir}/babl-%{apiver}/
2019-11-05 09:36:39 +00:00
%dir %{_libdir}/girepository-1.0
%{_libdir}/girepository-1.0/Babl-%{apiver}.typelib
2007-10-23 02:01:27 +00:00
%files devel
2012-04-03 09:18:36 +00:00
%{_includedir}/babl-%{apiver}/
%{_libdir}/libbabl-%{apiver}.so
2023-03-07 10:41:52 +00:00
%{_libdir}/pkgconfig/%{name}-%{apiver}.pc
2019-11-05 09:36:39 +00:00
%dir %{_datadir}/gir-1.0
%{_datadir}/gir-1.0/Babl-%{apiver}.gir
2020-06-15 07:41:17 +00:00
%{_datadir}/vala/
2007-10-23 02:01:27 +00:00
%files devel-docs
%doc %{develdocdir}
2007-10-23 02:01:27 +00:00
%changelog
%autochangelog