summaryrefslogtreecommitdiff
path: root/source3
diff options
context:
space:
mode:
authorStefan Metzmacher <metze@samba.org>2008-05-08 10:27:23 +0200
committerStefan Metzmacher <metze@samba.org>2008-05-16 08:51:52 +0200
commit2775d304d0e6e6350e37b503804110729133556b (patch)
treeb2fda5ffa16585696e0df50064ea4f602a043e2c /source3
parenta887473d3c9050348100d02cecc89c7fff2c8318 (diff)
downloadsamba-2775d304d0e6e6350e37b503804110729133556b.tar.gz
samba-2775d304d0e6e6350e37b503804110729133556b.tar.bz2
samba-2775d304d0e6e6350e37b503804110729133556b.zip
libreplace: include inet_ntoa.o when the system one is broken
metze (cherry picked from commit 67845d3471711d24069636d0d4032f9d53748334) (This used to be commit 734ade407ed8d5b61a831509c3efc90fc521fe1b)
Diffstat (limited to 'source3')
-rw-r--r--source3/lib/replace/libreplace_network.m45
1 files changed, 3 insertions, 2 deletions
diff --git a/source3/lib/replace/libreplace_network.m4 b/source3/lib/replace/libreplace_network.m4
index 5ff699b36a..6d10313e47 100644
--- a/source3/lib/replace/libreplace_network.m4
+++ b/source3/lib/replace/libreplace_network.m4
@@ -100,8 +100,6 @@ fi
AC_CHECK_FUNCS(socketpair,[],[LIBREPLACEOBJ="${LIBREPLACEOBJ} socketpair.o"])
-AC_CHECK_FUNCS(inet_ntoa,[],[LIBREPLACEOBJ="${LIBREPLACEOBJ} inet_ntoa.o"])
-
AC_CACHE_CHECK([for broken inet_ntoa],libreplace_cv_REPLACE_INET_NTOA,[
AC_TRY_RUN([
#include <stdio.h>
@@ -116,8 +114,11 @@ if (strcmp(inet_ntoa(ip),"18.52.86.120") &&
strcmp(inet_ntoa(ip),"120.86.52.18")) { exit(0); }
exit(1);}],
libreplace_cv_REPLACE_INET_NTOA=yes,libreplace_cv_REPLACE_INET_NTOA=no,libreplace_cv_REPLACE_INET_NTOA=cross)])
+
+AC_CHECK_FUNCS(inet_ntoa,[],[libreplace_cv_REPLACE_INET_NTOA=yes])
if test x"$libreplace_cv_REPLACE_INET_NTOA" = x"yes"; then
AC_DEFINE(REPLACE_INET_NTOA,1,[Whether inet_ntoa should be replaced])
+ LIBREPLACEOBJ="${LIBREPLACEOBJ} inet_ntoa.o"
fi
AC_CHECK_FUNCS(inet_aton,[],[LIBREPLACEOBJ="${LIBREPLACEOBJ} inet_aton.o"])