Summary:        A graph based image processing framework
Summary(ja):    グラフベースの画像処理フレームワーク
Name:           gegl04
Version:        0.4.44
Release:        1%{?_dist_release}
Group:          system
Vendor:         Project Vine
Distribution:   Vine Linux

# The binary is under the GPL, while the libs are under LGPL
License:        LGPLv3+ and GPLv3+
URL:            https://www.gegl.org/
%define         shortver %(echo %{version} | sed -e 's/\\.[0-9]*$//')
Source0:        https://download.gimp.org/pub/gegl/%{shortver}/gegl-%{version}.tar.xz
Patch0:         gegl04-openexr.patch

BuildRoot:      %{_tmppath}/%{name}-%{version}-%{release}-root
BuildRequires:  meson
BuildRequires:  glib2-devel
BuildRequires:  gdk-pixbuf2-devel
BuildRequires:  pango-devel
BuildRequires:  babl-devel >= 0.1.74
BuildRequires:  json-glib-devel
BuildRequires:  perl
BuildRequires:  ruby
BuildRequires:  exiv2-devel
BuildRequires:  jasper-devel
BuildRequires:  lcms2-devel
BuildRequires:  lensfun-devel
BuildRequires:  libgexiv2-devel
BuildRequires:  libjpeg-devel
BuildRequires:  libpng-devel
BuildRequires:  LibRaw-devel
BuildRequires:  librsvg2-devel
BuildRequires:  libtiff-devel
BuildRequires:  libv4l-devel
BuildRequires:  libwebp-devel
BuildRequires:  poppler-devel
BuildRequires:  python3-devel
BuildRequires:  python3-rpm-macros
BuildRequires:  python3-pygobject
BuildRequires:  pygobject3-devel
BuildRequires:  gobject-introspection-devel
BuildRequires:  vala-devel
BuildRequires:  asciidoc
BuildRequires:  SDL2-devel
BuildRequires:  OpenEXR-devel
BuildRequires:  lua-devel
BuildRequires:  enscript
BuildRequires:  w3m
BuildRequires:  graphviz

Obsoletes:      gegl < 0.4
Obsoletes:      gegl03 < 0.4
Obsoletes:      gegl02 < 0.4
Provides:       gegl = %{version}-%{release}

%description
GEGL (Generic Graphics Library) is a graph based image processing framework. 
GEGLs original design was made to scratch GIMPs itches for a new
compositing and processing core. This core is being designed to have
minimal dependencies. and a simple well defined API.


%package devel
Summary:  Development files for %{name}
Summary(ja):  %{name} の開発ファイル
Group:    programming
Requires: %{name} = %{version}-%{release}
Requires: pkgconfig babl-devel glib2-devel
Obsoletes:      gegl-devel < 0.4
Obsoletes:      gegl03-devel < 0.4
Provides:       gegl-devel = %{version}-%{release}

%description devel
This package contains the libraries and header files needed for
developing with %{name}.


%debug_package


%prep
%autosetup -p1 -n gegl-%{version}


%build
export PYTHON=%{__python3}
%meson \
	-Dlibspiro=disabled \
	-Dlibv4l=disabled \
	-Dlua=disabled \
	-Dmrg=disabled \
	-Dlibav=disabled \
	-Dumfpack=disabled \
	-Dmaxflow=disabled \
	-Ddocs=false -Dgtk-doc=false

%meson_build


%install
%{__rm} -rf %{buildroot}
%meson_install

find %{buildroot} -name '*.la' -delete

%find_lang gegl-%{shortver}


%clean
%{__rm} -rf %{buildroot}


%files -f gegl-%{shortver}.lang
%defattr(-, root, root, -)
%license COPYING COPYING.LESSER
%doc AUTHORS MAINTAINERS
%doc docs/ChangeLog docs/NEWS.txt
%{_bindir}/*
%{_libdir}/libgegl-%{shortver}.so.*
%{_libdir}/libgegl-npd-%{shortver}.so
%{_libdir}/libgegl-sc-%{shortver}.so
%{_libdir}/gegl-%{shortver}
%{_libdir}/girepository-1.0/Gegl-%{shortver}.typelib

%files devel
%defattr(-, root, root, -)
%{_includedir}/gegl-%{shortver}
%{_libdir}/libgegl-%{shortver}.so
%{_libdir}/pkgconfig/gegl-%{shortver}.pc
%{_libdir}/pkgconfig/gegl-sc-%{shortver}.pc
%{_datadir}/gir-1.0/Gegl-%{shortver}.gir
%{_datadir}/vala/vapi/gegl-%{shortver}.deps
%{_datadir}/vala/vapi/gegl-%{shortver}.vapi
#{_datadir}/gtk-doc/html/*


%changelog
* Sat Apr 22 2023 Tomohiro "Tomo-p" KATO <tomop@teamgedoh.net> 0.4.44-1
- new upstream release.

* Thu Jan 13 2022 Tomohiro "Tomo-p" KATO <tomop@teamgedoh.net> 0.4.34-1
- new upstream release.

* Thu Sep 02 2021 Tomohiro "Tomo-p" KATO <tomop@teamgedoh.net> 0.4.30-2
- rebuilt with OpenEXR-3.1.1.

* Tue Mar 30 2021 Tomohiro "Tomo-p" KATO <tomop@teamgedoh.net> 0.4.30-1
- new upstream release.
- dropped ldconfig scriptlets.

* Sat Dec 12 2020 Tomohiro "Tomo-p" KATO <tomop@teamgedoh.net> 0.4.26-2
- rebuilt with OpenEXR-2.5.3.

* Fri Sep 04 2020 Tomohiro "Tomo-p" KATO <tomop@teamgedoh.net> 0.4.26-1
- new upstream release.

* Fri Apr 17 2020 Tomohiro "Tomo-p" KATO <tomop@teamgedoh.net> 0.4.22-1
- new upstream release.

* Sat Oct 26 2019 Tomohiro "Tomo-p" KATO <tomop@teamgedoh.net> 0.4.16-1
- new upstream release.
- built with OpenEXR-2.4.0.

* Mon Sep 09 2019 Toshiaki Ara <ara_t@384.jp> 0.4.12-2
- rebuild with LibRaw-0.19.5
- add BuildRequires:  python3-devel

* Mon Dec 31 2018 Tomohiro "Tomo-p" KATO <tomop@teamgedoh.net> 0.4.12-1
- new upstream release.
- added O:gegl{,03}{,-devel}: none required.

* Tue Oct 02 2018 Toshiaki Ara <ara_t@384.jp> 0.4.8-1
- initial build

