glib2: fix build when res_nquery is not available 5810/head
authorSebastian Kemper <sebastian_ml@gmx.net>
Sat, 24 Mar 2018 08:27:29 +0000 (09:27 +0100)
committerSebastian Kemper <sebastian_ml@gmx.net>
Sat, 24 Mar 2018 08:37:28 +0000 (09:37 +0100)
commit9bc047b89db33d4db612188c23ab9b8b5e06957f
tree88923242ddeefb570862fd66781e643d8b640ccf
parent655b02a54fda5e7407f3f18c99085427aeae50ff
glib2: fix build when res_nquery is not available

Upstream commit "gio: Port GThreadedResolver to use res_nquery() to fix
thread-safety" introduced a bug that causes compile failures on
platforms where res_nquery is unavailable. This patch fixes that.

Bug 794606 has been opened upstream: https://bugzilla.gnome.org/show_bug.cgi?id=794606

On the OpenWrt buildbots this bug is visible during the arc_archs
compile:

  gthreadedresolver.c: In function 'do_lookup_records':
  gthreadedresolver.c:875:16: error: 'res' undeclared (first use in this function); did you mean '_res'?
     res_nclose (&res);
                  ^~~
                  _res
  gthreadedresolver.c:875:16: note: each undeclared identifier is reported only once for each function it appears in
  Makefile:3334: recipe for target 'libgio_2_0_la-gthreadedresolver.lo' failed
  make[8]: *** [libgio_2_0_la-gthreadedresolver.lo] Error 1

Signed-off-by: Sebastian Kemper <sebastian_ml@gmx.net>
libs/glib2/patches/002-fix-gthreadedresolver.patch [new file with mode: 0644]