The cirros image was rebuilt against the 3.13.0-83 kernel, drivers e1000e, igbvf...
[packages/trusty/cirros-testvm.git] / cirros-testvm / src-cirros / buildroot-2015.05 / package / rtptools / 0001-host2ip-no-nis-on-uClibc.patch
1 host2ip.c: disable NIS support when building with uClibc
2
3 uClibc doesn't have NIS support, so simply disable the fallback.
4
5 Signed-off-by: Peter Korsgaard <peter@korsgaard.com>
6 ---
7  host2ip.c |   11 +++++++++++
8  1 file changed, 11 insertions(+)
9
10 Index: rtptools-1.20/host2ip.c
11 ===================================================================
12 --- rtptools-1.20.orig/host2ip.c
13 +++ rtptools-1.20/host2ip.c
14 @@ -3,7 +3,16 @@
15  #include <netdb.h>           /* gethostbyname() */
16  #include <netinet/in.h>      /* sockaddr_in */
17  #include <arpa/inet.h>       /* inet_addr() */
18 +
19 +#include <features.h>
20 +#ifndef __UCLIBC__
21 +#define HAVE_YP
22 +#endif
23 +
24 +#ifdef HAVE_YP
25  #include <rpcsvc/ypclnt.h>   /* YP */
26 +#endif
27 +
28  #include <string.h>          /* strlen() added by Akira 12/27/01 */ 
29  #include "sysdep.h"
30  
31 @@ -28,6 +37,7 @@
32    else if ((hep = gethostbyname(host))) {
33      in = *(struct in_addr *)(hep->h_addr_list[0]);
34    }
35 +#ifdef HAVE_YP
36    /* As a last resort, try YP. */
37    else {
38      static char *domain = 0;  /* YP domain */
39 @@ -39,5 +49,6 @@
40        in.s_addr = inet_addr(value);
41      }
42    }
43 +#endif
44    return in;
45  } /* host2ip */