Commit 98638874 authored by Daniel Salzman's avatar Daniel Salzman
Browse files

configure: fix AC_SEARCH_LIBS usage if the result is cached with value 'none required'

parent 5626aa00
......@@ -594,9 +594,10 @@ AS_IF([test "$enable_cap_ng" != "no"],[
AC_CHECK_HEADER([cap-ng.h], [
save_LIBS="$LIBS"
AC_SEARCH_LIBS([capng_apply], [cap-ng], [
enable_cap_ng=yes
cap_ng_LIBS="$ac_cv_search_capng_apply"
AS_IF([test "$ac_cv_search_capng_apply" != "none required"],
[cap_ng_LIBS="$ac_cv_search_capng_apply"], [cap_ng_LIBS=])
AC_SUBST([cap_ng_LIBS])
enable_cap_ng=yes
])
LIBS="$save_LIBS"
])
......@@ -612,7 +613,8 @@ AS_IF([test "$enable_cap_ng" = yes],
save_LIBS="$LIBS"
AC_SEARCH_LIBS([pthread_create], [pthread], [
pthread_LIBS="$ac_cv_search_pthread_create"
AS_IF([test "$ac_cv_search_pthread_create" != "none required"],
[pthread_LIBS="$ac_cv_search_pthread_create"], [pthread_LIBS=])
AC_SUBST([pthread_LIBS])
],[
AC_MSG_ERROR([pthreads not found])
......@@ -621,7 +623,8 @@ LIBS="$save_LIBS"
save_LIBS="$LIBS"
AC_SEARCH_LIBS([dlopen], [dl], [
dlopen_LIBS="$ac_cv_search_dlopen"
AS_IF([test "$ac_cv_search_dlopen" != "none required"],
[dlopen_LIBS="$ac_cv_search_dlopen"], [dlopen_LIBS=])
AC_SUBST([dlopen_LIBS])
],[
AC_MSG_ERROR([dlopen not found])
......@@ -630,7 +633,8 @@ LIBS="$save_LIBS"
save_LIBS="$LIBS"
AC_SEARCH_LIBS([pow], [m], [
math_LIBS="$ac_cv_search_pow"
AS_IF([test "$ac_cv_search_pow" != "none required"],
[math_LIBS="$ac_cv_search_pow"], [math_LIBS=])
AC_SUBST([math_LIBS])
],[
AC_MSG_ERROR([math not found])
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment