1 |
ahmad |
6682 |
# enable_gtkdoc: Toggle if gtk-doc files should be rebuilt. |
2 |
|
|
# 0 = no |
3 |
|
|
# 1 = yes |
4 |
ahmad |
51699 |
%define enable_gtkdoc 1 |
5 |
ahmad |
6682 |
|
6 |
|
|
# enable_bootstrap: Toggle if bootstrapping package |
7 |
|
|
# 0 = no |
8 |
|
|
# 1 = yes |
9 |
ahmad |
51701 |
# N.B. when disabling bootstrap, toggle enable_gtkdoc to 1, otherwise the build |
10 |
|
|
# fails as autoreconf -fi exits with 1 |
11 |
dmorgan |
51656 |
%define enable_bootstrap 0 |
12 |
ahmad |
6682 |
|
13 |
|
|
# enable_tests: Run test suite in build |
14 |
|
|
# 0 = no |
15 |
|
|
# 1 = yes |
16 |
|
|
%define enable_tests 0 |
17 |
|
|
|
18 |
|
|
%{?_without_gtkdoc: %{expand: %%define enable_gtkdoc 0}} |
19 |
|
|
%{?_without_bootstrap: %{expand: %%define enable_bootstrap 0}} |
20 |
|
|
%{?_without_tests: %{expand: %%define enable_tests 0}} |
21 |
|
|
|
22 |
|
|
%{?_with_gtkdoc: %{expand: %%define enable_gtkdoc 1}} |
23 |
|
|
%{?_with_bootstrap: %{expand: %%define enable_bootstrap 1}} |
24 |
|
|
%{?_with_tests: %{expand: %%define enable_tests 1}} |
25 |
|
|
|
26 |
|
|
|
27 |
|
|
# required version of various libraries |
28 |
ahmad |
77866 |
%define req_glib_version 2.27.3 |
29 |
ahmad |
6682 |
%define req_pango_version 1.20.0 |
30 |
|
|
%define req_atk_version 1.29.4 |
31 |
|
|
%define req_cairo_version 1.6.0 |
32 |
|
|
%define req_gdk_pixbuf_version 2.21.0 |
33 |
|
|
|
34 |
|
|
%define pkgname gtk+ |
35 |
|
|
%define api_version 2.0 |
36 |
ahmad |
77866 |
%define binary_version 2.10 |
37 |
ahmad |
6682 |
%define lib_major 0 |
38 |
|
|
%define libname %mklibname %{pkgname} %{api_version} %{lib_major} |
39 |
|
|
%define libname_x11 %mklibname %{pkgname}-x11- %{api_version} %{lib_major} |
40 |
|
|
%define develname %mklibname -d %pkgname %api_version |
41 |
|
|
|
42 |
|
|
%define gail_major 18 |
43 |
|
|
%define gail_libname %mklibname gail %gail_major |
44 |
|
|
%define gaildevelname %mklibname -d gail |
45 |
|
|
|
46 |
|
|
%define git_url git://git.gnome.org/gtk+ |
47 |
|
|
|
48 |
wally |
157493 |
%define major_url %(echo %{version}|cut -d. -f1,2) |
49 |
ahmad |
77866 |
|
50 |
wally |
121215 |
%define gi_major 2.0 |
51 |
|
|
%define girname %mklibname gtk-gir %gi_major |
52 |
dmorgan |
119798 |
|
53 |
ahmad |
6682 |
Summary: The GIMP ToolKit (GTK+), a library for creating GUIs |
54 |
|
|
Name: %{pkgname}%{api_version} |
55 |
wally |
157493 |
Version: 2.24.7 |
56 |
fwang |
157593 |
Release: %mkrel 2 |
57 |
ahmad |
6682 |
License: LGPLv2+ |
58 |
|
|
Group: System/Libraries |
59 |
wally |
157493 |
Source0: http://download.gnome.org/sources/%{pkgname}/%{major_url}/%{pkgname}-%{version}.tar.xz |
60 |
ahmad |
6682 |
# extra IM modules (vietnamese and tamil) -- pablo |
61 |
|
|
#gw TODO, needs to be fixed for 2.21.3 |
62 |
|
|
Patch4: gtk+-2.13.1-extra_im.patch |
63 |
|
|
# (fc) 2.0.6-8mdk fix infinite loop and crash in file selector when / and $HOME are not readable (bug #90) |
64 |
|
|
Patch5: gtk+-2.6.9-fileselectorfallback.patch |
65 |
|
|
# (fc) 2.4.0-2mdk use Ia Ora theme by default if available |
66 |
|
|
Patch12: gtk+-defaulttheme.patch |
67 |
|
|
# (gb) 2.4.4-2mdk handle biarch |
68 |
|
|
Patch13: gtk+-2.2.4-lib64.patch |
69 |
|
|
# (fc) 2.18.2-2mdv fix nautilus crash (GNOME bug #596977) (pterjan) |
70 |
|
|
Patch15: gtk+-2.18.1-fixnautiluscrash.patch |
71 |
|
|
# (fc) 2.20.0-2mdv improve tooltip appareance (GNOME bug #599617) (Fedora) |
72 |
|
|
Patch18: gtk+-2.21.1-fresh-tooltips.patch |
73 |
|
|
# (fc) 2.20.0-2mdv improve tooltip positioning (GNOME bug #599618) (Fedora) |
74 |
|
|
Patch19: gtk+-2.20.0-tooltip-positioning.patch |
75 |
|
|
# (fc) 2.20.0-2mdv allow window dragging toolbars / menubar (GNOME bug #611313) |
76 |
wally |
157493 |
Patch20: gtk+-2.24.7-window-dragging.patch |
77 |
ahmad |
6682 |
# (fc) 2.20.0-3mdv allow specifying icon padding for tray icon (GNOME bug #583273) (Fedora) |
78 |
|
|
Patch21: gtk+-2.20.0-icon-padding.patch |
79 |
|
|
|
80 |
|
|
Conflicts: perl-Gtk2 < 1.113 |
81 |
|
|
|
82 |
|
|
URL: http://www.gtk.org |
83 |
|
|
Requires: common-licenses |
84 |
|
|
BuildRequires: gettext-devel |
85 |
|
|
BuildRequires: libglib2.0-devel >= %{req_glib_version} |
86 |
|
|
BuildRequires: libatk1.0-devel >= %{req_atk_version} |
87 |
|
|
BuildRequires: cairo-devel >= %{req_cairo_version} |
88 |
|
|
BuildRequires: pango-devel >= %{req_pango_version} |
89 |
|
|
BuildRequires: gobject-introspection-devel >= 0.9.5 |
90 |
|
|
BuildRequires: libgdk_pixbuf2.0-devel >= %req_gdk_pixbuf_version |
91 |
ahmad |
77866 |
BuildRequires: libx11-devel |
92 |
|
|
BuildRequires: libxext-devel |
93 |
|
|
BuildRequires: libxinerama-devel |
94 |
|
|
BuildRequires: libxi-devel |
95 |
|
|
BuildRequires: libxrender-devel |
96 |
|
|
BuildRequires: libxrandr-devel |
97 |
|
|
BuildRequires: libxcomposite-devel |
98 |
|
|
BuildRequires: libxdamage-devel |
99 |
|
|
BuildRequires: libxfixes-devel |
100 |
|
|
BuildRequires: libxcursor-devel |
101 |
ahmad |
6682 |
BuildRequires: cups-devel |
102 |
|
|
BuildRequires: fam-devel |
103 |
|
|
%if %enable_tests |
104 |
|
|
BuildRequires: x11-server-xvfb |
105 |
|
|
%endif |
106 |
|
|
%if %enable_gtkdoc |
107 |
|
|
BuildRequires: gtk-doc >= 0.9 |
108 |
|
|
BuildRequires: sgml-tools |
109 |
|
|
BuildRequires: texinfo |
110 |
|
|
%endif |
111 |
|
|
# gw tests will fail without this |
112 |
|
|
BuildRequires: fonts-ttf-dejavu |
113 |
ahmad |
77894 |
# so that the demos don't fail to build |
114 |
|
|
BuildRequires: shared-mime-info |
115 |
ahmad |
6682 |
%if !%{enable_bootstrap} |
116 |
|
|
Suggests: xdg-user-dirs-gtk |
117 |
dmorgan |
118944 |
Suggests: oxygen-gtk |
118 |
ahmad |
6682 |
%endif |
119 |
|
|
Requires: %{libname} = %{version} |
120 |
|
|
Provides: %{pkgname}2 = %{version}-%{release} |
121 |
|
|
Obsoletes: %{pkgname}2 |
122 |
|
|
Provides: gail = %version-%release |
123 |
|
|
Obsoletes: gail |
124 |
|
|
|
125 |
|
|
%description |
126 |
|
|
The gtk+ package contains the GIMP ToolKit (GTK+), a library for creating |
127 |
|
|
graphical user interfaces for the X Window System. GTK+ was originally |
128 |
|
|
written for the GIMP (GNU Image Manipulation Program) image processing |
129 |
|
|
program, but is now used by several other programs as well. |
130 |
|
|
|
131 |
|
|
If you are planning on using the GIMP or another program that uses GTK+, |
132 |
|
|
you'll need to have the gtk+ package installed. |
133 |
|
|
|
134 |
dmorgan |
119790 |
|
135 |
|
|
%post |
136 |
|
|
if [ -d %{_datadir}/icons ]; then |
137 |
|
|
for i in `/bin/ls %{_datadir}/icons` ; do |
138 |
|
|
[ -d "%{_datadir}/icons/$i" -a -e "%{_datadir}/icons/$i/icon-theme.cache" -a -e "%{_datadir}/icons/$i/index.theme" ] && gtk-update-icon-cache --force --quiet %{_datadir}/icons/$i |
139 |
|
|
done |
140 |
|
|
exit 0 |
141 |
|
|
fi |
142 |
|
|
|
143 |
|
|
%files -f gtk20.lang |
144 |
|
|
%defattr(-, root, root) |
145 |
|
|
%doc README |
146 |
|
|
%{_bindir}/gtk-query-immodules-%{api_version} |
147 |
|
|
%{_bindir}/gtk-update-icon-cache |
148 |
|
|
%{_datadir}/themes |
149 |
|
|
%dir %{_sysconfdir}/gtk-%{api_version} |
150 |
|
|
%config(noreplace) %{_sysconfdir}/gtk-%{api_version}/im-multipress.conf |
151 |
|
|
|
152 |
|
|
#-------------------------------------------------------------------- |
153 |
|
|
|
154 |
ahmad |
6682 |
%package -n %{libname} |
155 |
|
|
Summary: %{summary} |
156 |
|
|
Group: %{group} |
157 |
|
|
Obsoletes: lib%{pkgname}2 |
158 |
|
|
Provides: lib%{pkgname}2 = %{version}-%{release} |
159 |
|
|
Provides: lib%{name} = %{version}-%{release} |
160 |
|
|
Provides: gtk2 = %{version}-%{release} |
161 |
|
|
Requires: libglib2.0 >= %{req_glib_version} |
162 |
|
|
Requires: libpango1.0 >= %{req_pango_version} |
163 |
|
|
Requires(post): %{libname_x11} = %{version} |
164 |
|
|
%if !%{enable_bootstrap} |
165 |
|
|
Suggests: %{_lib}ia_ora-gnome |
166 |
|
|
%endif |
167 |
|
|
|
168 |
|
|
%description -n %{libname} |
169 |
|
|
This package contains the library needed to run programs dynamically |
170 |
|
|
linked with gtk+. |
171 |
|
|
|
172 |
dmorgan |
119802 |
%post -n %{libname} |
173 |
|
|
if [ "$1" = "2" ]; then |
174 |
|
|
if [ -f %{_sysconfdir}/gtk-%{api_version}/gtk.immodules ]; then |
175 |
|
|
rm -f %{_sysconfdir}/gtk-%{api_version}/gtk.immodules |
176 |
|
|
fi |
177 |
|
|
fi |
178 |
|
|
|
179 |
|
|
%{_libdir}/gtk-%{api_version}/bin/gtk-query-immodules-%{api_version} > %{_sysconfdir}/gtk-%{api_version}/gtk.immodules.%{_lib} |
180 |
|
|
|
181 |
dmorgan |
119790 |
%files -n %{libname} |
182 |
|
|
%defattr(-, root, root) |
183 |
|
|
%doc README |
184 |
|
|
%ghost %verify (not md5 mtime size) %config(noreplace) %{_sysconfdir}/gtk-%{api_version}/gtk.immodules.%{_lib} |
185 |
|
|
%dir %{_libdir}/gtk-%{api_version} |
186 |
|
|
%dir %{_libdir}/gtk-%{api_version}/bin |
187 |
|
|
%{_libdir}/gtk-%{api_version}/bin/gtk-query-immodules-%{api_version} |
188 |
|
|
%dir %{_libdir}/gtk-%{api_version}/modules |
189 |
|
|
%dir %{_libdir}/gtk-%{api_version}/%{binary_version}.* |
190 |
|
|
%dir %{_libdir}/gtk-%{api_version}/%{binary_version}.*/immodules |
191 |
|
|
%{_libdir}/gtk-%{api_version}/%{binary_version}.*/immodules/im-am-et.so |
192 |
|
|
%{_libdir}/gtk-%{api_version}/%{binary_version}.*/immodules/im-cedilla.so |
193 |
|
|
%{_libdir}/gtk-%{api_version}/%{binary_version}.*/immodules/im-cyrillic-translit.so |
194 |
|
|
%{_libdir}/gtk-%{api_version}/%{binary_version}.*/immodules/im-inuktitut.so |
195 |
|
|
%{_libdir}/gtk-%{api_version}/%{binary_version}.*/immodules/im-ipa.so |
196 |
|
|
%{_libdir}/gtk-%{api_version}/%{binary_version}.*/immodules/im-multipress.so |
197 |
|
|
%{_libdir}/gtk-%{api_version}/%{binary_version}.*/immodules/im-thai.so |
198 |
|
|
%{_libdir}/gtk-%{api_version}/%{binary_version}.*/immodules/im-ti-er.so |
199 |
|
|
%{_libdir}/gtk-%{api_version}/%{binary_version}.*/immodules/im-ti-et.so |
200 |
|
|
%{_libdir}/gtk-%{api_version}/%{binary_version}.*/immodules/im-viqr.so |
201 |
|
|
%{_libdir}/gtk-%{api_version}/%{binary_version}.*/immodules/im-xim.so |
202 |
|
|
%{_libdir}/gtk-%{api_version}/%{binary_version}.*/immodules/im-tamilvp-tsc.so |
203 |
|
|
%{_libdir}/gtk-%{api_version}/%{binary_version}.*/immodules/im-tamilvp-uni.so |
204 |
|
|
%{_libdir}/gtk-%{api_version}/%{binary_version}.*/immodules/im-telex.so |
205 |
|
|
%{_libdir}/gtk-%{api_version}/%{binary_version}.*/immodules/im-vni.so |
206 |
|
|
%dir %{_libdir}/gtk-%{api_version}/%{binary_version}.*/engines |
207 |
|
|
%{_libdir}/gtk-%{api_version}/%{binary_version}.*/engines/*.so |
208 |
|
|
%{_libdir}/gtk-%{api_version}/%{binary_version}.*/printbackends/*.so |
209 |
|
|
|
210 |
|
|
#-------------------------------------------------------------------- |
211 |
|
|
|
212 |
ahmad |
6682 |
%package -n %{develname} |
213 |
|
|
Summary: Development files for GTK+ (GIMP ToolKit) applications |
214 |
|
|
Group: Development/GNOME and GTK+ |
215 |
|
|
Obsoletes: %{libname_x11}-devel |
216 |
|
|
Provides: %{libname_x11}-devel = %{version}-%{release} |
217 |
|
|
Provides: gtk2-devel = %{version}-%{release} |
218 |
|
|
Obsoletes: %{pkgname}2-devel |
219 |
|
|
Obsoletes: lib%{pkgname}2-devel |
220 |
|
|
Obsoletes: %mklibname -d %{pkgname} 2.0 0 |
221 |
|
|
Provides: %{pkgname}2-devel = %{version}-%{release} |
222 |
|
|
Provides: lib%{pkgname}2-devel = %{version}-%{release} |
223 |
|
|
Provides: lib%{pkgname}%{api_version}-devel = %{version}-%{release} |
224 |
|
|
Provides: %{libname}-devel = %{version}-%{release} |
225 |
|
|
Provides: lib%{pkgname}-x11-%{api_version}-devel = %{version}-%{release} |
226 |
|
|
Requires: %{libname} = %{version} |
227 |
|
|
Requires: %{libname_x11} = %{version} |
228 |
|
|
Requires: libgdk_pixbuf2.0-devel >= %req_gdk_pixbuf_version |
229 |
|
|
Requires: libatk1.0-devel >= %{req_atk_version} |
230 |
|
|
Requires: libpango1.0-devel >= %{req_pango_version} |
231 |
|
|
|
232 |
|
|
|
233 |
|
|
%description -n %{develname} |
234 |
|
|
The libgtk+-devel package contains the static libraries and header files |
235 |
|
|
needed for developing GTK+ (GIMP ToolKit) applications. The libgtk+-devel |
236 |
|
|
package contains GDK (the General Drawing Kit, which simplifies the interface |
237 |
|
|
for writing GTK+ widgets and using GTK+ widgets in applications), and GTK+ |
238 |
|
|
(the widget set). |
239 |
|
|
|
240 |
dmorgan |
119790 |
%files -n %develname |
241 |
|
|
%defattr(-, root, root) |
242 |
|
|
%doc docs/*.txt AUTHORS ChangeLog NEWS* README* |
243 |
|
|
%doc %{_datadir}/gtk-doc/html/gdk |
244 |
|
|
%doc %{_datadir}/gtk-doc/html/gtk |
245 |
|
|
%{_bindir}/gtk-demo |
246 |
|
|
%_bindir/gtk-builder-convert |
247 |
|
|
%{_datadir}/aclocal/* |
248 |
|
|
%{_datadir}/gtk-%{api_version} |
249 |
|
|
%{_includedir}/gtk-unix-print-%{api_version}/ |
250 |
|
|
%{_includedir}/gtk-%{api_version}/gdk |
251 |
|
|
%{_includedir}/gtk-%{api_version}/gtk |
252 |
|
|
%{_libdir}/gtk-%{api_version}/include |
253 |
|
|
%{_libdir}/pkgconfig/gdk-%{api_version}.pc |
254 |
|
|
%{_libdir}/pkgconfig/gtk+-%{api_version}.pc |
255 |
|
|
%{_libdir}/pkgconfig/gtk+-unix-print-%{api_version}.pc |
256 |
|
|
%{_libdir}/*x11*.so |
257 |
|
|
%_datadir/gir-1.0/Gdk-2.0.gir |
258 |
|
|
%_datadir/gir-1.0/GdkX11-2.0.gir |
259 |
|
|
%_datadir/gir-1.0/Gtk-2.0.gir |
260 |
|
|
%{_libdir}/pkgconfig/*x11* |
261 |
ahmad |
6682 |
|
262 |
dmorgan |
119790 |
#-------------------------------------------------------------------- |
263 |
|
|
|
264 |
ahmad |
6682 |
%package -n %{libname_x11} |
265 |
|
|
Summary: X11 backend of The GIMP ToolKit (GTK+) |
266 |
|
|
Group: System/Libraries |
267 |
|
|
Provides: lib%{pkgname}-x11-%{api_version} = %{version}-%{release} |
268 |
|
|
Provides: %{name}-backend = %{version}-%{release} |
269 |
|
|
Requires: %{libname} = %{version} |
270 |
|
|
Requires: %{name} >= %{version}-%{release} |
271 |
ahmad |
77866 |
Requires: libatk1.0 >= %{req_atk_version} |
272 |
ahmad |
6682 |
Conflicts: gir-repository < 0.6.5-4 |
273 |
|
|
|
274 |
|
|
%description -n %{libname_x11} |
275 |
|
|
This package contains the X11 version of library needed to run |
276 |
|
|
programs dynamically linked with gtk+. |
277 |
|
|
|
278 |
dmorgan |
119790 |
%files -n %{libname_x11} |
279 |
|
|
%defattr(-, root, root) |
280 |
|
|
%{_libdir}/*x11*.so.* |
281 |
|
|
|
282 |
|
|
#-------------------------------------------------------------------- |
283 |
|
|
|
284 |
ahmad |
6682 |
%package -n %{gail_libname} |
285 |
|
|
Summary: GNOME Accessibility Implementation Library |
286 |
|
|
Group: System/Libraries |
287 |
|
|
Provides: libgail = %{version}-%{release} |
288 |
|
|
|
289 |
|
|
%description -n %{gail_libname} |
290 |
|
|
Gail is the GNOME Accessibility Implementation Library |
291 |
|
|
|
292 |
dmorgan |
119790 |
%files -n %gail_libname |
293 |
|
|
%defattr(-,root,root) |
294 |
|
|
%{_libdir}/libgailutil.so.%{gail_major}* |
295 |
|
|
%{_libdir}/gtk-2.0/modules/libferret.so |
296 |
|
|
%{_libdir}/gtk-2.0/modules/libgail.so |
297 |
|
|
|
298 |
|
|
#-------------------------------------------------------------------- |
299 |
|
|
|
300 |
ahmad |
6682 |
%package -n %gaildevelname |
301 |
|
|
Summary: Static libraries, include files for GAIL |
302 |
|
|
Group: Development/GNOME and GTK+ |
303 |
|
|
Provides: gail-devel = %{version}-%{release} |
304 |
|
|
Provides: libgail-devel = %{version}-%{release} |
305 |
|
|
Requires: %{gail_libname} = %{version} |
306 |
|
|
Conflicts: %{_lib}gail17-devel |
307 |
|
|
Obsoletes: %mklibname -d gail 18 |
308 |
|
|
|
309 |
|
|
%description -n %gaildevelname |
310 |
|
|
Gail is the GNOME Accessibility Implementation Library |
311 |
|
|
|
312 |
dmorgan |
119790 |
%files -n %gaildevelname |
313 |
|
|
%defattr(-,root,root) |
314 |
|
|
%{_datadir}/gtk-doc/html/gail-libgail-util |
315 |
|
|
%{_libdir}/libgailutil.so |
316 |
|
|
%{_includedir}/gail-1.0 |
317 |
|
|
%{_libdir}/pkgconfig/gail.pc |
318 |
|
|
|
319 |
|
|
#-------------------------------------------------------------------- |
320 |
|
|
|
321 |
dmorgan |
119798 |
%package -n %{girname} |
322 |
|
|
Summary: GObject Introspection interface description for %name |
323 |
|
|
Group: System/Libraries |
324 |
wally |
122408 |
Requires: %{libname} = %{version}-%{release} |
325 |
|
|
Requires: %{libname_x11} = %{version}-%{release} |
326 |
wally |
121215 |
Conflicts: %{mklibname %{name}-gir 2.0} < 2.24.5-5 |
327 |
|
|
Conflicts: %{mklibname %{pkgname}-x11- 2.0 0} < 2.24.5-3 |
328 |
dmorgan |
119798 |
|
329 |
|
|
%description -n %{girname} |
330 |
|
|
GObject Introspection interface description for %name. |
331 |
|
|
|
332 |
|
|
%files -n %{girname} |
333 |
dmorgan |
119810 |
%_libdir/girepository-1.0/Gdk-%{gi_major}.typelib |
334 |
|
|
%_libdir/girepository-1.0/GdkX11-%{gi_major}.typelib |
335 |
|
|
%_libdir/girepository-1.0/Gtk-%{gi_major}.typelib |
336 |
dmorgan |
119798 |
|
337 |
|
|
#-------------------------------------------------------------------- |
338 |
|
|
|
339 |
ahmad |
6682 |
%prep |
340 |
|
|
%setup -n %{pkgname}-%{version} -q |
341 |
|
|
%patch4 -p1 -b .extra_im |
342 |
|
|
%patch5 -p1 -b .fileselectorfallback |
343 |
|
|
%patch12 -p1 -b .defaulttheme |
344 |
dmorgan |
7389 |
%if !%{enable_bootstrap} |
345 |
ahmad |
6682 |
#gw disabled for bootstrapping |
346 |
|
|
%patch13 -p1 -b .lib64 |
347 |
dmorgan |
7389 |
%endif |
348 |
ahmad |
6682 |
#patch15 -p1 -b .fixnautiluscrash |
349 |
|
|
%patch18 -p1 -b .fresh-tooltips |
350 |
|
|
#%patch19 -p1 -b .tooltip-positioning |
351 |
|
|
%patch20 -p1 -b .window-dragging |
352 |
|
|
%patch21 -p1 -b .icon-padding |
353 |
|
|
|
354 |
|
|
#needed by patches 4 & 13 |
355 |
dmorgan |
7456 |
%if !%{enable_bootstrap} |
356 |
ahmad |
6682 |
#gw disabled for bootstrapping |
357 |
fwang |
110239 |
mkdir -p m4 |
358 |
ahmad |
6682 |
autoreconf -fi |
359 |
dmorgan |
7456 |
%endif |
360 |
ahmad |
6682 |
|
361 |
|
|
%build |
362 |
|
|
%ifarch ppc64 |
363 |
|
|
export CFLAGS="$RPM_OPT_FLAGS -mminimal-toc" |
364 |
|
|
%endif |
365 |
|
|
|
366 |
|
|
# Build X11 backend |
367 |
|
|
#[ -d X11-build ] || mkdir X11-build |
368 |
|
|
#cd X11-build |
369 |
|
|
|
370 |
|
|
# fix crash in nautilus (GNOME bug #596977) |
371 |
|
|
export CFLAGS=`echo $RPM_OPT_FLAGS | sed -e 's/-fomit-frame-pointer//g'` |
372 |
|
|
|
373 |
|
|
#CONFIGURE_TOP=.. |
374 |
|
|
export CPPFLAGS="-DGTK_COMPILATION" |
375 |
|
|
# --with-included-immodules=yes \ |
376 |
|
|
%configure2_5x --enable-xinerama \ |
377 |
|
|
--with-xinput=xfree \ |
378 |
|
|
%if !%enable_gtkdoc |
379 |
|
|
--enable-gtk-doc=no |
380 |
|
|
%endif |
381 |
|
|
|
382 |
|
|
%make |
383 |
|
|
|
384 |
|
|
%check |
385 |
|
|
%if %enable_tests |
386 |
|
|
#cd X11-build |
387 |
|
|
XDISPLAY=$(i=1; while [ -f /tmp/.X$i-lock ]; do i=$(($i+1)); done; echo $i) |
388 |
|
|
%{_bindir}/Xvfb :$XDISPLAY & |
389 |
|
|
export DISPLAY=:$XDISPLAY |
390 |
|
|
make check |
391 |
|
|
kill $(cat /tmp/.X$XDISPLAY-lock) ||: |
392 |
|
|
#cd .. |
393 |
|
|
%endif |
394 |
|
|
|
395 |
|
|
%install |
396 |
|
|
rm -rf $RPM_BUILD_ROOT |
397 |
|
|
|
398 |
|
|
#cd X11-build |
399 |
|
|
%makeinstall_std mandir=%{_mandir} RUN_QUERY_IMMODULES_TEST=false RUN_QUERY_LOADER_TEST=false |
400 |
|
|
|
401 |
|
|
|
402 |
|
|
#cd .. |
403 |
|
|
|
404 |
|
|
mkdir -p $RPM_BUILD_ROOT%{_sysconfdir}/gtk-%{api_version} |
405 |
|
|
touch $RPM_BUILD_ROOT%{_sysconfdir}/gtk-%{api_version}/gtk.immodules.%{_lib} |
406 |
|
|
mkdir -p $RPM_BUILD_ROOT%{_libdir}/gtk-%{api_version}/modules |
407 |
|
|
|
408 |
|
|
# handle biarch packages |
409 |
|
|
progs="gtk-query-immodules-%{api_version}" |
410 |
|
|
mkdir -p $RPM_BUILD_ROOT%{_libdir}/gtk-%{api_version}/bin |
411 |
|
|
for f in $progs; do |
412 |
|
|
mv -f $RPM_BUILD_ROOT%{_bindir}/$f $RPM_BUILD_ROOT%{_libdir}/gtk-%{api_version}/bin/ |
413 |
|
|
cat > $RPM_BUILD_ROOT%{_bindir}/$f << EOF |
414 |
|
|
#!/bin/sh |
415 |
|
|
lib=%{_lib} |
416 |
|
|
case ":\$1:" in |
417 |
|
|
:lib*:) lib="\$1"; shift 1;; |
418 |
|
|
esac |
419 |
|
|
exec %{_prefix}/\$lib/gtk-%{api_version}/bin/$f \${1+"\$@"} |
420 |
|
|
EOF |
421 |
|
|
chmod +x $RPM_BUILD_ROOT%{_bindir}/$f |
422 |
|
|
done |
423 |
|
|
|
424 |
|
|
%{find_lang} gtk20 |
425 |
|
|
%find_lang gtk20-properties |
426 |
|
|
cat gtk20-properties.lang >> gtk20.lang |
427 |
|
|
|
428 |
|
|
#remove not packaged files |
429 |
fwang |
142171 |
find %{buildroot} -name *.la | xargs rm |