summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorKhem Raj <raj.khem@gmail.com>2016-01-08 08:57:36 +0000
committerRichard Purdie <richard.purdie@linuxfoundation.org>2016-01-22 23:42:51 +0000
commit9d0fed7d3b2e70bc5d6bc2b0e1cc38166df3f0d2 (patch)
tree35a4be7b0a13bcb11c7235fb92d0a8c964db6d23
parentb16f41b43f1955331baf95ea17965332fe4556a2 (diff)
downloadopenembedded-core-9d0fed7d3b2e70bc5d6bc2b0e1cc38166df3f0d2.tar.gz
openembedded-core-9d0fed7d3b2e70bc5d6bc2b0e1cc38166df3f0d2.tar.bz2
openembedded-core-9d0fed7d3b2e70bc5d6bc2b0e1cc38166df3f0d2.zip
nspr: Drop older glibc code
This was not only getting included for libc5 but also for not-glibc libc implementations e.g. musl Signed-off-by: Khem Raj <raj.khem@gmail.com>
-rw-r--r--meta/recipes-support/nspr/nspr/0001-Remove-the-check-for-LINUX-glibc-case.patch35
-rw-r--r--meta/recipes-support/nspr/nspr_4.11.bb9
2 files changed, 44 insertions, 0 deletions
diff --git a/meta/recipes-support/nspr/nspr/0001-Remove-the-check-for-LINUX-glibc-case.patch b/meta/recipes-support/nspr/nspr/0001-Remove-the-check-for-LINUX-glibc-case.patch
new file mode 100644
index 0000000000..5b17355539
--- /dev/null
+++ b/meta/recipes-support/nspr/nspr/0001-Remove-the-check-for-LINUX-glibc-case.patch
@@ -0,0 +1,35 @@
+From 9b9c95e0390395c7e9ad24a882deb87a50846059 Mon Sep 17 00:00:00 2001
+From: Khem Raj <raj.khem@gmail.com>
+Date: Sat, 8 Aug 2015 17:10:34 -0700
+Subject: [PATCH] Remove the check for LINUX == glibc case
+
+Here it does not consider the case where musl can be an options it does
+consider the bionic case with !defined(ANDROID) but musl does not define
+and musl'ism defines like that
+
+Signed-off-by: Khem Raj <raj.khem@gmail.com>
+---
+Upstream-Status: Pending
+
+ pr/src/misc/prnetdb.c | 5 +----
+ 1 file changed, 1 insertion(+), 4 deletions(-)
+
+diff --git a/pr/src/misc/prnetdb.c b/pr/src/misc/prnetdb.c
+index b86248f..dc83a56 100644
+--- a/pr/src/misc/prnetdb.c
++++ b/pr/src/misc/prnetdb.c
+@@ -61,10 +61,7 @@ PRLock *_pr_dnsLock = NULL;
+ #define _PR_HAVE_GETPROTO_R_POINTER
+ #endif
+
+-#if defined(SOLARIS) || (defined(BSDI) && defined(_REENTRANT)) \
+- || (defined(LINUX) && defined(_REENTRANT) \
+- && !(defined(__GLIBC__) && __GLIBC__ >= 2) \
+- && !defined(ANDROID))
++#if defined(SOLARIS) || (defined(BSDI) && defined(_REENTRANT))
+ #define _PR_HAVE_GETPROTO_R
+ #define _PR_HAVE_GETPROTO_R_POINTER
+ #endif
+--
+2.1.4
+
diff --git a/meta/recipes-support/nspr/nspr_4.11.bb b/meta/recipes-support/nspr/nspr_4.11.bb
index 3048641c98..3dabcb6345 100644
--- a/meta/recipes-support/nspr/nspr_4.11.bb
+++ b/meta/recipes-support/nspr/nspr_4.11.bb
@@ -13,6 +13,15 @@ SRC_URI = "http://ftp.mozilla.org/pub/nspr/releases/v${PV}/src/nspr-${PV}.tar.gz
SRC_URI += "file://nspr.pc.in"
+CACHED_CONFIGUREVARS_append_libc-musl = " CFLAGS='${CFLAGS} -D_PR_POLL_AVAILABLE \
+ -D_PR_HAVE_OFF64_T -D_PR_INET6 -D_PR_HAVE_INET_NTOP \
+ -D_PR_HAVE_GETHOSTBYNAME2 -D_PR_HAVE_GETADDRINFO \
+ -D_PR_INET6_PROBE'"
+
+SRC_URI_append_libc-musl = "\
+ file://0001-Remove-the-check-for-LINUX-glibc-case.patch \
+ "
+
UPSTREAM_CHECK_URI = "http://ftp.mozilla.org/pub/nspr/releases/"
UPSTREAM_CHECK_REGEX = "v(?P<pver>\d+(\.\d+)+)/"