libraries should be always prepended to $LIBS, never appended
This commit is contained in:
parent
3d21a8cf0b
commit
ac471d1daf
@ -735,7 +735,7 @@ AC_ARG_WITH(libwrap,
|
||||
|
||||
_libs=${LIBS}
|
||||
AC_CHECK_HEADER(tcpd.h,
|
||||
LIBS="$LIBS -lwrap"
|
||||
LIBS="-lwrap $LIBS"
|
||||
AC_MSG_CHECKING(for TCP wrappers library -lwrap)
|
||||
AC_TRY_LINK([#include <tcpd.h>
|
||||
int allow_severity = 0;
|
||||
@ -1231,7 +1231,7 @@ fi
|
||||
AC_MSG_CHECKING("named thread libs:")
|
||||
if test "$with_named_thread" != "no"
|
||||
then
|
||||
LIBS="$with_named_thread $LIBS $with_named_thread"
|
||||
LIBS="$with_named_thread $LIBS"
|
||||
with_posix_threads="yes"
|
||||
with_mit_threads="no"
|
||||
AC_MSG_RESULT("$with_named_thread")
|
||||
@ -1250,7 +1250,7 @@ else
|
||||
then
|
||||
AC_MSG_CHECKING("for pthread_create in -lpthread");
|
||||
ac_save_LIBS="$LIBS"
|
||||
LIBS="$LIBS -lpthread"
|
||||
LIBS="-lpthread $LIBS"
|
||||
AC_TRY_LINK(
|
||||
[#include <pthread.h>],
|
||||
[ (void) pthread_create((pthread_t*) 0,(pthread_attr_t*) 0, 0, 0); ],
|
||||
@ -1258,7 +1258,7 @@ else
|
||||
AC_MSG_RESULT("$with_posix_threads")
|
||||
if test "$with_posix_threads" = "no"
|
||||
then
|
||||
LIBS=" $ac_save_LIBS -lpthreads"
|
||||
LIBS=" -lpthreads $ac_save_LIBS"
|
||||
AC_MSG_CHECKING("for pthread_create in -lpthreads");
|
||||
AC_TRY_LINK(
|
||||
[#include <pthread.h>],
|
||||
|
Loading…
x
Reference in New Issue
Block a user