File mingw32-gdk-pixbuf.spec of Package mingw32-gdk-pixbuf

%define __strip %{_mingw32_strip}
%define __objdump %{_mingw32_objdump}
%define _use_internal_dependency_generator 0
%define __find_requires %{_mingw32_findrequires}
%define __find_provides %{_mingw32_findprovides}
%define __os_install_post %{_mingw32_debug_install_post} \
                          %{_mingw32_install_post}

Name:           mingw32-gdk-pixbuf
Version:        2.26.3
Release:        0
Summary:        Image loading library

License:        LGPLv2+
Group:          Development/Libraries
Url:            http://www.gtk.org/
Source:         http://download.gnome.org/sources/gdk-pixbuf/2.26/gdk-pixbuf-%{version}.tar.xz
BuildRoot:      %{_tmppath}/%{name}-%{version}-build
Patch1000:      gdk-pixbuf-2.24.0-wix.patch

BuildArch:      noarch
#!BuildIgnore: post-build-checks

BuildRequires:  mingw32-filesystem
BuildRequires:  mingw32-cross-gcc
BuildRequires:  mingw32-cross-binutils
BuildRequires:  mingw32-cross-pkg-config
BuildRequires:  mingw32-libintl-devel
BuildRequires:  mingw32-glib2-devel >= 2.31.0
BuildRequires:  mingw32-libjasper-devel
BuildRequires:  mingw32-libjpeg-devel
BuildRequires:  mingw32-libpng-devel
BuildRequires:  mingw32-libtiff-devel
BuildRequires:  xz
BuildRequires:  gtk-doc
# Native version for glib-genmarshal
BuildRequires:  glib2-devel
Requires:       %{name}-lang = %{version}

BuildRequires:  automake autoconf libtool
BuildRequires:  wixwine
%description
gdk-pixbuf is an image loading library that can be extended by loadable modules for new image formats.
It is used by toolkits such as GTK+ or Clutter.


%package query-loaders
Summary:        Image loading library - Utility to create loaders cache
Group:          System/Libraries

%description query-loaders
gdk-pixbuf is an image loading library that can be extended by loadable modules for new image formats.
It is used by toolkits such as GTK+ or Clutter.

This package contains the utility to create the cache file needed for loadable modules.


%package devel-tools
Summary:        Image loading library - Development tools
Group:          Development/Libraries

%description devel-tools
gdk-pixbuf is an image loading library that can be extended by loadable modules for new image formats.
It is used by toolkits such as GTK+ or Clutter.


%package devel
Summary:        Image loading library - Development files
Group:          Development/Libraries

%description devel
gdk-pixbuf is an image loading library that can be extended by loadable modules for new image formats.
It is used by toolkits such as GTK+ or Clutter.

This package contains development files for gdk-pixbuf.


%{_mingw32_debug_package}

%lang_package

%prep
%setup -q -n gdk-pixbuf-%{version}


%patch1000 -p1 -b .wix
%build
autoreconf -f -i
# Need to run the correct version of glib-mkenums.
export PATH="%{_mingw32_bindir}:$PATH"

echo "lt_cv_deplibs_check_method='pass_all'" >>%{_mingw32_cache}

%{_mingw32_configure} \
	--without-gdiplus \
	--with-libjasper \
	--with-included-loaders=yes \
	--enable-shared --disable-static
rm gdk-pixbuf/gdiplus.def gdk-pixbuf/gdk_pixbuf.def # Force regeneration of .def files
make %{?_smp_mflags} || make


%install
make DESTDIR=$RPM_BUILD_ROOT install

chmod -x $RPM_BUILD_ROOT%{_mingw32_libdir}/*.def

%find_lang gdk-pixbuf

# Work around automake >= 11.4 not creating this
mkdir -p $RPM_BUILD_ROOT%{_mingw32_libdir}/gdk-pixbuf-2.0/2.10.0/loaders


%clean
rm -rf $RPM_BUILD_ROOT


%files
%defattr(-,root,root)
%{_mingw32_bindir}/libgdk_pixbuf-2.0-0.dll

%files lang -f gdk-pixbuf.lang
%defattr(-,root,root)

%files query-loaders
%defattr(-,root,root)
%{_mingw32_bindir}/gdk-pixbuf-query-loaders.exe
%{_mingw32_mandir}/man1/gdk-pixbuf-query-loaders.1*

%files devel-tools
%defattr(-,root,root)
%{_mingw32_bindir}/gdk-pixbuf-csource.exe
%{_mingw32_bindir}/gdk-pixbuf-pixdata.exe
%{_mingw32_mandir}/man1/gdk-pixbuf-csource.1*

%files devel
%defattr(-,root,root)
%{_mingw32_datadir}/gtk-doc/html/gdk-pixbuf
%{_mingw32_includedir}/gdk-pixbuf-2.0/
%{_mingw32_libdir}/libgdk_pixbuf-2.0.dll.a
%{_mingw32_libdir}/gdk_pixbuf-2.0.def
%{_mingw32_libdir}/pkgconfig/gdk-pixbuf-2.0.pc
%{_mingw32_datadir}/wixlib/gdk-pixbuf-2.0.wixlib


%changelog
openSUSE Build Service is sponsored by