diff options
author | Ross Burton <ross.burton@intel.com> | 2014-02-07 11:06:50 +0000 |
---|---|---|
committer | Richard Purdie <richard.purdie@linuxfoundation.org> | 2014-02-09 09:40:01 +0000 |
commit | ed2f7a2bf6596867cef92dbbfb5f9e5d842b5366 (patch) | |
tree | 041f08a57fa499364153308b7a26e6d1f96b8cbf /meta/recipes-gnome | |
parent | 3ec94b6013dd0cafe608a1d4ec5958111588fef6 (diff) | |
download | poky-ed2f7a2bf6596867cef92dbbfb5f9e5d842b5366.tar.gz |
gdk-pixbuf: enable ptest
(From OE-Core rev: b78d9b2f059f3f87c474bba8eb6258bb7299cabc)
Signed-off-by: Ross Burton <ross.burton@intel.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
Diffstat (limited to 'meta/recipes-gnome')
-rw-r--r-- | meta/recipes-gnome/gdk-pixbuf/gdk-pixbuf/run-ptest | 3 | ||||
-rw-r--r-- | meta/recipes-gnome/gdk-pixbuf/gdk-pixbuf/tests-check.patch | 465 | ||||
-rw-r--r-- | meta/recipes-gnome/gdk-pixbuf/gdk-pixbuf_2.30.3.bb | 17 |
3 files changed, 483 insertions, 2 deletions
diff --git a/meta/recipes-gnome/gdk-pixbuf/gdk-pixbuf/run-ptest b/meta/recipes-gnome/gdk-pixbuf/gdk-pixbuf/run-ptest new file mode 100644 index 0000000000..8f9072386e --- /dev/null +++ b/meta/recipes-gnome/gdk-pixbuf/gdk-pixbuf/run-ptest | |||
@@ -0,0 +1,3 @@ | |||
1 | #! /bin/sh | ||
2 | |||
3 | gnome-desktop-testing-runner gdk-pixbuf | ||
diff --git a/meta/recipes-gnome/gdk-pixbuf/gdk-pixbuf/tests-check.patch b/meta/recipes-gnome/gdk-pixbuf/gdk-pixbuf/tests-check.patch new file mode 100644 index 0000000000..31f33689c3 --- /dev/null +++ b/meta/recipes-gnome/gdk-pixbuf/gdk-pixbuf/tests-check.patch | |||
@@ -0,0 +1,465 @@ | |||
1 | Upstream-Status: Backport | ||
2 | Signed-off-by: Ross Burton <ross.burton@intel.com> | ||
3 | |||
4 | From 9fa240c1ad5a815d63d8aa9126954152c2607f2e Mon Sep 17 00:00:00 2001 | ||
5 | From: Matthias Clasen <mclasen@redhat.com> | ||
6 | Date: Sat, 25 Jan 2014 21:29:34 +0000 | ||
7 | Subject: Make testsuite robust against disabled formats | ||
8 | |||
9 | Skip tests if their file format is not supported by the | ||
10 | available loaders. | ||
11 | |||
12 | https://bugzilla.gnome.org/show_bug.cgi?id=722651 | ||
13 | --- | ||
14 | diff --git a/tests/Makefile.am b/tests/Makefile.am | ||
15 | index de3442e..80840c2 100644 | ||
16 | --- a/tests/Makefile.am | ||
17 | +++ b/tests/Makefile.am | ||
18 | @@ -42,17 +42,57 @@ dist_installed_test_data = \ | ||
19 | icc-profile.png \ | ||
20 | $(wildcard $(srcdir)/test-images/*) | ||
21 | |||
22 | +pixbuf_icc_SOURCES = \ | ||
23 | + pixbuf-icc.c \ | ||
24 | + test-common.c \ | ||
25 | + test-common.h \ | ||
26 | + $(NULL) | ||
27 | + | ||
28 | +pixbuf_scale_SOURCES = \ | ||
29 | + pixbuf-scale.c \ | ||
30 | + test-common.c \ | ||
31 | + test-common.h \ | ||
32 | + $(NULL) | ||
33 | + | ||
34 | +pixbuf_stream_SOURCES = \ | ||
35 | + pixbuf-stream.c \ | ||
36 | + test-common.c \ | ||
37 | + test-common.h \ | ||
38 | + $(NULL) | ||
39 | + | ||
40 | +pixbuf_threads_SOURCES = \ | ||
41 | + pixbuf-threads.c \ | ||
42 | + test-common.c \ | ||
43 | + test-common.h \ | ||
44 | + $(NULL) | ||
45 | + | ||
46 | +pixbuf_icon_serialize_SOURCES = \ | ||
47 | + pixbuf-icon-serialize.c \ | ||
48 | + test-common.c \ | ||
49 | + test-common.h \ | ||
50 | + $(NULL) | ||
51 | + | ||
52 | +pixbuf_save_SOURCES = \ | ||
53 | + pixbuf-save.c \ | ||
54 | + test-common.c \ | ||
55 | + test-common.h \ | ||
56 | + $(NULL) | ||
57 | + | ||
58 | pixbuf_resource_SOURCES = \ | ||
59 | pixbuf-resource.c \ | ||
60 | + test-common.c \ | ||
61 | + test-common.h \ | ||
62 | resources.h \ | ||
63 | - resources.c | ||
64 | + resources.c \ | ||
65 | + $(NULL) | ||
66 | |||
67 | BUILT_SOURCES += resources.h resources.c | ||
68 | DISTCLEANFILES += \ | ||
69 | resources.h resources.c \ | ||
70 | pixbuf-save-options \ | ||
71 | pixbuf-randomly-modified-image \ | ||
72 | - pixbuf-save-roundtrip | ||
73 | + pixbuf-save-roundtrip \ | ||
74 | + $(NULL) | ||
75 | |||
76 | EXTRA_DIST += resources.gresource.xml | ||
77 | TESTS_ENVIRONMENT += GDK_PIXBUF_MODULE_FILE=$(top_builddir)/gdk-pixbuf/loaders.cache | ||
78 | diff --git a/tests/pixbuf-icc.c b/tests/pixbuf-icc.c | ||
79 | index 9cb9c90..3b95b09 100644 | ||
80 | --- a/tests/pixbuf-icc.c | ||
81 | +++ b/tests/pixbuf-icc.c | ||
82 | @@ -22,6 +22,7 @@ | ||
83 | |||
84 | #include "config.h" | ||
85 | #include "gdk-pixbuf/gdk-pixbuf.h" | ||
86 | +#include "test-common.h" | ||
87 | |||
88 | static void | ||
89 | test_incremental (gconstpointer data) | ||
90 | @@ -34,7 +35,12 @@ test_incremental (gconstpointer data) | ||
91 | gchar *contents; | ||
92 | gsize size; | ||
93 | |||
94 | - | ||
95 | + if (!format_supported (filename)) | ||
96 | + { | ||
97 | + g_test_skip ("format not supported"); | ||
98 | + return; | ||
99 | + } | ||
100 | + | ||
101 | g_file_get_contents (g_test_get_filename (G_TEST_DIST, filename, NULL), &contents, &size, &error); | ||
102 | g_assert_no_error (error); | ||
103 | |||
104 | @@ -62,6 +68,12 @@ test_nonincremental (gconstpointer data) | ||
105 | GdkPixbuf *pixbuf; | ||
106 | const gchar *profile; | ||
107 | |||
108 | + if (!format_supported (filename)) | ||
109 | + { | ||
110 | + g_test_skip ("format not supported"); | ||
111 | + return; | ||
112 | + } | ||
113 | + | ||
114 | pixbuf = gdk_pixbuf_new_from_file (g_test_get_filename (G_TEST_DIST, filename, NULL), &error); | ||
115 | g_assert_no_error (error); | ||
116 | |||
117 | diff --git a/tests/pixbuf-icon-serialize.c b/tests/pixbuf-icon-serialize.c | ||
118 | index 20bf6e1..880c654 100644 | ||
119 | --- a/tests/pixbuf-icon-serialize.c | ||
120 | +++ b/tests/pixbuf-icon-serialize.c | ||
121 | @@ -1,5 +1,6 @@ | ||
122 | #include "config.h" | ||
123 | #include "gdk-pixbuf/gdk-pixbuf.h" | ||
124 | +#include "test-common.h" | ||
125 | #include <string.h> | ||
126 | #include <glib.h> | ||
127 | |||
128 | @@ -13,6 +14,12 @@ test_serialize (void) | ||
129 | GIcon *icon; | ||
130 | GInputStream *stream; | ||
131 | |||
132 | + if (!format_supported ("png")) | ||
133 | + { | ||
134 | + g_test_skip ("format not supported"); | ||
135 | + return; | ||
136 | + } | ||
137 | + | ||
138 | pixbuf = gdk_pixbuf_new_from_file (g_test_get_filename (G_TEST_DIST, "test-image.png", NULL), &error); | ||
139 | g_assert_no_error (error); | ||
140 | g_assert (pixbuf != NULL); | ||
141 | diff --git a/tests/pixbuf-resource.c b/tests/pixbuf-resource.c | ||
142 | index a747bca..aa0bed8 100644 | ||
143 | --- a/tests/pixbuf-resource.c | ||
144 | +++ b/tests/pixbuf-resource.c | ||
145 | @@ -22,6 +22,7 @@ | ||
146 | |||
147 | #include "config.h" | ||
148 | #include "gdk-pixbuf/gdk-pixbuf.h" | ||
149 | +#include "test-common.h" | ||
150 | #include <string.h> | ||
151 | |||
152 | #define compare_option(p1, p2, key) \ | ||
153 | @@ -77,6 +78,12 @@ test_resource (void) | ||
154 | GError *error = NULL; | ||
155 | GdkPixbuf *pixbuf, *ref; | ||
156 | |||
157 | + if (!format_supported ("png")) | ||
158 | + { | ||
159 | + g_test_skip ("format not supported"); | ||
160 | + return; | ||
161 | + } | ||
162 | + | ||
163 | path = g_test_get_filename (G_TEST_DIST, "icc-profile.png", NULL); | ||
164 | ref = gdk_pixbuf_new_from_file (path, &error); | ||
165 | g_assert_no_error (error); | ||
166 | @@ -111,6 +118,12 @@ test_resource_at_scale (void) | ||
167 | GError *error = NULL; | ||
168 | GdkPixbuf *pixbuf, *ref; | ||
169 | |||
170 | + if (!format_supported ("png")) | ||
171 | + { | ||
172 | + g_test_skip ("format not supported"); | ||
173 | + return; | ||
174 | + } | ||
175 | + | ||
176 | path = g_test_get_filename (G_TEST_DIST, "icc-profile.png", NULL); | ||
177 | ref = gdk_pixbuf_new_from_file_at_scale (path, 40, 10, FALSE, &error); | ||
178 | g_assert_no_error (error); | ||
179 | diff --git a/tests/pixbuf-save.c b/tests/pixbuf-save.c | ||
180 | index f7df29b..78ab288 100644 | ||
181 | --- a/tests/pixbuf-save.c | ||
182 | +++ b/tests/pixbuf-save.c | ||
183 | @@ -21,6 +21,7 @@ | ||
184 | */ | ||
185 | |||
186 | #include "gdk-pixbuf/gdk-pixbuf.h" | ||
187 | +#include "test-common.h" | ||
188 | #include <string.h> | ||
189 | |||
190 | #define compare_option(p1, p2, key) \ | ||
191 | @@ -76,6 +77,12 @@ test_save_roundtrip (void) | ||
192 | GdkPixbuf *ref; | ||
193 | GdkPixbuf *pixbuf; | ||
194 | |||
195 | + if (!format_supported ("png")) | ||
196 | + { | ||
197 | + g_test_skip ("format not supported"); | ||
198 | + return; | ||
199 | + } | ||
200 | + | ||
201 | ref = gdk_pixbuf_new_from_file (g_test_get_filename (G_TEST_DIST, "test-image.png", NULL), &error); | ||
202 | g_assert_no_error (error); | ||
203 | |||
204 | @@ -98,6 +105,12 @@ test_save_options (void) | ||
205 | GdkPixbuf *pixbuf; | ||
206 | GError *error = NULL; | ||
207 | |||
208 | + if (!format_supported ("png")) | ||
209 | + { | ||
210 | + g_test_skip ("format not supported"); | ||
211 | + return; | ||
212 | + } | ||
213 | + | ||
214 | ref = gdk_pixbuf_new (GDK_COLORSPACE_RGB, FALSE, 8, 10, 10); | ||
215 | gdk_pixbuf_fill (ref, 0xff00ff00); | ||
216 | |||
217 | diff --git a/tests/pixbuf-scale.c b/tests/pixbuf-scale.c | ||
218 | index 4fd9fd5..d57e56a 100644 | ||
219 | --- a/tests/pixbuf-scale.c | ||
220 | +++ b/tests/pixbuf-scale.c | ||
221 | @@ -22,6 +22,7 @@ | ||
222 | |||
223 | #include "config.h" | ||
224 | #include "gdk-pixbuf/gdk-pixbuf.h" | ||
225 | +#include "test-common.h" | ||
226 | |||
227 | static void | ||
228 | test_scale (gconstpointer data) | ||
229 | @@ -33,6 +34,12 @@ test_scale (gconstpointer data) | ||
230 | GdkPixbuf *pixbuf; | ||
231 | gint width, height; | ||
232 | |||
233 | + if (!format_supported (filename)) | ||
234 | + { | ||
235 | + g_test_skip ("format not supported"); | ||
236 | + return; | ||
237 | + } | ||
238 | + | ||
239 | path = g_test_get_filename (G_TEST_DIST, filename, NULL); | ||
240 | ref = gdk_pixbuf_new_from_file (path, &error); | ||
241 | g_assert_no_error (error); | ||
242 | diff --git a/tests/pixbuf-stream.c b/tests/pixbuf-stream.c | ||
243 | index 0c2cebe..d66ce3e 100644 | ||
244 | --- a/tests/pixbuf-stream.c | ||
245 | +++ b/tests/pixbuf-stream.c | ||
246 | @@ -22,6 +22,7 @@ | ||
247 | |||
248 | #include "config.h" | ||
249 | #include "gdk-pixbuf/gdk-pixbuf.h" | ||
250 | +#include "test-common.h" | ||
251 | #include <string.h> | ||
252 | |||
253 | #define compare_option(p1, p2, key) \ | ||
254 | @@ -71,6 +72,12 @@ test_stream (gconstpointer data) | ||
255 | GFile *file; | ||
256 | GInputStream *stream; | ||
257 | |||
258 | + if (!format_supported (filename)) | ||
259 | + { | ||
260 | + g_test_skip ("format not supported"); | ||
261 | + return; | ||
262 | + } | ||
263 | + | ||
264 | path = g_test_get_filename (G_TEST_DIST, filename, NULL); | ||
265 | ref = gdk_pixbuf_new_from_file (path, &error); | ||
266 | g_assert_no_error (error); | ||
267 | @@ -116,6 +123,12 @@ test_stream_async (gconstpointer data) | ||
268 | gsize size; | ||
269 | GInputStream *stream; | ||
270 | |||
271 | + if (!format_supported (filename)) | ||
272 | + { | ||
273 | + g_test_skip ("format not supported"); | ||
274 | + return; | ||
275 | + } | ||
276 | + | ||
277 | path = g_test_get_filename (G_TEST_DIST, filename, NULL); | ||
278 | ref = gdk_pixbuf_new_from_file (path, &error); | ||
279 | g_assert_no_error (error); | ||
280 | @@ -138,6 +151,12 @@ test_stream_at_scale (gconstpointer data) | ||
281 | GFile *file; | ||
282 | GInputStream *stream; | ||
283 | |||
284 | + if (!format_supported (filename)) | ||
285 | + { | ||
286 | + g_test_skip ("format not supported"); | ||
287 | + return; | ||
288 | + } | ||
289 | + | ||
290 | path = g_test_get_filename (G_TEST_DIST, filename, NULL); | ||
291 | ref = gdk_pixbuf_new_from_file_at_scale (path, 20, 30, TRUE, &error); | ||
292 | g_assert_no_error (error); | ||
293 | @@ -167,6 +186,12 @@ test_stream_at_scale_async (gconstpointer data) | ||
294 | gsize size; | ||
295 | GInputStream *stream; | ||
296 | |||
297 | + if (!format_supported (filename)) | ||
298 | + { | ||
299 | + g_test_skip ("format not supported"); | ||
300 | + return; | ||
301 | + } | ||
302 | + | ||
303 | path = g_test_get_filename (G_TEST_DIST, filename, NULL); | ||
304 | ref = gdk_pixbuf_new_from_file_at_scale (path, 40, 10, FALSE, &error); | ||
305 | g_assert_no_error (error); | ||
306 | diff --git a/tests/pixbuf-threads.c b/tests/pixbuf-threads.c | ||
307 | index 5eeb9dd..f2694fd 100644 | ||
308 | --- a/tests/pixbuf-threads.c | ||
309 | +++ b/tests/pixbuf-threads.c | ||
310 | @@ -18,7 +18,9 @@ | ||
311 | * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307, USA. | ||
312 | */ | ||
313 | |||
314 | +#include "config.h" | ||
315 | #include "gdk-pixbuf/gdk-pixbuf.h" | ||
316 | +#include "test-common.h" | ||
317 | |||
318 | static void | ||
319 | load_image (gpointer data, | ||
320 | @@ -71,15 +73,24 @@ test_threads (void) | ||
321 | |||
322 | for (i = 0; i < iterations; i++) | ||
323 | { | ||
324 | - g_thread_pool_push (pool, "valid_jpeg_test", NULL); | ||
325 | - g_thread_pool_push (pool, "valid_png_test", NULL); | ||
326 | - g_thread_pool_push (pool, "valid_gif_test", NULL); | ||
327 | - g_thread_pool_push (pool, "valid_bmp_test", NULL); | ||
328 | - g_thread_pool_push (pool, "valid_jpeg_progressive_test", NULL); | ||
329 | - g_thread_pool_push (pool, "valid_xpm_test", NULL); | ||
330 | - g_thread_pool_push (pool, "valid_ras_test", NULL); | ||
331 | - g_thread_pool_push (pool, "valid_tga_test", NULL); | ||
332 | - g_thread_pool_push (pool, "valid_tiff1_test", NULL); | ||
333 | + if (format_supported ("jpeg")) | ||
334 | + g_thread_pool_push (pool, "valid_jpeg_test", NULL); | ||
335 | + if (format_supported ("png")) | ||
336 | + g_thread_pool_push (pool, "valid_png_test", NULL); | ||
337 | + if (format_supported ("gif")) | ||
338 | + g_thread_pool_push (pool, "valid_gif_test", NULL); | ||
339 | + if (format_supported ("bmp")) | ||
340 | + g_thread_pool_push (pool, "valid_bmp_test", NULL); | ||
341 | + if (format_supported ("jpeg")) | ||
342 | + g_thread_pool_push (pool, "valid_jpeg_progressive_test", NULL); | ||
343 | + if (format_supported ("xpm")) | ||
344 | + g_thread_pool_push (pool, "valid_xpm_test", NULL); | ||
345 | + if (format_supported ("ras")) | ||
346 | + g_thread_pool_push (pool, "valid_ras_test", NULL); | ||
347 | + if (format_supported ("tga")) | ||
348 | + g_thread_pool_push (pool, "valid_tga_test", NULL); | ||
349 | + if (format_supported ("tiff")) | ||
350 | + g_thread_pool_push (pool, "valid_tiff1_test", NULL); | ||
351 | } | ||
352 | |||
353 | g_thread_pool_free (pool, FALSE, TRUE); | ||
354 | diff --git a/tests/test-common.c b/tests/test-common.c | ||
355 | new file mode 100644 | ||
356 | index 0000000..c7673e3 | ||
357 | --- /dev/null | ||
358 | +++ b/tests/test-common.c | ||
359 | @@ -0,0 +1,65 @@ | ||
360 | +/* -*- Mode: C; c-basic-offset: 2; -*- */ | ||
361 | +/* GdkPixbuf library - test loaders | ||
362 | + * | ||
363 | + * Copyright (C) 2014 Red Hat, Inc. | ||
364 | + * | ||
365 | + * This program is free software; you can redistribute it and/or modify | ||
366 | + * it under the terms of the GNU General Public License as published by | ||
367 | + * the Free Software Foundation; either version 2 of the License, or | ||
368 | + * (at your option) any later version. | ||
369 | + * | ||
370 | + * This program is distributed in the hope that it will be useful, | ||
371 | + * but WITHOUT ANY WARRANTY; without even the implied warranty of | ||
372 | + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the | ||
373 | + * GNU General Public License for more details. | ||
374 | + * | ||
375 | + * You should have received a copy of the GNU General Public License | ||
376 | + * along with this program; if not, write to the Free Software | ||
377 | + * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307, USA. | ||
378 | + * | ||
379 | + * Author: Matthias Clasen | ||
380 | + */ | ||
381 | + | ||
382 | +#include "config.h" | ||
383 | +#include "test-common.h" | ||
384 | +#include "gdk-pixbuf/gdk-pixbuf.h" | ||
385 | + | ||
386 | +#include <string.h> | ||
387 | + | ||
388 | +gboolean | ||
389 | +format_supported (const gchar *filename) | ||
390 | +{ | ||
391 | + const gchar *name = NULL; | ||
392 | + GSList *formats, *l; | ||
393 | + gboolean retval; | ||
394 | + const gchar *names[] = { "png", "jpeg", "bmp", "gif", "ras", | ||
395 | + "tga", "xpm", "xbm" }; | ||
396 | + gint i; | ||
397 | + | ||
398 | + for (i = 0; i < G_N_ELEMENTS (names); i++) | ||
399 | + { | ||
400 | + if (strstr (filename, names[i])) | ||
401 | + { | ||
402 | + name = names[i]; | ||
403 | + break; | ||
404 | + } | ||
405 | + } | ||
406 | + if (name == NULL) | ||
407 | + return FALSE; | ||
408 | + | ||
409 | + retval = FALSE; | ||
410 | + formats = gdk_pixbuf_get_formats (); | ||
411 | + for (l = formats; l; l = l->next) | ||
412 | + { | ||
413 | + GdkPixbufFormat *format = l->data; | ||
414 | + | ||
415 | + if (g_str_equal (gdk_pixbuf_format_get_name (format), name)) | ||
416 | + { | ||
417 | + retval = TRUE; | ||
418 | + break; | ||
419 | + } | ||
420 | + } | ||
421 | + g_slist_free (formats); | ||
422 | + | ||
423 | + return retval; | ||
424 | +} | ||
425 | diff --git a/tests/test-common.h b/tests/test-common.h | ||
426 | new file mode 100644 | ||
427 | index 0000000..32ff35a | ||
428 | --- /dev/null | ||
429 | +++ b/tests/test-common.h | ||
430 | @@ -0,0 +1,33 @@ | ||
431 | +/* -*- Mode: C; c-basic-offset: 2; -*- */ | ||
432 | +/* GdkPixbuf library - test loaders | ||
433 | + * | ||
434 | + * Copyright (C) 2014 Red Hat, Inc. | ||
435 | + * | ||
436 | + * This program is free software; you can redistribute it and/or modify | ||
437 | + * it under the terms of the GNU General Public License as published by | ||
438 | + * the Free Software Foundation; either version 2 of the License, or | ||
439 | + * (at your option) any later version. | ||
440 | + * | ||
441 | + * This program is distributed in the hope that it will be useful, | ||
442 | + * but WITHOUT ANY WARRANTY; without even the implied warranty of | ||
443 | + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the | ||
444 | + * GNU General Public License for more details. | ||
445 | + * | ||
446 | + * You should have received a copy of the GNU General Public License | ||
447 | + * along with this program; if not, write to the Free Software | ||
448 | + * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307, USA. | ||
449 | + * | ||
450 | + * Author: Matthias Clasen | ||
451 | + */ | ||
452 | + | ||
453 | +#ifndef __TEST_COMMON_H__ | ||
454 | + | ||
455 | +#include <glib.h> | ||
456 | + | ||
457 | +G_BEGIN_DECLS | ||
458 | + | ||
459 | +gboolean format_supported (const gchar *filename); | ||
460 | + | ||
461 | +G_END_DECLS | ||
462 | + | ||
463 | +#endif /* __TEST_COMMON_H__ */ | ||
464 | -- | ||
465 | cgit v0.9.2 \ No newline at end of file | ||
diff --git a/meta/recipes-gnome/gdk-pixbuf/gdk-pixbuf_2.30.3.bb b/meta/recipes-gnome/gdk-pixbuf/gdk-pixbuf_2.30.3.bb index 187af46a99..85a7b439de 100644 --- a/meta/recipes-gnome/gdk-pixbuf/gdk-pixbuf_2.30.3.bb +++ b/meta/recipes-gnome/gdk-pixbuf/gdk-pixbuf_2.30.3.bb | |||
@@ -16,12 +16,14 @@ MAJ_VER = "${@oe.utils.trim_version("${PV}", 2)}" | |||
16 | SRC_URI = "${GNOME_MIRROR}/${BPN}/${MAJ_VER}/${BPN}-${PV}.tar.xz \ | 16 | SRC_URI = "${GNOME_MIRROR}/${BPN}/${MAJ_VER}/${BPN}-${PV}.tar.xz \ |
17 | file://hardcoded_libtool.patch \ | 17 | file://hardcoded_libtool.patch \ |
18 | file://extending-libinstall-dependencies.patch \ | 18 | file://extending-libinstall-dependencies.patch \ |
19 | file://run-ptest \ | ||
20 | file://tests-check.patch \ | ||
19 | " | 21 | " |
20 | 22 | ||
21 | SRC_URI[md5sum] = "81161cc895eb43afd9ae7354b87e2261" | 23 | SRC_URI[md5sum] = "81161cc895eb43afd9ae7354b87e2261" |
22 | SRC_URI[sha256sum] = "c229c53f59573eab9410b53690a4b9db770312c80a4d84ecd6295aa894574494" | 24 | SRC_URI[sha256sum] = "c229c53f59573eab9410b53690a4b9db770312c80a4d84ecd6295aa894574494" |
23 | 25 | ||
24 | inherit autotools pkgconfig gettext pixbufcache | 26 | inherit autotools pkgconfig gettext pixbufcache ptest |
25 | 27 | ||
26 | LIBV = "2.10.0" | 28 | LIBV = "2.10.0" |
27 | 29 | ||
@@ -42,6 +44,7 @@ PACKAGECONFIG[x11] = "--with-x11,--without-x11,virtual/libx11" | |||
42 | 44 | ||
43 | EXTRA_OECONF = "\ | 45 | EXTRA_OECONF = "\ |
44 | --disable-introspection \ | 46 | --disable-introspection \ |
47 | ${@base_contains('DISTRO_FEATURES', 'ptest', '--enable-installed-tests', '--disable-installed-tests', d)} \ | ||
45 | " | 48 | " |
46 | 49 | ||
47 | PACKAGES =+ "${PN}-xlib" | 50 | PACKAGES =+ "${PN}-xlib" |
@@ -64,6 +67,11 @@ FILES_${PN}-dbg += " \ | |||
64 | ${libdir}/gdk-pixbuf-2.0/${LIBV}/loaders/.debug/* \ | 67 | ${libdir}/gdk-pixbuf-2.0/${LIBV}/loaders/.debug/* \ |
65 | " | 68 | " |
66 | 69 | ||
70 | FILES_${PN}-ptest += "${libdir}/gdk-pixbuf/installed-tests \ | ||
71 | ${datadir}/installed-tests/gdk-pixbuf" | ||
72 | |||
73 | RDEPENDS_${PN}-ptest += "gnome-desktop-testing" | ||
74 | |||
67 | PACKAGES_DYNAMIC += "^gdk-pixbuf-loader-.*" | 75 | PACKAGES_DYNAMIC += "^gdk-pixbuf-loader-.*" |
68 | PACKAGES_DYNAMIC_class-native = "" | 76 | PACKAGES_DYNAMIC_class-native = "" |
69 | 77 | ||
@@ -72,7 +80,12 @@ python populate_packages_prepend () { | |||
72 | 80 | ||
73 | loaders_root = d.expand('${libdir}/gdk-pixbuf-2.0/${LIBV}/loaders') | 81 | loaders_root = d.expand('${libdir}/gdk-pixbuf-2.0/${LIBV}/loaders') |
74 | 82 | ||
75 | d.setVar('PIXBUF_PACKAGES', ' '.join(do_split_packages(d, loaders_root, '^libpixbufloader-(.*)\.so$', 'gdk-pixbuf-loader-%s', 'GDK pixbuf loader for %s'))) | 83 | packages = ' '.join(do_split_packages(d, loaders_root, '^libpixbufloader-(.*)\.so$', 'gdk-pixbuf-loader-%s', 'GDK pixbuf loader for %s')) |
84 | d.setVar('PIXBUF_PACKAGES', packages) | ||
85 | |||
86 | # The test suite exercises all the loaders, so ensure they are all | ||
87 | # dependencies of the ptest package. | ||
88 | d.appendVar("RDEPENDS_gdk-pixbuf-ptest", " " + packages) | ||
76 | } | 89 | } |
77 | 90 | ||
78 | do_install_append_class-native() { | 91 | do_install_append_class-native() { |