From 15581560d9f599afa22928f4fb4a558f153072e1 Mon Sep 17 00:00:00 2001 From: Mikael Hallendal Date: Sun, 26 Oct 2008 17:41:28 +0100 Subject: Patch for asyncns.c on Mac OS X Hi, The asyncns-test.c file needed the same fix but 'make check' still fails with the following error: Undefined symbols: "_res_9_dn_expand", referenced from: _main in asyncns-test.o _main in asyncns-test.o _main in asyncns-test.o ld: symbol(s) not found I haven't looked into where they are supposed to be defined though (about to run off for dinner here). Attaching small patch for async-test.c (also moved the header check into your already existing AC_CHECK_HEADERS). Cheers, Micke Signed-off-by: Lennart Poettering --- configure.ac | 4 +--- libasyncns/asyncns-test.c | 4 ++++ 2 files changed, 5 insertions(+), 3 deletions(-) diff --git a/configure.ac b/configure.ac index 868038f..f4bcf3f 100644 --- a/configure.ac +++ b/configure.ac @@ -72,7 +72,7 @@ fi # Checks for header files. AC_HEADER_STDC AC_HEADER_SYS_WAIT -AC_CHECK_HEADERS([arpa/inet.h fcntl.h netdb.h stdlib.h string.h sys/socket.h unistd.h sys/prctl.h netinet/in.h]) +AC_CHECK_HEADERS([arpa/inet.h fcntl.h netdb.h stdlib.h string.h sys/socket.h unistd.h sys/prctl.h netinet/in.h arpa/nameser_compat.h]) # Checks for typedefs, structures, and compiler characteristics. AC_C_CONST @@ -93,8 +93,6 @@ AC_CHECK_FUNCS([memset select strndup setresuid setreuid strerror]) AC_CHECK_LIB(nsl, gethostbyname) AC_CHECK_LIB(socket, connect) -AC_CHECK_HEADERS([arpa/nameser_compat.h]) - AC_CHECK_FUNC(res_query, , [AC_CHECK_LIB(resolv, res_query, [], [ save_libs="$LIBS" diff --git a/libasyncns/asyncns-test.c b/libasyncns/asyncns-test.c index 053b5bd..112cf11 100644 --- a/libasyncns/asyncns-test.c +++ b/libasyncns/asyncns-test.c @@ -34,6 +34,10 @@ #include #include +#if HAVE_ARPA_NAMESER_COMPAT_H +#include +#endif + #include "asyncns.h" int main(int argc, char *argv[]) { -- cgit