X-Git-Url: http://git.openwrt.org/?a=blobdiff_plain;f=package%2Futils%2Fbusybox%2Fpatches%2F230-add_nslookup_lede.patch;fp=package%2Futils%2Fbusybox%2Fpatches%2F230-add_nslookup_lede.patch;h=9e89837a9924fb405547d2f2829b41693c2aff21;hb=7ae58bebc811a0ac6734405e9bc47533939d61d7;hp=bff88a69ccc06c380194349150cf0e50e59faa79;hpb=7d4147d86908b36dd8915bfeeb1c48c2a40941a5;p=openwrt%2Fopenwrt.git diff --git a/package/utils/busybox/patches/230-add_nslookup_lede.patch b/package/utils/busybox/patches/230-add_nslookup_lede.patch index bff88a69cc..9e89837a99 100644 --- a/package/utils/busybox/patches/230-add_nslookup_lede.patch +++ b/package/utils/busybox/patches/230-add_nslookup_lede.patch @@ -12,28 +12,10 @@ and the libresolv primitives to parse received DNS responses. Signed-off-by: Jo-Philipp Wich --- - Makefile.flags | 6 + networking/nslookup_lede.c | 869 +++++++++++++++++++++++++++++++++++++++++++++ 2 files changed, 875 insertions(+) create mode 100644 networking/nslookup_lede.c -diff --git a/Makefile.flags b/Makefile.flags -index 65021de..096ab77 100644 ---- a/Makefile.flags -+++ b/Makefile.flags -@@ -134,6 +134,12 @@ else - LDLIBS += m - endif - -+# nslookup_lede might need the resolv library -+RESOLV_AVAILABLE := $(shell echo 'int main(void){res_init();return 0;}' >resolvtest.c; $(CC) $(CFLAGS) -include resolv.h -lresolv -o /dev/null resolvtest.c >/dev/null 2>&1 && echo "y"; rm resolvtest.c) -+ifeq ($(RESOLV_AVAILABLE),y) -+LDLIBS += resolv -+endif -+ - # libpam may use libpthread, libdl and/or libaudit. - # On some platforms that requires an explicit -lpthread, -ldl, -laudit. - # However, on *other platforms* it fails when some of those flags diff --git a/networking/nslookup_lede.c b/networking/nslookup_lede.c new file mode 100644 index 0000000..fe927ad