aiccu: fix uClibc build after #1389
Signed-off-by: Jo-Philipp Wich <jow@openwrt.org>
This commit is contained in:
parent
bc4d049918
commit
1208a25e71
3 changed files with 8 additions and 17 deletions
|
@ -9,7 +9,7 @@ include $(TOPDIR)/rules.mk
|
||||||
|
|
||||||
PKG_NAME:=aiccu
|
PKG_NAME:=aiccu
|
||||||
PKG_VERSION:=20070115
|
PKG_VERSION:=20070115
|
||||||
PKG_RELEASE:=13
|
PKG_RELEASE:=14
|
||||||
|
|
||||||
PKG_SOURCE:=$(PKG_NAME)_$(PKG_VERSION).tar.gz
|
PKG_SOURCE:=$(PKG_NAME)_$(PKG_VERSION).tar.gz
|
||||||
PKG_SOURCE_URL:=http://www.sixxs.net/archive/sixxs/aiccu/unix
|
PKG_SOURCE_URL:=http://www.sixxs.net/archive/sixxs/aiccu/unix
|
||||||
|
|
|
@ -5,7 +5,7 @@
|
||||||
int getrrs(const char *label, int rrtype, void gotrec(unsigned int num, int type, const char *record))
|
int getrrs(const char *label, int rrtype, void gotrec(unsigned int num, int type, const char *record))
|
||||||
{
|
{
|
||||||
-#ifdef _LINUX
|
-#ifdef _LINUX
|
||||||
+#if defined(_LINUX) && defined(__GLIBC__)
|
+#if defined(_LINUX) && defined(__GLIBC__) && !defined(__UCLIBC__)
|
||||||
struct __res_state res;
|
struct __res_state res;
|
||||||
#endif
|
#endif
|
||||||
unsigned char answer[8192];
|
unsigned char answer[8192];
|
||||||
|
@ -14,7 +14,7 @@
|
||||||
uint32_t ttl = 0;
|
uint32_t ttl = 0;
|
||||||
|
|
||||||
-#ifdef _LINUX
|
-#ifdef _LINUX
|
||||||
+#if defined(_LINUX) && defined(__GLIBC__)
|
+#if defined(_LINUX) && defined(__GLIBC__) && !defined(__UCLIBC__)
|
||||||
memset(&res, 0, sizeof(res));
|
memset(&res, 0, sizeof(res));
|
||||||
res.options = RES_DEBUG;
|
res.options = RES_DEBUG;
|
||||||
res_ninit(&res);
|
res_ninit(&res);
|
||||||
|
@ -23,18 +23,7 @@
|
||||||
|
|
||||||
memset(answer, 0, sizeof(answer));
|
memset(answer, 0, sizeof(answer));
|
||||||
-#ifdef _LINUX
|
-#ifdef _LINUX
|
||||||
+#if defined(_LINUX) && defined(__GLIBC__)
|
+#if defined(_LINUX) && defined(__GLIBC__) && !defined(__UCLIBC__)
|
||||||
ret = res_nquery(&res, label, C_IN, rrtype, answer, sizeof(answer));
|
ret = res_nquery(&res, label, C_IN, rrtype, answer, sizeof(answer));
|
||||||
#else
|
#else
|
||||||
ret = res_query(label, C_IN, rrtype, answer, sizeof(answer));
|
ret = res_query(label, C_IN, rrtype, answer, sizeof(answer));
|
||||||
--- a/common/dn_skipname.c
|
|
||||||
+++ b/common/dn_skipname.c
|
|
||||||
@@ -9,7 +9,7 @@
|
|
||||||
* return:
|
|
||||||
* 0 on success, -1 (with errno set) on failure.
|
|
||||||
*/
|
|
||||||
-int ns_name_skip(const u_char **ptrptr, const u_char *eom)
|
|
||||||
+static int ns_name_skip(const u_char **ptrptr, const u_char *eom)
|
|
||||||
{
|
|
||||||
const u_char *cp;
|
|
||||||
u_int n;
|
|
||||||
|
|
|
@ -20,10 +20,12 @@
|
||||||
#include <linux/if_tun.h>
|
#include <linux/if_tun.h>
|
||||||
--- a/common/dn_skipname.c
|
--- a/common/dn_skipname.c
|
||||||
+++ b/common/dn_skipname.c
|
+++ b/common/dn_skipname.c
|
||||||
@@ -1,5 +1,6 @@
|
@@ -1,6 +1,8 @@
|
||||||
#include <errno.h>
|
#include <errno.h>
|
||||||
#include <resolv.h>
|
#include <resolv.h>
|
||||||
+#include <sys/types.h>
|
|
||||||
|
|
||||||
|
+#include <sys/types.h>
|
||||||
|
+
|
||||||
/* Ripped from glibc 2.4 sources. */
|
/* Ripped from glibc 2.4 sources. */
|
||||||
|
|
||||||
|
/*
|
||||||
|
|
Loading…
Reference in a new issue