summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorKhem Raj <raj.khem@gmail.com>2011-05-18 18:37:59 -0700
committerRichard Purdie <richard.purdie@linuxfoundation.org>2011-05-20 12:40:45 +0100
commitc166eb1ada5739f4a38f664cae5c983e8b0c43e8 (patch)
treecc83fb6adb8aaa0c501969517aac00d7896380c5
parent7576968a0eebb1fef2b78f41026a7c83a56ffd32 (diff)
downloadpoky-c166eb1ada5739f4a38f664cae5c983e8b0c43e8.tar.gz
nfs-utils_1.2.3.bb: Fix compile failure on uclibc
libio.h is not needed even in case of eglibc but still the patch is uclibc specific Refreshed nfs-utils-1.0.6-uclibc.patch against nfs-utils_1.2.3 no code change (From OE-Core rev: 36e40db9e779b7c0319f1f14aa2cd979cf1de723) Signed-off-by: Khem Raj <raj.khem@gmail.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
-rw-r--r--meta/recipes-connectivity/nfs-utils/nfs-utils/nfs-utils-1.0.6-uclibc.patch16
-rw-r--r--meta/recipes-connectivity/nfs-utils/nfs-utils/nfs-utils-1.2.3-uclibc-libio.h.patch26
-rw-r--r--meta/recipes-connectivity/nfs-utils/nfs-utils_1.2.3.bb1
3 files changed, 36 insertions, 7 deletions
diff --git a/meta/recipes-connectivity/nfs-utils/nfs-utils/nfs-utils-1.0.6-uclibc.patch b/meta/recipes-connectivity/nfs-utils/nfs-utils/nfs-utils-1.0.6-uclibc.patch
index e82480a072..6d46d3a591 100644
--- a/meta/recipes-connectivity/nfs-utils/nfs-utils/nfs-utils-1.0.6-uclibc.patch
+++ b/meta/recipes-connectivity/nfs-utils/nfs-utils/nfs-utils-1.0.6-uclibc.patch
@@ -1,20 +1,22 @@
1Upstream-Status: Inappropriate [embedded specific] 1Upstream-Status: Inappropriate [embedded specific]
2 2
3--- ./support/nfs/svc_socket.c.orig 2004-12-12 06:43:52.000000000 +0000 3Index: nfs-utils-1.2.3/support/nfs/svc_socket.c
4+++ ./support/nfs/svc_socket.c 2004-12-12 06:50:04.000000000 +0000 4===================================================================
5@@ -66,6 +66,7 @@ 5--- nfs-utils-1.2.3.orig/support/nfs/svc_socket.c
6 memset ((char *) &addr, sizeof (addr)); 6+++ nfs-utils-1.2.3/support/nfs/svc_socket.c
7@@ -67,6 +67,7 @@ svc_socket (u_long number, int type, int
8 memset (&addr, 0, sizeof (addr));
7 addr.sin_family = AF_INET; 9 addr.sin_family = AF_INET;
8 10
9+#ifndef __UCLIBC__ /* neither getrpcbynumber() nor getrpcbynumber_r() is SuSv3 */ 11+#ifndef __UCLIBC__ /* neither getrpcbynumber() nor getrpcbynumber_r() is SuSv3 */
10 ret = getrpcbynumber_r (number, &rpcbuf, rpcdata, sizeof rpcdata, 12 ret = getrpcbynumber_r (number, &rpcbuf, rpcdata, sizeof rpcdata,
11 &rpcp); 13 &rpcp);
12 if (ret == 0 && rpcp != NULL) 14 if (ret == 0 && rpcp != NULL)
13@@ -99,6 +100,7 @@ 15@@ -100,6 +101,7 @@ svc_socket (u_long number, int type, int
14 } 16 }
15 } 17 }
16 else 18 else
17+#endif 19+#endif
18 { 20 {
19 if (bindresvport (sock, &addr)) 21 addr.sin_port = 0;
20 { 22 if (bind (sock, (struct sockaddr *) &addr, len) < 0)
diff --git a/meta/recipes-connectivity/nfs-utils/nfs-utils/nfs-utils-1.2.3-uclibc-libio.h.patch b/meta/recipes-connectivity/nfs-utils/nfs-utils/nfs-utils-1.2.3-uclibc-libio.h.patch
new file mode 100644
index 0000000000..465144a322
--- /dev/null
+++ b/meta/recipes-connectivity/nfs-utils/nfs-utils/nfs-utils-1.2.3-uclibc-libio.h.patch
@@ -0,0 +1,26 @@
1[PATCH] fix build with uClibc
2
3uClibc doesn't have/need libio.h, so don't include it from sockaddr.h
4
5Signed-off-by: Peter Korsgaard <jacmet@sunsite.dk>
6---
7 support/include/sockaddr.h | 5 ++++-
8 1 file changed, 4 insertions(+), 1 deletion(-)
9
10Upstream-Status: Pending
11
12Index: nfs-utils-1.2.3/support/include/sockaddr.h
13===================================================================
14--- nfs-utils-1.2.3.orig/support/include/sockaddr.h
15+++ nfs-utils-1.2.3/support/include/sockaddr.h
16@@ -20,7 +20,10 @@
17 #ifndef NFS_UTILS_SOCKADDR_H
18 #define NFS_UTILS_SOCKADDR_H
19
20+/* uClibc doesn't have/need libio.h */
21+#ifndef __UCLIBC__
22 #include <libio.h>
23+#endif
24 #include <stdbool.h>
25 #include <sys/socket.h>
26 #include <netinet/in.h>
diff --git a/meta/recipes-connectivity/nfs-utils/nfs-utils_1.2.3.bb b/meta/recipes-connectivity/nfs-utils/nfs-utils_1.2.3.bb
index b456474f9c..d344f3dd83 100644
--- a/meta/recipes-connectivity/nfs-utils/nfs-utils_1.2.3.bb
+++ b/meta/recipes-connectivity/nfs-utils/nfs-utils_1.2.3.bb
@@ -17,6 +17,7 @@ PR = "r2"
17 17
18SRC_URI = "${SOURCEFORGE_MIRROR}/nfs/nfs-utils-${PV}.tar.bz2 \ 18SRC_URI = "${SOURCEFORGE_MIRROR}/nfs/nfs-utils-${PV}.tar.bz2 \
19 file://nfs-utils-1.0.6-uclibc.patch \ 19 file://nfs-utils-1.0.6-uclibc.patch \
20 file://nfs-utils-1.2.3-uclibc-libio.h.patch \
20 file://nfsserver" 21 file://nfsserver"
21 22
22SRC_URI[md5sum] = "1131dc5f27c4f3905a6e7ee0d594fd4d" 23SRC_URI[md5sum] = "1131dc5f27c4f3905a6e7ee0d594fd4d"