summaryrefslogtreecommitdiffstats
path: root/configure.ac
diff options
context:
space:
mode:
authorDaniel Salzman <daniel.salzman@nic.cz>2018-08-29 09:23:41 +0200
committerDaniel Salzman <daniel.salzman@nic.cz>2018-08-29 09:27:22 +0200
commitd50340f112fc3e94673bd9b278aa662a53b61c03 (patch)
tree737159b0dad4973023305a300a8b52606b205b8c /configure.ac
parentconfigure: link libcap-ng with knotd only (diff)
downloadknot-d50340f112fc3e94673bd9b278aa662a53b61c03.tar.xz
knot-d50340f112fc3e94673bd9b278aa662a53b61c03.zip
configure: link pthread and dl with knotd only
Diffstat (limited to 'configure.ac')
-rw-r--r--configure.ac22
1 files changed, 19 insertions, 3 deletions
diff --git a/configure.ac b/configure.ac
index fe18305bc..2adc51c23 100644
--- a/configure.ac
+++ b/configure.ac
@@ -559,9 +559,25 @@ AS_IF([test "$enable_cap_ng" = yes],
[AC_DEFINE([ENABLE_CAP_NG], [1], [POSIX capabilities available])]
)
-AC_SEARCH_LIBS([pow], [m])
-AC_SEARCH_LIBS([pthread_create], [pthread], [], [AC_MSG_ERROR([pthreads not found])])
-AC_SEARCH_LIBS([dlopen], [dl])
+save_LIBS="$LIBS"
+AC_SEARCH_LIBS([pthread_create], [pthread], [
+ pthread_LIBS="$ac_cv_search_pthread_create"
+ AC_SUBST([pthread_LIBS])
+],[
+ AC_MSG_ERROR([pthreads not found])
+])
+LIBS="$save_LIBS"
+
+save_LIBS="$LIBS"
+AC_SEARCH_LIBS([dlopen], [dl], [
+ dlopen_LIBS="$ac_cv_search_dlopen"
+ AC_SUBST([dlopen_LIBS])
+],[
+ AC_MSG_ERROR([dlopen not found])
+])
+LIBS="$save_LIBS"
+
+AC_SEARCH_LIBS([pow], [m], [], [AC_MSG_ERROR([math not found])])
AC_SEARCH_LIBS([clock_gettime], [rt])
# Checks for header files.