summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorBjörn Stenberg <bjst@enea.com>2013-02-11 16:02:04 +0100
committerRichard Purdie <richard.purdie@linuxfoundation.org>2013-02-11 15:41:20 +0000
commitf9b894eaba94763a8ec790f8635f58b4e7e05381 (patch)
tree84df2fb2addc8ced505dbfff8e35f17e6f813aaf
parent21b6ff9bc36f5706456b3ed3ca7b6455f77a5eaa (diff)
downloadpoky-f9b894eaba94763a8ec790f8635f58b4e7e05381.tar.gz
glib-2.0: Fix ptest to build with uclibc.
Only install eglibc-specific dependencies when building for eglibc. Tweak a test case that won't build with uclibc. (From OE-Core rev: e28e04e26893416d577ee54e03019c03865e1bf6) Signed-off-by: Björn Stenberg <bjst@enea.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
-rw-r--r--meta/recipes-core/glib-2.0/glib-2.0/fix-conflicting-rand.patch35
-rw-r--r--meta/recipes-core/glib-2.0/glib-2.0_2.34.3.bb18
2 files changed, 46 insertions, 7 deletions
diff --git a/meta/recipes-core/glib-2.0/glib-2.0/fix-conflicting-rand.patch b/meta/recipes-core/glib-2.0/glib-2.0/fix-conflicting-rand.patch
new file mode 100644
index 0000000000..1571112b0e
--- /dev/null
+++ b/meta/recipes-core/glib-2.0/glib-2.0/fix-conflicting-rand.patch
@@ -0,0 +1,35 @@
1Rename 'rand' variable to avoid conflict.
2
3Upstream-Status: pending
4Signed-off-by: Björn Stenberg <bjst@enea.com>
5
6diff -u glib-2.34.3/tests/refcount/signals.c~ glib-2.34.3/tests/refcount/signals.c
7--- glib-2.34.3/tests/refcount/signals.c 2012-11-26 17:52:48.000000000 +0100
8+++ glib-2.34.3/tests/refcount/signals.c 2013-02-08 14:24:10.052477546 +0100
9@@ -9,7 +9,7 @@
10 #define MY_IS_TEST_CLASS(tclass) (G_TYPE_CHECK_CLASS_TYPE ((tclass), G_TYPE_TEST))
11 #define MY_TEST_GET_CLASS(test) (G_TYPE_INSTANCE_GET_CLASS ((test), G_TYPE_TEST, GTestClass))
12
13-static GRand *rand;
14+static GRand *grand;
15
16 typedef struct _GTest GTest;
17 typedef struct _GTestClass GTestClass;
18@@ -84,7 +84,7 @@
19 NULL
20 };
21
22- rand = g_rand_new();
23+ grand = g_rand_new();
24
25 test_type = g_type_register_static (G_TYPE_OBJECT, "GTest",
26 &test_info, 0);
27@@ -218,7 +218,7 @@
28 static void
29 my_test_do_prop (GTest * test)
30 {
31- test->value = g_rand_int (rand);
32+ test->value = g_rand_int (grand);
33 g_object_notify (G_OBJECT (test), "test-prop");
34 }
35
diff --git a/meta/recipes-core/glib-2.0/glib-2.0_2.34.3.bb b/meta/recipes-core/glib-2.0/glib-2.0_2.34.3.bb
index fe50220ea4..d58d4896c3 100644
--- a/meta/recipes-core/glib-2.0/glib-2.0_2.34.3.bb
+++ b/meta/recipes-core/glib-2.0/glib-2.0_2.34.3.bb
@@ -13,6 +13,7 @@ SRC_URI = "${GNOME_MIRROR}/glib/${SHRT_VER}/glib-${PV}.tar.xz \
13 file://configure-libtool.patch \ 13 file://configure-libtool.patch \
14 file://glib-2.0_fix_for_x32.patch \ 14 file://glib-2.0_fix_for_x32.patch \
15 file://obsolete_automake_macros.patch \ 15 file://obsolete_automake_macros.patch \
16 file://fix-conflicting-rand.patch \
16 file://Makefile-ptest.patch \ 17 file://Makefile-ptest.patch \
17 file://run-ptest \ 18 file://run-ptest \
18 " 19 "
@@ -23,6 +24,16 @@ SRC_URI_append_class-native = " file://glib-gettextize-dir.patch"
23BBCLASSEXTEND = "native nativesdk" 24BBCLASSEXTEND = "native nativesdk"
24 25
25RDEPENDS_${PN}-ptest += "\ 26RDEPENDS_${PN}-ptest += "\
27 tzdata \
28 tzdata-americas \
29 tzdata-asia \
30 tzdata-europe \
31 tzdata-posix \
32 python-pygobject \
33 python-dbus \
34 "
35
36RDEPENDS_${PN}-ptest_append_libc-glibc = "\
26 eglibc-gconv-utf-16 \ 37 eglibc-gconv-utf-16 \
27 eglibc-charmap-utf-8 \ 38 eglibc-charmap-utf-8 \
28 eglibc-gconv-cp1255 \ 39 eglibc-gconv-cp1255 \
@@ -31,13 +42,6 @@ RDEPENDS_${PN}-ptest += "\
31 eglibc-gconv-utf-7 \ 42 eglibc-gconv-utf-7 \
32 eglibc-charmap-invariant \ 43 eglibc-charmap-invariant \
33 eglibc-localedata-translit-cjk-variants \ 44 eglibc-localedata-translit-cjk-variants \
34 tzdata \
35 tzdata-americas \
36 tzdata-asia \
37 tzdata-europe \
38 tzdata-posix \
39 python-pygobject \
40 python-dbus \
41 " 45 "
42 46
43do_configure_prepend() { 47do_configure_prepend() {