All of lore.kernel.org
 help / color / mirror / Atom feed
From: Graham Gower <graham.gower@gmail.com>
To: openembedded-devel@lists.openembedded.org
Subject: [PATCH] glib-2.0_2.24.1.bb: Fix build when DISTRO_FEATURES lacks ipv6.
Date: Mon, 29 Nov 2010 15:04:26 +1030	[thread overview]
Message-ID: <4CF32D52.1000901@gmail.com> (raw)


mipsel-oe-linux-uclibc-libtool: link: mipsel-oe-linux-uclibc-gcc -march=mips32 -isystem/mnt/oe/tmp/sysroots/mipsel-oe-linux-uclibc/include -fexpensive-optimizations -fomit-frame-pointer -frename-registers -Os -Wall -Wl,-rpath-link -Wl,/mnt/oe/tmp/sysroots/mipsel-oe-linux-uclibc/lib -Wl,-O1 -o .libs/gio-querymodules gio-querymodules.o  -L/mnt/oe/tmp/sysroots/mipsel-oe-linux-uclibc/lib ../glib/.libs/libglib-2.0.so ../gobject/.libs/libgobject-2.0.so ../gmodule/.libs/libgmodule-2.0.so ./.libs/libgio-2.0.so /mnt/oe/tmp/work/mipsel-oe-linux-uclibc/glib-2.0-2.24.1-r2/glib-2.24.1/gobject/.libs/libgobject-2.0.so /mnt/oe/tmp/work/mipsel-oe-linux-uclibc/glib-2.0-2.24.1-r2/glib-2.24.1/gthread/.libs/libgthread-2.0.so -lpthread /mnt/oe/tmp/work/mipsel-oe-linux-uclibc/glib-2.0-2.24.1-r2/glib-2.24.1/gmodule/.libs/libgmodule-2.0.so -ldl /mnt/oe/tmp/work/mipsel-oe-linux-uclibc/glib-2.0-2.24.1-r2/glib-2.24.1/glib/.libs/libglib-2.0.so /mnt/oe/tmp/sysroots/mipsel-oe-linux-uclibc/lib/libz.so /mnt/
oe/tmp/sysroots/mipsel-oe-linux-uclibc/lib/libintl.so /mnt/oe/tmp/sysroots/mipsel-oe-linux-uclibc/lib/libiconv.so -lc
../glib/.libs/libglib-2.0.so: warning: the use of OBSOLESCENT `utime' is discouraged, use `utimes'
./.libs/libgio-2.0.so: undefined reference to `in6addr_loopback'
./.libs/libgio-2.0.so: undefined reference to `in6addr_any'
collect2: ld returned 1 exit status
make[4]: *** [gio-querymodules] Error 1

Signed-off-by: Graham Gower <graham.gower@gmail.com>
---
 .../glib-2.0/glib-2.0-2.24.1/disable-ipv6.patch    |   26 ++++++++++++++++++++
 recipes/glib-2.0/glib-2.0_2.24.1.bb                |    4 +++
 2 files changed, 30 insertions(+), 0 deletions(-)
 create mode 100644 recipes/glib-2.0/glib-2.0-2.24.1/disable-ipv6.patch

diff --git a/recipes/glib-2.0/glib-2.0-2.24.1/disable-ipv6.patch b/recipes/glib-2.0/glib-2.0-2.24.1/disable-ipv6.patch
new file mode 100644
index 0000000..9e7951b
--- /dev/null
+++ b/recipes/glib-2.0/glib-2.0-2.24.1/disable-ipv6.patch
@@ -0,0 +1,26 @@
+--- glib-2.24.1/gio/ginetaddress.c.orig	2010-11-29 14:54:17.000000000 +1030
++++ glib-2.24.1/gio/ginetaddress.c	2010-11-29 14:55:03.000000000 +1030
+@@ -485,7 +485,11 @@
+       return g_inet_address_new_from_bytes (addr, family);
+     }
+   else
++#ifdef DISABLE_IPV6
++    return NULL;
++#else
+     return g_inet_address_new_from_bytes (in6addr_loopback.s6_addr, family);
++#endif
+ }
+ 
+ /**
+@@ -512,7 +516,11 @@
+       return g_inet_address_new_from_bytes (addr, family);
+     }
+   else
++#ifdef DISABLE_IPV6
++    return NULL;
++#else
+     return g_inet_address_new_from_bytes (in6addr_any.s6_addr, family);
++#endif
+ }
+ 
+ 
diff --git a/recipes/glib-2.0/glib-2.0_2.24.1.bb b/recipes/glib-2.0/glib-2.0_2.24.1.bb
index 401212d..b150a3f 100644
--- a/recipes/glib-2.0/glib-2.0_2.24.1.bb
+++ b/recipes/glib-2.0/glib-2.0_2.24.1.bb
@@ -21,8 +21,12 @@ SRC_URI = "\
   file://gio.patch \
   file://60_wait-longer-for-threads-to-die.patch \
   file://glib-mkenums-interpreter.patch \
+  file://disable-ipv6.patch \
 "
 
+noipv6 = "${@base_contains('DISTRO_FEATURES', 'ipv6', '', '-DDISABLE_IPV6', d)}"
+EXTRA_OEMAKE_append = "'CFLAGS=${CFLAGS} ${noipv6}'"
+
 SRC_URI[archive.md5sum] = "6a7db81c9a2cffe6a34dadb57d7ba2d2"
 SRC_URI[archive.sha256sum] = "014c3da960bf17117371075c16495f05f36501db990851ceea658f15d2ea6d04"
 
-- 
1.7.1




             reply	other threads:[~2010-11-29  4:35 UTC|newest]

Thread overview: 2+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2010-11-29  4:34 Graham Gower [this message]
2010-11-29 10:00 ` [PATCH] glib-2.0_2.24.1.bb: Fix build when DISTRO_FEATURES lacks ipv6 Andrea Adami

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=4CF32D52.1000901@gmail.com \
    --to=graham.gower@gmail.com \
    --cc=openembedded-devel@lists.openembedded.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.