summaryrefslogtreecommitdiff
blob: 215128283f3535ee4aa3758dc5306a14b62abd4b (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
--- configure.ac.orig	2010-04-20 20:29:01.136283062 +0200
+++ configure.ac	2010-04-20 20:29:45.884283632 +0200
@@ -455,11 +455,11 @@
   for flag in "pthreads" "pthread"; do
     if test "x$checkpthread" = "xyes"; then
       AC_MSG_CHECKING([for pthread_create with -$flag])
-      OLDFLAGS="$LDFLAGS"
-      LDFLAGS="-$flag $LDFLAGS"
-      AC_TRY_LINK([], [pthread_create();], 
+       OLDLIBS="$LIBS"
+       LIBS="$LIBS -l$flag"
+       AC_TRY_LINK([], [pthread_create();], 
                       [pthflag=yes; checkpthread=no], 
-                      [pthflag=no; LDFLAGS="$OLDFLAGS"])
+                      [pthflag=no; LIBS="$OLDLIBS"])
       AC_MSG_RESULT($pthflag)
     fi
   done