]>
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 | |
2a444766 | 5 | |
c1e066f3 | 6 | %define abiver 2.10.0 |
88367156 JB |
7 | Summary: An image loading and scaling library |
8 | Summary(pl.UTF-8): Biblioteka ładująca i skalująca obrazki | |
c1e066f3 | 9 | Name: gdk-pixbuf2 |
6aab4d95 | 10 | Version: 2.38.0 |
1756601e | 11 | Release: 1 |
54f6e39e | 12 | License: LGPL v2+ |
c1e066f3 | 13 | Group: X11/Libraries |
6aab4d95 JP |
14 | Source0: http://ftp.gnome.org/pub/GNOME/sources/gdk-pixbuf/2.38/gdk-pixbuf-%{version}.tar.xz |
15 | # Source0-md5: 77765f24496dc8c90c6e0cbe10fd8f0e | |
c0889a6f | 16 | URL: https://developer.gnome.org/gdk-pixbuf/ |
8a6f58ac JB |
17 | BuildRequires: docbook-dtd43-xml |
18 | BuildRequires: docbook-style-xsl | |
cdaf86d0 | 19 | BuildRequires: gettext-tools >= 0.19 |
788d16ff | 20 | BuildRequires: glib2-devel >= 1:2.48.0 |
3023a791 | 21 | BuildRequires: gobject-introspection-devel >= 0.10.0 |
2c2cbfcf | 22 | BuildRequires: gtk-doc >= 1.20 |
c1e066f3 MB |
23 | BuildRequires: jasper-devel |
24 | BuildRequires: libjpeg-devel | |
788d16ff | 25 | BuildRequires: libpng-devel >= 1.0 |
14d965b8 | 26 | BuildRequires: libtiff-devel >= 4 |
c1e066f3 MB |
27 | BuildRequires: libtool >= 2:2.2.6 |
28 | BuildRequires: libxslt-progs | |
6aab4d95 JP |
29 | BuildRequires: meson >= 0.46.0 |
30 | BuildRequires: ninja | |
ebabf38d | 31 | BuildRequires: perl-devel |
c1e066f3 | 32 | BuildRequires: pkgconfig |
6aab4d95 | 33 | BuildRequires: rpmbuild(macros) >= 1.727 |
53b35dfe | 34 | BuildRequires: tar >= 1:1.22 |
c1e066f3 | 35 | BuildRequires: xorg-lib-libX11-devel |
53b35dfe | 36 | BuildRequires: xz |
788d16ff | 37 | Requires: glib2 >= 1:2.48.0 |
14d965b8 | 38 | Requires: shared-mime-info |
677d7e9e | 39 | Suggests: librsvg >= 2.31 |
c1e066f3 MB |
40 | Conflicts: gtk+2 < 2:2.21.3-1 |
41 | BuildRoot: %{tmpdir}/%{name}-%{version}-root-%(id -u -n) | |
42 | ||
43 | %if "%{_lib}" != "lib" | |
44 | %define libext %(lib="%{_lib}"; echo ${lib#lib}) | |
45 | %define pqext -%{libext} | |
46 | %else | |
47 | %define pqext %{nil} | |
48 | %endif | |
49 | ||
50 | %description | |
88367156 JB |
51 | gdk-pixbuf is an image loading and scaling library that can be |
52 | extended by loadable modules for new image formats. | |
c1e066f3 MB |
53 | |
54 | It is used by toolkits such as GTK+ or Clutter. | |
55 | ||
56 | %description -l pl.UTF-8 | |
88367156 JB |
57 | gdk-pixbuf to biblioteka ładująca i skalująca obrazki, której |
58 | funkcjonalność może być rozszerzana o obsługę nowych formatów poprzez | |
59 | ładowane moduły. | |
c1e066f3 MB |
60 | |
61 | Używana jest przez biblioteki takie jak GTK+ czy Clutter. | |
62 | ||
63 | %package devel | |
64 | Summary: Header files for gdk-pixbuf library | |
65 | Summary(pl.UTF-8): Pliki nagłówkowe biblioteki gdk-pixbuf | |
66 | Group: X11/Development/Libraries | |
67 | Requires: %{name} = %{version}-%{release} | |
788d16ff | 68 | Requires: glib2-devel >= 1:2.48.0 |
c1e066f3 | 69 | Conflicts: gtk+2-devel < 2:2.21.3-1 |
14d965b8 JB |
70 | # for gdk-pixbuf-xlib-2.0: |
71 | Requires: xorg-lib-libX11-devel | |
c1e066f3 MB |
72 | |
73 | %description devel | |
74 | Header files for gdk-pixbuf library. | |
75 | ||
76 | %description devel -l pl.UTF-8 | |
77 | Pliki nagłówkowe biblioteki gdk-pixbuf. | |
78 | ||
6aab4d95 JP |
79 | %package static |
80 | Summary: Static gdk-pixbuf libraries | |
81 | Summary(pl.UTF-8): Biblioteki statyczne gdk-pixbuf | |
82 | Group: Development/Libraries | |
83 | Requires: %{name}-devel = %{epoch}:%{version}-%{release} | |
84 | ||
85 | %description static | |
86 | Static gdk-pixbuf libraries. | |
87 | ||
88 | %description static -l pl.UTF-8 | |
89 | Biblioteki statyczne gdk-pixbuf. | |
90 | ||
c1e066f3 MB |
91 | %package apidocs |
92 | Summary: gdk-pixbuf API documentation | |
93 | Summary(pl.UTF-8): Dokumentacja API biblioteki gdk-pixbuf | |
94 | Group: Documentation | |
95 | Conflicts: gtk+2-apidocs < 2:2.21.3-1 | |
2a444766 ER |
96 | %if "%{_rpmversion}" >= "5" |
97 | BuildArch: noarch | |
98 | %endif | |
c1e066f3 MB |
99 | |
100 | %description apidocs | |
101 | API documentation for gdk-pixbuf library. | |
102 | ||
103 | %description apidocs -l pl.UTF-8 | |
104 | Dokumentacja API biblioteki gdk-pixbuf. | |
105 | ||
106 | %prep | |
107 | %setup -q -n gdk-pixbuf-%{version} | |
38a172e0 | 108 | |
c1e066f3 | 109 | %build |
6aab4d95 JP |
110 | %meson build \ |
111 | -Ddocs=%{?with_apidocs:true}%{!?with_apidocs:false} \ | |
112 | -Dinstalled_tests=false \ | |
113 | -Djasper=true \ | |
114 | -Dman=true \ | |
115 | -Dx11=true | |
116 | %meson_build -C build | |
c1e066f3 MB |
117 | |
118 | %install | |
119 | rm -rf $RPM_BUILD_ROOT | |
120 | ||
6aab4d95 | 121 | %meson_install -j1 -C build |
c1e066f3 MB |
122 | |
123 | %if "%{_lib}" != "lib" | |
124 | # We need to have 32-bit and 64-bit binaries as they have hardcoded LIBDIR. | |
125 | # (needed when multilib is used) | |
14d965b8 | 126 | %{__mv} $RPM_BUILD_ROOT%{_bindir}/gdk-pixbuf-query-loaders{,%{pqext}} |
c1e066f3 MB |
127 | %endif |
128 | ||
129 | touch $RPM_BUILD_ROOT%{_libdir}/gdk-pixbuf-2.0/%{abiver}/loaders.cache | |
130 | ||
73cec6ae | 131 | %{!?with_apidocs:%{__rm} -r $RPM_BUILD_ROOT%{_gtkdocdir}} |
c1e066f3 | 132 | |
f361a645 | 133 | %{__mv} $RPM_BUILD_ROOT%{_localedir}/{sr@ije,sr@ijekavian} |
ce56c90e | 134 | # not supported by glibc |
f361a645 | 135 | %{__rm} -r $RPM_BUILD_ROOT%{_localedir}/io |
ce56c90e | 136 | |
6822717d | 137 | %find_lang gdk-pixbuf %{name}.lang |
c1e066f3 MB |
138 | |
139 | %clean | |
140 | rm -rf $RPM_BUILD_ROOT | |
141 | ||
142 | %post | |
143 | /sbin/ldconfig | |
c1e066f3 | 144 | umask 022 |
36650217 | 145 | %{_bindir}/gdk-pixbuf-query-loaders%{pqext} --update-cache || : |
c1e066f3 MB |
146 | |
147 | %postun | |
148 | /sbin/ldconfig | |
c1e066f3 | 149 | if [ "$1" != "0" ]; then |
36650217 | 150 | umask 022 |
3854407a ER |
151 | # the $1 check does not match for multilib installs, check also that the binary still exists |
152 | [ ! -x %{_bindir}/gdk-pixbuf-query-loaders%{pqext} ] || \ | |
36650217 | 153 | %{_bindir}/gdk-pixbuf-query-loaders%{pqext} --update-cache || : |
c1e066f3 | 154 | fi |
c1e066f3 | 155 | |
36650217 | 156 | %files -f %{name}.lang |
c1e066f3 | 157 | %defattr(644,root,root,755) |
6aab4d95 | 158 | %doc NEWS README.md |
c1e066f3 | 159 | %attr(755,root,root) %{_bindir}/gdk-pixbuf-query-loaders%{pqext} |
13b94238 | 160 | %attr(755,root,root) %{_bindir}/gdk-pixbuf-thumbnailer |
c1e066f3 MB |
161 | %attr(755,root,root) %{_libdir}/libgdk_pixbuf-2.0.so.*.*.* |
162 | %attr(755,root,root) %ghost %{_libdir}/libgdk_pixbuf-2.0.so.0 | |
163 | %attr(755,root,root) %{_libdir}/libgdk_pixbuf_xlib-2.0.so.*.*.* | |
164 | %attr(755,root,root) %ghost %{_libdir}/libgdk_pixbuf_xlib-2.0.so.0 | |
165 | %dir %{_libdir}/gdk-pixbuf-2.0 | |
166 | %dir %{_libdir}/gdk-pixbuf-2.0/%{abiver} | |
167 | %ghost %{_libdir}/gdk-pixbuf-2.0/%{abiver}/loaders.cache | |
168 | %dir %{_libdir}/gdk-pixbuf-2.0/%{abiver}/loaders | |
36650217 | 169 | %attr(755,root,root) %{_libdir}/gdk-pixbuf-2.0/%{abiver}/loaders/libpixbufloader-*.so |
13b94238 | 170 | %{_datadir}/thumbnailers/gdk-pixbuf-thumbnailer.thumbnailer |
9d5ca6f5 | 171 | %{_libdir}/girepository-1.0/GdkPixbuf-2.0.typelib |
6aab4d95 | 172 | %{_libdir}/girepository-1.0/GdkPixdata-2.0.typelib |
c1e066f3 MB |
173 | %{_mandir}/man1/gdk-pixbuf-query-loaders.1* |
174 | ||
175 | %files devel | |
176 | %defattr(644,root,root,755) | |
177 | %attr(755,root,root) %{_bindir}/gdk-pixbuf-csource | |
8473b236 | 178 | %attr(755,root,root) %{_bindir}/gdk-pixbuf-pixdata |
c1e066f3 MB |
179 | %attr(755,root,root) %{_libdir}/libgdk_pixbuf-2.0.so |
180 | %attr(755,root,root) %{_libdir}/libgdk_pixbuf_xlib-2.0.so | |
9d5ca6f5 | 181 | %{_datadir}/gir-1.0/GdkPixbuf-2.0.gir |
6aab4d95 | 182 | %{_datadir}/gir-1.0/GdkPixdata-2.0.gir |
c1e066f3 MB |
183 | %{_mandir}/man1/gdk-pixbuf-csource.1* |
184 | %{_includedir}/gdk-pixbuf-2.0 | |
185 | %{_pkgconfigdir}/gdk-pixbuf-2.0.pc | |
186 | %{_pkgconfigdir}/gdk-pixbuf-xlib-2.0.pc | |
187 | ||
6aab4d95 JP |
188 | %files static |
189 | %defattr(644,root,root,755) | |
190 | %{_libdir}/libgdk_pixbuf-2.0.a | |
191 | %{_libdir}/libgdk_pixbuf_xlib-2.0.a | |
192 | ||
c1e066f3 MB |
193 | %if %{with apidocs} |
194 | %files apidocs | |
195 | %defattr(644,root,root,755) | |
196 | %{_gtkdocdir}/gdk-pixbuf | |
197 | %endif |