]> git.ipfire.org Git - thirdparty/freeradius-server.git/commitdiff
Re-order LIBS <-> -lpthread
authorAlan T. DeKok <aland@freeradius.org>
Fri, 6 Apr 2012 13:17:12 +0000 (15:17 +0200)
committerAlan T. DeKok <aland@freeradius.org>
Fri, 6 Apr 2012 13:17:12 +0000 (15:17 +0200)
-lpthread MAY need other libraries.  So adding it first is a good idea.

configure
configure.in

index 1a845d44bde6dbf274cbf0d91dfb11aaddea09d0..19f85abfb0f4519a598f81ee15577368063a0688 100755 (executable)
--- a/configure
+++ b/configure
@@ -21024,7 +21024,7 @@ fi
 echo "${ECHO_T}$ac_cv_lib_pthread_pthread_create" >&6; }
 if test $ac_cv_lib_pthread_pthread_create = yes; then
    CFLAGS="$CFLAGS -D_REENTRANT -D_POSIX_PTHREAD_SEMANTICS"
-                  LIBS="$LIBS -lpthread"
+                  LIBS="-lpthread $LIBS"
 else
   { echo "$as_me:$LINENO: checking for pthread_create in -lc_r" >&5
 echo $ECHO_N "checking for pthread_create in -lc_r... $ECHO_C" >&6; }
index 86bf7e9c80910494602fa1afbded7f3a29d3f907..cfa63bcc721e81a0cc886b36febba08e12a18c70 100644 (file)
@@ -500,7 +500,7 @@ dnl # to do the threading properly.
 dnl #
   AC_CHECK_LIB(pthread, pthread_create,
                [ CFLAGS="$CFLAGS -D_REENTRANT -D_POSIX_PTHREAD_SEMANTICS"
-                  LIBS="$LIBS -lpthread" ],
+                  LIBS="-lpthread $LIBS" ],
                AC_CHECK_LIB(c_r, pthread_create,
                            [ CFLAGS="$CFLAGS -pthread -D_THREAD_SAFE" ],
                            [ WITH_THREADS="no" ]