Apelete Seketeli | 26 Jun 2012 23:50

[oe] [oe-classic][PATCH 0/1] openssl_1.0.0e: fix build issue for hosts without ipv6

Hello,

The openssl.inc recipe modifies the bss_dgram.c source file to inject
some ipv6 specific code, which unfortunately breaks the build of
openssl_1.0.0e on hosts that doesn't support ipv6. I modified the
recipe to test for ipv6 support before modifying the bss_dgram.c
source file.

The patch that comes as a follow-up of this message is what it's all
about, and is targeting oe-classic.

Apelete Seketeli (1):
  openssl_1.0.0e: fix build issue for hosts without ipv6

 recipes/openssl/openssl.inc |    5 ++++-
 1 file changed, 4 insertions(+), 1 deletion(-)

--

-- 
1.7.10
Apelete Seketeli | 26 Jun 2012 23:50

[oe] [oe-classic][PATCH 1/1] openssl_1.0.0e: fix build issue for hosts without ipv6

This patch fixes an issue where some ipv6 code was injected into the
bss_dgram.c regardless of the ipv6 availability of the host.
The code is now injected only if the host is ipv6 enabled.

Signed-off-by: Apelete Seketeli <apelete <at> seketeli.net>
---
 recipes/openssl/openssl.inc |    5 ++++-
 1 file changed, 4 insertions(+), 1 deletion(-)

diff --git a/recipes/openssl/openssl.inc b/recipes/openssl/openssl.inc
index 2aff24a..d45fca9 100644
--- a/recipes/openssl/openssl.inc
+++ b/recipes/openssl/openssl.inc
 <at>  <at>  -106,7 +106,10  <at>  <at>  do_configure () {
 	perl ./Configure ${EXTRA_OECONF} shared --prefix=$useprefix --openssldir=${libdir}/ssl $target

 	eval "${ <at> base_contains('DISTRO_FEATURES', 'largefile', '', 'sed -i -e
"/_FILE_OFFSET_BITS/,/#endif/d" ${S}/crypto/bio/bss_file.c', d)}"
-	eval "${ <at> base_contains('DISTRO_FEATURES', 'ipv6', '', 'sed -i -e "/AF_INET6/,/break/d"
${S}/crypto/bio/bss_dgram.c', d)}"
+	# inject ipv6 specific code if ipv6 is enabled on host
+	if [ `lsmod | grep -q ipv6; echo $?` -eq 0 ]; then
+                eval "${ <at> base_contains('DISTRO_FEATURES', 'ipv6', '', 'sed -i -e "/AF_INET6/,/break/d"
${S}/crypto/bio/bss_dgram.c', d)}"
+	fi
 }

 do_compile () {
--

-- 
1.7.10
(Continue reading)


Gmane