From c527fd1f14c27855a37f2e8ac5346ce8d940ced2 Mon Sep 17 00:00:00 2001 From: Tudor Florea Date: Thu, 16 Oct 2014 03:05:19 +0200 Subject: initial commit for Enea Linux 4.0-140929 Migrated from the internal git server on the daisy-enea-point-release branch Signed-off-by: Tudor Florea --- .../extending-libinstall-dependencies.patch | 42 ++ .../gdk-pixbuf/gdk-pixbuf/fatal-loader.patch | 79 ++++ .../gdk-pixbuf/gdk-pixbuf/hardcoded_libtool.patch | 33 ++ meta/recipes-gnome/gdk-pixbuf/gdk-pixbuf/run-ptest | 3 + .../gdk-pixbuf/gdk-pixbuf/tests-check.patch | 465 +++++++++++++++++++++ meta/recipes-gnome/gdk-pixbuf/gdk-pixbuf_2.30.3.bb | 105 +++++ 6 files changed, 727 insertions(+) create mode 100644 meta/recipes-gnome/gdk-pixbuf/gdk-pixbuf/extending-libinstall-dependencies.patch create mode 100644 meta/recipes-gnome/gdk-pixbuf/gdk-pixbuf/fatal-loader.patch create mode 100644 meta/recipes-gnome/gdk-pixbuf/gdk-pixbuf/hardcoded_libtool.patch create mode 100644 meta/recipes-gnome/gdk-pixbuf/gdk-pixbuf/run-ptest create mode 100644 meta/recipes-gnome/gdk-pixbuf/gdk-pixbuf/tests-check.patch create mode 100644 meta/recipes-gnome/gdk-pixbuf/gdk-pixbuf_2.30.3.bb (limited to 'meta/recipes-gnome/gdk-pixbuf') diff --git a/meta/recipes-gnome/gdk-pixbuf/gdk-pixbuf/extending-libinstall-dependencies.patch b/meta/recipes-gnome/gdk-pixbuf/gdk-pixbuf/extending-libinstall-dependencies.patch new file mode 100644 index 0000000000..edbdced43a --- /dev/null +++ b/meta/recipes-gnome/gdk-pixbuf/gdk-pixbuf/extending-libinstall-dependencies.patch @@ -0,0 +1,42 @@ +Upstream-Status: Pending + +This patch fixes parallel install issue that lib libpixbufloader-png.la +depends on libgdk_pixbuf-2.0.la which will be regenerated during insta- +llation, if libgdk_pixbuf-2.0.la is regenerating and at the same time +libpixbufloader-png.la links it, the error will happen. + +Error message is: +* usr/bin/ld: cannot find -lgdk_pixbuf-2.0 +* collect2: ld returned 1 exit status + +Make an explicit dependency to the libs install targets would fix this +issue. + +Signed-off-by: Wenzong Fan +--- + gdk-pixbuf/Makefile.am | 1 + + libdeps.mk | 3 +++ + 2 files changed, 4 insertions(+), 0 deletions(-) + create mode 100644 libdeps.mk + +diff --git a/gdk-pixbuf/Makefile.am b/gdk-pixbuf/Makefile.am +index 95a93a8..db44cae 100644 +--- a/gdk-pixbuf/Makefile.am ++++ b/gdk-pixbuf/Makefile.am +@@ -783,3 +783,4 @@ loaders.cache: + endif + + -include $(top_srcdir)/git.mk ++-include $(top_srcdir)/libdeps.mk +diff --git a/libdeps.mk b/libdeps.mk +new file mode 100644 +index 0000000..d7a10a8 +--- /dev/null ++++ b/libdeps.mk +@@ -0,0 +1,3 @@ ++# Extending dependencies of install-loaderLTLIBRARIES: ++# The $(lib-LTLIBRARIES) is needed by relinking $(loader_LTLIBRARIES) ++install-loaderLTLIBRARIES: install-libLTLIBRARIES +-- +1.7.6.1 + diff --git a/meta/recipes-gnome/gdk-pixbuf/gdk-pixbuf/fatal-loader.patch b/meta/recipes-gnome/gdk-pixbuf/gdk-pixbuf/fatal-loader.patch new file mode 100644 index 0000000000..70146c6181 --- /dev/null +++ b/meta/recipes-gnome/gdk-pixbuf/gdk-pixbuf/fatal-loader.patch @@ -0,0 +1,79 @@ +If an environment variable is specified set the return value from main() to +non-zero if the loader had errors (missing libraries, generally). + +Upstream-Status: Pending +Signed-off-by: Ross Burton + +diff --git a/gdk-pixbuf/queryloaders.c b/gdk-pixbuf/queryloaders.c +index a9ca015..395674a 100644 +--- a/gdk-pixbuf/queryloaders.c ++++ b/gdk-pixbuf/queryloaders.c +@@ -146,7 +146,7 @@ write_loader_info (GString *contents, const char *path, GdkPixbufFormat *info) + g_string_append_c (contents, '\n'); + } + +-static void ++static gboolean + query_module (GString *contents, const char *dir, const char *file) + { + char *path; +@@ -155,6 +155,7 @@ query_module (GString *contents, const char *dir, const char *file) + void (*fill_vtable) (GdkPixbufModule *module); + gpointer fill_info_ptr; + gpointer fill_vtable_ptr; ++ gboolean ret = TRUE; + + if (g_path_is_absolute (file)) + path = g_strdup (file); +@@ -204,10 +205,13 @@ query_module (GString *contents, const char *dir, const char *file) + g_module_error()); + else + g_fprintf (stderr, "Cannot load loader %s\n", path); ++ ret = FALSE; + } + if (module) + g_module_close (module); + g_free (path); ++ ++ return ret; + } + + #ifdef G_OS_WIN32 +@@ -257,6 +261,7 @@ int main (int argc, char **argv) + GString *contents; + gchar *cache_file = NULL; + gint first_file = 1; ++ gboolean success = TRUE; + + #ifdef G_OS_WIN32 + gchar *libdir; +@@ -360,7 +365,8 @@ int main (int argc, char **argv) + gint len = strlen (dent); + if (len > SOEXT_LEN && + strcmp (dent + len - SOEXT_LEN, SOEXT) == 0) { +- query_module (contents, path, dent); ++ if (!query_module (contents, path, dent)) ++ success = FALSE; + } + } + g_dir_close (dir); +@@ -378,7 +384,8 @@ int main (int argc, char **argv) + infilename = g_locale_to_utf8 (infilename, + -1, NULL, NULL, NULL); + #endif +- query_module (contents, cwd, infilename); ++ if (!query_module (contents, cwd, infilename)) ++ success = FALSE; + } + g_free (cwd); + } +@@ -394,5 +401,8 @@ int main (int argc, char **argv) + else + g_print ("%s\n", contents->str); + +- return 0; ++ if (g_getenv ("GDK_PIXBUF_FATAL_LOADER")) ++ return success ? 0 : 1; ++ else ++ return 0; + } diff --git a/meta/recipes-gnome/gdk-pixbuf/gdk-pixbuf/hardcoded_libtool.patch b/meta/recipes-gnome/gdk-pixbuf/gdk-pixbuf/hardcoded_libtool.patch new file mode 100644 index 0000000000..ecca62a712 --- /dev/null +++ b/meta/recipes-gnome/gdk-pixbuf/gdk-pixbuf/hardcoded_libtool.patch @@ -0,0 +1,33 @@ +Upstream-Status: Inappropriate [configuration] + +Index: gdk-pixbuf-2.22.1/configure.ac +=================================================================== +--- gdk-pixbuf-2.22.1.orig/configure.ac 2010-11-26 09:06:34.000000000 +0800 ++++ gdk-pixbuf-2.22.1/configure.ac 2010-11-26 09:07:33.000000000 +0800 +@@ -287,7 +287,7 @@ + case $enable_explicit_deps in + auto) + export SED +- deplibs_check_method=`(./libtool --config; echo 'eval echo \"$deplibs_check_method\"') | sh` ++ deplibs_check_method=`(./$host_alias-libtool --config; echo 'eval echo \"$deplibs_check_method\"') | sh` + if test "x$deplibs_check_method" '!=' xpass_all || test "x$enable_static" = xyes ; then + enable_explicit_deps=yes + else +@@ -484,7 +484,7 @@ + dnl Now we check to see if our libtool supports shared lib deps + dnl (in a rather ugly way even) + if $dynworks; then +- pixbuf_libtool_config="${CONFIG_SHELL-/bin/sh} ./libtool --config" ++ pixbuf_libtool_config="${CONFIG_SHELL-/bin/sh} ./$host_alias-libtool --config" + pixbuf_deplibs_check=`$pixbuf_libtool_config | \ + grep '^[[a-z_]]*check[[a-z_]]*_method=[['\''"]]' | \ + sed 's/.*[['\''"]]\(.*\)[['\''"]]$/\1/'` +@@ -957,7 +957,7 @@ + # We are using gmodule-no-export now, but I'm leaving the stripping + # code in place for now, since pango and atk still require gmodule. + export SED +-export_dynamic=`(./libtool --config; echo eval echo \\$export_dynamic_flag_spec) | sh` ++export_dynamic=`(./$host_alias-libtool --config; echo eval echo \\$export_dynamic_flag_spec) | sh` + if test -n "$export_dynamic"; then + GDK_PIXBUF_DEP_LIBS=`echo $GDK_PIXBUF_DEP_LIBS | sed -e "s/$export_dynamic//"` + fi 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 @@ +#! /bin/sh + +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 @@ +Upstream-Status: Backport +Signed-off-by: Ross Burton + +From 9fa240c1ad5a815d63d8aa9126954152c2607f2e Mon Sep 17 00:00:00 2001 +From: Matthias Clasen +Date: Sat, 25 Jan 2014 21:29:34 +0000 +Subject: Make testsuite robust against disabled formats + +Skip tests if their file format is not supported by the +available loaders. + +https://bugzilla.gnome.org/show_bug.cgi?id=722651 +--- +diff --git a/tests/Makefile.am b/tests/Makefile.am +index de3442e..80840c2 100644 +--- a/tests/Makefile.am ++++ b/tests/Makefile.am +@@ -42,17 +42,57 @@ dist_installed_test_data = \ + icc-profile.png \ + $(wildcard $(srcdir)/test-images/*) + ++pixbuf_icc_SOURCES = \ ++ pixbuf-icc.c \ ++ test-common.c \ ++ test-common.h \ ++ $(NULL) ++ ++pixbuf_scale_SOURCES = \ ++ pixbuf-scale.c \ ++ test-common.c \ ++ test-common.h \ ++ $(NULL) ++ ++pixbuf_stream_SOURCES = \ ++ pixbuf-stream.c \ ++ test-common.c \ ++ test-common.h \ ++ $(NULL) ++ ++pixbuf_threads_SOURCES = \ ++ pixbuf-threads.c \ ++ test-common.c \ ++ test-common.h \ ++ $(NULL) ++ ++pixbuf_icon_serialize_SOURCES = \ ++ pixbuf-icon-serialize.c \ ++ test-common.c \ ++ test-common.h \ ++ $(NULL) ++ ++pixbuf_save_SOURCES = \ ++ pixbuf-save.c \ ++ test-common.c \ ++ test-common.h \ ++ $(NULL) ++ + pixbuf_resource_SOURCES = \ + pixbuf-resource.c \ ++ test-common.c \ ++ test-common.h \ + resources.h \ +- resources.c ++ resources.c \ ++ $(NULL) + + BUILT_SOURCES += resources.h resources.c + DISTCLEANFILES += \ + resources.h resources.c \ + pixbuf-save-options \ + pixbuf-randomly-modified-image \ +- pixbuf-save-roundtrip ++ pixbuf-save-roundtrip \ ++ $(NULL) + + EXTRA_DIST += resources.gresource.xml + TESTS_ENVIRONMENT += GDK_PIXBUF_MODULE_FILE=$(top_builddir)/gdk-pixbuf/loaders.cache +diff --git a/tests/pixbuf-icc.c b/tests/pixbuf-icc.c +index 9cb9c90..3b95b09 100644 +--- a/tests/pixbuf-icc.c ++++ b/tests/pixbuf-icc.c +@@ -22,6 +22,7 @@ + + #include "config.h" + #include "gdk-pixbuf/gdk-pixbuf.h" ++#include "test-common.h" + + static void + test_incremental (gconstpointer data) +@@ -34,7 +35,12 @@ test_incremental (gconstpointer data) + gchar *contents; + gsize size; + +- ++ if (!format_supported (filename)) ++ { ++ g_test_skip ("format not supported"); ++ return; ++ } ++ + g_file_get_contents (g_test_get_filename (G_TEST_DIST, filename, NULL), &contents, &size, &error); + g_assert_no_error (error); + +@@ -62,6 +68,12 @@ test_nonincremental (gconstpointer data) + GdkPixbuf *pixbuf; + const gchar *profile; + ++ if (!format_supported (filename)) ++ { ++ g_test_skip ("format not supported"); ++ return; ++ } ++ + pixbuf = gdk_pixbuf_new_from_file (g_test_get_filename (G_TEST_DIST, filename, NULL), &error); + g_assert_no_error (error); + +diff --git a/tests/pixbuf-icon-serialize.c b/tests/pixbuf-icon-serialize.c +index 20bf6e1..880c654 100644 +--- a/tests/pixbuf-icon-serialize.c ++++ b/tests/pixbuf-icon-serialize.c +@@ -1,5 +1,6 @@ + #include "config.h" + #include "gdk-pixbuf/gdk-pixbuf.h" ++#include "test-common.h" + #include + #include + +@@ -13,6 +14,12 @@ test_serialize (void) + GIcon *icon; + GInputStream *stream; + ++ if (!format_supported ("png")) ++ { ++ g_test_skip ("format not supported"); ++ return; ++ } ++ + pixbuf = gdk_pixbuf_new_from_file (g_test_get_filename (G_TEST_DIST, "test-image.png", NULL), &error); + g_assert_no_error (error); + g_assert (pixbuf != NULL); +diff --git a/tests/pixbuf-resource.c b/tests/pixbuf-resource.c +index a747bca..aa0bed8 100644 +--- a/tests/pixbuf-resource.c ++++ b/tests/pixbuf-resource.c +@@ -22,6 +22,7 @@ + + #include "config.h" + #include "gdk-pixbuf/gdk-pixbuf.h" ++#include "test-common.h" + #include + + #define compare_option(p1, p2, key) \ +@@ -77,6 +78,12 @@ test_resource (void) + GError *error = NULL; + GdkPixbuf *pixbuf, *ref; + ++ if (!format_supported ("png")) ++ { ++ g_test_skip ("format not supported"); ++ return; ++ } ++ + path = g_test_get_filename (G_TEST_DIST, "icc-profile.png", NULL); + ref = gdk_pixbuf_new_from_file (path, &error); + g_assert_no_error (error); +@@ -111,6 +118,12 @@ test_resource_at_scale (void) + GError *error = NULL; + GdkPixbuf *pixbuf, *ref; + ++ if (!format_supported ("png")) ++ { ++ g_test_skip ("format not supported"); ++ return; ++ } ++ + path = g_test_get_filename (G_TEST_DIST, "icc-profile.png", NULL); + ref = gdk_pixbuf_new_from_file_at_scale (path, 40, 10, FALSE, &error); + g_assert_no_error (error); +diff --git a/tests/pixbuf-save.c b/tests/pixbuf-save.c +index f7df29b..78ab288 100644 +--- a/tests/pixbuf-save.c ++++ b/tests/pixbuf-save.c +@@ -21,6 +21,7 @@ + */ + + #include "gdk-pixbuf/gdk-pixbuf.h" ++#include "test-common.h" + #include + + #define compare_option(p1, p2, key) \ +@@ -76,6 +77,12 @@ test_save_roundtrip (void) + GdkPixbuf *ref; + GdkPixbuf *pixbuf; + ++ if (!format_supported ("png")) ++ { ++ g_test_skip ("format not supported"); ++ return; ++ } ++ + ref = gdk_pixbuf_new_from_file (g_test_get_filename (G_TEST_DIST, "test-image.png", NULL), &error); + g_assert_no_error (error); + +@@ -98,6 +105,12 @@ test_save_options (void) + GdkPixbuf *pixbuf; + GError *error = NULL; + ++ if (!format_supported ("png")) ++ { ++ g_test_skip ("format not supported"); ++ return; ++ } ++ + ref = gdk_pixbuf_new (GDK_COLORSPACE_RGB, FALSE, 8, 10, 10); + gdk_pixbuf_fill (ref, 0xff00ff00); + +diff --git a/tests/pixbuf-scale.c b/tests/pixbuf-scale.c +index 4fd9fd5..d57e56a 100644 +--- a/tests/pixbuf-scale.c ++++ b/tests/pixbuf-scale.c +@@ -22,6 +22,7 @@ + + #include "config.h" + #include "gdk-pixbuf/gdk-pixbuf.h" ++#include "test-common.h" + + static void + test_scale (gconstpointer data) +@@ -33,6 +34,12 @@ test_scale (gconstpointer data) + GdkPixbuf *pixbuf; + gint width, height; + ++ if (!format_supported (filename)) ++ { ++ g_test_skip ("format not supported"); ++ return; ++ } ++ + path = g_test_get_filename (G_TEST_DIST, filename, NULL); + ref = gdk_pixbuf_new_from_file (path, &error); + g_assert_no_error (error); +diff --git a/tests/pixbuf-stream.c b/tests/pixbuf-stream.c +index 0c2cebe..d66ce3e 100644 +--- a/tests/pixbuf-stream.c ++++ b/tests/pixbuf-stream.c +@@ -22,6 +22,7 @@ + + #include "config.h" + #include "gdk-pixbuf/gdk-pixbuf.h" ++#include "test-common.h" + #include + + #define compare_option(p1, p2, key) \ +@@ -71,6 +72,12 @@ test_stream (gconstpointer data) + GFile *file; + GInputStream *stream; + ++ if (!format_supported (filename)) ++ { ++ g_test_skip ("format not supported"); ++ return; ++ } ++ + path = g_test_get_filename (G_TEST_DIST, filename, NULL); + ref = gdk_pixbuf_new_from_file (path, &error); + g_assert_no_error (error); +@@ -116,6 +123,12 @@ test_stream_async (gconstpointer data) + gsize size; + GInputStream *stream; + ++ if (!format_supported (filename)) ++ { ++ g_test_skip ("format not supported"); ++ return; ++ } ++ + path = g_test_get_filename (G_TEST_DIST, filename, NULL); + ref = gdk_pixbuf_new_from_file (path, &error); + g_assert_no_error (error); +@@ -138,6 +151,12 @@ test_stream_at_scale (gconstpointer data) + GFile *file; + GInputStream *stream; + ++ if (!format_supported (filename)) ++ { ++ g_test_skip ("format not supported"); ++ return; ++ } ++ + path = g_test_get_filename (G_TEST_DIST, filename, NULL); + ref = gdk_pixbuf_new_from_file_at_scale (path, 20, 30, TRUE, &error); + g_assert_no_error (error); +@@ -167,6 +186,12 @@ test_stream_at_scale_async (gconstpointer data) + gsize size; + GInputStream *stream; + ++ if (!format_supported (filename)) ++ { ++ g_test_skip ("format not supported"); ++ return; ++ } ++ + path = g_test_get_filename (G_TEST_DIST, filename, NULL); + ref = gdk_pixbuf_new_from_file_at_scale (path, 40, 10, FALSE, &error); + g_assert_no_error (error); +diff --git a/tests/pixbuf-threads.c b/tests/pixbuf-threads.c +index 5eeb9dd..f2694fd 100644 +--- a/tests/pixbuf-threads.c ++++ b/tests/pixbuf-threads.c +@@ -18,7 +18,9 @@ + * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307, USA. + */ + ++#include "config.h" + #include "gdk-pixbuf/gdk-pixbuf.h" ++#include "test-common.h" + + static void + load_image (gpointer data, +@@ -71,15 +73,24 @@ test_threads (void) + + for (i = 0; i < iterations; i++) + { +- g_thread_pool_push (pool, "valid_jpeg_test", NULL); +- g_thread_pool_push (pool, "valid_png_test", NULL); +- g_thread_pool_push (pool, "valid_gif_test", NULL); +- g_thread_pool_push (pool, "valid_bmp_test", NULL); +- g_thread_pool_push (pool, "valid_jpeg_progressive_test", NULL); +- g_thread_pool_push (pool, "valid_xpm_test", NULL); +- g_thread_pool_push (pool, "valid_ras_test", NULL); +- g_thread_pool_push (pool, "valid_tga_test", NULL); +- g_thread_pool_push (pool, "valid_tiff1_test", NULL); ++ if (format_supported ("jpeg")) ++ g_thread_pool_push (pool, "valid_jpeg_test", NULL); ++ if (format_supported ("png")) ++ g_thread_pool_push (pool, "valid_png_test", NULL); ++ if (format_supported ("gif")) ++ g_thread_pool_push (pool, "valid_gif_test", NULL); ++ if (format_supported ("bmp")) ++ g_thread_pool_push (pool, "valid_bmp_test", NULL); ++ if (format_supported ("jpeg")) ++ g_thread_pool_push (pool, "valid_jpeg_progressive_test", NULL); ++ if (format_supported ("xpm")) ++ g_thread_pool_push (pool, "valid_xpm_test", NULL); ++ if (format_supported ("ras")) ++ g_thread_pool_push (pool, "valid_ras_test", NULL); ++ if (format_supported ("tga")) ++ g_thread_pool_push (pool, "valid_tga_test", NULL); ++ if (format_supported ("tiff")) ++ g_thread_pool_push (pool, "valid_tiff1_test", NULL); + } + + g_thread_pool_free (pool, FALSE, TRUE); +diff --git a/tests/test-common.c b/tests/test-common.c +new file mode 100644 +index 0000000..c7673e3 +--- /dev/null ++++ b/tests/test-common.c +@@ -0,0 +1,65 @@ ++/* -*- Mode: C; c-basic-offset: 2; -*- */ ++/* GdkPixbuf library - test loaders ++ * ++ * Copyright (C) 2014 Red Hat, Inc. ++ * ++ * This program is free software; you can redistribute it and/or modify ++ * it under the terms of the GNU General Public License as published by ++ * the Free Software Foundation; either version 2 of the License, or ++ * (at your option) any later version. ++ * ++ * This program is distributed in the hope that it will be useful, ++ * but WITHOUT ANY WARRANTY; without even the implied warranty of ++ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the ++ * GNU General Public License for more details. ++ * ++ * You should have received a copy of the GNU General Public License ++ * along with this program; if not, write to the Free Software ++ * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307, USA. ++ * ++ * Author: Matthias Clasen ++ */ ++ ++#include "config.h" ++#include "test-common.h" ++#include "gdk-pixbuf/gdk-pixbuf.h" ++ ++#include ++ ++gboolean ++format_supported (const gchar *filename) ++{ ++ const gchar *name = NULL; ++ GSList *formats, *l; ++ gboolean retval; ++ const gchar *names[] = { "png", "jpeg", "bmp", "gif", "ras", ++ "tga", "xpm", "xbm" }; ++ gint i; ++ ++ for (i = 0; i < G_N_ELEMENTS (names); i++) ++ { ++ if (strstr (filename, names[i])) ++ { ++ name = names[i]; ++ break; ++ } ++ } ++ if (name == NULL) ++ return FALSE; ++ ++ retval = FALSE; ++ formats = gdk_pixbuf_get_formats (); ++ for (l = formats; l; l = l->next) ++ { ++ GdkPixbufFormat *format = l->data; ++ ++ if (g_str_equal (gdk_pixbuf_format_get_name (format), name)) ++ { ++ retval = TRUE; ++ break; ++ } ++ } ++ g_slist_free (formats); ++ ++ return retval; ++} +diff --git a/tests/test-common.h b/tests/test-common.h +new file mode 100644 +index 0000000..32ff35a +--- /dev/null ++++ b/tests/test-common.h +@@ -0,0 +1,33 @@ ++/* -*- Mode: C; c-basic-offset: 2; -*- */ ++/* GdkPixbuf library - test loaders ++ * ++ * Copyright (C) 2014 Red Hat, Inc. ++ * ++ * This program is free software; you can redistribute it and/or modify ++ * it under the terms of the GNU General Public License as published by ++ * the Free Software Foundation; either version 2 of the License, or ++ * (at your option) any later version. ++ * ++ * This program is distributed in the hope that it will be useful, ++ * but WITHOUT ANY WARRANTY; without even the implied warranty of ++ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the ++ * GNU General Public License for more details. ++ * ++ * You should have received a copy of the GNU General Public License ++ * along with this program; if not, write to the Free Software ++ * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307, USA. ++ * ++ * Author: Matthias Clasen ++ */ ++ ++#ifndef __TEST_COMMON_H__ ++ ++#include ++ ++G_BEGIN_DECLS ++ ++gboolean format_supported (const gchar *filename); ++ ++G_END_DECLS ++ ++#endif /* __TEST_COMMON_H__ */ +-- +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 new file mode 100644 index 0000000000..50e54d8eab --- /dev/null +++ b/meta/recipes-gnome/gdk-pixbuf/gdk-pixbuf_2.30.3.bb @@ -0,0 +1,105 @@ +SUMMARY = "Image loading library for GTK+" +HOMEPAGE = "http://www.gtk.org/" +BUGTRACKER = "https://bugzilla.gnome.org/" + +LICENSE = "LGPLv2" +LIC_FILES_CHKSUM = "file://COPYING;md5=3bf50002aefd002f49e7bb854063f7e7 \ + file://gdk-pixbuf/gdk-pixbuf.h;endline=26;md5=5066b71daefeff678494fffa3040aba9" + +SECTION = "libs" + +DEPENDS = "glib-2.0" +DEPENDS_append_linuxstdbase = " virtual/libx11" + +MAJ_VER = "${@oe.utils.trim_version("${PV}", 2)}" + +SRC_URI = "${GNOME_MIRROR}/${BPN}/${MAJ_VER}/${BPN}-${PV}.tar.xz \ + file://hardcoded_libtool.patch \ + file://extending-libinstall-dependencies.patch \ + file://run-ptest \ + file://tests-check.patch \ + file://fatal-loader.patch \ + " + +SRC_URI[md5sum] = "81161cc895eb43afd9ae7354b87e2261" +SRC_URI[sha256sum] = "c229c53f59573eab9410b53690a4b9db770312c80a4d84ecd6295aa894574494" + +inherit autotools pkgconfig gettext pixbufcache ptest + +LIBV = "2.10.0" + +GDK_PIXBUF_LOADERS ?= "png jpeg" + +PACKAGECONFIG ??= "${GDK_PIXBUF_LOADERS}" +PACKAGECONFIG_linuxstdbase = "${@base_contains('DISTRO_FEATURES', 'x11', 'x11', '', d)} ${GDK_PIXBUF_LOADERS}" +PACKAGECONFIG_class-native = "${GDK_PIXBUF_LOADERS}" + +PACKAGECONFIG[png] = "--with-libpng,--without-libpng,libpng" +PACKAGECONFIG[jpeg] = "--with-libjpeg,--without-libjpeg,jpeg" +PACKAGECONFIG[tiff] = "--with-libtiff,--without-libtiff,tiff" +PACKAGECONFIG[jpeg2000] = "--with-libjasper,--without-libjasper,jasper" + +# Use GIO to sniff image format instead of trying all loaders +PACKAGECONFIG[gio-sniff] = "--enable-gio-sniffing,--disable-gio-sniffing,,shared-mime-info" +PACKAGECONFIG[x11] = "--with-x11,--without-x11,virtual/libx11" + +EXTRA_OECONF = "\ + --disable-introspection \ + ${@base_contains('DISTRO_FEATURES', 'ptest', '--enable-installed-tests', '--disable-installed-tests', d)} \ +" + +PACKAGES =+ "${PN}-xlib" + +FILES_${PN}-xlib = "${libdir}/*pixbuf_xlib*${SOLIBS}" +ALLOW_EMPTY_${PN}-xlib = "1" + +FILES_${PN} = "${bindir}/gdk-pixbuf-query-loaders \ + ${bindir}/gdk-pixbuf-pixdata \ + ${libdir}/lib*.so.*" + +FILES_${PN}-dev += " \ + ${bindir}/gdk-pixbuf-csource \ + ${includedir}/* \ + ${libdir}/gdk-pixbuf-2.0/${LIBV}/loaders/*.la \ +" + +FILES_${PN}-dbg += " \ + ${libdir}/.debug/* \ + ${libdir}/gdk-pixbuf-2.0/${LIBV}/loaders/.debug/* \ +" + +FILES_${PN}-ptest += "${libdir}/gdk-pixbuf/installed-tests \ + ${datadir}/installed-tests/gdk-pixbuf" + +RDEPENDS_${PN}-ptest += "gnome-desktop-testing" + +PACKAGES_DYNAMIC += "^gdk-pixbuf-loader-.*" +PACKAGES_DYNAMIC_class-native = "" + +python populate_packages_prepend () { + postinst_pixbufloader = d.getVar("postinst_pixbufloader", True) + + loaders_root = d.expand('${libdir}/gdk-pixbuf-2.0/${LIBV}/loaders') + + packages = ' '.join(do_split_packages(d, loaders_root, '^libpixbufloader-(.*)\.so$', 'gdk-pixbuf-loader-%s', 'GDK pixbuf loader for %s')) + d.setVar('PIXBUF_PACKAGES', packages) + + # The test suite exercises all the loaders, so ensure they are all + # dependencies of the ptest package. + d.appendVar("RDEPENDS_gdk-pixbuf-ptest", " " + packages) +} + +do_install_append_class-native() { + find ${D}${libdir} -name "libpixbufloader-*.la" -exec rm \{\} \; + + create_wrapper ${D}/${bindir}/gdk-pixbuf-csource \ + GDK_PIXBUF_MODULE_FILE=${STAGING_LIBDIR_NATIVE}/gdk-pixbuf-2.0/${LIBV}/loaders.cache + + create_wrapper ${D}/${bindir}/gdk-pixbuf-pixdata \ + GDK_PIXBUF_MODULE_FILE=${STAGING_LIBDIR_NATIVE}/gdk-pixbuf-2.0/${LIBV}/loaders.cache + + create_wrapper ${D}/${bindir}/gdk-pixbuf-query-loaders \ + GDK_PIXBUF_MODULE_FILE=${STAGING_LIBDIR_NATIVE}/gdk-pixbuf-2.0/${LIBV}/loaders.cache \ + GDK_PIXBUF_MODULEDIR=${STAGING_LIBDIR_NATIVE}/gdk-pixbuf-2.0/${LIBV}/loaders +} +BBCLASSEXTEND = "native" -- cgit v1.2.3-54-g00ecf