]> git.pld-linux.org Git - packages/crossmingw32-gdk-pixbuf2.git/blob - crossmingw32-gdk-pixbuf2.spec
- merged png-nodep patch from native version: no need to have libpng as dependency...
[packages/crossmingw32-gdk-pixbuf2.git] / crossmingw32-gdk-pixbuf2.spec
1 #
2 # Conditional build:
3 %bcond_without  gdiplus # use libjpeg and libtiff instead of system GDIPLUS
4 #
5 Summary:        An image loading and scaling library - cross MinGW32 version
6 Summary(pl.UTF-8):      Biblioteka ładująca i skalująca obrazki - wersja skrośna MinGW32
7 Name:           crossmingw32-gdk-pixbuf2
8 Version:        2.24.1
9 Release:        2
10 License:        LGPL v2+
11 Group:          Development/Libraries
12 Source0:        http://ftp.gnome.org/pub/GNOME/sources/gdk-pixbuf/2.24/gdk-pixbuf-%{version}.tar.xz
13 # Source0-md5:  72f39b34b20f68148c1609bd27415412
14 Patch0:         gdk-pixbuf2-png-nodep.patch
15 Patch1:         gdk-pixbuf2-gdip.patch
16 URL:            http://developer.gnome.org/gdk-pixbuf/
17 BuildRequires:  crossmingw32-gcc
18 BuildRequires:  crossmingw32-glib2 >= 2.28.0
19 BuildRequires:  crossmingw32-jasper
20 BuildRequires:  crossmingw32-libpng
21 BuildRequires:  gtk-doc >= 1.11
22 BuildRequires:  pkgconfig >= 1:0.15
23 BuildRequires:  tar >= 1:1.22
24 BuildRequires:  xz
25 %if %{without gdiplus}
26 BuildRequires:  crossmingw32-libjpeg
27 BuildRequires:  crossmingw32-libtiff
28 %endif
29 Requires:       crossmingw32-glib2 >= 2.28.0
30 Conflicts:      crossmingw32-gtk+2 < 2.22.0
31 BuildRoot:      %{tmpdir}/%{name}-%{version}-root-%(id -u -n)
32
33 %define         abiver  2.10.0
34
35 %define         no_install_post_strip   1
36
37 %define         target                  i386-mingw32
38 %define         target_platform         i386-pc-mingw32
39
40 %define         _sysprefix              /usr
41 %define         _prefix                 %{_sysprefix}/%{target}
42 %define         _libdir                 %{_prefix}/lib
43 %define         _pkgconfigdir           %{_prefix}/lib/pkgconfig
44 %define         _dlldir                 /usr/share/wine/windows/system
45 %define         __cc                    %{target}-gcc
46 %define         __cxx                   %{target}-g++
47
48 #define         filterout_ld            (-Wl,)?-as-needed.*
49
50 %ifnarch %{ix86}
51 # arch-specific flags (like alpha's -mieee) are not valid for i386 gcc
52 %define         optflags        -O2
53 %endif
54 # -z options are invalid for mingw linker
55 %define         filterout_ld    -Wl,-z,.*
56
57 %description
58 gdk-pixbuf is an image loading and scaling library that can be
59 extended by loadable modules for new image formats.
60
61 This package contains the cross version for Win32.
62
63 %description -l pl.UTF-8
64 gdk-pixbuf to biblioteka ładująca i skalująca obrazki, której
65 funkcjonalność może być rozszerzana o obsługę nowych formatów poprzez
66 ładowane moduły.
67
68 Ten pakiet zawiera wersję skrośną dla Win32.
69
70 %package dll
71 Summary:        DLL gdk-pixbuf libraries for Windows
72 Summary(pl.UTF-8):      Biblioteki DLL gdk-pixbuf dla Windows
73 Group:          Applications/Emulators
74 Requires:       crossmingw32-glib2-dll >= 2.28.0
75 Requires:       wine
76 Conflicts:      crossmingw32-gtk+2-dll < 2.22.0
77
78 %description dll
79 DLL gdk-pixbuf libraries for Windows.
80
81 %description dll -l pl.UTF-8
82 Biblioteki DLL gdk-pixbuf dla Windows.
83
84 %prep
85 %setup -q -n gdk-pixbuf-%{version}
86 %patch0 -p1
87 %patch1 -p1
88
89 %build
90 export PKG_CONFIG_LIBDIR=%{_prefix}/lib/pkgconfig
91 %configure \
92         --target=%{target} \
93         --host=%{target} \
94         --disable-gtk-doc \
95         --disable-man \
96         --with-libjasper \
97         %{!?with_gdiplus:--without-gdiplus}
98
99 %{__make}
100
101 %install
102 rm -rf $RPM_BUILD_ROOT
103
104 %{__make} install \
105         DESTDIR=$RPM_BUILD_ROOT
106
107 install -d $RPM_BUILD_ROOT%{_dlldir}
108 mv -f $RPM_BUILD_ROOT%{_prefix}/bin/*.dll $RPM_BUILD_ROOT%{_dlldir}
109
110 %if 0%{!?debug:1}
111 %{target}-strip --strip-unneeded -R.comment -R.note $RPM_BUILD_ROOT%{_dlldir}/*.dll \
112         $RPM_BUILD_ROOT%{_libdir}/gdk-pixbuf-2.0/%{abiver}/loaders/*.dll
113 %{target}-strip -g -R.comment -R.note $RPM_BUILD_ROOT%{_libdir}/*.a
114 %endif
115
116 # shut up check-files
117 %{__rm} -r $RPM_BUILD_ROOT%{_datadir}/{gtk-doc,locale,man}
118 %{__rm} -r $RPM_BUILD_ROOT%{_libdir}/gdk-pixbuf-2.0/%{abiver}/loaders/*.{la,dll.a}
119
120 %clean
121 rm -rf $RPM_BUILD_ROOT
122
123 %files
124 %defattr(644,root,root,755)
125 %{_libdir}/libgdk_pixbuf-2.0.dll.a
126 %{_libdir}/libgdk_pixbuf-2.0.la
127 %{_libdir}/gdk_pixbuf-2.0.def
128 %{_includedir}/gdk-pixbuf-2.0
129 %{_pkgconfigdir}/gdk-pixbuf-2.0.pc
130
131 %files dll
132 %defattr(644,root,root,755)
133 %{_dlldir}/libgdk_pixbuf-2.0-*.dll
134 %dir %{_libdir}/gdk-pixbuf-2.0
135 %dir %{_libdir}/gdk-pixbuf-2.0/%{abiver}
136 %dir %{_libdir}/gdk-pixbuf-2.0/%{abiver}/loaders
137 %{_libdir}/gdk-pixbuf-2.0/%{abiver}/loaders/libpixbufloader-*.dll
This page took 0.038152 seconds and 3 git commands to generate.