]>
Commit | Line | Data |
---|---|---|
dd8fb7b3 | 1 | # TODO: consider -x11 subpackages |
c1e066f3 MB |
2 | # |
3 | # Conditional build: | |
4 | %bcond_without apidocs # do not build and package API docs | |
5 | # | |
6 | %define abiver 2.10.0 | |
7 | # | |
88367156 JB |
8 | Summary: An image loading and scaling library |
9 | Summary(pl.UTF-8): Biblioteka ładująca i skalująca obrazki | |
c1e066f3 | 10 | Name: gdk-pixbuf2 |
59a682d2 | 11 | Version: 2.26.4 |
03617b75 | 12 | Release: 1 |
54f6e39e | 13 | License: LGPL v2+ |
c1e066f3 | 14 | Group: X11/Libraries |
8473b236 | 15 | Source0: http://ftp.gnome.org/pub/GNOME/sources/gdk-pixbuf/2.26/gdk-pixbuf-%{version}.tar.xz |
59a682d2 | 16 | # Source0-md5: e634924654bedfdbe58fab059f38ffed |
38a172e0 | 17 | Patch0: %{name}-png-nodep.patch |
6ddf3e6f | 18 | URL: http://developer.gnome.org/gdk-pixbuf/ |
c1e066f3 | 19 | BuildRequires: autoconf >= 2.63 |
011aa2c5 | 20 | BuildRequires: automake >= 1:1.11 |
c1e066f3 | 21 | BuildRequires: gettext-devel >= 0.17 |
8473b236 | 22 | BuildRequires: glib2-devel >= 1:2.32.0 |
3023a791 | 23 | BuildRequires: gobject-introspection-devel >= 0.10.0 |
c1e066f3 MB |
24 | BuildRequires: gtk-doc >= 1.11 |
25 | BuildRequires: jasper-devel | |
26 | BuildRequires: libjpeg-devel | |
27 | BuildRequires: libpng-devel | |
28 | BuildRequires: libtiff-devel | |
29 | BuildRequires: libtool >= 2:2.2.6 | |
30 | BuildRequires: libxslt-progs | |
ebabf38d | 31 | BuildRequires: perl-devel |
c1e066f3 | 32 | BuildRequires: pkgconfig |
58fa43f3 | 33 | BuildRequires: rpmbuild(macros) >= 1.527 |
53b35dfe | 34 | BuildRequires: tar >= 1:1.22 |
c1e066f3 | 35 | BuildRequires: xorg-lib-libX11-devel |
53b35dfe | 36 | BuildRequires: xz |
8473b236 | 37 | Requires: glib2 >= 1:2.32.0 |
677d7e9e | 38 | Suggests: librsvg >= 2.31 |
c1e066f3 MB |
39 | Conflicts: gtk+2 < 2:2.21.3-1 |
40 | BuildRoot: %{tmpdir}/%{name}-%{version}-root-%(id -u -n) | |
41 | ||
42 | %if "%{_lib}" != "lib" | |
43 | %define libext %(lib="%{_lib}"; echo ${lib#lib}) | |
44 | %define pqext -%{libext} | |
45 | %else | |
46 | %define pqext %{nil} | |
47 | %endif | |
48 | ||
49 | %description | |
88367156 JB |
50 | gdk-pixbuf is an image loading and scaling library that can be |
51 | extended by loadable modules for new image formats. | |
c1e066f3 MB |
52 | |
53 | It is used by toolkits such as GTK+ or Clutter. | |
54 | ||
55 | %description -l pl.UTF-8 | |
88367156 JB |
56 | gdk-pixbuf to biblioteka ładująca i skalująca obrazki, której |
57 | funkcjonalność może być rozszerzana o obsługę nowych formatów poprzez | |
58 | ładowane moduły. | |
c1e066f3 MB |
59 | |
60 | Używana jest przez biblioteki takie jak GTK+ czy Clutter. | |
61 | ||
62 | %package devel | |
63 | Summary: Header files for gdk-pixbuf library | |
64 | Summary(pl.UTF-8): Pliki nagłówkowe biblioteki gdk-pixbuf | |
65 | Group: X11/Development/Libraries | |
66 | Requires: %{name} = %{version}-%{release} | |
8473b236 | 67 | Requires: glib2-devel >= 1:2.32.0 |
c1e066f3 MB |
68 | Conflicts: gtk+2-devel < 2:2.21.3-1 |
69 | ||
70 | %description devel | |
71 | Header files for gdk-pixbuf library. | |
72 | ||
73 | %description devel -l pl.UTF-8 | |
74 | Pliki nagłówkowe biblioteki gdk-pixbuf. | |
75 | ||
76 | %package apidocs | |
77 | Summary: gdk-pixbuf API documentation | |
78 | Summary(pl.UTF-8): Dokumentacja API biblioteki gdk-pixbuf | |
79 | Group: Documentation | |
80 | Conflicts: gtk+2-apidocs < 2:2.21.3-1 | |
81 | ||
82 | %description apidocs | |
83 | API documentation for gdk-pixbuf library. | |
84 | ||
85 | %description apidocs -l pl.UTF-8 | |
86 | Dokumentacja API biblioteki gdk-pixbuf. | |
87 | ||
88 | %prep | |
89 | %setup -q -n gdk-pixbuf-%{version} | |
38a172e0 JB |
90 | %patch0 -p1 |
91 | ||
f48b93b6 | 92 | sed -i s#^io## po/LINGUAS |
73cec6ae | 93 | %{__rm} po/io.po |
c1e066f3 MB |
94 | |
95 | %build | |
88367156 | 96 | %{__gettextize} |
c1e066f3 MB |
97 | %{__libtoolize} |
98 | %{__aclocal} | |
99 | %{__autoconf} | |
100 | %{__autoheader} | |
101 | %{__automake} | |
102 | %configure \ | |
8473b236 | 103 | --disable-silent-rules \ |
c1e066f3 MB |
104 | --enable-man \ |
105 | %{__enable_disable apidocs gtk-doc} \ | |
106 | --with-html-dir=%{_gtkdocdir} \ | |
d5771b42 ŁK |
107 | --with-libjasper \ |
108 | --with-x11 | |
c1e066f3 MB |
109 | %{__make} |
110 | ||
111 | %install | |
112 | rm -rf $RPM_BUILD_ROOT | |
113 | ||
114 | %{__make} install \ | |
115 | DESTDIR=$RPM_BUILD_ROOT | |
116 | ||
117 | %if "%{_lib}" != "lib" | |
118 | # We need to have 32-bit and 64-bit binaries as they have hardcoded LIBDIR. | |
119 | # (needed when multilib is used) | |
36650217 | 120 | mv -f $RPM_BUILD_ROOT%{_bindir}/gdk-pixbuf-query-loaders{,%{pqext}} |
c1e066f3 MB |
121 | %endif |
122 | ||
123 | touch $RPM_BUILD_ROOT%{_libdir}/gdk-pixbuf-2.0/%{abiver}/loaders.cache | |
124 | ||
73cec6ae TP |
125 | %{__rm} $RPM_BUILD_ROOT%{_libdir}/gdk-pixbuf-2.0/%{abiver}/loaders/*.la \ |
126 | $RPM_BUILD_ROOT%{_libdir}/libgdk_pixbuf{,_xlib}-2.0.la | |
c1e066f3 | 127 | |
73cec6ae | 128 | %{!?with_apidocs:%{__rm} -r $RPM_BUILD_ROOT%{_gtkdocdir}} |
c1e066f3 | 129 | |
6822717d | 130 | %find_lang gdk-pixbuf %{name}.lang |
c1e066f3 MB |
131 | |
132 | %clean | |
133 | rm -rf $RPM_BUILD_ROOT | |
134 | ||
135 | %post | |
136 | /sbin/ldconfig | |
c1e066f3 | 137 | umask 022 |
36650217 | 138 | %{_bindir}/gdk-pixbuf-query-loaders%{pqext} --update-cache || : |
c1e066f3 MB |
139 | |
140 | %postun | |
141 | /sbin/ldconfig | |
c1e066f3 | 142 | if [ "$1" != "0" ]; then |
36650217 | 143 | umask 022 |
3854407a ER |
144 | # the $1 check does not match for multilib installs, check also that the binary still exists |
145 | [ ! -x %{_bindir}/gdk-pixbuf-query-loaders%{pqext} ] || \ | |
36650217 | 146 | %{_bindir}/gdk-pixbuf-query-loaders%{pqext} --update-cache || : |
c1e066f3 | 147 | fi |
c1e066f3 | 148 | |
36650217 | 149 | %files -f %{name}.lang |
c1e066f3 | 150 | %defattr(644,root,root,755) |
e0ed300b | 151 | %doc AUTHORS NEWS |
c1e066f3 MB |
152 | %attr(755,root,root) %{_bindir}/gdk-pixbuf-query-loaders%{pqext} |
153 | %attr(755,root,root) %{_libdir}/libgdk_pixbuf-2.0.so.*.*.* | |
154 | %attr(755,root,root) %ghost %{_libdir}/libgdk_pixbuf-2.0.so.0 | |
155 | %attr(755,root,root) %{_libdir}/libgdk_pixbuf_xlib-2.0.so.*.*.* | |
156 | %attr(755,root,root) %ghost %{_libdir}/libgdk_pixbuf_xlib-2.0.so.0 | |
157 | %dir %{_libdir}/gdk-pixbuf-2.0 | |
158 | %dir %{_libdir}/gdk-pixbuf-2.0/%{abiver} | |
159 | %ghost %{_libdir}/gdk-pixbuf-2.0/%{abiver}/loaders.cache | |
160 | %dir %{_libdir}/gdk-pixbuf-2.0/%{abiver}/loaders | |
36650217 | 161 | %attr(755,root,root) %{_libdir}/gdk-pixbuf-2.0/%{abiver}/loaders/libpixbufloader-*.so |
9d5ca6f5 | 162 | %{_libdir}/girepository-1.0/GdkPixbuf-2.0.typelib |
c1e066f3 MB |
163 | %{_mandir}/man1/gdk-pixbuf-query-loaders.1* |
164 | ||
165 | %files devel | |
166 | %defattr(644,root,root,755) | |
167 | %attr(755,root,root) %{_bindir}/gdk-pixbuf-csource | |
8473b236 | 168 | %attr(755,root,root) %{_bindir}/gdk-pixbuf-pixdata |
c1e066f3 MB |
169 | %attr(755,root,root) %{_libdir}/libgdk_pixbuf-2.0.so |
170 | %attr(755,root,root) %{_libdir}/libgdk_pixbuf_xlib-2.0.so | |
9d5ca6f5 | 171 | %{_datadir}/gir-1.0/GdkPixbuf-2.0.gir |
c1e066f3 MB |
172 | %{_mandir}/man1/gdk-pixbuf-csource.1* |
173 | %{_includedir}/gdk-pixbuf-2.0 | |
174 | %{_pkgconfigdir}/gdk-pixbuf-2.0.pc | |
175 | %{_pkgconfigdir}/gdk-pixbuf-xlib-2.0.pc | |
176 | ||
177 | %if %{with apidocs} | |
178 | %files apidocs | |
179 | %defattr(644,root,root,755) | |
180 | %{_gtkdocdir}/gdk-pixbuf | |
181 | %endif |