summaryrefslogtreecommitdiff
path: root/configure.ac
diff options
context:
space:
mode:
authorDiego 'Flameeyes' Pettenò <flameeyes@gmail.com>2007-03-10 00:57:30 +0000
committerDiego 'Flameeyes' Pettenò <flameeyes@gmail.com>2007-03-10 00:57:30 +0000
commite7b7ee301659be9bf81f0f86310fb31e8a154e60 (patch)
tree647bfec21276b87bd24f7df888cd931a54ad903b /configure.ac
parent4d2180de7a9255ae90a753922b72d7958bccd923 (diff)
downloadxine-lib-e7b7ee301659be9bf81f0f86310fb31e8a154e60.tar.gz
xine-lib-e7b7ee301659be9bf81f0f86310fb31e8a154e60.tar.bz2
When hstrerror() is found in libresolv, link it where it is used. Patch by Albert Lee.
CVS patchset: 8660 CVS date: 2007/03/10 00:57:30
Diffstat (limited to 'configure.ac')
-rw-r--r--configure.ac7
1 files changed, 6 insertions, 1 deletions
diff --git a/configure.ac b/configure.ac
index ab25ed7a4..4b85c3021 100644
--- a/configure.ac
+++ b/configure.ac
@@ -2185,9 +2185,14 @@ AC_LINK_IFELSE([#include <netdb.h>
int main(void) {
hstrerror(0);
}], ac_cv_function_system_hstrerror="yes")
-AC_CHECK_LIB([resolv], [hstrerror], [ac_cv_function_system_hstrerror="yes"])
+AC_CHECK_LIB([resolv], [hstrerror], [
+ ac_cv_function_system_hstrerror="yes"
+ NET_LIBS="-lresolv $NET_LIBS"
+])
+AC_SUBST(NET_LIBS)
if test "x$ac_cv_function_system_hstrerror" = "xyes"; then
AC_DEFINE(HAVE_HSTRERROR, 1, [Define to 1 if you have 'hstrerror' in <netdb.h>])
+
else
AC_LIBOBJ(hstrerror)
fi